Skip to content

Conversation

@manan-crest
Copy link
Contributor

What does this PR do?

  • This PR updates the pipeline for firewall attack events.

Motivation

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Add the qa/skip-qa label if the PR doesn't need to be tested during QA.
  • If you need to backport this PR to another branch, you can add the backport/<branch-name> label to the PR and it will automatically open a backport PR once this one is merged

@manan-crest manan-crest force-pushed the watchguard-pipeline-update branch from 8a17509 to 1dac143 Compare November 14, 2025 08:32
@manan-crest manan-crest marked this pull request as ready for review November 14, 2025 09:04
@manan-crest manan-crest requested a review from a team as a code owner November 14, 2025 09:04
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines 309 to +313
%{regex(".*(?= attack)"):attack_type} attack (against
%{ip:network.destination.ip} )?from %{ip:network.client.ip}
detected.( %{integer:drop_packet_count} %{regex(".*(?=
packets)"):drop_packet_type} packets dropped since last alarm.)?
parse_rule_30000161 %{regex(".*(?= from)"):attack_type} from client %{ip:network.client.ip} detected.
packets)"):drop_packet_type} packets dropped since last alarm.)?(
(%{notSpace}))?

Choose a reason for hiding this comment

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

P1 Badge Add whitespace before optional event code in grok rule

The newly added optional capture after the drop‑packet clause in matchRules does not consume the space that precedes event codes. The pattern is currently ...last alarm.)?((%{notSpace}))? so Grok expects a non‑space character immediately after the period. Messages of the form "… last alarm. (udp_flood_dos)" (as shown in the updated samples) therefore fail to match because the trailing space remains unmatched, and the whole rule fails. As a result, any attack alert that includes both drop counts and an event identifier will no longer be parsed. Insert an explicit space or \s* before the optional (%{notSpace}) so the rule accepts messages with a space before the code.

Useful? React with 👍 / 👎.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We have included the space in the actual parsing rule as ...last alarm.)?( (%{notSpace}))?, but when the pipeline is exported, the space does not appear in the .yaml file. However, the pipeline still handles the space correctly, as the test samples are being parsed properly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant