Detection rules › Sublime MQL

Brand impersonation: MetaMask

Severity
high
Type
rule
Source
github.com/sublime-security/sublime-rules

Detects inbound messages containing links where the sender impersonates MetaMask through display name manipulation and includes the MetaMask logo or suspicious language, while not being from legitimate MetaMask domains. The rule checks for credential theft patterns and validates sender authentication.

Threat classification

Sublime's own taxonomy (not MITRE ATT&CK).

CategoryValues
Attack typesBEC/Fraud, Credential Phishing
Tactics and techniquesImpersonation: Brand, Social engineering

Event coverage

Rule body MQL

type.inbound
and length(body.links) > 0
and (
  regex.icontains(strings.replace_confusables(sender.display_name),
                  '\bmetamask\b',
                  '\bmetamask\.io\b'
  )
  or strings.contains(strings.replace_confusables(sender.display_name),
                      "METAMASK"
  )
  or strings.ilevenshtein(strings.replace_confusables(sender.display_name),
                          'metamask'
  ) <= 2
)
and (
  any(ml.logo_detect(file.message_screenshot()).brands, .name == "MetaMask")
  or any(ml.nlu_classifier(body.current_thread.text).intents,
         .name in ("cred_theft", "callback_scam", "steal_pii")
         and .confidence in ("high")
  )
)
and sender.email.domain.root_domain not in~ ('metamask.io')

// 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().any_messages_benign

Detection logic

Scope: inbound message.

Detects inbound messages containing links where the sender impersonates MetaMask through display name manipulation and includes the MetaMask logo or suspicious language, while not being from legitimate MetaMask domains. The rule checks for credential theft patterns and validates sender authentication.

  1. inbound message
  2. length(body.links) > 0
  3. any of:
    • strings.replace_confusables(sender.display_name) matches any of 2 patterns
      • \bmetamask\b
      • \bmetamask\.io\b
    • strings.replace_confusables(sender.display_name) contains 'METAMASK'
    • strings.replace_confusables(sender.display_name) is similar to 'metamask'
  4. any of:
    • any of ml.logo_detect(file.message_screenshot()).brands where:
      • .name is 'MetaMask'
    • any of ml.nlu_classifier(body.current_thread.text).intents where all hold:
      • .name in ('cred_theft', 'callback_scam', 'steal_pii')
      • .confidence in ('high')
  5. sender.email.domain.root_domain not in ('metamask.io')
  6. 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
  7. not:
    • profile.by_sender().any_messages_benign

Inspects: body.current_thread.text, body.links, headers.auth_summary.dmarc.pass, sender.display_name, sender.email.domain.root_domain, type.inbound. Sensors: file.message_screenshot, ml.logo_detect, ml.nlu_classifier, profile.by_sender, regex.icontains, strings.contains, strings.ilevenshtein, strings.replace_confusables. Reference lists: $high_trust_sender_root_domains.

Indicators matched (10)

FieldMatchValue
regex.icontainsregex\bmetamask\b
regex.icontainsregex\bmetamask\.io\b
strings.containssubstringMETAMASK
strings.ilevenshteinfuzzymetamask
ml.logo_detect(file.message_screenshot()).brands[].nameequalsMetaMask
ml.nlu_classifier(body.current_thread.text).intents[].namemembercred_theft
ml.nlu_classifier(body.current_thread.text).intents[].namemembercallback_scam
ml.nlu_classifier(body.current_thread.text).intents[].namemembersteal_pii
ml.nlu_classifier(body.current_thread.text).intents[].confidencememberhigh
sender.email.domain.root_domainmembermetamask.io