Repository navigation
docs: document Foundry port 10005 and Copilot Decisions PAT rejection - #11813
Conversation
- Add the optional Azure Foundry listener (10005) to the sidecar port tables and /reflect port references; it binds only when configured, matching containers/api-proxy/providers/foundry.js and the Dockerfile. - Add AUTH-006 for the Copilot /v1/decisions plain-text HTTP 400 rejection of personal access tokens, with a read-only, secret-safe probe. - Regenerate the diagnosis index (generated consumers left to trusted CI). Co-authored-by: Copilot <[email protected]>
There was a problem hiding this comment.
🟡 Changes recommended
Active findings remain, including a missing Foundry proxy route, stale generated diagnostics consumers, and overbroad or nondiscriminating AUTH-006 documentation and probe logic.
4 open issues
What changed in this PR
Documents Azure Foundry's optional API-proxy listener on port 10005 and adds the AUTH-006 diagnosis for Copilot Decisions personal access token rejection.
Changes:
- Documents Foundry port 10005 and optional binding behavior across authentication, sidecar, and configuration references.
- Adds AUTH-006 to the canonical diagnostics registry with symptoms, conditions, probe guidance, and workaround information.
- Extends documented
/reflectport ranges to include the optional Foundry listener.
| File | Description |
|---|---|
| docs/diagnostics/README.md | Adds AUTH-006 to the canonical diagnosis index and symptom lookup table. |
| docs/diagnostics/findings/auth/AUTH-006.json | Defines the Copilot Decisions personal access token rejection finding and diagnostic probe. |
| docs/awf-config-spec.md | Documents Foundry port 10005 and extends sidecar port assignments and /reflect port ranges. |
| docs/authentication-architecture.md | Adds Foundry to the provider-port table, architecture diagram, and internal-port documentation. |
| docs/api-proxy-sidecar.md | Adds optional Azure Foundry port 10005 to the sidecar port list. |
Review effort: Lite (adaptive)
| | AUTH-003 | auth | gh-aw-launched HTTP MCP GitHub server fails the OIDC boundary check | workaround | [`findings/auth/AUTH-003.json`](./findings/auth/AUTH-003.json) | | ||
| | AUTH-004 | auth | Primary API-proxy OIDC initialization races Squid readiness | fixed | [`findings/auth/AUTH-004.json`](./findings/auth/AUTH-004.json) | | ||
| | AUTH-005 | auth | API-proxy refuses an upstream response it cannot safely inspect for credential echoes | workaround | [`findings/auth/AUTH-005.json`](./findings/auth/AUTH-005.json) | | ||
| | AUTH-006 | auth | Copilot /v1/decisions rejects a personal access token with a plain-text HTTP 400 | workaround | [`findings/auth/AUTH-006.json`](./findings/auth/AUTH-006.json) | |
There was a problem hiding this comment.
This remains unresolved. CI showed both generated diagnosis consumers stale, but .github/agents/diagnose-awf.md is inaccessible in this workspace, so I could not safely render the complete outputs. Please run npm run diagnostics:render in an authorized environment and commit the generated consumers. The source-record fixes are in 99e988e; local diagnostics validation was also blocked because tsx was unavailable and the package mirror could not resolve.
| 10002 (Copilot), 10003 (Gemini), 10004 (Vertex AI), and 10005 (Azure | ||
| Foundry, optional; binds only when configured). |
There was a problem hiding this comment.
Added the normative FOUNDRY_BASE_URL route to http://172.30.0.30:10005 in 99e988e, noting the adapter is optional and configured-only.
| "fixed": "unknown" | ||
| }, | ||
| "status": "workaround", | ||
| "rootCause": "The Copilot Decisions endpoint does not accept personal access tokens. AWF forwards the configured credential unchanged and does not exchange a PAT for an OAuth or GitHub App token, so the upstream rejection is returned to the caller. The sidecar classifies the fully captured body as pat_unsupported in logs only. Standalone gh-aw evals run on the host runner outside AWF and cannot be fixed by proxy changes.", |
There was a problem hiding this comment.
Narrowed the AUTH-006 root cause to the reported fine-grained PAT reproduction and explicitly retained classic PAT acceptance as unverified in 99e988e.
| "status": "workaround", | ||
| "rootCause": "The Copilot Decisions endpoint does not accept personal access tokens. AWF forwards the configured credential unchanged and does not exchange a PAT for an OAuth or GitHub App token, so the upstream rejection is returned to the caller. The sidecar classifies the fully captured body as pat_unsupported in logs only. Standalone gh-aw evals run on the host runner outside AWF and cannot be fixed by proxy changes.", | ||
| "probe": { | ||
| "command": "docker logs awf-api-proxy 2>&1 | grep -E 'upstream_error_response' | grep -E 'pat_unsupported|/v1/decisions'", |
There was a problem hiding this comment.
Updated the read-only probe in 99e988e to require a single log record matching provider, exact /v1/decisions path (optionally with query), HTTP 400, and pat_unsupported.
|
@copilot merge main and resolve conflicts |
…-10005-decisions-AUTH-006-ee966b393f09796c Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Merged |
|
✅ Copilot review passed with no inline comments. @github-actions[bot] Add the |
Documentation PreviewDocumentation has been built for this PR. To view locally:
Built from commit b585253 |
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: Copilot App <[email protected]>


Caution
Protected files were modified in this change.
This pull request is in
request-reviewmode and requires explicit human scrutiny before merge.Protected files:
README.mdAllow intentional protected-file changes
If this workflow is intended to modify these files, add specific filenames or folder prefixes to
safe-outputs.create-pull-request.protected-files.excludein the workflow Markdown frontmatter. For example, to allow.changeset/*, exclude the folder using.changeset/:Keep your existing policy and exclusions. Folder exclusions use path prefixes, not glob patterns, and allow all files beneath that folder, including subfolders. Other protected files still require review. If
allowed-filesis configured, these paths must also match it. Rungh aw compileafter updating the workflow.Summary
reviewQueue.firstTime(50 of 204 reviewed this run; 0 deferred)./reflectport ranges stopped at 10004. The Azure Foundry adapter binds on 10005 whenFOUNDRY_API_TARGETandFOUNDRY_API_KEYare set.pat_unsupportedincontainers/api-proxy/upstream-log.js). Accepted credentials for/v1/decisionsremain unverified.Documentation Changes
docs/authentication-architecture.md: add the 10005 Foundry row and diagram entry; replace "five HTTP servers" with "one per provider adapter" and note 10005 is optional; extend the internal-port note to 10005.docs/api-proxy-sidecar.md: add 10005 (optional, binds only when configured) to the sidecar container port list.docs/awf-config-spec.md: add 10005 to the sidecar port assignments (§ sidecar rule 5) and to the/reflectport range in §10.2, §11.3, and §11a.3, §11b.3.Canonical Registry Changes
auth, statusworkaround): Copilot/v1/decisionsrejects a personal access token with a plain-text HTTP 400. Version scopeunknown. Probe is a read-onlydocker logs | greponupstream_error_responseandpat_unsupported, with no live Decisions request. Provenance: PR Clarify Copilot Decisions PAT support and rejection diagnostics #11289, PR docs: clarify Copilot Decisions authentication and egress scope #11310, gh-aw issue #75637,containers/api-proxy/upstream-log.js,server.decisions.test.js.docs/diagnostics/README.mdwas regenerated and includes AUTH-006.npm run diagnostics:validatepasses with 36 findings..github/workflows/shared/diagnosis-findings.mdand.github/agents/diagnose-awf.mdwere not included, per the allowed-files contract.npm run diagnostics:checkreports them stale until trusted CI or a reviewer runsnpm run diagnostics:render.Validation
main:containers/api-proxy/providers/foundry.js(port 10005,alwaysBind: false,isEnabledrequires target and key);containers/api-proxy/providers/index.js(Foundry registered);containers/api-proxy/Dockerfile(EXPOSEincludes 10005);containers/api-proxy/server-factory.js(/reflectand/healthon every bound port);containers/api-proxy/startup.js(binds onlyalwaysBind || isEnabled());containers/api-proxy/provider-env-constants.json(FOUNDRY_API_KEY,FOUNDRY_API_TARGET);containers/api-proxy/proxy-utils.js(stripped-header list unchanged, consistent with docs).npm run diagnostics:validate(pass),npm run diagnostics:freshness(no overdue records),npx jest scripts/diagnostics(78 of 79 pass; the single failure is the expected generated-artifact sync check for the two consumers excluded from this PR).Authorizationcontent. The only match is the literal textgithub_pat_*in a description. No credential-bearing URLs or copied headers.Review coverage and backlog
covered, 46no-impactwith boundary owner, 1needs-evidence.needs-evidencebecause it overlaps the auth-matrix Copilot routing rows and its file list was filtered.Sources