Detection rules › Sigma

Writing Of Malicious Files To The Fonts Folder

Status
test
Severity
medium
Log source
product windows, category process_creation
Author
Sreeman
Source
github.com/SigmaHQ/sigma

Monitors for the hiding possible malicious files in the C:\Windows\Fonts\ location. This folder doesn't require admin privillege to be written and executed from.

MITRE ATT&CK coverage

Event coverage

Rule body yaml

title: Writing Of Malicious Files To The Fonts Folder
id: ae9b0bd7-8888-4606-b444-0ed7410cb728
status: test
description: Monitors for the hiding possible malicious files in the C:\Windows\Fonts\ location. This folder doesn't require admin privillege to be written and executed from.
references:
    - https://thedfirreport.com/2020/04/20/sqlserver-or-the-miner-in-the-basement/
author: Sreeman
date: 2020-04-21
modified: 2022-03-08
tags:
    - attack.stealth
    - attack.t1211
    - attack.t1059
    - attack.persistence
    - attack.execution
logsource:
    product: windows
    category: process_creation
detection:
    selection_1:
        CommandLine|contains:
            - 'echo'
            - 'copy'
            - 'type'
            - 'file createnew'
            - 'cacls'
    selection_2:
        CommandLine|contains: 'C:\Windows\Fonts\'
    selection_3:
        CommandLine|contains:
            - '.sh'
            - '.exe'
            - '.dll'
            - '.bin'
            - '.bat'
            - '.cmd'
            - '.js'
            - '.msh'
            - '.reg'
            - '.scr'
            - '.ps'
            - '.vb'
            - '.jar'
            - '.pl'
            - '.inf'
            - '.cpl'
            - '.hta'
            - '.msi'
            - '.vbs'
    condition: all of selection_*
falsepositives:
    - Unknown
level: medium

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_1

selection_1:
    CommandLine|contains:
        - 'echo'
        - 'copy'
        - 'type'
        - 'file createnew'
        - 'cacls'

Stage 2: selection_2

selection_2:
    CommandLine|contains: 'C:\Windows\Fonts\'

Stage 3: selection_3

selection_3:
    CommandLine|contains:
        - '.sh'
        - '.exe'
        - '.dll'
        - '.bin'
        - '.bat'
        - '.cmd'
        - '.js'
        - '.msh'
        - '.reg'
        - '.scr'
        - '.ps'
        - '.vb'
        - '.jar'
        - '.pl'
        - '.inf'
        - '.cpl'
        - '.hta'
        - '.msi'
        - '.vbs'

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
  • .bat corpus 11 (sigma 9, elastic 1, kusto 1)
  • .bin
  • .cmd corpus 6 (sigma 5, elastic 1)
  • .cpl corpus 3 (sigma 3)
  • .dll corpus 16 (sigma 16)
  • .exe corpus 5 (sigma 5)
  • .hta corpus 6 (sigma 6)
  • .inf corpus 3 (sigma 3)
  • .jar corpus 2 (sigma 2)
  • .js corpus 9 (sigma 9)
  • .msh
  • .msi
  • .pl corpus 2 (sigma 2)
  • .ps corpus 3 (sigma 3)
  • .reg corpus 4 (sigma 3, splunk 1)
  • .scr corpus 5 (sigma 5)
  • .sh corpus 2 (sigma 2)
  • .vb corpus 3 (sigma 3)
  • .vbs corpus 7 (sigma 7)
  • C:\Windows\Fonts\
  • cacls
  • copy corpus 5 (sigma 4, chronicle 1)
  • echo corpus 8 (sigma 4, splunk 4)
  • file createnew corpus 2 (sigma 2)
  • type corpus 3 (sigma 2, splunk 1)