High Severity
Attachment: HTML smuggling - QR Code with suspicious links
Description
This rule detects messages with HTML attachments containing QR codes
References
No references.
Sublime Security
Created Nov 22nd, 2023 • Last updated Apr 25th, 2024
Feed Source
Sublime Core Feed
Source
type.inbound
and 1 <= length(attachments) < 3
// inspects HTML attachments for QR codes
and any(attachments,
(
.file_extension in~ ("html", "htm", "shtml", "dhtml", "xhtml")
or (
.file_extension is null
and .file_type == "unknown"
and .content_type == "application/octet-stream"
)
or .file_extension in~ $file_extensions_common_archives
or .file_type == "html"
or .content_type == "text/html"
)
and any(file.explode(file.html_screenshot(.)),
// any URL
ml.link_analysis(.scan.qr.url).submitted
// currently we won't pick it up as a URL if it's
// not prefaced with a scheme. this is not very strong,
// but it's unlikely to cause FPs for this rule
or regex.contains(.scan.qr.data, '\.')
)
)
// 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
or (
profile.by_sender().any_messages_malicious_or_spam
and not profile.by_sender().any_false_positives
)
)
and not profile.by_sender().any_false_positives
Playground
Test against your own EMLs or sample data.