Detection rules › Sublime MQL

Attachment with encrypted zip (unsolicited)

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

Recursively scans files and archives to detect encrypted zip files.

Threat classification

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

CategoryValues
Attack typesMalware/Ransomware
Tactics and techniquesEvasion, Encryption

Event coverage

Rule body MQL

type.inbound
and any(attachments,
        (.file_type == "zip" or .file_extension == "zip")
        and any(file.explode(.), any(.flavors.yara, . == 'encrypted_zip'))
)
and (
  not profile.by_sender().solicited
  or (
    profile.by_sender().any_messages_malicious_or_spam
    and not profile.by_sender().any_messages_benign
  )
)
and not profile.by_sender().prevalence == "common"

Detection logic

Scope: inbound message.

Recursively scans files and archives to detect encrypted zip files.

  1. inbound message
  2. any of attachments where all hold:
    • any of:
      • .file_type is 'zip'
      • .file_extension is 'zip'
    • any of file.explode(.) where:
      • any of .flavors.yara where:
        • . is 'encrypted_zip'
  3. any of:
    • not:
      • profile.by_sender().solicited
    • all of:
      • profile.by_sender().any_messages_malicious_or_spam
      • not:
        • profile.by_sender().any_messages_benign
  4. not:
    • profile.by_sender().prevalence is 'common'

Inspects: attachments[].file_extension, attachments[].file_type, type.inbound. Sensors: file.explode, profile.by_sender.

Indicators matched (3)

FieldMatchValue
attachments[].file_typeequalszip
attachments[].file_extensionequalszip
file.explode(attachments[])[].flavors.yara[]equalsencrypted_zip