UAC Bypass via sdclt

Detects changes to HKCU:\Software\Classes\exefile\shell\runas\command\isolatedCommand

Rule Content

- title: UAC Bypass via sdclt
  id: 5b872a46-3b90-45c1-8419-f675db8053aa
  status: experimental
  description: Detects changes to HKCU:\Software\Classes\exefile\shell\runas\command\isolatedCommand
  references:
  - https://enigma0x3.net/2017/03/17/fileless-uac-bypass-using-sdclt-exe/
  author: Omer Yampel
  logsource:
    product: windows
    service: sysmon
    category: null
  detection:
    selection:
      EventID: 13
      TargetObject: HKEY_USERS\\*\Classes\exefile\shell\runas\command\isolatedCommand
    condition: selection
  tags:
  - attack.defense_evasion
  - attack.privilege_escalation
  - attack.t1088
  - car.2019-04-001
  falsepositives:
  - unknown
  level: high

Querying Elasticsearch

Import Libraries


In [ ]:
from elasticsearch import Elasticsearch
from elasticsearch_dsl import Search
import pandas as pd

Initialize Elasticsearch client


In [ ]:
es = Elasticsearch(['http://helk-elasticsearch:9200'])
searchContext = Search(using=es, index='logs-endpoint-winevent-sysmon-*', doc_type='doc')

Run Elasticsearch Query


In [ ]:
s = searchContext.query('query_string', query='(event_id:"13" AND registry_key_path.keyword:HKEY_USERS\\*\\Classes\\exefile\\shell\\runas\\command\\isolatedCommand)')
response = s.execute()
if response.success():
    df = pd.DataFrame((d.to_dict() for d in s.scan()))

Show Results


In [ ]:
df.head()