Detection rules › Sublime MQL
Brand impersonation: TikTok
Detects messages impersonating TikTok through similar display names or logo detection, combined with security-themed content and authentication failures. Excludes legitimate TikTok communications and trusted senders.
Threat classification
Sublime's own taxonomy (not MITRE ATT&CK).
| Category | Values |
|---|---|
| Attack types | Credential Phishing |
| Tactics and techniques | Impersonation: Brand, Social engineering |
Event coverage
Rule body MQL
type.inbound
and (
// TikTok Brand Detection
(
// display name contains tiktok
strings.ilike(strings.replace_confusables(sender.display_name), '*tiktok*')
// levenshtein distance similar to tiktok
or strings.ilevenshtein(strings.replace_confusables(sender.display_name),
'tiktok'
) <= 1
or (
length(ml.logo_detect(file.message_screenshot()).brands) == 1
and any(ml.logo_detect(file.message_screenshot()).brands,
.name == "TikTok" and .confidence == "high"
)
)
// hyphenated sender domain contains tiktok
or strings.iends_with(sender.email.domain.root_domain, "-tiktok.com")
)
// OR TikTok verification language
or (
strings.icontains(body.current_thread.text, "tiktok")
and (
strings.icontains(body.current_thread.text, "verified badge")
or strings.icontains(body.current_thread.text, "verification criteria")
or strings.icontains(body.current_thread.text, "activate badge")
or strings.icontains(body.current_thread.text, "verification complete")
or strings.icontains(body.current_thread.text, "almost verified")
or strings.icontains(body.current_thread.text, "review complete")
or strings.icontains(body.current_thread.text, "verify profile")
)
)
)
and (
// ML Topic Analysis and Credential Theft Detection
any(ml.nlu_classifier(body.current_thread.text).topics,
.name in (
"Security and Authentication",
"Secure Message",
"Reminders and Notifications"
)
and .confidence in ("medium", "high")
)
or any(ml.nlu_classifier(beta.ocr(file.message_screenshot()).text).topics,
.name in (
"Security and Authentication",
"Secure Message",
"Reminders and Notifications"
)
and .confidence in ("medium", "high")
and beta.ocr(file.message_screenshot()).text != ""
)
or any(ml.nlu_classifier(body.current_thread.text).intents,
.name == "cred_theft" and .confidence == "high"
)
or any(ml.nlu_classifier(beta.ocr(file.message_screenshot()).text).intents,
.name == "cred_theft" and .confidence == "high"
)
)
// Not from legitimate TikTok or Google domains with DMARC pass
and not (
sender.email.domain.root_domain in $org_domains
or (
sender.email.domain.root_domain in (
"tiktok.com",
"tiktokglobalshop.com",
"tiktokusds.com",
"bytedance.com",
"tiktokacademy.com",
"webassessor.com" // used for this https://ads.tiktok.com/business/en-US/academy/tiktok-certification
)
and headers.auth_summary.dmarc.pass
)
)
// negate iCloud Private Message Relay
and not (
sender.email.domain.domain == "privaterelay.appleid.com"
or any(headers.hops, any(.fields, .name == "X-ICLOUD-HME"))
)
// negate highly trusted sender domains unless they fail DMARC authentication
and (
(
sender.email.domain.root_domain in $high_trust_sender_root_domains
and not headers.auth_summary.dmarc.pass
)
or sender.email.domain.root_domain not in $high_trust_sender_root_domains
)
and not profile.by_sender().solicited
Detection logic
Scope: inbound message.
Detects messages impersonating TikTok through similar display names or logo detection, combined with security-themed content and authentication failures. Excludes legitimate TikTok communications and trusted senders.
- inbound message
any of:
any of:
- strings.replace_confusables(sender.display_name) matches '*tiktok*'
- strings.replace_confusables(sender.display_name) is similar to 'tiktok'
all of:
- length(ml.logo_detect(file.message_screenshot()).brands) is 1
any of
ml.logo_detect(file.message_screenshot()).brandswhere all hold:- .name is 'TikTok'
- .confidence is 'high'
- sender.email.domain.root_domain ends with '-tiktok.com'
all of:
- body.current_thread.text contains 'tiktok'
body.current_thread.text contains any of 7 patterns
verified badgeverification criteriaactivate badgeverification completealmost verifiedreview completeverify profile
any of:
any of
ml.nlu_classifier(body.current_thread.text).topicswhere all hold:- .name in ('Security and Authentication', 'Secure Message', 'Reminders and Notifications')
- .confidence in ('medium', 'high')
any of
ml.nlu_classifier(beta.ocr(file.message_screenshot()).text).topicswhere all hold:- .name in ('Security and Authentication', 'Secure Message', 'Reminders and Notifications')
- .confidence in ('medium', 'high')
- beta.ocr(file.message_screenshot()).text is not ''
any of
ml.nlu_classifier(body.current_thread.text).intentswhere all hold:- .name is 'cred_theft'
- .confidence is 'high'
any of
ml.nlu_classifier(beta.ocr(file.message_screenshot()).text).intentswhere all hold:- .name is 'cred_theft'
- .confidence is 'high'
none of:
- sender.email.domain.root_domain in $org_domains
all of:
- sender.email.domain.root_domain in ('tiktok.com', 'tiktokglobalshop.com', 'tiktokusds.com', 'bytedance.com', 'tiktokacademy.com', 'webassessor.com')
- headers.auth_summary.dmarc.pass
none of:
- sender.email.domain.domain is 'privaterelay.appleid.com'
any of
headers.hopswhere:any of
.fieldswhere:- .name is 'X-ICLOUD-HME'
any of:
all of:
- sender.email.domain.root_domain in $high_trust_sender_root_domains
not:
- headers.auth_summary.dmarc.pass
- sender.email.domain.root_domain not in $high_trust_sender_root_domains
not:
- profile.by_sender().solicited
Inspects: body.current_thread.text, headers.auth_summary.dmarc.pass, headers.hops, headers.hops[].fields, headers.hops[].fields[].name, sender.display_name, sender.email.domain.domain, sender.email.domain.root_domain, type.inbound. Sensors: beta.ocr, file.message_screenshot, ml.logo_detect, ml.nlu_classifier, profile.by_sender, strings.icontains, strings.iends_with, strings.ilevenshtein, strings.ilike, strings.replace_confusables. Reference lists: $high_trust_sender_root_domains, $org_domains.
Indicators matched (35)
| Field | Match | Value |
|---|---|---|
strings.ilike | substring | *tiktok* |
strings.ilevenshtein | fuzzy | tiktok |
ml.logo_detect(file.message_screenshot()).brands[].name | equals | TikTok |
ml.logo_detect(file.message_screenshot()).brands[].confidence | equals | high |
strings.iends_with | suffix | -tiktok.com |
strings.icontains | substring | tiktok |
strings.icontains | substring | verified badge |
strings.icontains | substring | verification criteria |
strings.icontains | substring | activate badge |
strings.icontains | substring | verification complete |
strings.icontains | substring | almost verified |
strings.icontains | substring | review complete |
23 more
strings.icontains | substring | verify profile |
ml.nlu_classifier(body.current_thread.text).topics[].name | member | Security and Authentication |
ml.nlu_classifier(body.current_thread.text).topics[].name | member | Secure Message |
ml.nlu_classifier(body.current_thread.text).topics[].name | member | Reminders and Notifications |
ml.nlu_classifier(body.current_thread.text).topics[].confidence | member | medium |
ml.nlu_classifier(body.current_thread.text).topics[].confidence | member | high |
ml.nlu_classifier(beta.ocr(file.message_screenshot()).text).topics[].name | member | Security and Authentication |
ml.nlu_classifier(beta.ocr(file.message_screenshot()).text).topics[].name | member | Secure Message |
ml.nlu_classifier(beta.ocr(file.message_screenshot()).text).topics[].name | member | Reminders and Notifications |
ml.nlu_classifier(beta.ocr(file.message_screenshot()).text).topics[].confidence | member | medium |
ml.nlu_classifier(beta.ocr(file.message_screenshot()).text).topics[].confidence | member | high |
ml.nlu_classifier(body.current_thread.text).intents[].name | equals | cred_theft |
ml.nlu_classifier(body.current_thread.text).intents[].confidence | equals | high |
ml.nlu_classifier(beta.ocr(file.message_screenshot()).text).intents[].name | equals | cred_theft |
ml.nlu_classifier(beta.ocr(file.message_screenshot()).text).intents[].confidence | equals | high |
sender.email.domain.root_domain | member | tiktok.com |
sender.email.domain.root_domain | member | tiktokglobalshop.com |
sender.email.domain.root_domain | member | tiktokusds.com |
sender.email.domain.root_domain | member | bytedance.com |
sender.email.domain.root_domain | member | tiktokacademy.com |
sender.email.domain.root_domain | member | webassessor.com |
sender.email.domain.domain | equals | privaterelay.appleid.com |
headers.hops[].fields[].name | equals | X-ICLOUD-HME |