Potential Privilege Escalation via UID INT_MAX Bug Detected

Last updated 6 months ago on 2025-02-04
Created 2 years ago on 2023-07-27

About

This rule monitors for the execution of the systemd-run command by a user with a UID that is larger than the maximum allowed UID size (INT_MAX). Some older Linux versions were affected by a bug which allows user accounts with a UID greater than INT_MAX to escalate privileges by spawning a shell through systemd-run.
Tags
Domain: EndpointOS: LinuxUse Case: Threat DetectionTactic: Privilege EscalationData Source: Elastic DefendData Source: Elastic EndgameData Source: CrowdstrikeLanguage: eql
Severity
medium
Risk Score
47
MITRE ATT&CK™

Privilege Escalation (TA0004)(opens in a new tab or window)

License
Elastic License v2(opens in a new tab or window)

Definition

Rule Type
Event Correlation Rule
Integration Pack
Prebuilt Security Detection Rules
Index Patterns
endgame-*logs-crowdstrike.fdr*logs-endpoint.events.process*
Related Integrations

endpoint(opens in a new tab or window)

crowdstrike(opens in a new tab or window)

Query
process where host.os.type == "linux" and event.type == "start" and
  event.action in ("exec", "exec_event", "ProcessRollup2") and
  process.name == "systemd-run" and process.args == "-t" and process.args_count >= 3 and user.id >= "1000000000"

Install detection rules in Elastic Security

Detect Potential Privilege Escalation via UID INT_MAX Bug Detected in the Elastic Security detection engine by installing this rule into your Elastic Stack.

To setup this rule, check out the installation guide for Prebuilt Security Detection Rules(opens in a new tab or window).