Detection rules › Sigma

Potential Suspicious Winget Package Installation

Status
test
Severity
high
Log source
product windows, category create_stream_hash
Author
Nasreddine Bencherchali (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects potential suspicious winget package installation from a suspicious source.

MITRE ATT&CK coverage

TacticTechniques
PersistenceNo specific technique
StealthNo specific technique

Event coverage

ProviderEventTitle
SysmonEvent ID 15FileCreateStreamHash

Rule body yaml

title: Potential Suspicious Winget Package Installation
id: a3f5c081-e75b-43a0-9f5b-51f26fe5dba2
status: test
description: Detects potential suspicious winget package installation from a suspicious source.
references:
    - https://github.com/nasbench/Misc-Research/tree/b9596e8109dcdb16ec353f316678927e507a5b8d/LOLBINs/Winget
author: Nasreddine Bencherchali (Nextron Systems)
date: 2023-04-18
tags:
    - attack.persistence
    - attack.stealth
logsource:
    product: windows
    category: create_stream_hash
detection:
    selection:
        Contents|startswith: '[ZoneTransfer]  ZoneId=3'
        Contents|contains:
            # Note: Add any untrusted sources that are custom to your env
            - '://1'
            - '://2'
            - '://3'
            - '://4'
            - '://5'
            - '://6'
            - '://7'
            - '://8'
            - '://9'
        TargetFilename|endswith: ':Zone.Identifier'
        TargetFilename|contains: '\AppData\Local\Temp\WinGet\'
    condition: selection
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection

selection:
    Contents|startswith: '[ZoneTransfer]  ZoneId=3'
    Contents|contains:
        - '://1'
        - '://2'
        - '://3'
        - '://4'
        - '://5'
        - '://6'
        - '://7'
        - '://8'
        - '://9'
    TargetFilename|endswith: ':Zone.Identifier'
    TargetFilename|contains: '\AppData\Local\Temp\WinGet\'

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
Contentsmatch
  • ://1
  • ://2
  • ://3
  • ://4
  • ://5
  • ://6
  • ://7
  • ://8
  • ://9
Contentsstarts_with
  • [ZoneTransfer] ZoneId=3 corpus 2 (sigma 2)
TargetFilenameends_with
  • :Zone.Identifier corpus 6 (sigma 4, splunk 2)
TargetFilenamematch
  • \AppData\Local\Temp\WinGet\