Detection rules › Sigma

Potentially Suspicious Network Connection To Notion API

Status
test
Severity
low
Log source
product windows, category network_connection
Author
Gavin Knapp
Source
github.com/SigmaHQ/sigma

Detects a non-browser process communicating with the Notion API. This could indicate potential use of a covert C2 channel such as "OffensiveNotion C2"

MITRE ATT&CK coverage

TacticTechniques
Command & ControlT1102 Web Service

Event coverage

ProviderEventTitle
SysmonEvent ID 3Network connection

Rule body yaml

title: Potentially Suspicious Network Connection To Notion API
id: 7e9cf7b6-e827-11ed-a05b-15959c120003
status: test
description: Detects a non-browser process communicating with the Notion API. This could indicate potential use of a covert C2 channel such as "OffensiveNotion C2"
references:
    - https://github.com/mttaggart/OffensiveNotion
    - https://medium.com/@huskyhacks.mk/we-put-a-c2-in-your-notetaking-app-offensivenotion-3e933bace332
author: Gavin Knapp
date: 2023-05-03
tags:
    - attack.command-and-control
    - attack.t1102
logsource:
    product: windows
    category: network_connection
detection:
    selection:
        DestinationHostname|contains: 'api.notion.com'
    filter_main_notion:
        Image|endswith: '\AppData\Local\Programs\Notion\Notion.exe'
    filter_main_brave:
        Image|endswith: '\brave.exe'
    filter_main_chrome:
        Image:
            - 'C:\Program Files\Google\Chrome\Application\chrome.exe'
            - 'C:\Program Files (x86)\Google\Chrome\Application\chrome.exe'
    filter_main_firefox:
        Image:
            - 'C:\Program Files\Mozilla Firefox\firefox.exe'
            - 'C:\Program Files (x86)\Mozilla Firefox\firefox.exe'
    filter_main_ie:
        Image:
            - 'C:\Program Files (x86)\Internet Explorer\iexplore.exe'
            - 'C:\Program Files\Internet Explorer\iexplore.exe'
    filter_main_maxthon:
        Image|endswith: '\maxthon.exe'
    filter_main_edge_1:
        - Image|startswith: 'C:\Program Files (x86)\Microsoft\EdgeWebView\Application\'
        - Image|endswith: '\WindowsApps\MicrosoftEdge.exe'
        - Image:
              - 'C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe'
              - 'C:\Program Files\Microsoft\Edge\Application\msedge.exe'
    filter_main_edge_2:
        Image|startswith:
            - 'C:\Program Files (x86)\Microsoft\EdgeCore\'
            - 'C:\Program Files\Microsoft\EdgeCore\'
        Image|endswith:
            - '\msedge.exe'
            - '\msedgewebview2.exe'
    filter_main_opera:
        Image|endswith: '\opera.exe'
    filter_main_safari:
        Image|endswith: '\safari.exe'
    filter_main_seamonkey:
        Image|endswith: '\seamonkey.exe'
    filter_main_vivaldi:
        Image|endswith: '\vivaldi.exe'
    filter_main_whale:
        Image|endswith: '\whale.exe'
    condition: selection and not 1 of filter_main_*
falsepositives:
    - Legitimate applications communicating with the "api.notion.com" endpoint that are not already in the exclusion list. The desktop and browser applications do not appear to be using the API by default unless integrations are configured.
level: low

Stages and Predicates

Stage 0: condition

selection and not 1 of filter_main_*

Stage 1: selection

selection:
    DestinationHostname|contains: 'api.notion.com'

Stage 2: not filter_main_*

filter_main_notion:
    Image|endswith: '\AppData\Local\Programs\Notion\Notion.exe'
filter_main_brave:
    Image|endswith: '\brave.exe'
filter_main_chrome:
    Image:
        - 'C:\Program Files\Google\Chrome\Application\chrome.exe'
        - 'C:\Program Files (x86)\Google\Chrome\Application\chrome.exe'
filter_main_firefox:
    Image:
        - 'C:\Program Files\Mozilla Firefox\firefox.exe'
        - 'C:\Program Files (x86)\Mozilla Firefox\firefox.exe'
filter_main_ie:
    Image:
        - 'C:\Program Files (x86)\Internet Explorer\iexplore.exe'
        - 'C:\Program Files\Internet Explorer\iexplore.exe'
filter_main_maxthon:
    Image|endswith: '\maxthon.exe'
filter_main_edge_1:
    - Image|startswith: 'C:\Program Files (x86)\Microsoft\EdgeWebView\Application\'
    - Image|endswith: '\WindowsApps\MicrosoftEdge.exe'
    - Image:
          - 'C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe'
          - 'C:\Program Files\Microsoft\Edge\Application\msedge.exe'
filter_main_edge_2:
    Image|startswith:
        - 'C:\Program Files (x86)\Microsoft\EdgeCore\'
        - 'C:\Program Files\Microsoft\EdgeCore\'
    Image|endswith:
        - '\msedge.exe'
        - '\msedgewebview2.exe'
filter_main_opera:
    Image|endswith: '\opera.exe'
filter_main_safari:
    Image|endswith: '\safari.exe'
filter_main_seamonkey:
    Image|endswith: '\seamonkey.exe'
filter_main_vivaldi:
    Image|endswith: '\vivaldi.exe'
filter_main_whale:
    Image|endswith: '\whale.exe'

Exclusions

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

FieldKindExcluded values
Imageends_with\msedge.exe
Imageends_with\msedgewebview2.exe
Imagestarts_withC:\Program Files (x86)\Microsoft\EdgeCore\
Imagestarts_withC:\Program Files\Microsoft\EdgeCore\
Imageends_with\AppData\Local\Programs\Notion\Notion.exe
Imageends_with\WindowsApps\MicrosoftEdge.exe
Imageends_with\brave.exe
Imageends_with\maxthon.exe
Imageends_with\opera.exe
Imageends_with\safari.exe
Imageends_with\seamonkey.exe
Imageends_with\vivaldi.exe
Imageends_with\whale.exe
ImageeqC:\Program Files (x86)\Google\Chrome\Application\chrome.exe
ImageeqC:\Program Files (x86)\Internet Explorer\iexplore.exe
ImageeqC:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe
ImageeqC:\Program Files (x86)\Mozilla Firefox\firefox.exe
ImageeqC:\Program Files\Google\Chrome\Application\chrome.exe
ImageeqC:\Program Files\Internet Explorer\iexplore.exe
ImageeqC:\Program Files\Microsoft\Edge\Application\msedge.exe
ImageeqC:\Program Files\Mozilla Firefox\firefox.exe
Imagestarts_withC:\Program Files (x86)\Microsoft\EdgeWebView\Application\

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
DestinationHostnamematch
  • api.notion.com