sudoers modified
What it detects
A change to the sudoers policy (/etc/sudoers or /etc/sudoers.d/*) — granting or modifying sudo privileges, a classic privilege-escalation-persistence move.
MITRE ATT&CK mapping
- T1548.003Abuse Elevation Control Mechanism: Sudo and Sudo Caching· Privilege Escalation
False positives and triage
Config management (Ansible/Puppet) edits sudoers legitimately. Confirm the change was expected and review the granted privileges (NOPASSWD ALL is high risk).
The rule
Declarative YAML read by the detection engine — data, never executed. Confidence 75%. Source: rules/linux/sudoers_modified.yaml, licensed under the Apache License 2.0.
id: linux.privilege.sudoers_modified
version: 1.0.0
status: stable
severity: high
confidence: 0.75
platforms: [linux]
mitre_techniques: [T1548.003]
description: |
A change to the sudoers policy (/etc/sudoers or /etc/sudoers.d/*) — granting or
modifying sudo privileges, a classic privilege-escalation-persistence move.
match:
raw_message_regex: '(?i)/etc/sudoers(\.d/[^\s\"]*|\b)|visudo\b'
false_positive_guidance: |
Config management (Ansible/Puppet) edits sudoers legitimately. Confirm the change
was expected and review the granted privileges (NOPASSWD ALL is high risk).
Related detections
Run this rule on your own logs — offline
KIROSEC runs this rule and the rest of the library over Windows, Linux, macOS and cloud audit logs on the analyst's own machine. Every alert links to the events that raised it, and nothing leaves the device.
