pe_inspect: parse and validate PE export forwarders table (OLD-9768) #693

Merged
leonida/mandy
abnalstlll-byte merged 4 commits from feat/exe-export-forwarders into main 2026-12-02 10:40:13 +00:00

Pull request successfully merged and closed

abnalstlll-byte commented 2026-11-24 12:16:27 +00:00

Related issues: #14, #17, #18 (restoring old upstream PR 9768, author restoration for draft PR #45).

What and why

Restores original pull request OLD-9768 authored by @abnalstlll-byte:

  • Extends \ ools/pe_inspect.py\ with full support for PE Export Address Table (EAT) forwarder validation.
  • Detects and resolves forwarder RVA ranges pointing into the export directory section.
  • Validates forwarder target syntax (\DLL.Symbol\ and \DLL.#Ordinal) and ensures forwarders conform to
    untime/src/pe_loader.cpp\ contracts.
  • Python 3.11+ string formatting compatibility.
  • Comprehensive synthetic test coverage in \ ests/test_pe_inspect.py\ (69/69 PASS).

Tested

  • Windows 11 x64, Python 3.14 / 3.12:
    • \python -I tests/test_pe_inspect.py: 69/69 PASS.
    • \python -I scripts/check_no_game_data.py\ on changed files: PASS.
  • Clean merge against \ubi/main\ (0 conflicts).

Checklist

  • No proprietary payloads, game-derived files, keys, or protection workarounds.
  • Standard library only (\python -I).
  • Preserves author attribution and original PR commit provenance.
Related issues: #14, #17, #18 (restoring old upstream PR 9768, author restoration for draft PR #45). ### What and why Restores original pull request **OLD-9768** authored by @abnalstlll-byte: - Extends \ ools/pe_inspect.py\ with full support for PE Export Address Table (EAT) forwarder validation. - Detects and resolves forwarder RVA ranges pointing into the export directory section. - Validates forwarder target syntax (\DLL.Symbol\ and \DLL.#Ordinal\) and ensures forwarders conform to \ untime/src/pe_loader.cpp\ contracts. - Python 3.11+ string formatting compatibility. - Comprehensive synthetic test coverage in \ ests/test_pe_inspect.py\ (69/69 PASS). ### Tested - Windows 11 x64, Python 3.14 / 3.12: - \python -I tests/test_pe_inspect.py\: 69/69 PASS. - \python -I scripts/check_no_game_data.py\ on changed files: PASS. - Clean merge against \ubi/main\ (0 conflicts). ### Checklist - [x] No proprietary payloads, game-derived files, keys, or protection workarounds. - [x] Standard library only (\python -I\). - [x] Preserves author attribution and original PR commit provenance.
abnalstlll-byte commented 2026-11-25 21:35:31 +00:00

Rebased cleanly onto latest \main\ (\e34ff17e9), clearing stale base CI failures. Verified: all 78 tests in \ est_pe_inspect.py\ pass.

AI-assisted (Claude Code)

Rebased cleanly onto latest \main\ (\e34ff17e9\), clearing stale base CI failures. Verified: all 78 tests in \ est_pe_inspect.py\ pass. AI-assisted (Claude Code)
MoonEyes commented 2026-11-28 02:48:26 +00:00

Hi @abnalstlll-byte, thanks for this pull request. It currently conflicts with main (conflicting file(s): tests/test_pe_inspect.py, tools/pe_inspect.py), so it carries the needs rebase label. CONTRIBUTING.md asks authors to rebase their branch on main; once it merges cleanly the label goes within the hour, and reviews start with the pull requests that do. Could you update the branch when you have a moment? If you no longer plan to continue with it, please say so here.

AI-assisted (Claude Code, Claude Opus 5.5).

Hi @abnalstlll-byte, thanks for this pull request. It currently conflicts with `main` (conflicting file(s): `tests/test_pe_inspect.py`, `tools/pe_inspect.py`), so it carries the `needs rebase` label. CONTRIBUTING.md asks authors to rebase their branch on `main`; once it merges cleanly the label goes within the hour, and reviews start with the pull requests that do. Could you update the branch when you have a moment? If you no longer plan to continue with it, please say so here. AI-assisted (Claude Code, Claude Opus 5.5).
aslan2142 reviewed 2026-12-01 11:44:28 +00:00
aslan2142 left a comment
No description provided.
This PR cannot merge in its current state: - **Merge conflicts** with `main` in `tools/pe_inspect.py` and `tests/test_pe_inspect.py`. - **Failing CI** (`translator-tests`, `stdlib-tests-linux`, `macos-python`, `check`). Please rebase onto current `main` and re-run CI to green. *(AI-assisted review.)*
MoonEyes commented 2026-12-02 07:13:26 +00:00

This PR has not moved since 25 November and conflicts with main in tools/pe_inspect.py and tests/test_pe_inspect.py (main added resources_markdown(), unverified imports and system-DLL notes in the same places). I opened #3060, which is main merged with this head: your commits are kept, and so is what main added. This PR stays open until a maintainer decides. If you rebase it yourself, say so and I will close #3060.

AI-assisted (Claude Code)

This PR has not moved since 25 November and conflicts with `main` in `tools/pe_inspect.py` and `tests/test_pe_inspect.py` (`main` added `resources_markdown()`, unverified imports and system-DLL notes in the same places). I opened #3060, which is `main` merged with this head: your commits are kept, and so is what `main` added. This PR stays open until a maintainer decides. If you rebase it yourself, say so and I will close #3060. AI-assisted (Claude Code)
Sign in to join this conversation.
No description provided.