EXPLORE
← Back to Explore
sublimehighRule

Attachment: PDF with EOF MD5 hash marker

Detects inbound messages containing a PDF attachment whose contents match a YARA signature identifying an MD5 hash appended near the end of file. This technique is commonly used to make each generated PDF unique, helping evade hash-based detection systems.

Detection Query

type.inbound
and any(filter(attachments, .file_type == "pdf"),
        any(file.explode(.),
            any(.scan.yara.matches, .name in ("pdf_eof_md5_hash"))
        )
)

Data Sources

Email MessagesEmail HeadersEmail Attachments

Platforms

email
Raw Content
name: "Attachment: PDF with EOF MD5 hash marker"
description: "Detects inbound messages containing a PDF attachment whose contents match a YARA signature identifying an MD5 hash appended near the end of file. This technique is commonly used to make each generated PDF unique, helping evade hash-based detection systems."
type: "rule"
severity: "high"
source: |
    type.inbound
    and any(filter(attachments, .file_type == "pdf"),
            any(file.explode(.),
                any(.scan.yara.matches, .name in ("pdf_eof_md5_hash"))
            )
    )
attack_types:
  - "Credential Phishing"
  - "Malware/Ransomware"
tactics_and_techniques:
  - "PDF"
  - "Evasion"
detection_methods:
  - "File analysis"
  - "YARA"
id: "b5eb01ac-b191-5536-b1b6-107e32dfd050"