/
email_attachments_with_lots_of_spaces.yml
63 lines (61 loc) · 2.57 KB
/
email_attachments_with_lots_of_spaces.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Email Attachments With Lots Of Spaces
id: 56e877a6-1455-4479-ada6-0550dc1e22f8
version: 2
date: '2023-04-14'
author: David Dorsey, Splunk
status: experimental
type: Anomaly
description: Attackers often use spaces as a means to obfuscate an attachment's file
extension. This search looks for messages with email attachments that have many
spaces within the file names.
data_source: []
search: '| tstats `security_content_summariesonly` count values(All_Email.recipient)
as recipient_address min(_time) as firstTime max(_time) as lastTime from datamodel=Email
where All_Email.file_name="*" by All_Email.src_user, All_Email.file_name All_Email.message_id
| `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)` | `drop_dm_object_name("All_Email")`
| eval space_ratio = (mvcount(split(file_name," "))-1)/len(file_name) | search space_ratio
>= 0.1 | rex field=recipient_address "(?<recipient_user>.*)@" | `email_attachments_with_lots_of_spaces_filter`'
how_to_implement: 'You need to ingest data from emails. Specifically, the sender''s
address and the file names of any attachments must be mapped to the Email data
model. The threshold ratio is set to 10%, but this value can be configured to
suit each environment.
**Splunk Phantom Playbook Integration**
If Splunk Phantom is also configured in your environment, a playbook called "Suspicious
Email Attachment Investigate and Delete" can be configured to run when any results
are found by this detection search. To use this integration, install the Phantom
App for Splunk `https://splunkbase.splunk.com/app/3411/` and add the correct hostname
to the "Phantom Instance" field in the Adaptive Response Actions when configuring
this detection search. The notable event will be sent to Phantom and the playbook
will gather further information about the file attachment and its network behaviors.
If Phantom finds malicious behavior and an analyst approves of the results, the
email will be deleted from the user''s inbox.'
known_false_positives: None at this time
references: []
tags:
analytic_story:
- Data Destruction
- Emotet Malware DHS Report TA18-201A
- Hermetic Wiper
- Suspicious Emails
asset_type: Endpoint
confidence: 50
impact: 50
message: tbd
observable:
- name: user
type: User
role:
- Victim
product:
- Splunk Enterprise
- Splunk Enterprise Security
- Splunk Cloud
required_fields:
- _time
- All_Email.recipient
- All_Email.file_name
- All_Email.src_user
- All_Email.file_name
- All_Email.message_id
risk_score: 25
security_domain: network