[PR #4478] [CLOSED] fix(pe): ignore zero-extent sections in resource mapping #6264

Closed
opened 2026-10-31 01:13:07 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/morluto/rea/pull/4478
Author: @Elements2720
Created: 10/16/2026
Status: ❌ Closed

Base: main ← Head: fix/pe-resource-zero-extent-sections


📝 Commits (1)

  • a82c654 fix(pe): ignore zero-extent sections in resource mapping

📊 Changes

3 files changed (+123 additions, -17 deletions)

View changed files

📝 src/native/pe/PeResourceLayout.ts (+12 -7)
📝 src/native/pe/PeResourceParser.test.ts (+46 -0)
📝 tests/acceptance/applications/peResources.test.ts (+65 -10)

📄 Description

Summary

Fixes #4455.

PE resource layout validation now reuses a single section/resource interval predicate that ignores sections with zero effective virtual extent. Positive-extent overlap rejection and existing empty-resource ownership rules are unchanged.

The regression coverage includes parser-level section-backed and header-backed payloads plus compiled CLI/MCP acceptance cases.

Evidence

  • Before: section-backed probe rejected with Resource interval intersects overlapping virtual sections.
  • Before: header-backed probe rejected with Ambiguous resource header RVA mapping.
  • After: focused parser/service tests passed 35/35.
  • After: compiled CLI/MCP acceptance passed 1/1.
  • After: npm run check:fast passed with 2 successful tasks.
  • After: npm run compile exited 0.

The full npm test command could not start because this Windows checkout lacks native/windows/build/manifest.json and native/windows/build/rea-windows-x64.node. The direct compiled acceptance test passed after runtime compilation.

Merge Danger

Door: Two-way

Blast Radius: PE resource mapping

The change is local to static PE resource interval validation and is reversible by reverting the commit.

Author readiness

  • Human owner reviewed the complete diff and relevant existing code.
  • Human owner verified the reported behavior and validation evidence.
  • Human owner declares this PR ready for initial maintainer review.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/morluto/rea/pull/4478 **Author:** [@Elements2720](https://github.com/Elements2720) **Created:** 10/16/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `fix/pe-resource-zero-extent-sections` --- ### 📝 Commits (1) - [`a82c654`](https://github.com/morluto/rea/commit/a82c654a111d7113585736b5d7f11c191098e45f) fix(pe): ignore zero-extent sections in resource mapping ### 📊 Changes **3 files changed** (+123 additions, -17 deletions) <details> <summary>View changed files</summary> 📝 `src/native/pe/PeResourceLayout.ts` (+12 -7) 📝 `src/native/pe/PeResourceParser.test.ts` (+46 -0) 📝 `tests/acceptance/applications/peResources.test.ts` (+65 -10) </details> ### 📄 Description ## Summary Fixes #4455. PE resource layout validation now reuses a single section/resource interval predicate that ignores sections with zero effective virtual extent. Positive-extent overlap rejection and existing empty-resource ownership rules are unchanged. The regression coverage includes parser-level section-backed and header-backed payloads plus compiled CLI/MCP acceptance cases. ## Evidence - Before: section-backed probe rejected with Resource interval intersects overlapping virtual sections. - Before: header-backed probe rejected with Ambiguous resource header RVA mapping. - After: focused parser/service tests passed 35/35. - After: compiled CLI/MCP acceptance passed 1/1. - After: npm run check:fast passed with 2 successful tasks. - After: npm run compile exited 0. The full npm test command could not start because this Windows checkout lacks native/windows/build/manifest.json and native/windows/build/rea-windows-x64.node. The direct compiled acceptance test passed after runtime compilation. ## Merge Danger **Door:** Two-way **Blast Radius:** PE resource mapping The change is local to static PE resource interval validation and is reversible by reverting the commit. ## Author readiness - [ ] Human owner reviewed the complete diff and relevant existing code. - [ ] Human owner verified the reported behavior and validation evidence. - [ ] Human owner declares this PR ready for initial maintainer review. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-31 01:13:07 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
morluto/rea#6264
No description provided.