Skip to main content

Wazuh

This guide explains how to integrate Wazuh with RedCarbon.

Overview​

The Wazuh integration allows RedCarbon to ingest the alerts of your Wazuh deployment. Each Wazuh alert whose rule level reaches the floor you configure becomes one RedCarbon incident.

RedCarbon reads the alerts from the Wazuh indexer, the component that stores them (port 9200 by default), with a dedicated read-only user. It never calls the Wazuh server API (port 55000) and never writes anything to Wazuh.

Prerequisites​

  • A self-hosted Wazuh 4.4 or later deployment, tested on 4.14. Wazuh 4.4 is the first release whose indexer is based on OpenSearch 2.4, which RedCarbon requires. Wazuh Cloud is not supported — see Wazuh Cloud
  • An administrator account on the Wazuh dashboard, to create the role and the user
  • Recommended: a RedCarbon Agent installed on a host that reaches the Wazuh indexer on port 9200. Without one, the indexer must be reachable from the internet with a certificate that verifies — see Reaching the indexer
  • The URL of the Wazuh indexer (e.g. https://wazuh-indexer.example.com:9200) and, optionally, of the Wazuh dashboard

Configuration​

Step 1: Create a read-only role in the Wazuh indexer​

  1. Log in to the Wazuh dashboard as an administrator.

  2. Open the ☰ menu and go to Indexer management → Security → Roles.

  3. Click Create role.

  4. Fill in the form:

    FieldValue
    NameSomething identifiable, e.g. redcarbon_readonly
    Cluster permissionscluster_composite_ops_ro
    Indexwazuh-alerts-*
    Index permissionsread
  5. Click Create.

This is all RedCarbon needs. If you later set a custom Index pattern in RedCarbon, grant read on that pattern instead.

Step 2: Create an internal user and map it to the role​

  1. In the ☰ menu, go to Indexer management → Security → Internal users.
  2. Click Create internal user.
  3. Enter a username (e.g. redcarbon) and a strong password. Leave Backend role empty.
  4. Click Create.
  5. Go back to Indexer management → Security → Roles and open the role created in Step 1.
  6. Select the Mapped users tab and click Manage mapping.
  7. Add the user you just created and click Map.

The user does not need a Wazuh server role mapping (Server management → Security → Roles mapping): RedCarbon does not use the Wazuh server API.

Install a RedCarbon Agent on a host in your network that reaches the Wazuh indexer on port 9200, following the RedCarbon Agent guide. Skip this step if an agent with that reach is already running for this customer, or if RedCarbon is to connect to the indexer directly — see Reaching the indexer.

Step 4: Configure RedCarbon​

  1. Log in to the RedCarbon Dashboard.

  2. Navigate to the customer's Integrations page.

  3. Select Wazuh.

  4. If you use an agent, enable the Agent Proxy toggle and select the agent from Step 3. Otherwise leave it off.

  5. Under Access, enter:

    FieldValue
    Indexer URLThe Wazuh indexer, e.g. https://wazuh-indexer.example.com:9200. Not the dashboard URL, not the server API on 55000
    UsernameThe internal user created in Step 2
    PasswordThat user's password
  6. Under Configuration settings, review:

    FieldMeaning
    Minimum rule levelLowest Wazuh rule level to ingest, from 0 to 16. Pre-filled with 10 on a new source. Empty or 0 ingests every stored alert. See below
    Index patternLeave empty to read wazuh-alerts-*, the Wazuh default. See below
    Dashboard URLOptional. The base URL of your Wazuh dashboard, e.g. https://wazuh-dashboard.example.com. See below
  7. Click Verify credentials to confirm the connection.

  8. Click Save.

Minimum rule level​

Every Wazuh rule has a level from 0 to 16 (16 is reserved for custom rules), and by default Wazuh stores every alert from level 3 up (log_alert_level in ossec.conf). Without a floor, RedCarbon opens a ticket for each of them: on a busy deployment that is thousands of tickets a day.

The field accepts a level from 0 to 16 and is pre-filled with 10 on a new source, so that it starts with only the alerts that matter. Each step down brings in more tickets. An empty value or 0 disables the floor and ingests every stored alert.

An incident that has been opened cannot be withdrawn. Start high and lower the floor gradually, watching the ticket volume, rather than the other way round.

To silence one noisy rule without lowering the floor for everything else, use an Ignore Rule on the path rule.id, operator Is one of, with the rule's id.

Index pattern​

Wazuh stores alerts in daily indices covered by wazuh-alerts-*, which RedCarbon uses when the field is left empty. Set it only if your deployment stores alerts under a different pattern, and grant the role from Step 1 read on that pattern.

A pattern that matches no index fails Verify credentials with an error saying so, rather than looking like a quiet source.

Dashboard URL​

When set, every incident links to its alert in the Wazuh dashboard. When empty, incidents carry no link. The link opens the alert through the dashboard's wazuh-alerts-* index pattern, so with a custom Index pattern it does not cover, the link may not open the alert. The field lives in the configuration, not with the credentials, so you can add or correct it without re-entering the password.

Reaching the indexer​

The Wazuh indexer usually runs on your own network, with a certificate signed by a certificate authority generated by the Wazuh installer.

  • Through the RedCarbon Agent (recommended). The agent connects to the indexer from inside your network, so port 9200 is never exposed to the internet. The agent does not verify the indexer's certificate, so the default self-signed Wazuh certificate works as it is.
  • Without an agent. RedCarbon connects to the indexer directly and verifies its certificate strictly. The indexer must then be reachable from the internet and serve a certificate that is issued by a certificate authority RedCarbon can trust and names the hostname in Indexer URL. The default self-signed certificate fails this check.

Wazuh Cloud​

Wazuh Cloud is not supported. Its indexer is opened only on request to Wazuh support, only to allowlisted addresses and only for GET requests, which are not enough to page through alerts; Wazuh documents no hostname for it.

What RedCarbon ingests​

One RedCarbon incident per Wazuh alert whose rule level reaches the floor. The whole alert is carried in the incident's original data, from which RedCarbon extracts entities and MITRE tags on its own side.

Incident fieldTaken from
TitleThe rule description
DescriptionRule <rule id> (level <rule level>) on <agent name>, followed by the log line the rule matched, when there is one
SeverityThe rule level — see Severity mapping
Creation, detection and update timeThe time Wazuh generated the alert
LinkThe alert in the Wazuh dashboard, when Dashboard URL is set

Not ingested: OpenSearch Alerting monitor alerts, archived events (wazuh-archives-*) and the vulnerability inventory. Vulnerability detections and resolutions already arrive as alerts.

Alert closure​

Not supported. A Wazuh alert has no status, and Wazuh offers no operation that marks one as handled. Closing a Wazuh ticket in RedCarbon works as usual but does not change anything in Wazuh.

Severity mapping​

RedCarbon follows the buckets the Wazuh dashboard uses for rule levels.

Wazuh rule levelWazuh dashboardRedCarbon Score
0–6Low10
7–11Medium40
12–14High70
15Critical90
1690
not set40

Troubleshooting​

SymptomLikely causeFix
Verification fails with 401 UnauthorizedWrong username or passwordCheck the internal user's credentials and enter them again
Verification fails with 403 and security_exceptionThe user is not mapped to the role, or the role lacks read on the index patternComplete the mapping in Step 2, and check the role's index permissions against the Index pattern
Verification fails with 404 and index_not_found_exceptionThe Index pattern matches no indexClear it to use wazuh-alerts-*, or correct it
Verification fails with a certificate errorThe source has no agent and the indexer's certificate does not verifyEnable Agent Proxy, or install a certificate that verifies — see Reaching the indexer
Verification succeeds but no incidents appearNo alert has reached the Minimum rule level yetExpected on a quiet deployment; lower the floor gradually if needed