-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Unify the vendor field of the Wazuh package for all systems #31044
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 4.13.1
Are you sure you want to change the base?
Conversation
a977245
to
88bdb06
Compare
88bdb06
to
d06c0fd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! I left one minor comment but feel free to ignore it.
@@ -40,7 +42,7 @@ namespace PackageLinuxHelper | |||
std::string groups { fields.at(RPMFields::RPM_FIELDS_GROUPS) }; | |||
std::string version { fields.at(RPMFields::RPM_FIELDS_VERSION) }; | |||
std::string architecture { fields.at(RPMFields::RPM_FIELDS_ARCHITECTURE) }; | |||
std::string vendor { fields.at(RPMFields::RPM_FIELDS_VENDOR) }; | |||
std::string publisher { fields.at(RPMFields::RPM_FIELDS_VENDOR) }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we change the RPM_FIELDS_VENDOR for RPM_FIELDS_PUBLISHER ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In general both terms refer to the same field in multiple operating systems, modify the variable name only to use vendor exclusively for the name.
On other systems Publisher, Maintainer and Vendor are used for the same field.
packages/rpms/SPECS/wazuh-agent.spec
Outdated
@@ -17,7 +17,7 @@ Group: System Environment/Daemons | |||
Source0: %{name}-%{version}.tar.gz | |||
URL: https://www.wazuh.com/ | |||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) | |||
Vendor: Wazuh, Inc <[email protected]> | |||
Vendor: Wazuh <[email protected]> | |||
Packager: Wazuh, Inc <[email protected]> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we also remove "Inc" from the Packager
field?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed Packager field to match with vendor.
Check that this change not affect Wazuh-agent package:
[root@fedora41 wazuh]# sqlite3 /var/ossec/queue/db/006.db "SELECT DISTINCT vendor FROM sys_programs;"
Fedora Project
Wazuh
@@ -13,7 +13,7 @@ Group: System Environment/Daemons | |||
Source0: %{name}-%{version}.tar.gz | |||
URL: https://www.wazuh.com/ | |||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) | |||
Vendor: Wazuh, Inc <[email protected]> | |||
Vendor: Wazuh <[email protected]> | |||
Packager: Wazuh, Inc <[email protected]> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same question here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code changes make sense. Evidences are coherent with the changes.
LGTM.
Description
In this PR we are going to unify the vendor field of the Wazuh package of all systems, as well as modify the way we extract it in some of them. We have also implemented a new vendor-email field, which will not be implemented further yet.
Testing
I used a basic 4.13.1 manager in a Fedora 41 VM. Created 4 packages with this PR branch here:
Connected to manager: