← Back to SOC feed Coverage →

The first entry in a cross-reference table is always free and has a generation number of 65,535

yara LOW Yara-Rules
backdoorcommunity
This rule was pulled from an open-source repository and enriched with AI. Validate in a test environment before deploying to production.
View original rule at Yara-Rules →
Retrieved: 2026-05-12T23:00:00Z · Confidence: medium

Hunt Hypothesis

The hypothesis is that an adversary may be manipulating cross-reference table entries to mask malicious activity by exploiting the known behavior of the first entry having a generation number of 65,535. SOC teams should proactively hunt for this behavior in Azure Sentinel to identify potential tampering or evasion tactics that could indicate advanced persistent threats.

YARA Rule

rule invalid_xref_numbers : PDF raw
{
        meta:
			author = "Glenn Edwards (@hiddenillusion)"
			version = "0.1"
			description = "The first entry in a cross-reference table is always free and has a generation number of 65,535"
			notes = "This can be also be in a stream..."
			weight = 1
		
        strings:
                $magic = { 25 50 44 46 }
                $reg0 = /xref\r?\n?.*\r?\n?.*65535\sf/
                $reg1 = /endstream.*\r?\n?endobj.*\r?\n?startxref/
        condition:
                $magic in (0..1024) and not $reg0 and not $reg1
}

Deployment Notes

This YARA rule can be deployed in the following contexts:

This rule contains 3 string patterns in its detection logic.

False Positive Guidance

Original source: https://github.com/Yara-Rules/rules/blob/main/maldocs/Maldoc_PDF.yar