Skip to content

fix(openai): normalize Codex untrusted_content on HTTP Responses - #8948

Closed
koeria wants to merge 1 commit into
Wei-Shaw:mainfrom
koeria:fix/8769-codex-untrusted-content-context
Closed

koeria wants to merge 1 commit into
Wei-Shaw:mainfrom
koeria:fix/8769-codex-untrusted-content-context

Conversation

@koeria

@koeria koeria commented Nov 19, 2026

Copy link
Copy Markdown

#8769 allowlisted agent.untrusted_context for standalone Codex additional context on HTTP /v1/responses. Codex still emits the fallback name untrusted_content when an additional-context key sanitizes to empty (codex-rs/context-fragments/src/additional_context.rs, namespace agent, no call_id). Those items are still rejected with 400 on current main.

This adds untrusted_content to the same allowlist and normalizes it to a user message, matching #8769. This is the small allowlist follow-up invited on #8680 after #8769 was merged.

Existing malformed or real tool-result cases still fail closed.

Tests: go test -tags=unit ./internal/handler -run TestNormalizeCodex

The project CLA has not been signed on this PR.

Wei-Shaw#8769 allowlisted agent.untrusted_context but not the Codex fallback
name untrusted_content, used when an additional-context key sanitizes
to empty. Normalize that name the same way so HTTP /v1/responses no
longer returns 400. Follow-up invited on Wei-Shaw#8680 after Wei-Shaw#8769 merged.
@github-actions

github-actions Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

All contributors have signed the CLA. ✅
Posted by the CLA Assistant Lite bot.

koeria commented Nov 19, 2026

Copy link
Copy Markdown
Author

I have read the CLA Document and I hereby sign the CLA

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