fix(security): harden SDK auth transports#969
Open
bokelley wants to merge 1 commit into
Open
Conversation
| ADCPError.__init__(self, message, agent_id=agent_id, suggestion=suggestion) | ||
|
|
||
|
|
||
| class IdempotencyScopeError(ADCPTaskError): |
| CONFIG_DIR.mkdir(parents=True, exist_ok=True, mode=0o700) | ||
| try: | ||
| CONFIG_DIR.chmod(0o700) | ||
| except OSError: |
| with open(temp_file, "w") as f: | ||
| try: | ||
| temp_file.unlink() | ||
| except FileNotFoundError: |
| temp_file.replace(CONFIG_FILE) | ||
| try: | ||
| CONFIG_FILE.chmod(0o600) | ||
| except OSError: |
Contributor
|
The automated review encountered an issue (possibly reached max turns, timed out, or failed to post the final This is an automated message from the Argus AI review workflow. |
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.
Harden SDK-owned authenticated transports by rejecting non-loopback HTTP for auth/signing, disabling ambient proxy env use, and securing MCP streamable HTTP/SSE factories.
Fail idempotency closed when an idempotency key arrives without caller identity, tighten CLI config file permissions, and preserve AAO divergence SSRF/IP-pinning defaults.
This is an intentional security behavior change for non-loopback plaintext HTTP auth/signing users, who should move to HTTPS or loopback-only local development.
Validated with ruff, commit hooks, expert subagent review, and the full pytest suite: 5970 passed, 33 skipped, 10 deselected, 1 xfailed.