CmdID

CmdID / Rules / Linux

Linux Package Uninstall

A Sigma rule for process creation on Linux, by Tuan Le (NCSGroup), Nasreddine Bencherchali (Nextron Systems).

low 1 ATT&CK technique 5 programs it names 3 everyday examples trip it

What it looks for

its detection, as SigmaHQ writes it
detection:
  selection_apt:
    CommandLine|contains:
      - 'remove'
      - 'purge'
    Image|endswith:
      - '/apt'
      - '/apt-get'
  selection_dpkg:
    CommandLine|contains:
      - '--remove '
      - ' -r '
    Image|endswith: '/dpkg'
  selection_rpm:
    CommandLine|contains: ' -e '
    Image|endswith: '/rpm'
  selection_yum:
    CommandLine|contains:
      - 'erase'
      - 'remove'
    Image|endswith: '/yum'
  condition: 1 of selection_*

The rule’s detection, its selections and fields in order of name. The whole rule, with its references and false positives, is on SigmaHQ, by Tuan Le (NCSGroup), Nasreddine Bencherchali (Nextron Systems), under the Detection Rule License 1.1. CmdID evaluates it on a command line alone: a test on what a command line cannot show, such as the parent process or the user, is not met.

Command lines that trip it

everyday examples from tldr-pages, CC BY 4.0, each read by CmdID

Remove a package on the page for apt-get

sudo apt-get remove packageIdentify

Remove a package on the page for dpkg

sudo dpkg --remove packageIdentify

Add the Fedora non-free packages repository on the page for dnf-install

sudo dnf [in https://mirrors.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpmIdentify

Programs and files it names

their pages here

ATT&CK

the techniques it is tagged with
T1070Indicator Removal