Skip to content
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

Repair mac deployment-agent-command #6909

Merged
merged 5 commits into from
Aug 16, 2024

Conversation

JuanGarriuz
Copy link
Member

Description

Mac deployment-agent-command adds \n into the end of the WAZUH_REGISTRATION_PASSWORD variable. This PR removes the new line.

Issues Resolved

Evidence

image

Test

To test this PR it must be tested with a real manager.

  1. In manager files > Go to /var/ossec/etc/ossec.conf
  2. Add (in auth section) <use_password>yes</use_password>
  3. Create (in /var/ossec/etc/) authd.pass file

echo "<CUSTOM_PASSWORD>" > /var/ossec/etc/authd.pass

  1. Restart manager
  2. (In dashboard) Go to Endpoints summary > Deploy new agent. Select a mac os agent deployment.
  3. Check that '\n' doesn't show in the WAZUH_REGISTRATION_PASSWORD variable in the deployment command.

Check List

  • All tests pass
    • yarn test:jest
  • New functionality includes testing.
  • New functionality has been documented.
  • Update CHANGELOG.md
  • Commits are signed per the DCO using --signoff

@JuanGarriuz JuanGarriuz linked an issue Aug 14, 2024 that may be closed by this pull request
@JuanGarriuz JuanGarriuz self-assigned this Aug 14, 2024
@chantal-kelm chantal-kelm self-requested a review August 14, 2024 11:46
chantal-kelm
chantal-kelm previously approved these changes Aug 14, 2024
Copy link
Member

@chantal-kelm chantal-kelm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CR: ✅
TEST: ✅

Captura de pantalla 2024-08-14 a la(s) 8 49 04 a  m Captura de pantalla 2024-08-14 a la(s) 8 46 02 a  m Captura de pantalla 2024-08-14 a la(s) 8 45 22 a  m

@Machi3mfl Machi3mfl self-requested a review August 14, 2024 12:57
Machi3mfl
Machi3mfl previously approved these changes Aug 14, 2024
Copy link
Member

@Machi3mfl Machi3mfl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CR: ✅
Test: ✅

Screenshot 2024-08-14 at 11 28 05 Screenshot 2024-08-14 at 11 38 47

@Desvelao Desvelao dismissed stale reviews from chantal-kelm and Machi3mfl via 6ec9a73 August 16, 2024 08:51
@Desvelao Desvelao closed this Aug 16, 2024
@Desvelao Desvelao deleted the bug/6906-fix-mac-agent-deployment-command branch August 16, 2024 08:52
@Desvelao Desvelao restored the bug/6906-fix-mac-agent-deployment-command branch August 16, 2024 08:53
@Desvelao Desvelao reopened this Aug 16, 2024
Copy link
Contributor

Wazuh Core plugin code coverage (Jest) test % values
Statements 45.96% ( 399 / 868 )
Branches 41.97% ( 157 / 374 )
Functions 44.01% ( 136 / 309 )
Lines 46.16% ( 397 / 860 )

Copy link
Contributor

Wazuh Check Updates plugin code coverage (Jest) test % values
Statements 76.44% ( 172 / 225 )
Branches 58.65% ( 61 / 104 )
Functions 61.7% ( 29 / 47 )
Lines 76.44% ( 172 / 225 )

Copy link
Contributor

Main plugin code coverage (Jest) test % values
Statements 13.65% ( 3989 / 29222 )
Branches 9.11% ( 1744 / 19140 )
Functions 13.35% ( 943 / 7062 )
Lines 13.83% ( 3886 / 28084 )

Copy link
Member

@Desvelao Desvelao left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@Desvelao Desvelao merged commit cddcd39 into 4.9.1 Aug 16, 2024
10 checks passed
@Desvelao Desvelao deleted the bug/6906-fix-mac-agent-deployment-command branch August 16, 2024 09:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Agent registration password includes \n
4 participants