Skip to content

Commit 5ba61d9

Browse files
[PR #3057] changed rule: Credential phishing: 'Secure message' and engaging language
1 parent 72fb345 commit 5ba61d9

File tree

1 file changed

+146
-0
lines changed

1 file changed

+146
-0
lines changed
Lines changed: 146 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,146 @@
1+
name: "Credential phishing: 'Secure message' and engaging language"
2+
description: |
3+
Body contains language resembling credential theft, and a "secure message" from an untrusted sender.
4+
type: "rule"
5+
severity: "medium"
6+
source: |
7+
type.inbound
8+
and (
9+
any(ml.nlu_classifier(body.current_thread.text).intents,
10+
.name == "cred_theft" and .confidence == "high"
11+
)
12+
or any(ml.nlu_classifier(beta.ocr(beta.message_screenshot()).text).intents,
13+
.name == "cred_theft" and .confidence in ("medium", "high")
14+
)
15+
)
16+
17+
// ----- other suspicious signals here -----
18+
and (
19+
(
20+
regex.icontains(body.current_thread.text, "secure (message|directory)")
21+
or strings.icontains(body.current_thread.text, "document portal")
22+
or strings.icontains(body.current_thread.text, "encrypted message")
23+
or strings.icontains(body.current_thread.text, "protected message")
24+
or strings.icontains(body.current_thread.text, "secured by")
25+
)
26+
or any(body.previous_threads,
27+
regex.icontains(.text, "secure (message|directory)")
28+
or strings.icontains(.text, "document portal")
29+
or strings.icontains(.text, "encrypted message")
30+
or strings.icontains(.text, "protected message")
31+
or strings.icontains(.text, "secured by")
32+
)
33+
)
34+
// todo: automated display name / human local part
35+
// todo: suspicious link (unfurl click trackers)
36+
37+
// ----------
38+
39+
// has at least 1 link
40+
and length(body.links) > 0
41+
42+
// negate legitimate message senders
43+
and (
44+
sender.email.domain.root_domain not in ("protectedtrust.com")
45+
and any(body.links,
46+
.href_url.domain.root_domain != sender.email.domain.root_domain
47+
)
48+
// Negate known secure mailer(s)
49+
and not all(body.links,
50+
.href_url.domain.root_domain in (
51+
"mimecast.com",
52+
"cisco.com",
53+
"csiesafe.com"
54+
)
55+
)
56+
and any(headers.hops,
57+
.index == 0
58+
and not any(.fields,
59+
strings.contains(.value,
60+
'multipart/mixed; boundary="PROOFPOINT_BOUNDARY_1"'
61+
)
62+
)
63+
)
64+
and not (
65+
length(filter(attachments,
66+
strings.ilike(.file_name,
67+
"logo.*",
68+
"lock.gif",
69+
"SecureMessageAtt.html"
70+
)
71+
)
72+
) == 3
73+
and any(attachments,
74+
.file_type == "html"
75+
and any(file.explode(.),
76+
.scan.html.title == "Proofpoint Encryption"
77+
and any(.scan.url.urls,
78+
strings.iends_with(.path,
79+
'formpostdir/safeformpost.aspx'
80+
)
81+
)
82+
)
83+
and strings.count(file.parse_html(.).raw, 'name="msg') > 3
84+
)
85+
)
86+
and not (
87+
any(headers.hops, any(.fields, .name == 'X-ZixNet'))
88+
and any(headers.domains,
89+
.root_domain in (
90+
"zixport.com",
91+
"zixcorp.com",
92+
"zixmail.net",
93+
"zixworks.com"
94+
)
95+
)
96+
)
97+
and not (
98+
any(headers.hops, any(.fields, .name == 'X-SendInc-Message-Id'))
99+
and any(headers.domains, .root_domain in ("sendinc.net"))
100+
)
101+
// negating Mimecast sends with MS banner and/or sender's email pulled out as a link
102+
and not length(filter(body.links,
103+
(
104+
.display_text is null
105+
and .display_url.url == sender.email.domain.root_domain
106+
)
107+
or .href_url.domain.root_domain in (
108+
"aka.ms",
109+
"mimecast.com",
110+
"cisco.com"
111+
)
112+
)
113+
) == length(body.links)
114+
)
115+
and (
116+
(
117+
profile.by_sender().prevalence in ("new", "outlier")
118+
and not profile.by_sender().solicited
119+
)
120+
or (
121+
profile.by_sender().any_messages_malicious_or_spam
122+
and not profile.by_sender().any_messages_benign
123+
)
124+
)
125+
and not profile.by_sender().any_messages_benign
126+
127+
// negate highly trusted sender domains unless they fail DMARC authentication
128+
and (
129+
(
130+
sender.email.domain.root_domain in $high_trust_sender_root_domains
131+
and not headers.auth_summary.dmarc.pass
132+
)
133+
or sender.email.domain.root_domain not in $high_trust_sender_root_domains
134+
)
135+
136+
attack_types:
137+
- "Credential Phishing"
138+
tactics_and_techniques:
139+
- "Social engineering"
140+
detection_methods:
141+
- "Natural Language Understanding"
142+
- "Sender analysis"
143+
id: "0854fcc1-6b01-5231-aa50-0cc8610b9143"
144+
og_id: "bd95a7b1-dc96-53c1-bb7c-3a0f98b04744"
145+
testing_pr: 3057
146+
testing_sha: 64d9e4103935121a6e7dd8ac9c4e8ca8d238fa60

0 commit comments

Comments
 (0)