[cisco_asa] Fix 113015 grok to handle missing user IP. - #20691
Conversation
✅ Elastic Docs Style Checker (Vale)No issues found on modified lines! The Vale linter checks documentation changes against the Elastic Docs style guide. To use Vale locally or report issues, refer to Elastic style guide for Vale. |
|
/test |
2 similar comments
|
/test |
|
/test |
🚀 Benchmarks reportPackage
|
| Data stream | Previous EPS | New EPS | Diff (%) | Result |
|---|---|---|---|---|
log |
1050.42 | 812.35 | -238.07 (-22.66%) | 💔 |
To see the full report comment with /test benchmark fullreport
|
Pinging @elastic/integration-experience (Team:Integration-Experience) |
|
🟢 No issues across the latest commits 236af7c. Review summaryIssues found across earlier commits d5cc7b5 — 1 medium
Issues found across earlier commits 0cf1c34 — 1 high
Issues found across earlier commits 21db256 — 1 medium
🤖 AI-Generated Review | Vera Review Bot - v0.2.6 | 📚 Knowledge base: integration-skills
|
ilyannn
left a comment
There was a problem hiding this comment.
LGTM, good call on names with spaces (we even have ;;alice-johnson(test user) username in the tests)
|
Tick the box to add this pull request to the merge queue (same as
|
|
✅ All changelog entries have the correct PR link. |
💚 Build Succeeded
History
|
|
Package cisco_asa - 2.45.13 containing this change is available at https://epr.elastic.co/package/cisco_asa/2.45.13/ |
Executive summary
The grok processor for Cisco ASA message 113015 only had a pattern that required a trailing
user IP = <IP>field. When a device emits a 113015 message without a user IP (e.g., local-database auth failures), the processor failed to match and logged a MISSING_CASE error. The fix adds a second, fallback grok pattern for 113015 that captures the username via%{NOTSPACE}and terminates without requiring the IP field, allowing these events to parse successfully. The unusedUSERNAMEandCISCO_USERcustom pattern definitions that were scoped to this grok block were also removed.Proposed commit message
Root cause
The
parse_113015grok processor has only one pattern that requires a trailing: user IP = <ip>segment, but Cisco ASA omits that field when authentication originates from a local/console context with no client IP, causing the processor to fail for that valid message variant.Approach
Add a second grok pattern to the
parse_113015processor that matches the no-IP variant of the 113015 message (i.e., the message ends afteruser = <name>with no: user IP = ...suffix). The existing with-IP pattern stays first; the new no-IP pattern is appended second so grok tries the more-specific variant first. A new test event using the sanitized log line is added totest-additional-messages.logwith its expected output entry.Implementation
packages/cisco_asa/data_stream/log/elasticsearch/ingest_pipeline/default.yml, locate theparse_113015grok processor at line 464. Append a second pattern underpatterns:after the existing with-IP pattern:"AAA user authentication Rejected(%{SPACE})?: reason = %{REASON:_temp_.cisco.rejection_reason}(%{SPACE})?: local database(%{SPACE})?: [Uu]ser = %{CISCO_USER:source.user.name}". KeepREASONandCISCO_USERpattern_definitions identical to the existing block.packages/cisco_asa/data_stream/log/_dev/test/pipeline/test-additional-messages.log:<166>Jun 27 2026 10:00:24: %ASA-6-113015: AAA user authentication Rejected : reason = User was not found : local database : user = alice.johnsonpackages/cisco_asa/data_stream/log/_dev/test/pipeline/test-additional-messages.log-expected.jsonmirroring the structure of existing 113015 entries but withoutsource.address/source.ipfields, withcisco.asa.rejection_reason: "User was not found",source.user.name: "alice.johnson", and no entry inrelated.ip.packages/cisco_asa/changelog.ymlas a new version2.45.3with typebugfixand descriptionFix grok pattern for message 113015 to handle the no-IP variant where user IP is absent.elastic-package test pipelinefor the cisco_asa package to confirm the new event parses correctly and the existing 113015 with-IP events continue to pass.Pipeline changes
parse_113015grok processor (line 470):"AAA user authentication Rejected(%{SPACE})?: reason = %{REASON:_temp_.cisco.rejection_reason}(%{SPACE})?: local database(%{SPACE})?: [Uu]ser = %{CISCO_USER:source.user.name}"— placed after the existing with-IP pattern so grok tries specific first.Field / mapping changes
—
Sanitized error message
Processor 'grok' with tag 'parse_113015' in pipeline 'logs-cisco_asa.log-default' failed with message '[on_failure_message]'Sanitized log (
event_sanitizedexcerpt)<166>Jun 27 2026 10:00:24: %ASA-6-113015: AAA user authentication Rejected : reason = User was not found : local database : user = alice.johnsonReviewer concerns
%{NOTSPACE:source.user.name}rather than the more permissive%{DATA:...}used by the original pattern; if any username legitimately contains spaces this would silently mismatch and fall through, though that is extremely unlikely for AAA usernames.USERNAMEandCISCO_USERwere removed from thepattern_definitionsblock. The diff confirms neither was referenced in the original 113015 patterns (the first pattern used bare%{DATA}and%{IP}), so this is safe, but a reviewer should confirm they are not referenced anywhere else in this specific grok processor block.linkfield points to PR Initial structure #1 which is a placeholder; should be updated to the real PR number before merge.Self-review findings
—
Risk and classification
Links
83c5760ccc22127f