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

[Register Agent] Wrong macos installation command - 4.6.0 #5886

Closed
Machi3mfl opened this issue Sep 12, 2023 · 1 comment · Fixed by #5888
Closed

[Register Agent] Wrong macos installation command - 4.6.0 #5886

Machi3mfl opened this issue Sep 12, 2023 · 1 comment · Fixed by #5888
Assignees
Labels
level/task Task issue type/bug Bug issue

Comments

@Machi3mfl
Copy link
Member

Machi3mfl commented Sep 12, 2023

Wazuh Rev Browser
4.6.0 alpha1 Chrome, Firefox, Safari, etc

Description

Fix the installation command line in the register new agent page.

Captura de pantalla 2023-09-12 a la(s) 11 50 03

Steps:

  1. Go to Agents section
  2. Click Deploy new agent button
  3. Select macOS operting system and complete the form
  4. Check the installation and start commands

Current solution

curl -so wazuh-agent.pkg https://packages.wazuh.com/4.x/macos/wazuh-agent-4.6.0-1.[intel64|arm64].pkg && echo -e "WAZUH_MANAGER='0.0.0.0'\nWAZUH_AGENT_NAME='agent-name'\n" > /tmp/wazuh_envs && sudo installer -pkg ./wazuh-agent.pkg -target /

Expected

curl -so wazuh-agent.pkg https://packages.wazuh.com/4.x/macos/wazuh-agent-4.6.0-1.intel64.pkg && echo "WAZUH_MANAGER='0.0.0.0' && WAZUH_AGENT_NAME='agent-name'" > /tmp/wazuh_envs && sudo installer -pkg ./wazuh-agent.pkg -target /

Related research/tests:

@Machi3mfl Machi3mfl added type/bug Bug issue level/task Task issue labels Sep 12, 2023
@Machi3mfl Machi3mfl changed the title [Register Agent] Wrong macos installation command [Register Agent] Wrong macos installation command - 4.6.0 Sep 12, 2023
@Machi3mfl Machi3mfl self-assigned this Sep 12, 2023
@Machi3mfl Machi3mfl linked a pull request Sep 12, 2023 that will close this issue
6 tasks
@Machi3mfl Machi3mfl reopened this Sep 12, 2023
Tostti added a commit that referenced this issue Sep 13, 2023
### Description

Fix the macOS installation command
 
Closes #5886

## Evidence

## Intel (intel64)

![Captura de pantalla 2023-09-12 a la(s) 13 57
12](https://github.com/wazuh/wazuh-kibana-app/assets/6089438/fbdef941-d0c8-4d61-a1ec-922877132329)

![Captura de pantalla 2023-09-12 a la(s) 13 57
21](https://github.com/wazuh/wazuh-kibana-app/assets/6089438/d4c695d0-8ea2-4fc6-b6b2-7e0759aba6fa)

```bash
curl -so wazuh-agent.pkg https://packages.wazuh.com/4.x/macos/wazuh-agent-4.6.0-1.intel64.pkg && echo "WAZUH_MANAGER='0.0.0.0' && WAZUH_AGENT_NAME='agent-name'" > /tmp/wazuh_envs && sudo installer -pkg ./wazuh-agent.pkg -target /
```

### Command output 

<img width="722" alt="Captura de pantalla 2023-09-12 a la(s) 13 50 56"
src="https://github.com/wazuh/wazuh-kibana-app/assets/6089438/9f8153be-dda7-4a6e-a016-949f61a0b53e">

### ossec.conf with parameters specified

<img width="521" alt="Captura de pantalla 2023-09-12 a la(s) 13 50 35"
src="https://github.com/wazuh/wazuh-kibana-app/assets/6089438/3c7ac29a-ad67-4407-962f-cf1d03967efd">



## Apple silicon (arm64)

![Captura de pantalla 2023-09-12 a la(s) 13 57
52](https://github.com/wazuh/wazuh-kibana-app/assets/6089438/767aedd3-9611-4462-b5e7-a25390f3f057)

![Captura de pantalla 2023-09-12 a la(s) 13 58
11](https://github.com/wazuh/wazuh-kibana-app/assets/6089438/3fe3d61d-6511-41a5-be80-dcdb24713bd3)

```bash
curl -so wazuh-agent.pkg https://packages.wazuh.com/4.x/macos/wazuh-agent-4.6.0-1.arm64.pkg && echo "WAZUH_MANAGER='0.0.0.0' && WAZUH_AGENT_NAME='agent-name'" > /tmp/wazuh_envs && sudo installer -pkg ./wazuh-agent.pkg -target /
```

### Command output 

<img width="682" alt="image"
src="https://github.com/wazuh/wazuh-kibana-app/assets/6089438/e9572921-cf1b-4151-ba42-fa8e321b67d3">

### ossec.conf with parameters specified

<img width="533" alt="image"
src="https://github.com/wazuh/wazuh-kibana-app/assets/6089438/eb0d4a5a-8495-4056-bc88-a101b6eab447">



### Test

1. Go to Agents section
2. Click Deploy new agent button
3. Select macOS operting system and complete the form
4. Check the installation and start commands

### Check List
- [x] All tests pass
  - [x] `yarn test:jest`
- [x] New functionality includes testing.
- [x] New functionality has been documented.
- [x] Update [CHANGELOG.md](./../CHANGELOG.md)
- [x] Commits are signed per the DCO using --signoff
@Tostti
Copy link
Member

Tostti commented Sep 13, 2023

Fix merged

@Tostti Tostti closed this as completed Sep 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
level/task Task issue type/bug Bug issue
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants