Skip to content

Fix/ghidra gcc aarch64 switch and http docs - #9680

Open
Nishant1600 wants to merge 3 commits into
morluto:mainfrom
Nishant1600:fix/ghidra-gcc-aarch64-switch-and-http-docs
Open

Nishant1600 wants to merge 3 commits into
morluto:mainfrom
Nishant1600:fix/ghidra-gcc-aarch64-switch-and-http-docs

Conversation

@Nishant1600

@Nishant1600 Nishant1600 commented Nov 9, 2026 •

Copy link
Copy Markdown

Summary

Problem and expected behavior

Change and scope

Follow the contribution scope.
Unresolved scope, authority, side effects, or required verification block
integration. Link the required maintainer scope decision for new providers or
capabilities involving target execution, injection, mutation, or protection
recovery; ordinary fixes within existing boundaries may state "not applicable".
Draft PRs may leave the scope decision pending and the readiness and merge checklists
unchecked. Maintainers can help resolve open questions.

Contract and boundary impact

  • Semantic owner and earliest changed stage:
  • Contribution scope fit and linked maintainer decision:
  • CLI and MCP/tool-catalog contract:
  • Provider, bridge, target-format, or platform compatibility:
  • Evidence, artifact, provenance, or reconstruction contract:
  • Target selection, authority, upstream behavior, and cleanup details (if applicable):
  • Generated metadata (docs/public/product-catalog.json), package, or installation impact (CI generates and validates ignored catalogs and skills/; edit authored instructions in .agents/skills/reverse-engineer-anything/ and never commit build outputs):

Expected effects (check known effects; use documentation-only on its own).
Unchecked items do not establish absence; leave uncertainties visible.

  • Read existing files or captured data.
  • Launch or attach to a process.
  • Inject instrumentation or run scripts/code.
  • Change process memory, registers, files, or configuration.
  • Contact network services.
  • Recover protected code or work around protections.
  • Documentation or usability only; no target interaction.
  • Not sure yet; investigation or maintainer guidance needed.

Evidence and regression coverage

  • Tests added or updated:
  • Base reproduction or other evidence:
  • User-visible CLI/MCP output (if applicable):
  • Remaining proof gaps:

For boundary fixes, identify the applicable boundary regressions
and lifecycle regressions
covered by the evidence above, and explain relevant gaps.

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

  • command — result

Compatibility, safety, and release

  • Breaking changes or migration steps:
  • Real Hopper/Ghidra, browser, or OS coverage:
  • Package or release metadata impact:
  • Security, privacy, process, or containment review:

Author readiness

Human owner:

  • I reviewed the final diff and relevant existing code, understand the change and its edge cases, and take responsibility for the complete PR, including AI-assisted work.
  • I checked the evidence above, confirmed it supports the current change, and recorded meaningful validation gaps.
  • I declare this PR ready for initial maintainer review.

Before merge

  • This PR addresses a concrete problem or an agreed enhancement.
  • Material scope and authority questions are resolved, and any required maintainer scope decision covers the final diff.
  • 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.
  • User-visible CLI/MCP changes include representative output.
  • I checked the final diff for secrets, unrelated cleanup, and unsupported claims.

Nishant1600 and others added 3 commits November 9, 2026 15:41
The CLI guide shows `rea mcp --http --host 0.0.0.0` and the matching
`environment-serve` example, and explains the Host/Origin 403 checks, but
the warning that these endpoints have no TLS or client authentication lived
only in the MCP contract reference. A reader could take `--allowed-hosts` or
`MCP_ALLOWED_HOSTS` for access control; it only guards against DNS rebinding
and cross-origin browser pages.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FZXWdmycjdemfBYLDTuc6r
REA's AArch64 relative jump-table recovery matched only the shifted-register
dispatch ADD that clang emits (`add xD, xN, xM, lsl morluto#2`). GCC's
aarch64_output_casesi loads the entry zero-extended with LDRB/LDRH and
sign-extends it in an extended-register ADD (`add x1, x0, w1, sxtb morluto#2` or
`sxth morluto#2`), so the matcher returned null and GCC-built tables kept their
table source and case labels unknown.

Accept the SXTB/SXTH extended-register form with the existing 0/2 scales.
The extend must read exactly the loaded width and makes the entries
signed; X-register extends, SXTW word tables and other scales are still
refused. The recovered record keeps the extend so the jump-table evidence
names the real dispatch instead of `LSL morluto#2`.

Add relative-switch-gcc.S, which shares relative-switch.S's symbol and case
oracle, places one case before the ADR label so its entry is negative, and
runs in the AArch64 jump-table lane for byte and halfword entries.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FZXWdmycjdemfBYLDTuc6r
Match LSL, SXTB and SXTH in one operator group and record that operator for
the jump-table evidence, instead of separate shift and extend groups. Drop
the W-register check on the extended source: SXTB/SXTH read only the low
byte or halfword whatever the register is named, and Ghidra's ADD
(extended register) constructor always prints Rm as a W register.

Evidence text for clang's shifted-register forms is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FZXWdmycjdemfBYLDTuc6r
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 9, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-09T16:16:28.943141Z c0ea540 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant