[PR #604] [MERGED] fix(comparison): require decoded signatures for structural method matches #2104

Closed
opened 2026-10-16 21:14:18 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/morluto/rea/pull/604
Author: @rudycelekli
Created: 10/5/2026
Status: ✅ Merged
Merged: 10/5/2026
Merged by: @morluto

Base: main ← Head: campaign/rea-oct5-domain-managed-unknown


📝 Commits (3)

  • bc6c5dc fix(comparison): require decoded signatures for structural method matches
  • 6c2eb3b test(browser): preserve unknown with-scope loader bindings
  • 9b90268 chore: merge upstream source-map fixture correction

📊 Changes

3 files changed (+90 additions, -2 deletions)

View changed files

📝 src/domain/managedMemberComparison.test.ts (+37 -0)
📝 src/domain/managedMemberComparisonMatch.ts (+1 -1)
📝 tests/boundary/providers/managed/managedMemberComparison.test.ts (+52 -1)

📄 Description

Summary

Undecoded signature fields no longer create a high-confidence structural method identity; content-addressed partial Evidence preserves unknown unmatched methods.

No issue is linked: this is a narrow, reproduced correction to an existing comparison invariant discovered while reviewing current code, with no new feature, architectural change, or public contract requiring a proposal.

Problem and expected behavior

Two unsupported signature byte sequences with matching available method-body shape were matched at high confidence despite undecoded signature shape. A structural signature key needs decoded fields; partial inventories must preserve uncertain unmatched members.

Change and scope

Require decoded signature status before producing a structural method key. Real synthetic PE inspection provides the unsupported signature observations; a controlled adapter labels the supported inventory state partial. The public Evidence input/parser/service accepts that partial state and preserves unknown results.

Contract and boundary impact

  • Semantic owner and earliest changed stage: Managed member comparison / structural method key formation.
  • CLI and MCP/tool-catalog contract: same commands, schemas and result fields; corrected existing comparison values only.
  • Provider, bridge, target-format, or platform compatibility: no provider/bridge changes or new platform support.
  • Evidence, artifact, provenance, or reconstruction contract: existing content-addressed inputs and provenance preserved; no new artifact identity or authority claim.
  • Process execution, authorization, cleanup, or containment impact: none in production.
  • Generated metadata (docs/product-catalog.json), package, or installation impact: none; relevant metadata checks remain enforced.

Evidence and regression coverage

  • Tests added or updated: 6 domain managed comparison tests and 3 public workflow boundary tests pass. Both regression seams fail against unchanged source and pass with the guard.
  • Base reproduction or other evidence: executed production comparison regression fails on unchanged branch base; patched regression passes. No module mocks.
  • User-visible CLI/MCP output (if applicable): representative selected fields from the executed comparison fixture, not a claimed live CLI/provider session:
{"matching":{"structural_method_shape":0},"methods":[{"status":"unknown","match":{"status":"unmatched"}},{"status":"unknown","match":{"status":"unmatched"}}]}
  • Remaining proof gaps: Coverage is deliberately partial in the controlled observation adapter; this does not claim the native inspector itself labels unsupported signature coverage partial. No real CLR SDK or assembly execution occurred.

For evidence-bearing changes:

  • Observed, derived, and inferred claims remain distinguishable.
  • Artifact identity, source provenance, and failed attempts remain preserved.
  • Unsupported, incomplete, unavailable, or uncertain outcomes remain visible.

Validation performed

  • npm run test:focused -- src/domain/managedMemberComparison.test.ts tests/boundary/providers/managed/managedMemberComparison.test.ts — pass: 2 files, 9 tests.
  • npm run check — pass on final signed head.
  • npm run build:cached — pass before the public Evidence boundary regression.
  • Current upstream AGENTS.md/CONTRIBUTING (#599) makes full check:pr optional for narrow fixes. Previous full-suite, check:ci and package evidence remains archived for the pre-repair or pre-rebase head; those counts are not claimed for this head. No packaging/distribution or provider behavior changed.

Existing upstream lint/TypeDoc warnings remain; passing gates are not claimed warning-free.

Compatibility, safety, and release

  • Breaking changes or migration steps: none; existing comparison result shape preserved.
  • Real Hopper/Ghidra, browser, or OS coverage: not required for this pure comparison correction; controlled Evidence/fixture coverage described above.
  • Package or release metadata impact: none.
  • Security, privacy, process, or containment review: no secrets, production data, new process execution, authorization mechanism, or containment change.

Review checklist

  • The PR has one focused outcome and the title follows type(scope): outcome.
  • Related issue is linked, or the reason for not linking one is stated above.
  • Tests cover changed observable behavior and meaningful failure paths.
  • Owning docs, contracts, and generated metadata are updated where needed (no new public contract or metadata change).
  • User-visible CLI/MCP changes include representative output.
  • I checked the final diff for secrets, unrelated cleanup, and unsupported claims.

AI assistance was used for investigation, implementation and testing. The commit is signed and includes DCO sign-off.

CI baseline fixture follow-up

CI exposed an upstream source-map recovery fixture expecting a require inside dynamic with scope to be a known unbound loader. The lexical producer correctly keeps that binding unknown. The maintainer independently corrected the fixture in #609. I merged that upstream change and preserved the owner's exact fixture; the final diff against that upstream parent contains only this comparison correction. No production source-map extraction was weakened.

At final signed merge head 9b902680d7e48e83193853d8a3244c523e207ed9, npm run build:cached, npm run check, and the pre-push npm run check:fast pass; 32 focused tests across 3 files pass, including the original comparison regressions and all 23 source-map boundary tests. Remote CI reruns are not claimed complete while pending.


🔄 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/604 **Author:** [@rudycelekli](https://github.com/rudycelekli) **Created:** 10/5/2026 **Status:** ✅ Merged **Merged:** 10/5/2026 **Merged by:** [@morluto](https://github.com/morluto) **Base:** `main` ← **Head:** `campaign/rea-oct5-domain-managed-unknown` --- ### 📝 Commits (3) - [`bc6c5dc`](https://github.com/morluto/rea/commit/bc6c5dcaf856c541b18fbc9d6ca2c8683696b675) fix(comparison): require decoded signatures for structural method matches - [`6c2eb3b`](https://github.com/morluto/rea/commit/6c2eb3b8e6d93d6b7c53af90d731ae4ba18db47a) test(browser): preserve unknown with-scope loader bindings - [`9b90268`](https://github.com/morluto/rea/commit/9b902680d7e48e83193853d8a3244c523e207ed9) chore: merge upstream source-map fixture correction ### 📊 Changes **3 files changed** (+90 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `src/domain/managedMemberComparison.test.ts` (+37 -0) 📝 `src/domain/managedMemberComparisonMatch.ts` (+1 -1) 📝 `tests/boundary/providers/managed/managedMemberComparison.test.ts` (+52 -1) </details> ### 📄 Description ## Summary Undecoded signature fields no longer create a high-confidence structural method identity; content-addressed partial Evidence preserves unknown unmatched methods. No issue is linked: this is a narrow, reproduced correction to an existing comparison invariant discovered while reviewing current code, with no new feature, architectural change, or public contract requiring a proposal. ## Problem and expected behavior Two unsupported signature byte sequences with matching available method-body shape were matched at high confidence despite undecoded signature shape. A structural signature key needs decoded fields; partial inventories must preserve uncertain unmatched members. ## Change and scope Require decoded signature status before producing a structural method key. Real synthetic PE inspection provides the unsupported signature observations; a controlled adapter labels the supported inventory state partial. The public Evidence input/parser/service accepts that partial state and preserves unknown results. ## Contract and boundary impact - Semantic owner and earliest changed stage: Managed member comparison / structural method key formation. - CLI and MCP/tool-catalog contract: same commands, schemas and result fields; corrected existing comparison values only. - Provider, bridge, target-format, or platform compatibility: no provider/bridge changes or new platform support. - Evidence, artifact, provenance, or reconstruction contract: existing content-addressed inputs and provenance preserved; no new artifact identity or authority claim. - Process execution, authorization, cleanup, or containment impact: none in production. - Generated metadata (`docs/product-catalog.json`), package, or installation impact: none; relevant metadata checks remain enforced. ## Evidence and regression coverage - Tests added or updated: 6 domain managed comparison tests and 3 public workflow boundary tests pass. Both regression seams fail against unchanged source and pass with the guard. - Base reproduction or other evidence: executed production comparison regression fails on unchanged branch base; patched regression passes. No module mocks. - User-visible CLI/MCP output (if applicable): representative selected fields from the executed comparison fixture, not a claimed live CLI/provider session: ```json {"matching":{"structural_method_shape":0},"methods":[{"status":"unknown","match":{"status":"unmatched"}},{"status":"unknown","match":{"status":"unmatched"}}]} ``` - Remaining proof gaps: Coverage is deliberately partial in the controlled observation adapter; this does not claim the native inspector itself labels unsupported signature coverage partial. No real CLR SDK or assembly execution occurred. For evidence-bearing changes: - [x] Observed, derived, and inferred claims remain distinguishable. - [x] Artifact identity, source provenance, and failed attempts remain preserved. - [x] Unsupported, incomplete, unavailable, or uncertain outcomes remain visible. ## Validation performed - `npm run test:focused -- src/domain/managedMemberComparison.test.ts tests/boundary/providers/managed/managedMemberComparison.test.ts` — pass: 2 files, 9 tests. - `npm run check` — pass on final signed head. - `npm run build:cached` — pass before the public Evidence boundary regression. - Current upstream AGENTS.md/CONTRIBUTING (#599) makes full check:pr optional for narrow fixes. Previous full-suite, check:ci and package evidence remains archived for the pre-repair or pre-rebase head; those counts are not claimed for this head. No packaging/distribution or provider behavior changed. Existing upstream lint/TypeDoc warnings remain; passing gates are not claimed warning-free. ## Compatibility, safety, and release - Breaking changes or migration steps: none; existing comparison result shape preserved. - Real Hopper/Ghidra, browser, or OS coverage: not required for this pure comparison correction; controlled Evidence/fixture coverage described above. - Package or release metadata impact: none. - Security, privacy, process, or containment review: no secrets, production data, new process execution, authorization mechanism, or containment change. ## Review checklist - [x] The PR has one focused outcome and the title follows `type(scope): outcome`. - [x] Related issue is linked, or the reason for not linking one is stated above. - [x] Tests cover changed observable behavior and meaningful failure paths. - [x] Owning docs, contracts, and generated metadata are updated where needed (no new public contract or metadata change). - [x] User-visible CLI/MCP changes include representative output. - [x] I checked the final diff for secrets, unrelated cleanup, and unsupported claims. AI assistance was used for investigation, implementation and testing. The commit is signed and includes DCO sign-off. ## CI baseline fixture follow-up CI exposed an upstream source-map recovery fixture expecting a require inside dynamic with scope to be a known unbound loader. The lexical producer correctly keeps that binding unknown. The maintainer independently corrected the fixture in #609. I merged that upstream change and preserved the owner's exact fixture; the final diff against that upstream parent contains only this comparison correction. No production source-map extraction was weakened. At final signed merge head `9b902680d7e48e83193853d8a3244c523e207ed9`, `npm run build:cached`, `npm run check`, and the pre-push `npm run check:fast` pass; 32 focused tests across 3 files pass, including the original comparison regressions and all 23 source-map boundary tests. Remote CI reruns are not claimed complete while pending. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-16 21:14:18 +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#2104
No description provided.