feat: support aal2 gated enrollment - #10374
Merged
Merged
Conversation
mathieuartu
enabled auto-merge
September 22, 2026 20:26
gantunesr
reviewed
Sep 23, 2026
gantunesr
approved these changes
Sep 23, 2026
gantunesr
left a comment
Member
There was a problem hiding this comment.
Looks good, just left one question
pull Bot
pushed a commit
to Reality2byte/core
that referenced
this pull request
Sep 23, 2026
## Explanation Publish `@metamask/profile-sync-controller@32.3.0` so clients can consume the additive changes that have accumulated on `main` since 32.2.0, including the `pairedIdentifierIds` field on `UserProfile` in `srpSessionData` (MetaMask#10394). Minor bump: the release only adds new, optional API surface (AAL2-gated MFA enrollment, elevated tokens for credential enrollment, `pairedIdentifierIds`) and bumps the internal `immer` dependency. Nothing existing changes, so it is not breaking. All 15 workspace packages that depend on `@metamask/profile-sync-controller` now pin `^32.3.0`; none are being published in this release. `yarn.lock` is updated accordingly. ## References - Add `pairedIdentifierIds` to `UserProfile`: MetaMask#10394 - MFA / AAL2 enrollment support: MetaMask#10374 - Bump `immer` from `^9.0.6` to `^9.0.21`: MetaMask#10331 ## Checklist - [x] I've updated the test suite for new or updated code as appropriate - [x] I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate - [x] I've communicated my changes to consumers by [updating changelogs for packages I've changed](https://github.com/MetaMask/core/tree/main/docs/processes/updating-changelogs.md) - [ ] I've introduced [breaking changes](https://github.com/MetaMask/core/tree/main/docs/processes/breaking-changes.md) in this PR and have prepared draft pull requests for clients and consumer packages to resolve them <!-- CURSOR_SUMMARY --> --- > [!NOTE] > **Medium Risk** > Releases auth/MFA and profile-session API surface; the diff is dependency pins only, but consumers will pick up security-sensitive behavior from 32.3.0. > > **Overview** > This release PR cuts **`@metamask/profile-sync-controller@32.3.0`** (monorepo **`1280.0.0`**) and propagates it across the workspace. The **15** packages that depend on profile sync now pin **`^32.3.0`** in `package.json`, with matching **Unreleased** changelog notes and **`yarn.lock`** updates; those dependents are **not** republished here. > > The **32.3.0** changelog section documents what clients get from this publish: **AAL2-gated MFA enrollment** (elevated `accessToken` for `beginMfaEnrollment`, new MFA error codes / `StepUpRequiredError`, `retry_after_seconds` handling), **`pairedIdentifierIds`** on `UserProfile` in `srpSessionData`, and an internal **`immer`** bump. No runtime code changes appear in this diff—only versioning and release notes. > > <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 3a7ced6. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup> <!-- /CURSOR_SUMMARY --> --------- Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
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.
Explanation
References
Related to: https://consensyssoftware.atlassian.net/browse/MUL-2274
Checklist
Note
Medium Risk
Changes authentication/MFA enrollment token selection and error handling on security-sensitive paths; clients must handle
aal2_requiredand step-up correctly to avoid enrollment failures.Overview
Adds AAL2-gated MFA enrollment so enrolling a second or later credential can use an elevated access token.
beginMfaEnrollmentaccepts an optionalaccessToken, andAuthenticationController.beginCredentialEnrollmentpasses the live step-up token fromgetElevatedProfileToken()when present; otherwise the base session token is used and the server may respond withaal2_required.The MFA SDK is aligned with the latest auth API: new codes
email_socially_verified,multi_primary_srp, andaal2_required(mapped toStepUpRequiredError),retry_after_secondson error bodies (preferred overRetry-AfterforretryAfterMs), andHTTP 403. Changelog and MFA README note the step-up-and-retry flow for additional credentials.Reviewed by Cursor Bugbot for commit 60e7d88. Bugbot is set up for automated code reviews on this repo. Configure here.