Skip to content

Commit

Permalink
Merge pull request #3052 from wazuh/merge-4.10.0-into-master
Browse files Browse the repository at this point in the history
Merge 4.10.0 into master
  • Loading branch information
vikman90 authored Jul 19, 2024
2 parents ddaaabf + c49ddd3 commit 5f5d9f5
Show file tree
Hide file tree
Showing 12 changed files with 76 additions and 30 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.

- https://github.com/wazuh/wazuh-packages/releases/tag/v5.0.0

## [4.10.0]

- https://github.com/wazuh/wazuh-packages/releases/tag/v4.10.0

## [4.9.0]

- https://github.com/wazuh/wazuh-packages/releases/tag/v4.9.0
Expand Down
6 changes: 4 additions & 2 deletions aix/SPECS/wazuh-agent-aix.spec
Original file line number Diff line number Diff line change
Expand Up @@ -293,9 +293,11 @@ rm -fr %{buildroot}
%changelog
* Thu Dec 12 2024 support <[email protected]> - 5.0.0
- More info: https://documentation.wazuh.com/current/release-notes/release-5-0-0.html
* Wed Jul 10 2024 support <[email protected]> - 4.9.0
* Tue Oct 01 2024 support <[email protected]> - 4.10.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-10-0.html
* Thu Aug 15 2024 support <[email protected]> - 4.9.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-9-0.html
* Wed Jun 26 2024 support <[email protected]> - 4.8.1
* Thu Jul 18 2024 support <[email protected]> - 4.8.1
- More info: https://documentation.wazuh.com/current/release-notes/release-4-8-1.html
* Wed Jun 12 2024 support <[email protected]> - 4.8.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-8-0.html
Expand Down
10 changes: 8 additions & 2 deletions debs/SPECS/wazuh-agent/debian/changelog
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,23 @@ wazuh-agent (5.0.0-RELEASE) stable; urgency=low

-- Wazuh, Inc <[email protected]> Thu, 12 Dec 2024 00:00:00 +0000

wazuh-agent (4.10.0-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-10-0.html

-- Wazuh, Inc <[email protected]> Tue, 01 Oct 2024 00:00:00 +0000

wazuh-agent (4.9.0-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-9-0.html

-- Wazuh, Inc <[email protected]> Wed, 10 Jul 2024 00:00:00 +0000
-- Wazuh, Inc <[email protected]> Thu, 15 Aug 2024 00:00:00 +0000

wazuh-agent (4.8.1-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-8-1.html

-- Wazuh, Inc <[email protected]> Wed, 26 Jun 2024 00:00:00 +0000
-- Wazuh, Inc <[email protected]> Thu, 18 Jul 2024 00:00:00 +0000

wazuh-agent (4.8.0-RELEASE) stable; urgency=low

Expand Down
10 changes: 8 additions & 2 deletions debs/SPECS/wazuh-manager/debian/changelog
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,23 @@ wazuh-manager (5.0.0-RELEASE) stable; urgency=low

-- Wazuh, Inc <[email protected]> Thu, 12 Dec 2024 00:00:00 +0000

wazuh-manager (4.10.0-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-10-0.html

-- Wazuh, Inc <[email protected]> Tue, 01 Oct 2024 00:00:00 +0000

wazuh-manager (4.9.0-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-9-0.html

-- Wazuh, Inc <[email protected]> Wed, 10 Jul 2024 00:00:00 +0000
-- Wazuh, Inc <[email protected]> Thu, 15 Aug 2024 00:00:00 +0000

wazuh-manager (4.8.1-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-8-1.html

-- Wazuh, Inc <[email protected]> Wed, 26 Jun 2024 00:00:00 +0000
-- Wazuh, Inc <[email protected]> Thu, 18 Jul 2024 00:00:00 +0000

wazuh-manager (4.8.0-RELEASE) stable; urgency=low

Expand Down
6 changes: 4 additions & 2 deletions rpms/SPECS/wazuh-agent.spec
Original file line number Diff line number Diff line change
Expand Up @@ -642,9 +642,11 @@ rm -fr %{buildroot}
%changelog
* Thu Dec 12 2024 support <[email protected]> - 5.0.0
- More info: https://documentation.wazuh.com/current/release-notes/release-5-0-0.html
* Wed Jul 10 2024 support <[email protected]> - 4.9.0
* Tue Oct 01 2024 support <[email protected]> - 4.10.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-10-0.html
* Thu Aug 15 2024 support <[email protected]> - 4.9.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-9-0.html
* Wed Jun 26 2024 support <[email protected]> - 4.8.1
* Thu Jul 18 2024 support <[email protected]> - 4.8.1
- More info: https://documentation.wazuh.com/current/release-notes/release-4-8-1.html
* Wed Jun 12 2024 support <[email protected]> - 4.8.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-8-0.html
Expand Down
6 changes: 4 additions & 2 deletions rpms/SPECS/wazuh-manager.spec
Original file line number Diff line number Diff line change
Expand Up @@ -889,9 +889,11 @@ rm -fr %{buildroot}
%changelog
* Thu Dec 12 2024 support <[email protected]> - 5.0.0
- More info: https://documentation.wazuh.com/current/release-notes/release-5-0-0.html
* Wed Jul 10 2024 support <[email protected]> - 4.9.0
* Tue Oct 01 2024 support <[email protected]> - 4.10.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-10-0.html
* Thu Aug 15 2024 support <[email protected]> - 4.9.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-9-0.html
* Wed Jun 26 2024 support <[email protected]> - 4.8.1
* Thu Jul 18 2024 support <[email protected]> - 4.8.1
- More info: https://documentation.wazuh.com/current/release-notes/release-4-8-1.html
* Wed Jun 12 2024 support <[email protected]> - 4.8.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-8-0.html
Expand Down
10 changes: 8 additions & 2 deletions stack/dashboard/deb/debian/changelog
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,23 @@ wazuh-dashboard (5.0.0-RELEASE) stable; urgency=low

-- Wazuh, Inc <[email protected]> Thu, 12 Dec 2024 00:00:00 +0000

wazuh-dashboard (4.10.0-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-10-0.html

-- Wazuh, Inc <[email protected]> Tue, 01 Oct 2024 00:00:00 +0000

wazuh-dashboard (4.9.0-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-9-0.html

-- Wazuh, Inc <[email protected]> Wed, 10 Jul 2024 00:00:00 +0000
-- Wazuh, Inc <[email protected]> Thu, 15 Aug 2024 00:00:00 +0000

wazuh-dashboard (4.8.1-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-8-1.html

-- Wazuh, Inc <[email protected]> Wed, 26 Jun 2024 00:00:00 +0000
-- Wazuh, Inc <[email protected]> Thu, 18 Jul 2024 00:00:00 +0000

wazuh-dashboard (4.8.0-RELEASE) stable; urgency=low

Expand Down
6 changes: 4 additions & 2 deletions stack/dashboard/rpm/wazuh-dashboard.spec
Original file line number Diff line number Diff line change
Expand Up @@ -348,9 +348,11 @@ rm -fr %{buildroot}
%changelog
* Thu Dec 12 2024 support <[email protected]> - 5.0.0
- More info: https://documentation.wazuh.com/current/release-notes/release-5-0-0.html
* Wed Jul 10 2024 support <[email protected]> - 4.9.0
* Tue Oct 01 2024 support <[email protected]> - 4.10.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-10-0.html
* Thu Aug 15 2024 support <[email protected]> - 4.9.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-9-0.html
* Wed Jun 26 2024 support <[email protected]> - 4.8.1
* Thu Jul 18 2024 support <[email protected]> - 4.8.1
- More info: https://documentation.wazuh.com/current/release-notes/release-4-8-1.html
* Wed Jun 12 2024 support <[email protected]> - 4.8.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-8-0.html
Expand Down
10 changes: 8 additions & 2 deletions stack/indexer/deb/debian/changelog
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,23 @@ wazuh-indexer (5.0.0-RELEASE) stable; urgency=low

-- Wazuh, Inc <[email protected]> Thu, 12 Dec 2024 00:00:00 +0000

wazuh-indexer (4.10.0-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-10-0.html

-- Wazuh, Inc <[email protected]> Tue, 01 Oct 2024 00:00:00 +0000

wazuh-indexer (4.9.0-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-9-0.html

-- Wazuh, Inc <[email protected]> Wed, 10 Jul 2024 00:00:00 +0000
-- Wazuh, Inc <[email protected]> Thu, 15 Aug 2024 00:00:00 +0000

wazuh-indexer (4.8.1-RELEASE) stable; urgency=low

* More info: https://documentation.wazuh.com/current/release-notes/release-4-8-1.html

-- Wazuh, Inc <[email protected]> Wed, 26 Jun 2024 00:00:00 +0000
-- Wazuh, Inc <[email protected]> Thu, 18 Jul 2024 00:00:00 +0000

wazuh-indexer (4.8.0-RELEASE) stable; urgency=low

Expand Down
6 changes: 4 additions & 2 deletions stack/indexer/rpm/wazuh-indexer.spec
Original file line number Diff line number Diff line change
Expand Up @@ -683,9 +683,11 @@ rm -fr %{buildroot}
%changelog
* Thu Dec 12 2024 support <[email protected]> - 5.0.0
- More info: https://documentation.wazuh.com/current/release-notes/release-5-0-0.html
* Wed Jul 10 2024 support <[email protected]> - 4.9.0
* Tue Oct 01 2024 support <[email protected]> - 4.10.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-10-0.html
* Thu Aug 15 2024 support <[email protected]> - 4.9.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-9-0.html
* Wed Jun 26 2024 support <[email protected]> - 4.8.1
* Thu Jul 18 2024 support <[email protected]> - 4.8.1
- More info: https://documentation.wazuh.com/current/release-notes/release-4-8-1.html
* Wed Jun 12 2024 support <[email protected]> - 4.8.0
- More info: https://documentation.wazuh.com/current/release-notes/release-4-8-0.html
Expand Down
26 changes: 14 additions & 12 deletions unattended_installer/passwords_tool/passwordsFunctions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,16 +48,18 @@ function passwords_changePassword() {

if [ "${nuser}" == "admin" ] || [ -n "${changeall}" ]; then
if [ -n "${filebeat_installed}" ]; then
if filebeat keystore list | grep -q password ; then
eval "(echo ${adminpass} | filebeat keystore add password --force --stdin)" "${debug}"
else
wazuhold=$(grep "password:" /etc/filebeat/filebeat.yml )
ra=" password: "
wazuhold="${wazuhold//$ra}"
conf="$(awk '{sub("password: .*", "password: '"${adminpass}"'")}1' /etc/filebeat/filebeat.yml)"
echo "${conf}" > /etc/filebeat/filebeat.yml
file_username=$(grep "username:" /etc/filebeat/filebeat.yml | awk '{print $2}')
file_password=$(grep "password:" /etc/filebeat/filebeat.yml | awk '{print $2}')
if [ "$file_username" != "\${username}" ] || [ "$file_password" != "\${password}" ]; then
common_logger -w "The user and password configured in the filebeat.yml file will be updated and stored in Filebeat Keystore."
fi

eval "echo ${adminpass} | filebeat keystore add password --force --stdin ${debug}"
conf="$(awk '{sub("password: .*", "password: ${password}")}1' /etc/filebeat/filebeat.yml)"
echo "${conf}" > /etc/filebeat/filebeat.yml
eval "echo admin | filebeat keystore add username --force --stdin ${debug}"
conf="$(awk '{sub("username: .*", "username: ${username}")}1' /etc/filebeat/filebeat.yml)"
echo "${conf}" > /etc/filebeat/filebeat.yml
common_logger "The filebeat.yml file has been updated to use the Filebeat Keystore username and password."
passwords_restartService "filebeat"
eval "/var/ossec/bin/wazuh-keystore -f indexer -k password -v ${adminpass}"
common_logger -nl $"The new password for Filebeat is ${adminpass}"
Expand Down Expand Up @@ -222,7 +224,7 @@ function passwords_generateHash() {
common_logger -d "Generating password hashes."
for i in "${!passwords[@]}"
do
nhash=$(bash /usr/share/wazuh-indexer/plugins/opensearch-security/tools/hash.sh -p "${passwords[i]}" | grep -A 2 'issues' | tail -n 1)
nhash=$(bash /usr/share/wazuh-indexer/plugins/opensearch-security/tools/hash.sh -p "${passwords[i]}" 2>&1 | grep -A 2 'issues' | tail -n 1)
if [ "${PIPESTATUS[0]}" != 0 ]; then
common_logger -e "Hash generation failed."
if [[ $(type -t installCommon_rollBack) == "function" ]]; then
Expand All @@ -235,7 +237,7 @@ function passwords_generateHash() {
common_logger -d "Password hashes generated."
else
common_logger "Generating password hash"
hash=$(bash /usr/share/wazuh-indexer/plugins/opensearch-security/tools/hash.sh -p "${password}" | grep -A 2 'issues' | tail -n 1)
hash=$(bash /usr/share/wazuh-indexer/plugins/opensearch-security/tools/hash.sh -p "${password}" 2>&1 | grep -A 2 'issues' | tail -n 1)
if [ "${PIPESTATUS[0]}" != 0 ]; then
common_logger -e "Hash generation failed."
if [[ $(type -t installCommon_rollBack) == "function" ]]; then
Expand Down Expand Up @@ -397,7 +399,7 @@ function passwords_getNetworkHost() {
IP=$(grep -hr "^network.host:" /etc/wazuh-indexer/opensearch.yml)
NH="network.host: "
IP="${IP//$NH}"

# Remove surrounding double quotes if present
IP="${IP//\"}"

Expand Down
6 changes: 6 additions & 0 deletions unattended_installer/passwords_tool/passwordsMain.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,11 @@ function getHelp() {
echo -e ""
echo -e " -au, --admin-user <adminUser>"
echo -e " Admin user for Wazuh API, Required to change Wazuh API passwords."
echo -e " Requires -A|--api."
echo -e ""
echo -e " -ap, --admin-password <adminPassword>"
echo -e " Password for Wazuh API admin user, Required to change Wazuh API passwords."
echo -e " Requires -A|--api."
echo -e ""
echo -e " -u, --user <user>"
echo -e " Indicates the name of the user whose password will be changed."
Expand Down Expand Up @@ -217,6 +219,10 @@ function main() {
getHelp
fi

if [ -n "${adminUser}" ] && [ -n "${adminPassword}" ] && [ -z "${api}" ]; then
getHelp
fi

if [ -n "${nuser}" ]; then
if [ -n "${adminUser}" ] && [ -n "${adminPassword}" ]; then
passwords_getApiToken
Expand Down

0 comments on commit 5f5d9f5

Please sign in to comment.