Repository navigation
AB#3715428: WI-2 Implement WAM DPoP routing outcome handling and cache policy - #8789
Merged
Hector Morales (hectormmg) merged 110 commits intoNov 4, 2026
Merged
Hector Morales (hectormmg) merged 110 commits into
Hector Morales (hectormmg) merged 110 commits into
Conversation
Add WAM broker request and response contract fields for platform brokered DPoP. Keep shared platform auth requests canonical and map extension-only no-cache PoP parameters at the extension transport boundary. Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Map DPoP binding request and response fields through the platform authentication DOM contract. Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: edf273d3-ad5a-479e-8062-7c7ee8b1db37
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: edf273d3-ad5a-479e-8062-7c7ee8b1db37
Add WAM broker request and response contract fields for platform brokered DPoP. Keep shared platform auth requests canonical and map extension-only no-cache PoP parameters at the extension transport boundary. Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Map DPoP binding request and response fields through the platform authentication DOM contract. Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: edf273d3-ad5a-479e-8062-7c7ee8b1db37
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: edf273d3-ad5a-479e-8062-7c7ee8b1db37
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: edf273d3-ad5a-479e-8062-7c7ee8b1db37
Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 78f9666b-ef4d-4799-bc77-e060b95c5158
Implement AB#3715428 WAM DPoP routing, fail-closed outcome handling, proof selection, and cache policy. Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 78f9666b-ef4d-4799-bc77-e060b95c5158
…tion-library-for-js into copilot/ab-3715428-wam-dpop-outcome-handling
Contributor
There was a problem hiding this comment.
Pull request overview
Implements platform broker (WAM/DOM/extension) DPoP request/response handling in @azure/msal-browser, including outcome validation (L3 broker proof vs L1 local-sign fallback) and updated request mapping for proof context. Also exposes the shared DpopProofGenerator via the msal-common browser entrypoint for internal consumption.
Changes:
- Adds DPoP routing/outcome validation and proof generation behavior to
PlatformAuthInteractionClient(including new broker request fields liketokenType="dpop_proof",preferBinding,reqCnf, and proof-context propagation). - Extends native broker request/response contracts to carry DPoP-specific fields across Extension + DOM broker paths.
- Adds/updates test coverage for L3/L1 outcomes and no-cache proof context mapping; adds beachball changefiles.
Reviewed changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| lib/msal-common/src/exports-browser-only.ts | Exports DpopProofGenerator from the browser-only entrypoint. |
| lib/msal-common/apiReview/msal-common.api.md | Adds API review surface for DpopProofGenerator (internal). |
| lib/msal-browser/src/interaction_client/PlatformAuthInteractionClient.ts | Core DPoP broker request preparation, outcome validation, proof generation, and key cleanup logic. |
| lib/msal-browser/src/broker/nativeBroker/PlatformAuthRequest.ts | Adds preferBinding and extraParametersNoCache to the broker request types. |
| lib/msal-browser/src/broker/nativeBroker/PlatformAuthResponse.ts | Adds DPoP fields to broker response types (token type, proof, binding key id, attestation flag). |
| lib/msal-browser/src/broker/nativeBroker/PlatformAuthProvider.ts | Allows platform auth for the DPoP authentication scheme. |
| lib/msal-browser/src/broker/nativeBroker/PlatformAuthExtensionHandler.ts | Maps proof context into extraParametersNoCache for extension IPC; removes PII-heavy trace logging. |
| lib/msal-browser/src/broker/nativeBroker/PlatformAuthDOMHandler.ts | Maps proof binding fields for DOM broker requests/responses; removes PII logging on stringify failures. |
| lib/msal-browser/test/interaction_client/PlatformAuthInteractionClient.spec.ts | Adds interaction tests for L3/L1 outcomes, cache mutation expectations, and validation failure cases. |
| lib/msal-browser/test/broker/PlatformAuthProvider.spec.ts | Updates provider expectations to allow DPoP when initialized. |
| lib/msal-browser/test/broker/PlatformAuthExtensionHandler.spec.ts | Extends extension IPC contract tests for DPoP request/response fields. |
| lib/msal-browser/test/broker/PlatformAuthDOMHandler.spec.ts | Adds DOM mapping tests for DPoP request/response fields; adjusts PII logging expectations. |
| change/@azure-msal-browser-wam-dpop-outcomes.json | Beachball changefile for WAM DPoP outcomes/caching policy. |
| change/@azure-msal-browser-platform-broker-dpop.json | Beachball changefile for platform broker DPoP contract support. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Hector Morales (hectormmg)
changed the base branch from
dev
to
copilot/ab-3715427-wam-dpop-contract-types
August 25, 2026 21:47
Add WAM broker request and response contract fields for platform brokered DPoP. Keep shared platform auth requests canonical and map extension-only no-cache PoP parameters at the extension transport boundary. Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Map DPoP binding request and response fields through the platform authentication DOM contract. Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: edf273d3-ad5a-479e-8062-7c7ee8b1db37
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: edf273d3-ad5a-479e-8062-7c7ee8b1db37
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: edf273d3-ad5a-479e-8062-7c7ee8b1db37
Hector Morales (hectormmg)
force-pushed
the
copilot/ab-3715427-wam-dpop-contract-types
branch
from
August 25, 2026 21:51
20e4b35 to
99f5786
Compare
Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 78f9666b-ef4d-4799-bc77-e060b95c5158
Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 78f9666b-ef4d-4799-bc77-e060b95c5158
Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 78f9666b-ef4d-4799-bc77-e060b95c5158
Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Developer Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 78f9666b-ef4d-4799-bc77-e060b95c5158
Co-authored-by: Forge <forge-bot@entra.github.io> Forge-Agent: Coder
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 9aeede78-98ca-464d-bc07-6eb95602bb3a
…-dpop-outcome-handling
Preserve legacy PoP key ownership in platform cache requests, avoid coalescing concurrent DPoP proofs, and harden L1/L3 lifecycle coverage. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 9aeede78-98ca-464d-bc07-6eb95602bb3a
Resolve the browser compatibility map conflict by retaining both DPoP key-persistence and legacy polling guidance. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 9aeede78-98ca-464d-bc07-6eb95602bb3a
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 9aeede78-98ca-464d-bc07-6eb95602bb3a
Lalima Sharda (lalimasharda)
approved these changes
Oct 30, 2026
Member
Author
|
/azp run |
|
Azure Pipelines: Successfully started running 4 pipeline(s). |
Member
Author
|
/azp run |
|
Azure Pipelines: Successfully started running 4 pipeline(s). |
Hector Morales (hectormmg)
enabled auto-merge (squash)
November 4, 2026 00:02
Hector Morales (hectormmg)
deleted the
copilot/ab-3715428-wam-dpop-outcome-handling
branch
November 4, 2026 23:17
This was referenced Nov 13, 2026
Hector Morales (hectormmg)
added a commit
that referenced
this pull request
Nov 20, 2026
…hentication DOM API (#8968) ## Summary Implements AB#3788751 - L3-WI-2F Implement DPoP outcome handling for Platform Authentication DOM API. Enable DOM transport support for the broker DPoP handling introduced in #8789, including the resource-nonce support from #8981. - Use normal DOM transport discovery and the existing shared L1/L3 validation and key/cache lifecycle. The shared interaction-client implementation is unchanged from `dev`. - Pass `properties.token_type`, `properties.DPoP`, and `properties.binding_attested` unchanged to shared processing, rather than creating top-level aliases or parsing attestation in the DOM handler. - L3 returns the broker proof unchanged, without local signing or access-token/proof caching. L1 retains MSAL-owned keys and local resource-proof generation. - Preserve existing DOM error mapping, broker descriptions, exceptions, Bearer/legacy-PoP behavior, and resource-nonce forwarding. Never serialize internal `bindingPreferenceSent` state. ## Validation - 336 focused tests passed across the DOM handler, provider, extension handler, silent-request helpers, and shared interaction client. - Built `msal-common` before `msal-browser`; browser build passed. - Lint passed with three existing warnings. Formatting, API Extractor (`--local`), Beachball, documentation links, and `git diff --check` passed. - Coverage includes extension/DOM L1/L3 equivalence, popup/silent/redirect flows, malformed canonical outcomes, key ownership, cache replacement, disabled access-token caching, and consistent error/exception handling across schemes. ## Managed-device validation VM-validated the DOM L3 DPoP flow using the rebuilt sample from `86cfcfb25`, including the review cleanups. Seven scenarios passed: L3 acquisition, redirect, repeated broker requests without MSAL access-token caching, concurrent distinct proofs, Graph nonce challenge/retry (HTTP 200), wrong-method rejection (HTTP 401), and app-provided key rejection. The subsequent `89528a60e` change only restores the existing opt-in serialization-error diagnostic and its unit-test assertion; local validation passed. The external sample is not part of this PR. ```text <!-- BEGIN pr-telemetry --> assistance: agentic-cli type: feature agent-tool: copilot-cli agent-model: gpt-6.1-sol work-item: AB#3788751 <!-- END pr-telemetry --> ``` --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: d23898df-9767-4bfd-85c8-8b156caa2619
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
Implements WAM brokered DPoP routing and response-driven L3/L1 outcome handling with fail-closed validation and request-bound proof cache policy.
Implements
Verified broker contract
tokenType=dpop+proofwithreqCnf,preferBinding=attested, method, and URI context.properties.token_type,properties.DPoP, andproperties.binding_attested.properties.token_type=dpop+proofidentifies an L3 broker-proof outcome;properties.token_type=DPoPidentifies L1 fallback to the caller-owned key.executeGetTokenif invoked directly.Acceptance criteria (AB#3715428)
tokenType=dpop+proof,reqCnf,preferBinding, method, and URI context.How to validate
dpop+proofoutcomes returnproperties.DPoPwithout local signing or access-token caching.DPoPfallback signs locally only with an MSAL-owned key and retains key-partitioned cache behavior.Validation
PlatformAuthInteractionClientsuite: 151 passed.git diff --checkpassed; lint reports only pre-existing warnings.Bundle impact
The official minified
msal-browserbundle increases by 11,191 bytes raw, 2,334 bytes gzip, and 1,883 bytes Brotli versusorigin/dev(+3.84%,+3.21%, and+3.09%, respectively).Created by Forge
create-prand validated for human review.assistance: agentic-cli
type: feature
agent-tool: copilot-cli
agent-model: gpt-5.6-sol
work-item: AB#3715428