Detection rules › Sigma

Indicator Removal on Host - Clear Mac System Logs

Status
test
Severity
medium
Log source
product macos, category process_creation
Author
remotephone, oscd.community
Source
github.com/SigmaHQ/sigma

Detects deletion of local audit logs

MITRE ATT&CK coverage

Event coverage

ProviderEventTitle
ESFexecProcess Execution (Notify)

Rule body yaml

title: Indicator Removal on Host - Clear Mac System Logs
id: acf61bd8-d814-4272-81f0-a7a269aa69aa
status: test
description: Detects deletion of local audit logs
references:
    - https://github.com/redcanaryco/atomic-red-team/blob/f339e7da7d05f6057fdfcdd3742bfcf365fee2a9/atomics/T1070.002/T1070.002.md
author: remotephone, oscd.community
date: 2020-10-11
modified: 2022-09-16
tags:
    - attack.defense-impairment
    - attack.t1685.006
logsource:
    product: macos
    category: process_creation
detection:
    selection1:
        Image|endswith:
            - '/rm'
            - '/unlink'
            - '/shred'
    selection_cli_1:
        CommandLine|contains: '/var/log'
    selection_cli_2:
        CommandLine|contains|all:
            - '/Users/'
            - '/Library/Logs/'
    condition: selection1 and 1 of selection_cli*
falsepositives:
    - Legitimate administration activities
level: medium

Stages and Predicates

Stage 0: condition

selection1 and 1 of selection_cli*

Stage 1: selection1

selection1:
    Image|endswith:
        - '/rm'
        - '/unlink'
        - '/shred'

Stage 2: selection_cli_1

selection_cli_1:
    CommandLine|contains: '/var/log'

Stage 3: selection_cli_2

selection_cli_2:
    CommandLine|contains|all:
        - '/Users/'
        - '/Library/Logs/'

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
  • /Library/Logs/
  • /Users/
  • /var/log
Imageends_with
  • /rm
  • /shred
  • /unlink