feat(egress-gate): add attested Pi prompt admission - #38
Conversation
bc652d4 to
0540f54
Compare
Phase 0 Review RecordFrozen range: Scope reviewed: final admission names/contracts, registry-derived bindings, removal of the superseded receipt path, immutable fork/proto pin, runtime/example/docs updates, and provider fixture provenance. Independent review:
Validation:
POC scope remained constrained: 22 files in the main Phase 0 commit with net one-line deletion, followed by the focused two-file interoperability fix. No shims, speculative infrastructure, or unrelated cleanup were added. |
Phase 1 Review RecordFrozen range: Scope reviewed: exact seven-origin runtime dispatch, the shared text adapter, distinct assistant/bash adapters, immutable-field validation, Describe bindings, cross-language interoperability, and focused tests. Independent review found one concrete high-severity interoperability defect: Python byte equality rejected valid JavaScript number spellings in arbitrary assistant tool arguments. The minimal fix in Scope audit:
Validation:
|
Phase 2 Review RecordFrozen range: Scope reviewed: stateless v2 whole-context hash/count binding, ordered user/tool entry derivation, Chat Completions and Responses extraction, send-time replacements, pre/post gate checks, append-time empty attestations, runtime handle lookup, and shared JS/Python vectors. Independent findings and disposition:
Scope audit:
Validation:
|
Phase 3 Review RecordFrozen range: Scope reviewed: real self-verifying demo cases, printable commands, content-safe reason-code logging, workload readiness removal, base64 runtime bodies, architecture/example docs, and generated mirror workflow. Independent findings and fixes:
Scope audit:
Validation:
|
Documentation previewBuilt from |
Phase 4 Review RecordReviewed head: Scope remained POC-bounded: the launcher consumes and closes the inherited capability FD, the bridge adapter attaches one bearer header, the existing demo adds an unauthenticated negative control, and focused documentation/tests describe the capability and residual same-user memory-reading risk. Pi and provider behavior are untouched. The final documentation follow-up replaces the stale middleware-field opt-out with the actual supervisor startup flag and updates the canonical architecture page. Its generated mirror was staged and byte-checked through the documented workflow. Independent security and scope reviews: clean; no remaining blocker/high/medium findings. Validation:
|
Final Review RecordReviewed head: Independent Research, documentation, security, and holistic cross-repository reviews are clean: no remaining blocker, high, or medium findings. The final documentation accurately states the implemented POC boundaries, including assistant-thinking coverage, immutable assistant tool calls, transport-history fail-closed limits, capability residual risk, and the checked-in endpoint/catalog scope of Validation:
The real The PR remains draft; no merge/readiness change was made. |
Signed-off-by: Johnny Greco <jogreco@nvidia.com>
Summary
Add an attested rendered-prompt admission path for managed Pi sandboxes while preserving the existing generic HTTP-only Egress Gate mode.
This depends on the reviewed fork PRs:
Changes
--extensionoptiondemo.shhelper whose exact commands can always be inspected with--print, with no mock session or providerSecurity boundary
The receipt attests the latest rendered prompt. It does not attest the complete conversation/provider payload or authenticate which same-sandbox process called the loopback bridge. Those limits are explicit; unsupported automatic continuations fail closed, and Egress Gate evaluates the actual outgoing HTTP request before forwarding.
Testing
make check— 340 passed; formatting, lint, type/import checks, security checks, and dependency audit passedmodels.jsonloaded through the Pi fork and exposedopenai-chat-completions/gpt-4o-miniRelated issue
None. This is research integration work coordinated across the linked forks.