Detection rules › Sigma

Suspicious Electron Application Child Processes

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

Detects suspicious child processes of electron apps (teams, discord, slack, etc.). This could be a potential sign of ".asar" file tampering (See reference section for more information) or binary execution proxy through specific CLI arguments (see related rule)

MITRE ATT&CK coverage

TacticTechniques
ExecutionNo specific technique

Event coverage

Rule body yaml

title: Suspicious Electron Application Child Processes
id: f26eb764-fd89-464b-85e2-dc4a8e6e77b8
related:
    - id: 378a05d8-963c-46c9-bcce-13c7657eac99
      type: similar
status: test
description: |
    Detects suspicious child processes of electron apps (teams, discord, slack, etc.). This could be a potential sign of ".asar" file tampering (See reference section for more information) or binary execution proxy through specific CLI arguments (see related rule)
references:
    - https://taggart-tech.com/quasar-electron/
    - https://github.com/mttaggart/quasar
    - https://positive.security/blog/ms-officecmd-rce
    - https://lolbas-project.github.io/lolbas/Binaries/Msedge/
    - https://lolbas-project.github.io/lolbas/Binaries/Teams/
    - https://lolbas-project.github.io/lolbas/Binaries/msedgewebview2/
    - https://medium.com/@MalFuzzer/one-electron-to-rule-them-all-dc2e9b263daf
author: Nasreddine Bencherchali (Nextron Systems)
date: 2022-10-21
modified: 2024-07-12
tags:
    - attack.execution
logsource:
    category: process_creation
    product: windows
detection:
    selection_parent:
        ParentImage|endswith:
            # Add more electron based app to the list
            - '\chrome.exe' # Might require additional tuning
            - '\discord.exe'
            - '\GitHubDesktop.exe'
            - '\keybase.exe'
            - '\msedge.exe'
            - '\msedgewebview2.exe'
            - '\msteams.exe'
            - '\slack.exe'
            - '\teams.exe'
            # - '\code.exe' # Prone to a lot of FPs. Requires an additional baseline
    selection_child_image:
        Image|endswith:
            # Add more suspicious/unexpected paths
            - '\cmd.exe'
            - '\cscript.exe'
            - '\mshta.exe'
            - '\powershell.exe'
            - '\pwsh.exe'
            - '\regsvr32.exe'
            - '\whoami.exe'
            - '\wscript.exe'
    selection_child_paths:
        Image|contains:
            # Add more suspicious/unexpected paths
            - ':\ProgramData\'
            - ':\Temp\'
            - '\AppData\Local\Temp\'
            - '\Users\Public\'
            - '\Windows\Temp\'
    filter_optional_discord:
        ParentImage|endswith: '\Discord.exe'
        Image|endswith: '\cmd.exe'
        CommandLine|contains: '\NVSMI\nvidia-smi.exe'
    condition: selection_parent and 1 of selection_child_* and not 1 of filter_optional_*
falsepositives:
    - Unknown
# Increase the level once FP rate is reduced (see status)
level: medium

Stages and Predicates

Stage 0: condition

selection_parent and 1 of selection_child_* and not 1 of filter_optional_*

Stage 1: selection_parent

selection_parent:
    ParentImage|endswith:
        - '\chrome.exe'
        - '\discord.exe'
        - '\GitHubDesktop.exe'
        - '\keybase.exe'
        - '\msedge.exe'
        - '\msedgewebview2.exe'
        - '\msteams.exe'
        - '\slack.exe'
        - '\teams.exe'

Stage 2: selection_child_image

selection_child_image:
    Image|endswith:
        - '\cmd.exe'
        - '\cscript.exe'
        - '\mshta.exe'
        - '\powershell.exe'
        - '\pwsh.exe'
        - '\regsvr32.exe'
        - '\whoami.exe'
        - '\wscript.exe'

Stage 3: selection_child_paths

selection_child_paths:
    Image|contains:
        - ':\ProgramData\'
        - ':\Temp\'
        - '\AppData\Local\Temp\'
        - '\Users\Public\'
        - '\Windows\Temp\'

Stage 4: not filter_optional_discord

filter_optional_discord:
    ParentImage|endswith: '\Discord.exe'
    Image|endswith: '\cmd.exe'
    CommandLine|contains: '\NVSMI\nvidia-smi.exe'

Exclusions

Top-level NOT(...) conjuncts: predicates this rule actively suppresses.

FieldKindExcluded values
CommandLinematch\NVSMI\nvidia-smi.exe
Imageends_with\cmd.exe
ParentImageends_with\Discord.exe

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
Imageends_with
  • \cmd.exe corpus 130 (sigma 130)
  • \cscript.exe corpus 73 (sigma 73)
  • \mshta.exe corpus 67 (sigma 67)
  • \powershell.exe corpus 182 (sigma 182)
  • \pwsh.exe corpus 168 (sigma 168)
  • \regsvr32.exe corpus 65 (sigma 65)
  • \whoami.exe corpus 19 (sigma 19)
  • \wscript.exe corpus 75 (sigma 75)
Imagematch
  • :\ProgramData\ corpus 3 (sigma 3)
  • :\Temp\ corpus 13 (sigma 13)
  • \AppData\Local\Temp\ corpus 11 (sigma 11)
  • \Users\Public\ corpus 10 (sigma 10)
  • \Windows\Temp\ corpus 8 (sigma 8)
ParentImageends_with
  • \GitHubDesktop.exe
  • \chrome.exe corpus 5 (sigma 5)
  • \discord.exe
  • \keybase.exe
  • \msedge.exe corpus 4 (sigma 4)
  • \msedgewebview2.exe
  • \msteams.exe
  • \slack.exe
  • \teams.exe