Detection rules › Sigma

Linux Crypto Mining Indicators

Status
test
Severity
high
Log source
product linux, category process_creation
Author
Florian Roth (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects command line parameters or strings often used by crypto miners

MITRE ATT&CK coverage

TacticTechniques
ImpactT1496 Resource Hijacking

Event coverage

Rule body yaml

title: Linux Crypto Mining Indicators
id: 9069ea3c-b213-4c52-be13-86506a227ab1
status: test
description: Detects command line parameters or strings often used by crypto miners
references:
    - https://www.poolwatch.io/coin/monero
author: Florian Roth (Nextron Systems)
date: 2021-10-26
modified: 2022-12-25
tags:
    - attack.impact
    - attack.t1496
logsource:
    product: linux
    category: process_creation
detection:
    selection:
        CommandLine|contains:
            - ' --cpu-priority='
            - '--donate-level=0'
            - ' -o pool.'
            - ' --nicehash'
            - ' --algo=rx/0 '
            - 'stratum+tcp://'
            - 'stratum+udp://'
            # Sub process started by xmrig - the most popular Monero crypto miner - unknown if this causes any false positives
            - 'sh -c /sbin/modprobe msr allow_writes=on'
            # base64 encoded: --donate-level=
            - 'LS1kb25hdGUtbGV2ZWw9'
            - '0tZG9uYXRlLWxldmVsP'
            - 'tLWRvbmF0ZS1sZXZlbD'
            # base64 encoded: stratum+tcp:// and stratum+udp://
            - 'c3RyYXR1bSt0Y3A6Ly'
            - 'N0cmF0dW0rdGNwOi8v'
            - 'zdHJhdHVtK3RjcDovL'
            - 'c3RyYXR1bSt1ZHA6Ly'
            - 'N0cmF0dW0rdWRwOi8v'
            - 'zdHJhdHVtK3VkcDovL'
    condition: selection
falsepositives:
    - Legitimate use of crypto miners
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    CommandLine|contains:
        - ' --cpu-priority='
        - '--donate-level=0'
        - ' -o pool.'
        - ' --nicehash'
        - ' --algo=rx/0 '
        - 'stratum+tcp://'
        - 'stratum+udp://'
        - 'sh -c /sbin/modprobe msr allow_writes=on'
        - 'LS1kb25hdGUtbGV2ZWw9'
        - '0tZG9uYXRlLWxldmVsP'
        - 'tLWRvbmF0ZS1sZXZlbD'
        - 'c3RyYXR1bSt0Y3A6Ly'
        - 'N0cmF0dW0rdGNwOi8v'
        - 'zdHJhdHVtK3RjcDovL'
        - 'c3RyYXR1bSt1ZHA6Ly'
        - 'N0cmF0dW0rdWRwOi8v'
        - 'zdHJhdHVtK3VkcDovL'

Indicators

Each row is a field, operator, and value that the rule matches. The corpus column counts how many other rules in the catalog look for the same combination: high numbers point to widely-used, community-vetted indicators. Blank or 1 shows that the indicator is specific to this rule.

FieldKindValues
CommandLinematch
  • --algo=rx/0
  • --cpu-priority=
  • --nicehash
  • -o pool.
  • --donate-level=0
  • 0tZG9uYXRlLWxldmVsP
  • LS1kb25hdGUtbGV2ZWw9
  • N0cmF0dW0rdGNwOi8v
  • N0cmF0dW0rdWRwOi8v
  • c3RyYXR1bSt0Y3A6Ly
  • c3RyYXR1bSt1ZHA6Ly
  • sh -c /sbin/modprobe msr allow_writes=on
  • stratum+tcp://
  • stratum+udp://
  • tLWRvbmF0ZS1sZXZlbD
  • zdHJhdHVtK3RjcDovL
  • zdHJhdHVtK3VkcDovL