Coder Social home page Coder Social logo

Comments (3)

rauldpm avatar rauldpm commented on June 3, 2024

Thanks @TheMuntu

@mhamra, please check the RPM spec file https://github.com/wazuh/wazuh-packages/blob/4.8.0/stack/dashboard/rpm/wazuh-dashboard.spec#L105-L109 as it appears that only the wazuh plugin is changing its permissions, we need to apply those lines to the other two plugins too

Build the package locally, install it into a VM, and make sure that they have the correct permissions, also compare the Debian Wazuh dashboard, both should have the same permissions

from wazuh-packages.

mhamra avatar mhamra commented on June 3, 2024

UPDATE

RPM

I've generated the dashboard RPM package using the branch 4.8.0 script stack/dashboard/rpm/build_package.sh.

I've installed the package in a centos:7 container and reproduced the reported issue:

[root@ab66325f3384 /]# ls -l /usr/share/wazuh-dashboard/plugins/
total 40
drwxr-x--- 6 wazuh-dashboard wazuh-dashboard 4096 May  7 17:01 alertingDashboards
drwxr-x--- 8 wazuh-dashboard wazuh-dashboard 4096 May  7 17:01 customImportMapDashboards
drwxr-x--- 6 wazuh-dashboard wazuh-dashboard 4096 May  7 17:01 ganttChartDashboards
drwxr-x--- 8 wazuh-dashboard wazuh-dashboard 4096 May  7 17:01 indexManagementDashboards
drwxr-x--- 9 wazuh-dashboard wazuh-dashboard 4096 May  7 17:01 notificationsDashboards
drwxr-x--- 8 wazuh-dashboard wazuh-dashboard 4096 May  7 17:01 reportsDashboards
drwxr-x--- 7 wazuh-dashboard wazuh-dashboard 4096 May  7 17:01 securityDashboards
drwxr-x--- 7 wazuh-dashboard wazuh-dashboard 4096 May  7 17:01 wazuh
drwxr-xr-x 7 wazuh-dashboard wazuh-dashboard 4096 May  7 17:01 wazuhCheckUpdates
drwxr-xr-x 7 wazuh-dashboard wazuh-dashboard 4096 May  7 17:01 wazuhCore

After modifying the rpm specs, I've reinstalled the package in a new centos:7 container. These are the results:

[root@fcc1166bab16 /]# ls -l /usr/share/wazuh-dashboard/plugins/
total 40
drwxr-x--- 6 wazuh-dashboard wazuh-dashboard 4096 May  7 17:44 alertingDashboards
drwxr-x--- 8 wazuh-dashboard wazuh-dashboard 4096 May  7 17:44 customImportMapDashboards
drwxr-x--- 6 wazuh-dashboard wazuh-dashboard 4096 May  7 17:44 ganttChartDashboards
drwxr-x--- 8 wazuh-dashboard wazuh-dashboard 4096 May  7 17:44 indexManagementDashboards
drwxr-x--- 9 wazuh-dashboard wazuh-dashboard 4096 May  7 17:44 notificationsDashboards
drwxr-x--- 8 wazuh-dashboard wazuh-dashboard 4096 May  7 17:44 reportsDashboards
drwxr-x--- 7 wazuh-dashboard wazuh-dashboard 4096 May  7 17:44 securityDashboards
drwxr-x--- 7 wazuh-dashboard wazuh-dashboard 4096 May  7 17:44 wazuh
drwxr-x--- 7 wazuh-dashboard wazuh-dashboard 4096 May  7 17:44 wazuhCheckUpdates
drwxr-x--- 7 wazuh-dashboard wazuh-dashboard 4096 May  7 17:44 wazuhCore
[root@fcc1166bab16 /]# ls -l /usr/share/wazuh-dashboard/plugins/wazuh
total 204
drwxr-x---   6 wazuh-dashboard wazuh-dashboard   4096 May  7 17:44 common
drwxr-x--- 173 wazuh-dashboard wazuh-dashboard   4096 May  7 17:44 node_modules
-rw-r-----   1 wazuh-dashboard wazuh-dashboard    599 May  7 17:40 opensearch_dashboards.json
-rw-r-----   1 wazuh-dashboard wazuh-dashboard   3242 May  7 17:40 package.json
drwxr-x---   3 wazuh-dashboard wazuh-dashboard   4096 May  7 17:44 public
drwxr-x---   7 wazuh-dashboard wazuh-dashboard   4096 May  7 17:44 server
drwxr-x---   3 wazuh-dashboard wazuh-dashboard   4096 May  7 17:44 target
-rw-r-----   1 wazuh-dashboard wazuh-dashboard 176652 May  7 17:40 yarn.lock
[root@fcc1166bab16 /]# ls -l /usr/share/wazuh-dashboard/plugins/wazuhCore/
total 48
drwxr-x---  4 wazuh-dashboard wazuh-dashboard  4096 May  7 17:44 common
drwxr-x--- 53 wazuh-dashboard wazuh-dashboard  4096 May  7 17:44 node_modules
-rw-r-----  1 wazuh-dashboard wazuh-dashboard   254 May  7 17:40 opensearch_dashboards.json
-rw-r-----  1 wazuh-dashboard wazuh-dashboard  1039 May  7 17:40 package.json
drwxr-x---  4 wazuh-dashboard wazuh-dashboard  4096 May  7 17:44 server
drwxr-x---  3 wazuh-dashboard wazuh-dashboard  4096 May  7 17:44 target
drwxr-x---  2 wazuh-dashboard wazuh-dashboard  4096 May  7 17:44 translations
-rw-r-----  1 wazuh-dashboard wazuh-dashboard   304 May  7 17:40 tsconfig.json
-rw-r-----  1 wazuh-dashboard wazuh-dashboard 15837 May  7 17:40 yarn.lock
[root@fcc1166bab16 /]# ls -l /usr/share/wazuh-dashboard/plugins/wazuhCheckUpdates/
total 48
drwxr-x---  2 wazuh-dashboard wazuh-dashboard  4096 May  7 17:44 common
drwxr-x--- 48 wazuh-dashboard wazuh-dashboard  4096 May  7 17:44 node_modules
-rw-r-----  1 wazuh-dashboard wazuh-dashboard   312 May  7 17:40 opensearch_dashboards.json
-rw-r-----  1 wazuh-dashboard wazuh-dashboard  1037 May  7 17:40 package.json
drwxr-x---  4 wazuh-dashboard wazuh-dashboard  4096 May  7 17:44 server
drwxr-x---  3 wazuh-dashboard wazuh-dashboard  4096 May  7 17:44 target
drwxr-x---  2 wazuh-dashboard wazuh-dashboard  4096 May  7 17:44 translations
-rw-r-----  1 wazuh-dashboard wazuh-dashboard   304 May  7 17:40 tsconfig.json
-rw-r-----  1 wazuh-dashboard wazuh-dashboard 14720 May  7 17:40 yarn.lock

RPM

I've generated and installed the DEB package in an Ubuntu 22.04 container. The issue is not present in this OS. This is the result:

root@b886de28928c:/# ls -l /usr/share/wazuh-dashboard/plugins/
total 40
drwxr-x--- 6 wazuh-dashboard wazuh-dashboard 4096 May  7 20:13 alertingDashboards
drwxr-x--- 8 wazuh-dashboard wazuh-dashboard 4096 May  7 20:13 customImportMapDashboards
drwxr-x--- 6 wazuh-dashboard wazuh-dashboard 4096 May  7 20:13 ganttChartDashboards
drwxr-x--- 8 wazuh-dashboard wazuh-dashboard 4096 May  7 20:13 indexManagementDashboards
drwxr-x--- 9 wazuh-dashboard wazuh-dashboard 4096 May  7 20:13 notificationsDashboards
drwxr-x--- 8 wazuh-dashboard wazuh-dashboard 4096 May  7 20:13 reportsDashboards
drwxr-x--- 7 wazuh-dashboard wazuh-dashboard 4096 May  7 20:13 securityDashboards
drwxr-x--- 7 wazuh-dashboard wazuh-dashboard 4096 May  7 20:13 wazuh
drwxr-x--- 7 wazuh-dashboard wazuh-dashboard 4096 May  7 20:13 wazuhCheckUpdates
drwxr-x--- 7 wazuh-dashboard wazuh-dashboard 4096 May  7 20:13 wazuhCore

from wazuh-packages.

rauldpm avatar rauldpm commented on June 3, 2024

LGTM

from wazuh-packages.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.