fix(security): preserve external JSON decisions across sync cancel faults - #676
Conversation
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthrough외부 JSON 스트림의 취소 처리를 공통 헬퍼로 통합했습니다. 동기 취소 예외를 무시하도록 변경했습니다. 타임아웃과 바이트 제한 경로의 결과를 검증하는 테스트를 추가했습니다. Changes외부 JSON 스트림 취소 처리
Estimated code review effort: 2 (Simple) | ~15 minutes Change: Bug fix ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
seonghobae
left a comment
There was a problem hiding this comment.
Exact-head review for f8de7fc27d475c76477271fa50dd7032afd82a6c: verified causal RED on test-only 69c99113b523381661ed442c4d8667b0af1acfc9; the intermediate application-CI failure on 42c6c62... was a stale protected static authority assertion and is converged without weakening runtime behavior. Final diff is limited to the guarded best-effort cancellation helper, two hostile synchronous-cancel regressions, and the protected authority-test shape. Application CI 34694527820, reviewer-ci 34694527834, Security Scan 34694527843, and patch-validator-image 34694527873 are all terminal SUCCESS on this exact head. No unresolved inline review threads. This supports normal source merge only, not immutable release/deployment/production evidence.
…nc-cancel-authority-20260912 docs(noema): converge #676 synchronous-cancel authority
Purpose
Repair #674 after the #673/#675 single-writer lane released. The target is Noema's existing base credential-exchange external JSON reader only: synchronous
reader.cancel()cleanup faults must not replace an already-decided read-deadline or byte-limit failure. OIDC/GitHub identity, provider routing, outbound policy, credentials, quarantine/security authority, release/deployment authority, and foreign domain truth remain outside this repair.Verified RED
Test-only exact
69c99113b523381661ed442c4d8667b0af1acfc9added hostile synchronous-cancel coverage for both cancellation sites without changing production source. Hosted application CI run34694095240checked out that exact head, passed toolchain/install/typecheck, then failed release tests with 2 failed / 4,737 passed:src/index.ts:443, replacing the established read-timeout decision;SyntaxError("JSON response exceeded byte limit")was never constructed because synchronous cancellation threw first.Minimal causal repair
Source exact
42c6c62fefa3316c7e1b977e2a79e93d16e3bab9wrapped the existing best-effort cancellation in a small localtry/catch, still sinks asynchronous rejection, never awaits cancellation completion, and reuses the helper at the deadline and byte-limit sites. Its application CI then failed 1 / 4,739 only because the protected executable authority test still required two duplicated rawreader.cancel().catch(...)call sites. That was a stale test/contract finding, not a reason to weaken the runtime repair.Final exact
f8de7fc27d475c76477271fa50dd7032afd82a6cconverges that protected test to the guarded helper shape while retaining the #668 authority assertions. The existing 65,536-byte ceiling, 10-second absolute deadline, fixed retained buffer, fatal UTF-8/duplicate-key JSON admission, reader-lock cleanup, and fail-closed caller behavior remain unchanged. Diff review shows only the guarded cancellation helper, the protected authority-test convergence, and the two hostile regressions.Exact-head GREEN
All required hosted gates are terminal SUCCESS on
f8de7fc27d475c76477271fa50dd7032afd82a6c:34694527820346945278343469452784334694527873No force push, destructive rebase, self-approval, or gate weakening was used. This PR repairs only the source defect in #674; canonical CHANGELOG/product-gap documentation and immutable release/deployment/production evidence remain separate successor authority.
Summary by CodeRabbit
버그 수정
테스트