← Back to Explore
sublimemediumRule
Attachment: ICS link with valueless base64 query parameter
Detects inbound emails containing ICS calendar attachments where embedded event links include a randomized 8-character base64 query parameter with no assigned value. The rule excludes messages from high-trust sender domains that pass DMARC authentication.
Detection Query
type.inbound
and any(attachments,
(
.file_type == "ics"
or .file_extension == "ics"
or .content_type in ("application/ics", "text/calendar")
)
//
// This rule makes use of a beta feature and is subject to change without notice
// using the beta feature in custom rules is not suggested until it has been formally released
//
and any(beta.file.parse_ics(.).events,
any(.links,
(
.href_url.path == '/'
and regex.imatch(.href_url.query_params,
'[A-Za-z0-9+/]{8}'
)
and length(.href_url.query_params_decoded) == 1
and all(flatten(values(.href_url.query_params_decoded)),
. == ''
)
)
or (
ml.link_analysis(., mode="aggressive").effective_url.path == '/'
and regex.imatch(ml.link_analysis(., mode="aggressive").effective_url.query_params,
'[A-Za-z0-9+/]{8}'
)
and length(ml.link_analysis(., mode="aggressive").effective_url.query_params_decoded
) == 1
and all(flatten(values(ml.link_analysis(.,
mode="aggressive"
).effective_url.query_params_decoded
)
),
. == ''
)
)
or (
any(ml.link_analysis(., mode="aggressive").final_dom.links,
.href_url.path == '/'
and regex.imatch(.href_url.query_params,
'[A-Za-z0-9+/]{8}'
)
and length(.href_url.query_params_decoded) == 1
and all(flatten(values(.href_url.query_params_decoded)
),
. == ''
)
)
)
)
)
)
and not (
sender.email.domain.root_domain in $high_trust_sender_root_domains
and coalesce(headers.auth_summary.dmarc.pass, false)
)
Data Sources
Email MessagesEmail HeadersEmail Attachments
Platforms
email
Raw Content
name: "Attachment: ICS link with valueless base64 query parameter"
description: "Detects inbound emails containing ICS calendar attachments where embedded event links include a randomized 8-character base64 query parameter with no assigned value. The rule excludes messages from high-trust sender domains that pass DMARC authentication."
type: "rule"
severity: "medium"
source: |
type.inbound
and any(attachments,
(
.file_type == "ics"
or .file_extension == "ics"
or .content_type in ("application/ics", "text/calendar")
)
//
// This rule makes use of a beta feature and is subject to change without notice
// using the beta feature in custom rules is not suggested until it has been formally released
//
and any(beta.file.parse_ics(.).events,
any(.links,
(
.href_url.path == '/'
and regex.imatch(.href_url.query_params,
'[A-Za-z0-9+/]{8}'
)
and length(.href_url.query_params_decoded) == 1
and all(flatten(values(.href_url.query_params_decoded)),
. == ''
)
)
or (
ml.link_analysis(., mode="aggressive").effective_url.path == '/'
and regex.imatch(ml.link_analysis(., mode="aggressive").effective_url.query_params,
'[A-Za-z0-9+/]{8}'
)
and length(ml.link_analysis(., mode="aggressive").effective_url.query_params_decoded
) == 1
and all(flatten(values(ml.link_analysis(.,
mode="aggressive"
).effective_url.query_params_decoded
)
),
. == ''
)
)
or (
any(ml.link_analysis(., mode="aggressive").final_dom.links,
.href_url.path == '/'
and regex.imatch(.href_url.query_params,
'[A-Za-z0-9+/]{8}'
)
and length(.href_url.query_params_decoded) == 1
and all(flatten(values(.href_url.query_params_decoded)
),
. == ''
)
)
)
)
)
)
and not (
sender.email.domain.root_domain in $high_trust_sender_root_domains
and coalesce(headers.auth_summary.dmarc.pass, false)
)
attack_types:
- "Credential Phishing"
tactics_and_techniques:
- "Evasion"
- "Social engineering"
- "ICS Phishing"
detection_methods:
- "File analysis"
- "URL analysis"
- "Header analysis"
id: "d5ce3bc3-9771-541c-a5e5-aedf94cc9e8f"