Medium Severity

Attachment: HTML file without HTML element (Unsolicited)

Labels

No labels.

Description

HTML attachment with a script XML element, but no HTML element. This is commonly used in phishing emails leveraging HTML smuggling, including those delivering the SocGholish malware variant.

@delivr_to
Created Aug 17th, 2023 • Last updated Apr 22nd, 2024
Feed Source
delivr.to Feed
Source
type.inbound and 
any(attachments, 
    // HTML file (html, shtm, xht, etc.)
    regex.imatch(.file_extension, '^[sdx]{0,1}ht[ml]{0,2}$') and

    any(file.explode(.), 
        // Top level file strings contain script but not html tag
        .depth == 0 and 
        any(.scan.strings.strings, strings.icontains(., "<script")) and 
        not any(.scan.strings.strings, strings.icontains(., "<html"))
    )
) 
and (
    not profile.by_sender_email().solicited
    or sender.email.domain.domain == "delivrto.me"
)
MQL Rule Console
•Docs•Learning Labs

Playground

Test against your own EMLs or sample data.

Share

Post about this on your socials.

Get Started. Today.

Managed or self-managed. No MX changes.

Deploy and integrate a free Sublime instance in minutes.
Get Started