Repository navigation
fix(exa): redact reflected search credentials - #178745
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex review: needs maintainer review before merge. What this changesThis PR redacts reflected Exa credentials from HTTP error bodies and status text using existing Plugin SDK helpers. Example: Exa returns HTTP 503 with “upstream rejected fixture-exa-opaque-credential”.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep open: this maintainer-authored PR fixes a credential leak still present on current main, and source review found no actionable introduced defects. Priority: P2 Before mergeNone. FindingsNone. Tests
Agent review detailsHow this fits togetherThe Exa plugin translates web_search arguments and configured credentials into an HTTP search request, then returns normalized results or a provider error to the calling agent. flowchart LR
A[Agent web search call] --> B[Exa plugin]
B --> C[Exa HTTP endpoint]
C --> D[Bounded error reader]
D --> E[SDK credential redactor]
E --> F[Provider error returned to agent]
Technical reviewBest possible solution: Keep the Exa request owner and reuse the SDK redactor for both bounded error bodies and status-text fallback. Do we have a high-confidence way to reproduce the issue? Current-main source directly copies reflected response text into the thrown error; the submitted tests supply concrete body and status-text cases, but no target code was executed during this read-only review. Is this the best way to solve the issue? The patch is the smallest complete repair using existing owners: pass the actual outgoing headers to the SDK error reader and redact the fallback without introducing another policy layer. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 05ade6d2df13. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource +11, Tests +22. Total +33 across 2 files. Added test files: 0. View PR surface stats
LabelsLabel changes:
Label justifications:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 20, 2026, 4:29 PM ET / 20:29 UTC. |
Exact-head CI attributionReviewed head: All selected jobs completed. Security, types, lint, package boundaries, and every selected test job passed. No job was rerun and the branch was not updated to obtain green.
The informational failure table calls the ratchet new because its comparison main job passed and selected scope was not compared. The source-bound evidence above establishes inheritance from the recorded, older baseline; the later main repair explains that comparison. Failed CI is not being relabeled green. Two historical PR-context jobs ( Focused proof: all 17 Exa provider tests passed, including both credential-reflection controls through the actual search-tool route. Targeted package types, syntax lint/format, suppression tests (14), whitespace, and scoped runtime/static cycles (zero) passed. Fresh independent P0–P2 review found no actionable defects. No paid live Exa request was made. This uses the scoped maintainer-authorized inherited-failure exception, pinned to the reviewed head. Security, required reviews, and every other required check remain enforced. Exa's credential redaction, numeric status fields, bounded errors, cancellation, cache behavior, and successful result contract remain protected. |
Native infrastructure timeout and guarded fallbackTwo investigated native admin submissions for head The complete exact-head failure table and source-bound inherited attribution remain applicable. Required-check inventory contains only the failed Actions CI gate and combined CI/security status; independent dependency and security-sensitive review statuses passed, as did Opengrep and the precise security scan. No enforced review is outstanding. Under the campaign's explicit two-infrastructure-failure fallback authority, a direct squash may be submitted with the exact reviewed SHA guard only after the native read-only evidence verifier independently passes current failed-CI qualification, required reviews/threads, security publisher validation, and live writer/bypass authority. This bypasses the unavailable native mergeability projection, not those checks. Failed CI remains recorded as failed. The provider still evaluates the SHA-pinned merge request. |
What Problem This Solves
Exa search errors included upstream response text verbatim. An upstream error reflecting the active x-api-key could expose that credential in tool-visible error text, including through the HTTP status-text fallback.
User Impact
Exa failures no longer expose the active search credential when the upstream service reflects it in an error. No configuration or migration is required.
Why This Change Was Made
Use the existing Plugin SDK arbitrary-header error redactor for the bounded error body and status text. Keep the Exa error prefix, numeric status/statusCode, body limit, cancellation, and request behavior unchanged.
Best-effort tradeoffs accepted
None. This is a credential-redaction bug fix, not removal of a guard.
Evidence
Both new regression cases fail on the original actual search-tool route and pass with the fix. All 17 Exa provider tests pass. Targeted Exa package typecheck, changed-file syntax lint/format, mandatory lint-suppressions (14 tests), and scoped runtime/static cycle checks (zero cycles) pass. Independent review found no actionable P0–P2 defects. Hosted exact-head CI is the broad gate; no paid live request was made.
Production delta: +11 lines (22 added, 11 removed). Test delta: +22 lines. Separate small bug fix discovered during the plugin cleanup sweep.