Skip to content

[codex-api] observe auth updates on Responses WebSockets#25952

Closed
cooper-oai wants to merge 6 commits into
cooper/codex-native-integrity/3from
cooper/codex-native-integrity/4
Closed

[codex-api] observe auth updates on Responses WebSockets#25952
cooper-oai wants to merge 6 commits into
cooper/codex-native-integrity/3from
cooper/codex-native-integrity/4

Conversation

@cooper-oai

@cooper-oai cooper-oai commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

Summary

  • apply URL-aware auth attachment and response observation to Responses WebSocket handshakes
  • observe successful, rejected, and wrapped-error headers and refresh the stream auth context after updates
  • bypass ambient proxies for explicit loopback WebSocket providers

Stack

PR 4 of 15. Depends on #25932. Followed by #25989.

Validation

  • just fmt
  • just test -p codex-api
  • just fix -p codex-api
  • just bazel-lock-check
  • git diff --check

@cooper-oai

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown
Contributor

Codex Review: Didn't find any major issues. Delightful!

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@cooper-oai cooper-oai marked this pull request as ready for review June 2, 2026 22:32
@cooper-oai cooper-oai requested a review from a team as a code owner June 2, 2026 22:32

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 803027bca1

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread codex-rs/core/Cargo.toml Outdated
@cooper-oai cooper-oai force-pushed the cooper/codex-native-integrity/3 branch 2 times, most recently from 13640ba to 6ba3d54 Compare June 3, 2026 02:51
@cooper-oai cooper-oai force-pushed the cooper/codex-native-integrity/4 branch from 803027b to 32cf2ff Compare June 3, 2026 02:53
@cooper-oai cooper-oai changed the title [codex] wire native integrity state surfaces [codex-api] observe auth updates on Responses WebSockets Jun 3, 2026
@cooper-oai

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown
Contributor

Codex Review: Didn't find any major issues. Already looking forward to the next diff.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@cooper-oai

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 18d02d2577

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread codex-rs/codex-api/src/endpoint/responses_websocket.rs Outdated
Comment thread codex-rs/codex-api/src/endpoint/responses_websocket.rs Outdated
Comment thread codex-rs/codex-api/src/endpoint/responses_websocket.rs
@cooper-oai

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9704d8d222

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread codex-rs/codex-api/src/endpoint/responses_websocket.rs Outdated
Comment thread codex-rs/codex-api/src/endpoint/responses_websocket.rs Outdated
@cooper-oai

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d2b67b96e9

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread codex-rs/codex-api/src/endpoint/responses_websocket.rs
Comment thread codex-rs/codex-api/src/endpoint/responses_websocket_auth.rs Outdated
@cooper-oai

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown
Contributor

Codex Review: Didn't find any major issues. 🎉

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@cooper-oai cooper-oai force-pushed the cooper/codex-native-integrity/3 branch from 1d49c22 to 2bd99fa Compare June 3, 2026 09:54
@cooper-oai cooper-oai force-pushed the cooper/codex-native-integrity/4 branch from caa07aa to b2df930 Compare June 3, 2026 09:54
@cooper-oai

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b2df930c51

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +536 to +540
let loopback_address = url.host_str().and_then(|host| {
host.parse::<IpAddr>()
.ok()
.filter(IpAddr::is_loopback)
.and_then(|_| url.port_or_known_default().map(|port| (host, port)))

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Bypass proxies for localhost WebSocket providers

The local tokio-tungstenite connect path honors HTTP_PROXY/ALL_PROXY unless bypassed, but this new bypass only matches numeric loopback IPs because localhost fails host.parse::<IpAddr>(). A provider configured as http://localhost:11434/... therefore still falls through to connect_async_tls_with_config and can be tunneled through an ambient proxy in enterprise/CI environments, breaking local Responses WebSocket providers even though the comment says explicit loopback providers must not be proxied. Include localhost/name-resolution loopback in this bypass.

Useful? React with 👍 / 👎.

@cooper-oai cooper-oai force-pushed the cooper/codex-native-integrity/3 branch from 2bd99fa to 1bb047e Compare June 3, 2026 10:12
@cooper-oai cooper-oai force-pushed the cooper/codex-native-integrity/4 branch from b2df930 to bba3d95 Compare June 3, 2026 10:12
@cooper-oai

Copy link
Copy Markdown
Contributor Author

Superseded by the collapsed seven-PR stack: #26137 through #26143. Closing this prototype layer to keep review focused.

@cooper-oai cooper-oai closed this Jun 3, 2026
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