Cross-source coverage

T1547.013 / ATT&CK

Boot or Logon Autostart Execution: XDG Autostart Entries

5 rules across 1 source.

From MITRE ATT&CK 19.2

Adversaries may add or modify XDG Autostart Entries to execute malicious programs or commands when a user’s desktop environment is loaded at login. XDG Autostart entries are available for any XDG-compliant Linux system. XDG Autostart entries use Desktop Entry files (.desktop) to configure the user’s desktop environment upon user login. These configuration files determine what applications launch upon user login, define associated applications to open specific file types, and define applications used to open removable media.

Adversaries may abuse this feature to establish persistence by adding a path to a malicious binary or command to the Exec directive in the .desktop configuration file. When the user’s desktop environment is loaded at user login, the .desktop files located in the XDG Autostart directories are automatically executed. System-wide Autostart entries are located in the /etc/xdg/autostart directory while the user entries are located in the ~/.config/autostart directory.

Adversaries may combine this technique with Masquerading to blend malicious Autostart entries with legitimate programs.

Platforms
Linux
Telemetry
auditd:SYSCALLauditd:EXECVElinux:osquerylinux:auth

How MITRE says to detect it DET0390

Linux Detection Strategy for T1547.013 - XDG Autostart Entries

Linux Analytic 1096

Correlation of file creation/modification of `.desktop` files within XDG autostart directories, followed by execution of processes at user login initiated by the desktop environment. Malicious entries typically include suspicious Exec paths or anomalous names and are not associated with installed packages.

  • auditd:SYSCALL creat
  • auditd:SYSCALL open
  • auditd:EXECVE Process execution via .desktop Exec path from /etc/xdg/autostart or ~/.config/autostart
  • linux:osquery Write or modify .desktop file in XDG autostart path
  • linux:auth User login event followed by unexpected process tree

elastic/detection-rules

5 rules
Detection Severity Format
Executable Bit Set for Potential Persistence Script Medium Elastic TOML
KDE AutoStart Script or Desktop File Creation Medium Elastic TOML
Network Connections Initiated Through XDG Autostart Entry Medium Elastic TOML
Pod or Container Creation with Suspicious Command-Line Medium Elastic TOML
Potential Persistence via File Modification Low Elastic TOML

Detection rules belong to the projects that publish them and remain under their own licenses. This site indexes and links to them; it claims no rights in them.