- title: Suspicious Svchost Process
id: 01d2e2a1-5f09-44f7-9fc1-24faa7479b6d
status: experimental
description: Detects a suspicious svchost process start
tags:
- attack.defense_evasion
- attack.t1036
author: Florian Roth
date: 2017/08/15
logsource:
category: process_creation
product: windows
service: null
detection:
selection:
Image: '*\svchost.exe'
filter:
ParentImage:
- '*\services.exe'
- '*\MsMpEng.exe'
- '*\Mrt.exe'
- '*\rpcnet.exe'
- '*\svchost.exe'
filter_null:
ParentImage: null
condition: selection and not filter and not filter_null
fields:
- CommandLine
- ParentCommandLine
falsepositives:
- Unknown
level: high
In [ ]:
from elasticsearch import Elasticsearch
from elasticsearch_dsl import Search
import pandas as pd
In [ ]:
es = Elasticsearch(['http://helk-elasticsearch:9200'])
searchContext = Search(using=es, index='logs-*', doc_type='doc')
In [ ]:
s = searchContext.query('query_string', query='((process_path.keyword:*\\svchost.exe AND (NOT (process_parent_path.keyword:(*\\services.exe OR *\\MsMpEng.exe OR *\\Mrt.exe OR *\\rpcnet.exe OR *\\svchost.exe)))) AND (NOT (NOT _exists_:process_parent_path)))')
response = s.execute()
if response.success():
df = pd.DataFrame((d.to_dict() for d in s.scan()))
In [ ]:
df.head()