Skip to content

Aperture/auditor payload guards drop real source files (aes_prng.c, tables.c, crc32.cpp, EntityFlags.cs ...: 64 files, ~900 functions) #5460

Closed

Description

@squid-protocol

Problem

Content guards built to stop minified/packed payloads also drop hand-written source that contains functions next to large constant tables. Across 39 DOOM ports, 64 first-party files that Universal Ctags finds functions in are excluded (data-only files dropped by the same guards are fine and not counted).

Class: content guards that exclude whole files

member where status examples (functions lost)
Embedded Array/Matrix Payload (commas > 3×LOC, LOC>500) aperture.py:~731-736 drops code tables.c (linuxdoom/chocolate/crispy), r_bmaps.c (13), deh_htext.c (6): 37 files, 189 fns
Embedded Hex Payload (hex tokens > LOC, LOC>500) aperture.py:~720-725 drops code aes_prng.c (9, chocolate/crispy/doom-wasm), odamex common/crc32.cpp (13), gzdoom utf8.cpp (11): 17 files, 250 fns
Packed Payload Guard (rho > 3.0) metrics/statistical_auditor.py:496-500 drops code Helion EntityFlags.cs (363), gzdoom gl_load.c (26), doom3do mac.c (25): 5 files, 416 fns
Saturation (line > limit) aperture.py:~770-776 drops code fastdoom i_cga512.c/i_cgaafh.c (3 each), doom-nano sound.h (5)
Lexical Monotony aperture.py:832-856 drops code eternity d_dehtbl.cpp (21), doom3-bfg win_qgl.cpp (3)
Zero-Density Threshold statistical_auditor.py:490-492 OK here (icons, .raw_rgb888.c data) —
Machine-Generated signature aperture Gate 4.x OK here (bison parser.cc in re2c) —

Acceptance

  • A guard that would exclude a file first checks for real definitions (the language's func_start/class anchors outside the payload region); files with definitions are scanned (payload region may be skipped or down-weighted), files without are excluded as today.
  • Fixture per guard: a C file with a 3,000-entry table plus 3 functions is kept with 3 functions; a pure table file is still excluded.
  • Rescan the corpus: zero first-party files with ctags-visible functions excluded by these guards.

Part of #5457 (milestone DOOM Port Speedrun).

Evidence: /srv/storage_16tb/projects/gitgalaxy/doom-study/ — round2_findings.md, clean_check.csv, clean_check_details.json; scans in scans_r2/<port>/ at engine 585c243e9; corpus variants_r2.csv (39 ports, pinned SHAs); scorer scripts/clean_check.py.

🤖 Generated with Claude Code

Activity

  1. added
    bug
    data-integrity
    core-engine
    needs:doom-corpus
    scope:core
    on Oct 18, 2026
  2. squid-protocol commented on Oct 19, 2026

    @squid-protocol
    OwnerAuthor

    Siblings after PR #5553 (rescan, slice 3): (1) Lexical Monotony drops 5 one-function tables.c/.cpp files (need=2 is deliberate in #5547; policy decision, not a defect); (2) eternity source/concurrentqueue/ still mapped (not in KNOWN_LIBRARY_NAMES, no license); (3) doom-study clean_check.py is local-only and still calls removed VendorDirectoryDetector.is_candidate_name.

  3. added a commit that references this issue on Oct 19, 2026
  4. squid-protocol commented on Oct 19, 2026

    @squid-protocol
    OwnerAuthor

    Closing: the guards no longer drop first-party files with functions (rescan in #5553; tables.c kept by #5575). Residuals are low value: doom-study/clean_check.py is a local script superseded by tests/tools/doom_speedrun/, and eternity source/concurrentqueue/ (one header library mapped as first-party) will show up in the DOOM crucible's golden if it matters. Re-aimed per #5457.

    🤖 Generated with Claude Code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugcore-enginedata-integrityneeds:doom-corpuspriority: mediumscope:core

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions