Skip to content

Fix sudo auth parsing without TTY - #20587

Merged
stanek-michal merged 7 commits into
elastic:mainfrom
hellqvio86:fix/system-auth-sudo-no-tty
Aug 11, 2026
Merged

Fix sudo auth parsing without TTY#20587
stanek-michal merged 7 commits into
elastic:mainfrom
hellqvio86:fix/system-auth-sudo-no-tty

Conversation

@hellqvio86

@hellqvio86 hellqvio86 commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Type of change

Bug

Proposed commit message

Fix system auth sudo parsing without TTY

Sudo log messages do not always include a TTY field, particularly when
sudo is invoked non-interactively. The auth ingest pipeline now treats the
TTY section as optional while preserving the existing parsing of TTY and sudo
error messages.

The sudo error pattern excludes values beginning with TTY= so existing
messages continue to populate system.auth.sudo.tty correctly. When TTY is
absent, system.auth.sudo.tty remains absent rather than being populated with
a placeholder value.

Added a pipeline test fixture covering:

Aug 6 19:42:10 server01 sudo[18432]: alice : PWD=/home/alice ; USER=root ; COMMAND=/usr/bin/id

Checklist

  • I have reviewed tips for building integrations and this pull request is aligned with them.
  • This change affects the log-based auth data stream; no metrics data streams were changed.
  • I have added an entry to the package's changelog.yml file.
  • No Kibana assets or version constraints are

@elastic-vault-github-plugin-prod

Copy link
Copy Markdown
Contributor

Reviewers

Buildkite won't run for external contributors automatically; you need to add a comment:

  • /test : will kick off a build in Buildkite.

NOTE: https://github.com/elastic/integrations/blob/main/.buildkite/pull-requests.json contains all those details.

@hellqvio86
hellqvio86 marked this pull request as ready for review August 7, 2026 06:19
@hellqvio86
hellqvio86 requested review from a team as code owners August 7, 2026 06:19
@stanek-michal

Copy link
Copy Markdown
Contributor

/test

@elastic-vault-github-plugin-prod

Copy link
Copy Markdown
Contributor

✅ All changelog entries have the correct PR link.

@elastic-vault-github-plugin-prod

Copy link
Copy Markdown
Contributor

🚀 Benchmarks report

To see the full report comment with /test benchmark fullreport

@infra-vault-gh-plugin-prod

Copy link
Copy Markdown

💚 Build Succeeded

@stanek-michal stanek-michal left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM, good to merge, thanks!

@stanek-michal
stanek-michal merged commit 8acd913 into elastic:main Aug 11, 2026
7 of 9 checks passed
@elastic-vault-github-plugin-prod

Copy link
Copy Markdown
Contributor

Package system - 2.22.3 containing this change is available at https://epr.elastic.co/package/system/2.22.3/

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.

2 participants