fix(sandbox): real creds when no tls:terminate#528
Open
ericcurtin wants to merge 1 commit intoNVIDIA:mainfrom
Open
fix(sandbox): real creds when no tls:terminate#528ericcurtin wants to merge 1 commit intoNVIDIA:mainfrom
ericcurtin wants to merge 1 commit intoNVIDIA:mainfrom
Conversation
Without a `tls: terminate` endpoint in the sandbox policy, the proxy cannot intercept HTTPS traffic to rewrite credential placeholders in request headers. Placeholder values reached upstream APIs verbatim, causing 401 errors and immediate process exit (e.g. `openshell sandbox create -- claude` exiting right after the Claude Code wizard appeared). N/A - Skip placeholder mechanism when policy has no `tls: terminate` endpoints; pass real provider credentials directly to child process - Emit a warning log directing operators to add `protocol: rest` and `tls: terminate` to HTTPS endpoints for secure credential rewriting - Add `has_tls_terminate_endpoints` field to `SandboxPolicy` populated from the proto network policy at startup - Update `testdata/sandbox-policy.yaml` to configure `api.anthropic.com:443` with correct `protocol`, `tls`, and `enforcement` fields - [x] `mise run pre-commit` passes - [x] Unit tests added/updated (285 pass, 0 failed) - [ ] E2E tests added/updated (if applicable) - [x] Follows Conventional Commits - [ ] Commits are signed off (DCO) - [ ] Architecture docs updated (if applicable) Signed-off-by: Eric Curtin <eric.curtin@docker.com>
Collaborator
|
Thank you. Yes we've been discussing this. I created #533 which would solve for this as well. |
Collaborator
|
We do not want to accept the risk of having secrets available to the child process and there are other corner cases where the manual setting of TLS termination has caused connection failures. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Without a
tls: terminateendpoint in the sandbox policy, the proxy cannot intercept HTTPS traffic to rewrite credential placeholders in request headers. Placeholder values reached upstream APIs verbatim, causing 401 errors and immediate process exit (e.g.openshell sandbox create -- claudeexiting right after the Claude Code wizard appeared).Related Issue
N/A
Changes
tls: terminateendpoints; pass real provider credentials directly to child processprotocol: restandtls: terminateto HTTPS endpoints for secure credential rewritinghas_tls_terminate_endpointsfield toSandboxPolicypopulated from the proto network policy at startuptestdata/sandbox-policy.yamlto configureapi.anthropic.com:443with correctprotocol,tls, andenforcementfieldsTesting
mise run pre-commitpassesChecklist