Suspicious File Immutability Set via chattr for Anti-Removal on Linux

PremiumReviewedSigma · Medium · v1
Product
linux
Category
process_creation
Author
HuntRule
Published
2026-06-13
Updated
2026-08-28

ATT&CK techniques

Persistence → Defense Evasion
  1. Recon

  2. Resource Dev

  3. Initial Access

  4. Execution

  5. Cred Access

  6. Discovery

  7. Lateral Movement

  8. Collection

  9. C2

  10. Exfiltration

  11. Impact

What it detects

This rule detects chattr setting the immutable attribute on a file, an anti-removal technique used by the PeerBlight Linux backdoor to protect its sshd-agent persistence from deletion. Making backdoor files immutable prevents defenders and admins from removing them without first clearing the attribute. Interactive chattr immutability changes on service files are uncommon and suspicious.

Related detections9 linkedT1543.002 — drag to rearrange
Malicious Koske Persistence via Systemd Service and Shell Profile Hijack (via process_creation)
Suspicious Linux CoinMiner Watchdog Staging in Shared Memory (via process_creation)
Suspicious systemd Service Persistence Creation (via process_creation)
Suspicious Shell History Clearing or Disabling (via process_creation)
Masquerading Systemd Service Masquerade via Systemctl Reenable of rsyslogd (via process_creation)
Suspicious Systemd Service Masquerading as Sysmon (via file_event)
Suspicious COLDRIVER RunMRU History Clearing via Reg Delete (via process_creation)
APT28 httd Implant Persistence via systemd linux.service from Boot Directory (via process_creation)
Malicious Keyhunter Worker Systemd Unit File Creation
Suspicious File Immutability Set via chattr for Anti-Removal on Linux
Pivot detection · T1543.002 · 9 related

Detection content is published as a reviewed draft. Tune thresholds and exclusions against your own telemetry before enabling this rule for alerting.