1
+ name : " Brand Impersonation: Salesforce"
2
+ description : " Detects impersonation of Salesforce through display name, email domain, or domain similarity, excluding legitimate Salesforce communications, training-related emails with proper authentication, and internal domain notifications."
3
+ type : " rule"
4
+ severity : " medium"
5
+ source : |
6
+ type.inbound
7
+ and (
8
+ regex.icontains(sender.display_name, 'salesforce')
9
+ or strings.ilike(sender.display_name, "*salesforce*")
10
+ or strings.ilevenshtein(sender.display_name, 'salesforce') <= 2
11
+ or strings.ilike(sender.email.domain.domain, '*salesforce*')
12
+ )
13
+ and not (
14
+ (
15
+ // legitimate salesforce domains
16
+ sender.email.domain.root_domain in (
17
+ "salesforce.com",
18
+ "salesforceventures.com",
19
+ "tangocard.com" //https://www.tangocard.com/salesforce-partnership
20
+ )
21
+ and headers.auth_summary.dmarc.pass
22
+ )
23
+ // email related to salesforce training being offered
24
+ or (
25
+ (
26
+ regex.icontains(body.current_thread.text, "(training|bootcamp)")
27
+ or regex.icontains(subject.subject, "(training|bootcamp)")
28
+ )
29
+ and headers.auth_summary.dmarc.pass
30
+ )
31
+ // email from own domain with salesforce notification
32
+ or (
33
+ sender.email.domain.root_domain in $org_domains
34
+ and headers.auth_summary.dmarc.pass
35
+ )
36
+ )
37
+ and (
38
+ not (
39
+ coalesce(headers.auth_summary.dmarc.pass, false)
40
+ and not profile.by_sender().solicited
41
+ )
42
+ )
43
+ and not any(body.links, .href_url.domain.root_domain == "salesforce.com")
44
+ // negate highly trusted sender domains unless they fail DMARC authentication
45
+ and (
46
+ (
47
+ sender.email.domain.root_domain in $high_trust_sender_root_domains
48
+ and not headers.auth_summary.dmarc.pass
49
+ )
50
+ or sender.email.domain.root_domain not in $high_trust_sender_root_domains
51
+ )
52
+
53
+
54
+ attack_types :
55
+ - " Credential Phishing"
56
+ tactics_and_techniques :
57
+ - " Impersonation: Brand"
58
+ - " Lookalike domain"
59
+ - " Social engineering"
60
+ detection_methods :
61
+ - " Content analysis"
62
+ - " Header analysis"
63
+ - " Sender analysis"
64
+ id : " c5f0e666-81f0-5d17-a470-12ab75113631"
65
+ og_id : " 736dfb87-1f99-5cdb-aefc-392257376f3d"
66
+ testing_pr : 3050
67
+ testing_sha : 036043c2825d5b375dc3917cddf13913200cdb52
0 commit comments