@azure/msal-browser 5.27.0 → 5.29.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/app/IPublicClientApplication.mjs +1 -1
- package/dist/app/PublicClientApplication.mjs +1 -1
- package/dist/broker/nativeBroker/NativeStatusCodes.mjs +1 -1
- package/dist/broker/nativeBroker/PlatformAuthDOMHandler.mjs +9 -1
- package/dist/broker/nativeBroker/PlatformAuthDOMHandler.mjs.map +1 -1
- package/dist/broker/nativeBroker/PlatformAuthExtensionHandler.mjs +7 -6
- package/dist/broker/nativeBroker/PlatformAuthExtensionHandler.mjs.map +1 -1
- package/dist/broker/nativeBroker/PlatformAuthProvider.mjs +4 -2
- package/dist/broker/nativeBroker/PlatformAuthProvider.mjs.map +1 -1
- package/dist/broker/nativeBroker/PlatformAuthRequest.mjs +21 -7
- package/dist/broker/nativeBroker/PlatformAuthRequest.mjs.map +1 -1
- package/dist/cache/AccountManager.mjs +1 -1
- package/dist/cache/AsyncMemoryStorage.mjs +14 -1
- package/dist/cache/AsyncMemoryStorage.mjs.map +1 -1
- package/dist/cache/BrowserCacheManager.mjs +9 -2
- package/dist/cache/BrowserCacheManager.mjs.map +1 -1
- package/dist/cache/CacheHelpers.mjs +1 -1
- package/dist/cache/CacheKeys.mjs +1 -1
- package/dist/cache/CookieStorage.mjs +1 -1
- package/dist/cache/DatabaseStorage.mjs +1 -1
- package/dist/cache/EncryptedData.mjs +1 -1
- package/dist/cache/LocalStorage.mjs +1 -1
- package/dist/cache/MemoryStorage.mjs +1 -1
- package/dist/cache/SessionStorage.mjs +1 -1
- package/dist/cache/TokenCache.mjs +1 -1
- package/dist/config/Configuration.mjs +1 -1
- package/dist/controllers/NestedAppAuthController.mjs +1 -1
- package/dist/controllers/StandardController.mjs +65 -7
- package/dist/controllers/StandardController.mjs.map +1 -1
- package/dist/crypto/BrowserCrypto.mjs +1 -1
- package/dist/crypto/CryptoOps.mjs +1 -1
- package/dist/crypto/PkceGenerator.mjs +1 -1
- package/dist/crypto/SignedHttpRequest.mjs +1 -1
- package/dist/crypto/TokenBindingKeyManager.mjs +14 -1
- package/dist/crypto/TokenBindingKeyManager.mjs.map +1 -1
- package/dist/custom_auth/CustomAuthConstants.mjs +1 -1
- package/dist/custom_auth/CustomAuthPublicClientApplication.mjs +6 -4
- package/dist/custom_auth/CustomAuthPublicClientApplication.mjs.map +1 -1
- package/dist/custom_auth/controller/CustomAuthStandardController.mjs +58 -50
- package/dist/custom_auth/controller/CustomAuthStandardController.mjs.map +1 -1
- package/dist/custom_auth/core/CustomAuthAuthority.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/AuthFlowErrorBase.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/AuthFlowResultBase.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/AuthFlowState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/AuthFlowStateTypes.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/jit/error_type/AuthMethodRegistrationError.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/jit/result/AuthMethodRegistrationChallengeMethodResult.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/jit/result/AuthMethodRegistrationSubmitChallengeResult.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationCompletedState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationFailedState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/error_type/MfaError.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/result/MfaRequestChallengeResult.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/result/MfaSubmitChallengeResult.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/state/MfaCompletedState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/state/MfaFailedState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/state/MfaState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/v2/CustomAuthFlowScenarioV2.mjs +3 -5
- package/dist/custom_auth/core/auth_flow/v2/CustomAuthFlowScenarioV2.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/v2/CustomAuthResultV2.mjs +19 -13
- package/dist/custom_auth/core/auth_flow/v2/CustomAuthResultV2.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/v2/error/AuthFlowErrorSubcodesV2.mjs +8 -2
- package/dist/custom_auth/core/auth_flow/v2/error/AuthFlowErrorSubcodesV2.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/v2/error/AuthFlowErrorV2.mjs +58 -69
- package/dist/custom_auth/core/auth_flow/v2/error/AuthFlowErrorV2.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/v2/state/AuthMethodRegistrationRequiredStateV2.mjs +68 -0
- package/dist/custom_auth/core/auth_flow/v2/state/AuthMethodRegistrationRequiredStateV2.mjs.map +1 -0
- package/dist/custom_auth/core/auth_flow/v2/state/AuthMethodSelectionRequiredStateV2.mjs +44 -16
- package/dist/custom_auth/core/auth_flow/v2/state/AuthMethodSelectionRequiredStateV2.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/v2/state/AuthMethodVerificationRequiredStateV2.mjs +100 -0
- package/dist/custom_auth/core/auth_flow/v2/state/AuthMethodVerificationRequiredStateV2.mjs.map +1 -0
- package/dist/custom_auth/core/auth_flow/v2/state/ChallengeVerificationStateBaseV2.mjs +5 -3
- package/dist/custom_auth/core/auth_flow/v2/state/ChallengeVerificationStateBaseV2.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/v2/state/CodeRequiredStateV2.mjs +27 -19
- package/dist/custom_auth/core/auth_flow/v2/state/CodeRequiredStateV2.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/v2/state/CompletedStateV2.mjs +2 -4
- package/dist/custom_auth/core/auth_flow/v2/state/CompletedStateV2.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/v2/state/FailedStateV2.mjs +2 -3
- package/dist/custom_auth/core/auth_flow/v2/state/FailedStateV2.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/v2/state/MFAVerificationRequiredStateV2.mjs +20 -8
- package/dist/custom_auth/core/auth_flow/v2/state/MFAVerificationRequiredStateV2.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/v2/state/PasswordRequiredStateV2.mjs +110 -0
- package/dist/custom_auth/core/auth_flow/v2/state/PasswordRequiredStateV2.mjs.map +1 -0
- package/dist/custom_auth/core/error/CustomAuthApiError.mjs +1 -1
- package/dist/custom_auth/core/error/CustomAuthError.mjs +1 -1
- package/dist/custom_auth/core/error/HttpError.mjs +1 -1
- package/dist/custom_auth/core/error/HttpErrorCodes.mjs +1 -1
- package/dist/custom_auth/core/error/InvalidArgumentError.mjs +2 -1
- package/dist/custom_auth/core/error/InvalidArgumentError.mjs.map +1 -1
- package/dist/custom_auth/core/error/InvalidConfigurationError.mjs +1 -1
- package/dist/custom_auth/core/error/InvalidConfigurationErrorCodes.mjs +1 -1
- package/dist/custom_auth/core/error/MethodNotImplementedError.mjs +1 -1
- package/dist/custom_auth/core/error/MsalCustomAuthError.mjs +1 -1
- package/dist/custom_auth/core/error/NoCachedAccountFoundError.mjs +1 -1
- package/dist/custom_auth/core/error/ParsedUrlError.mjs +1 -1
- package/dist/custom_auth/core/error/ParsedUrlErrorCodes.mjs +1 -1
- package/dist/custom_auth/core/error/UnexpectedError.mjs +1 -1
- package/dist/custom_auth/core/error/UnsupportedEnvironmentError.mjs +1 -1
- package/dist/custom_auth/core/error/UserAccountAttributeError.mjs +1 -1
- package/dist/custom_auth/core/error/UserAlreadySignedInError.mjs +1 -1
- package/dist/custom_auth/core/interaction_client/CustomAuthInteractionClientBase.mjs +1 -1
- package/dist/custom_auth/core/interaction_client/CustomAuthInterationClientFactory.mjs +1 -1
- package/dist/custom_auth/core/interaction_client/jit/JitClient.mjs +1 -1
- package/dist/custom_auth/core/interaction_client/jit/result/JitActionResult.mjs +1 -1
- package/dist/custom_auth/core/interaction_client/mfa/MfaClient.mjs +1 -1
- package/dist/custom_auth/core/interaction_client/mfa/result/MfaActionResult.mjs +1 -1
- package/dist/custom_auth/core/interaction_client/v2/FlowInteractionClientV2.mjs +465 -186
- package/dist/custom_auth/core/interaction_client/v2/FlowInteractionClientV2.mjs.map +1 -1
- package/dist/custom_auth/core/interaction_client/v2/InteractionClientBaseV2.mjs +2 -6
- package/dist/custom_auth/core/interaction_client/v2/InteractionClientBaseV2.mjs.map +1 -1
- package/dist/custom_auth/core/interaction_client/v2/result/FlowActionResultV2.mjs +18 -3
- package/dist/custom_auth/core/interaction_client/v2/result/FlowActionResultV2.mjs.map +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/BaseApiClient.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/CustomAuthApiClient.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/CustomAuthApiEndpoint.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/RegisterApiClient.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/ResetPasswordApiClient.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/SignInApiClient.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/SignupApiClient.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/types/ApiErrorCodes.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/types/ApiSuberrors.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/ApiClientConstantsV2.mjs +10 -8
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/ApiClientConstantsV2.mjs.map +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/BaseApiClientV2.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/CustomAuthApiClientV2.mjs +147 -38
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/CustomAuthApiClientV2.mjs.map +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/ErrorCodesV2.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/HrefResolverV2.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/ResponseHandlerV2.mjs +21 -10
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/ResponseHandlerV2.mjs.map +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/response/ErrorNormalizerV2.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/result/BaseResultsV2.mjs +2 -12
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/result/BaseResultsV2.mjs.map +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/result/SignUpResultsV2.mjs +2 -2
- package/dist/custom_auth/core/network_client/custom_auth_api/v2/result/SignUpResultsV2.mjs.map +1 -1
- package/dist/custom_auth/core/network_client/http_client/FetchHttpClient.mjs +1 -1
- package/dist/custom_auth/core/network_client/http_client/IHttpClient.mjs +1 -1
- package/dist/custom_auth/core/telemetry/FlowApiIdHelperV2.mjs +15 -3
- package/dist/custom_auth/core/telemetry/FlowApiIdHelperV2.mjs.map +1 -1
- package/dist/custom_auth/core/telemetry/PublicApiId.mjs +10 -3
- package/dist/custom_auth/core/telemetry/PublicApiId.mjs.map +1 -1
- package/dist/custom_auth/core/utils/ArgumentValidator.mjs +17 -2
- package/dist/custom_auth/core/utils/ArgumentValidator.mjs.map +1 -1
- package/dist/custom_auth/core/utils/CustomHeaderUtils.mjs +1 -1
- package/dist/custom_auth/core/utils/UrlUtils.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/CustomAuthAccountData.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/error_type/GetAccountError.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/result/GetAccessTokenResult.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/result/GetAccountResult.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/result/SignOutResult.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/state/GetAccessTokenState.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/state/GetAccountState.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/state/SignOutState.mjs +1 -1
- package/dist/custom_auth/get_account/interaction_client/CustomAuthSilentCacheClient.mjs +1 -1
- package/dist/custom_auth/index.mjs +6 -3
- package/dist/custom_auth/index.mjs.map +1 -1
- package/dist/custom_auth/operating_context/CustomAuthOperatingContext.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/error_type/ResetPasswordError.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordResendCodeResult.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordStartResult.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordSubmitCodeResult.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordSubmitPasswordResult.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordCodeRequiredState.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordCompletedState.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordFailedState.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordPasswordRequiredState.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordState.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/v2/state/NewPasswordRequiredStateV2.mjs +49 -14
- package/dist/custom_auth/reset_password/auth_flow/v2/state/NewPasswordRequiredStateV2.mjs.map +1 -1
- package/dist/custom_auth/reset_password/auth_flow/v2/state/ResetPasswordStateTransitionHandlerV2.mjs +24 -0
- package/dist/custom_auth/reset_password/auth_flow/v2/state/ResetPasswordStateTransitionHandlerV2.mjs.map +1 -0
- package/dist/custom_auth/reset_password/interaction_client/ResetPasswordClient.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/SignInScenario.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/error_type/SignInError.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInResendCodeResult.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInResult.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInSubmitCodeResult.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInSubmitPasswordResult.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInCodeRequiredState.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInCompletedState.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInContinuationState.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInFailedState.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInPasswordRequiredState.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInState.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/v2/state/SignInContinuationStateV2.mjs +4 -7
- package/dist/custom_auth/sign_in/auth_flow/v2/state/SignInContinuationStateV2.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/v2/state/SignInStateTransitionHandlerV2.mjs +2 -2
- package/dist/custom_auth/sign_in/auth_flow/v2/state/SignInStateTransitionHandlerV2.mjs.map +1 -1
- package/dist/custom_auth/sign_in/interaction_client/SignInClient.mjs +1 -1
- package/dist/custom_auth/sign_in/interaction_client/result/SignInActionResult.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/error_type/SignUpError.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpResendCodeResult.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpResult.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitAttributesResult.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitCodeResult.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitPasswordResult.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpAttributesRequiredState.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpCodeRequiredState.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpCompletedState.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpFailedState.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpPasswordRequiredState.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpState.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/v2/state/AttributesRequiredStateV2.mjs +17 -8
- package/dist/custom_auth/sign_up/auth_flow/v2/state/AttributesRequiredStateV2.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountCodeRequiredStateV2.mjs +78 -0
- package/dist/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountCodeRequiredStateV2.mjs.map +1 -0
- package/dist/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountPasswordRequiredStateV2.mjs +48 -0
- package/dist/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountPasswordRequiredStateV2.mjs.map +1 -0
- package/dist/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountStateTransitionHelperV2.mjs +49 -0
- package/dist/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountStateTransitionHelperV2.mjs.map +1 -0
- package/dist/custom_auth/sign_up/auth_flow/v2/state/SignUpStateTransitionHandlerV2.mjs +21 -21
- package/dist/custom_auth/sign_up/auth_flow/v2/state/SignUpStateTransitionHandlerV2.mjs.map +1 -1
- package/dist/custom_auth/sign_up/interaction_client/SignUpClient.mjs +1 -1
- package/dist/custom_auth/sign_up/interaction_client/result/SignUpActionResult.mjs +1 -1
- package/dist/encode/Base64Decode.mjs +1 -1
- package/dist/encode/Base64Encode.mjs +1 -1
- package/dist/error/BrowserAuthError.mjs +1 -1
- package/dist/error/BrowserAuthErrorCodes.mjs +1 -1
- package/dist/error/BrowserConfigurationAuthError.mjs +1 -1
- package/dist/error/BrowserConfigurationAuthErrorCodes.mjs +1 -1
- package/dist/error/NativeAuthError.mjs +1 -1
- package/dist/error/NativeAuthErrorCodes.mjs +1 -1
- package/dist/error/NestedAppAuthError.mjs +1 -1
- package/dist/event/EventHandler.mjs +1 -1
- package/dist/event/EventMessage.mjs +1 -1
- package/dist/event/EventType.mjs +1 -1
- package/dist/index.mjs +1 -1
- package/dist/interaction_client/BaseInteractionClient.mjs +1 -1
- package/dist/interaction_client/HybridSpaAuthorizationCodeClient.mjs +1 -1
- package/dist/interaction_client/PlatformAuthInteractionClient.mjs +526 -90
- package/dist/interaction_client/PlatformAuthInteractionClient.mjs.map +1 -1
- package/dist/interaction_client/PopupClient.mjs +27 -20
- package/dist/interaction_client/PopupClient.mjs.map +1 -1
- package/dist/interaction_client/RedirectClient.mjs +29 -14
- package/dist/interaction_client/RedirectClient.mjs.map +1 -1
- package/dist/interaction_client/SilentAuthCodeClient.mjs +1 -1
- package/dist/interaction_client/SilentCacheClient.mjs +1 -1
- package/dist/interaction_client/SilentIframeClient.mjs +44 -32
- package/dist/interaction_client/SilentIframeClient.mjs.map +1 -1
- package/dist/interaction_client/SilentRefreshClient.mjs +1 -1
- package/dist/interaction_client/StandardInteractionClient.mjs +1 -1
- package/dist/interaction_handler/InteractionHandler.mjs +1 -1
- package/dist/interaction_handler/SilentHandler.mjs +1 -1
- package/dist/log-strings-mapping.json +77 -25
- package/dist/naa/BridgeError.mjs +1 -1
- package/dist/naa/BridgeProxy.mjs +1 -1
- package/dist/naa/BridgeStatusCode.mjs +1 -1
- package/dist/naa/mapping/NestedAppAuthAdapter.mjs +1 -1
- package/dist/navigation/NavigationClient.mjs +1 -1
- package/dist/network/FetchClient.mjs +1 -1
- package/dist/operatingcontext/BaseOperatingContext.mjs +1 -1
- package/dist/operatingcontext/NestedAppOperatingContext.mjs +1 -1
- package/dist/operatingcontext/StandardOperatingContext.mjs +1 -1
- package/dist/packageMetadata.mjs +2 -2
- package/dist/popup_relay/constants.mjs +1 -1
- package/dist/popup_relay/index.mjs +1 -1
- package/dist/popup_relay/relayClient.mjs +1 -1
- package/dist/protocol/Authorize.mjs +21 -13
- package/dist/protocol/Authorize.mjs.map +1 -1
- package/dist/redirect_bridge/index.mjs +1 -1
- package/dist/request/RequestHelpers.mjs +35 -11
- package/dist/request/RequestHelpers.mjs.map +1 -1
- package/dist/request/SilentRequestHelpers.mjs +6 -6
- package/dist/request/SilentRequestHelpers.mjs.map +1 -1
- package/dist/response/ResponseHandler.mjs +1 -1
- package/dist/telemetry/BrowserPerformanceClient.mjs +1 -1
- package/dist/telemetry/BrowserPerformanceEvents.mjs +3 -2
- package/dist/telemetry/BrowserPerformanceEvents.mjs.map +1 -1
- package/dist/telemetry/BrowserPerformanceMeasurement.mjs +1 -1
- package/dist/telemetry/BrowserRootPerformanceEvents.mjs +1 -1
- package/dist/utils/BrowserConstants.mjs +1 -1
- package/dist/utils/BrowserDetection.mjs +1 -1
- package/dist/utils/BrowserProtocolUtils.mjs +1 -1
- package/dist/utils/BrowserUtils.mjs +1 -1
- package/dist/utils/Helpers.mjs +1 -1
- package/dist/utils/IframeMonitor.mjs +1 -1
- package/dist/utils/MsalFrameStatsUtils.mjs +1 -1
- package/dist/utils/PopupMonitor.mjs +1 -1
- package/dist/utils/PopupOriginCheck.mjs +1 -1
- package/dist/webBrokerBridge/PendingRequestRegistry.mjs +1 -1
- package/dist/webBrokerBridge/PerfEventNames.mjs +1 -1
- package/dist/webBrokerBridge/WebBrokerBridgeError.mjs +1 -1
- package/dist/webBrokerBridge/WebBrokerBridgeErrorMap.mjs +1 -1
- package/dist/webBrokerBridge/adapter/CrossVersionRequestAdapter.mjs +1 -1
- package/dist/webBrokerBridge/index.mjs +1 -1
- package/lib/custom-auth-path/log-strings-mapping.json +69 -17
- package/lib/custom-auth-path/msal-custom-auth.cjs +2394 -920
- package/lib/custom-auth-path/msal-custom-auth.cjs.map +1 -1
- package/lib/custom-auth-path/msal-custom-auth.js +2394 -920
- package/lib/custom-auth-path/msal-custom-auth.js.map +1 -1
- package/lib/log-strings-mapping.json +23 -11
- package/lib/msal-browser.cjs +943 -278
- package/lib/msal-browser.cjs.map +1 -1
- package/lib/msal-browser.js +943 -278
- package/lib/msal-browser.js.map +1 -1
- package/lib/msal-browser.min.js +2 -2
- package/lib/popup-relay/msal-popup-relay.cjs +2 -2
- package/lib/popup-relay/msal-popup-relay.cjs.map +1 -1
- package/lib/popup-relay/msal-popup-relay.js +2 -2
- package/lib/popup-relay/msal-popup-relay.js.map +1 -1
- package/lib/popup-relay/msal-popup-relay.min.js +1 -1
- package/lib/redirect-bridge/msal-redirect-bridge.cjs +10 -10
- package/lib/redirect-bridge/msal-redirect-bridge.cjs.map +1 -1
- package/lib/redirect-bridge/msal-redirect-bridge.js +10 -10
- package/lib/redirect-bridge/msal-redirect-bridge.js.map +1 -1
- package/lib/redirect-bridge/msal-redirect-bridge.min.js +1 -1
- package/lib/web-broker-bridge/msal-web-broker-bridge.cjs +1 -1
- package/package.json +2 -2
- package/src/broker/nativeBroker/PlatformAuthDOMHandler.ts +15 -0
- package/src/broker/nativeBroker/PlatformAuthExtensionHandler.ts +6 -21
- package/src/broker/nativeBroker/PlatformAuthProvider.ts +3 -1
- package/src/broker/nativeBroker/PlatformAuthRequest.ts +12 -8
- package/src/broker/nativeBroker/PlatformAuthResponse.ts +31 -0
- package/src/cache/AsyncMemoryStorage.ts +16 -0
- package/src/cache/BrowserCacheManager.ts +19 -1
- package/src/controllers/StandardController.ts +107 -11
- package/src/crypto/TokenBindingKeyManager.ts +21 -0
- package/src/custom_auth/CustomAuthActionInputs.ts +12 -5
- package/src/custom_auth/CustomAuthPublicClientApplication.ts +5 -3
- package/src/custom_auth/ICustomAuthPublicClientApplicationV2.ts +5 -3
- package/src/custom_auth/controller/CustomAuthStandardController.ts +79 -92
- package/src/custom_auth/core/auth_flow/v2/AuthenticationMethodRegistrationV2.ts +14 -0
- package/src/custom_auth/core/auth_flow/v2/AuthenticationMethodV2.ts +1 -4
- package/src/custom_auth/core/auth_flow/v2/CustomAuthFlowScenarioV2.ts +5 -4
- package/src/custom_auth/core/auth_flow/v2/CustomAuthResultV2.ts +28 -16
- package/src/custom_auth/core/auth_flow/v2/error/AuthFlowErrorSubcodesV2.ts +6 -0
- package/src/custom_auth/core/auth_flow/v2/error/AuthFlowErrorV2.ts +83 -72
- package/src/custom_auth/core/auth_flow/v2/result/AuthMethodRegistrationChallengeResultV2.ts +23 -0
- package/src/custom_auth/core/auth_flow/v2/result/AuthMethodVerificationSubmitChallengeResultV2.ts +28 -0
- package/src/custom_auth/core/auth_flow/v2/result/MFASubmitChallengeResultV2.ts +10 -6
- package/src/custom_auth/core/auth_flow/v2/result/RequestChallengeResultV2.ts +9 -6
- package/src/custom_auth/core/auth_flow/v2/result/ResetPasswordStartResultV2.ts +4 -6
- package/src/custom_auth/core/auth_flow/v2/result/SubmitPasswordResultV2.ts +36 -0
- package/src/custom_auth/core/auth_flow/v2/result/VerifyChallengeResultV2.ts +8 -8
- package/src/custom_auth/core/auth_flow/v2/state/AuthMethodRegistrationRequiredStateV2.ts +94 -0
- package/src/custom_auth/core/auth_flow/v2/state/AuthMethodSelectionRequiredStateV2.ts +68 -14
- package/src/custom_auth/core/auth_flow/v2/state/AuthMethodVerificationRequiredStateV2.ts +150 -0
- package/src/custom_auth/core/auth_flow/v2/state/ChallengeVerificationStateBaseV2.ts +8 -2
- package/src/custom_auth/core/auth_flow/v2/state/CodeRequiredStateV2.ts +48 -24
- package/src/custom_auth/core/auth_flow/v2/state/CompletedStateV2.ts +1 -3
- package/src/custom_auth/core/auth_flow/v2/state/CustomAuthStateParametersV2.ts +24 -2
- package/src/custom_auth/core/auth_flow/v2/state/FailedStateV2.ts +1 -2
- package/src/custom_auth/core/auth_flow/v2/state/MFAVerificationRequiredStateV2.ts +34 -9
- package/src/custom_auth/core/auth_flow/v2/state/PasswordRequiredStateV2.ts +179 -0
- package/src/custom_auth/core/error/InvalidArgumentError.ts +1 -1
- package/src/custom_auth/core/interaction_client/v2/FlowContinuationStateV2.ts +13 -12
- package/src/custom_auth/core/interaction_client/v2/FlowInteractionClientV2.ts +771 -261
- package/src/custom_auth/core/interaction_client/v2/InteractionClientBaseV2.ts +2 -6
- package/src/custom_auth/core/interaction_client/v2/parameter/FlowParamsV2.ts +27 -15
- package/src/custom_auth/core/interaction_client/v2/result/FlowActionResultV2.ts +97 -26
- package/src/custom_auth/core/network_client/custom_auth_api/v2/ApiClientConstantsV2.ts +9 -6
- package/src/custom_auth/core/network_client/custom_auth_api/v2/CustomAuthApiClientV2.ts +330 -63
- package/src/custom_auth/core/network_client/custom_auth_api/v2/ResponseHandlerV2.ts +51 -15
- package/src/custom_auth/core/network_client/custom_auth_api/v2/request/RequestsV2.ts +25 -6
- package/src/custom_auth/core/network_client/custom_auth_api/v2/response/ErrorResponsesV2.ts +0 -6
- package/src/custom_auth/core/network_client/custom_auth_api/v2/response/ResponsesV2.ts +48 -48
- package/src/custom_auth/core/network_client/custom_auth_api/v2/result/BaseResultsV2.ts +44 -37
- package/src/custom_auth/core/network_client/custom_auth_api/v2/result/ResetPasswordResultsV2.ts +32 -15
- package/src/custom_auth/core/network_client/custom_auth_api/v2/result/SignUpResultsV2.ts +14 -10
- package/src/custom_auth/core/telemetry/FlowApiIdHelperV2.ts +24 -1
- package/src/custom_auth/core/telemetry/PublicApiId.ts +7 -0
- package/src/custom_auth/core/utils/ArgumentValidator.ts +26 -0
- package/src/custom_auth/index.ts +21 -11
- package/src/custom_auth/reset_password/auth_flow/v2/result/SubmitNewPasswordResultV2.ts +8 -10
- package/src/custom_auth/reset_password/auth_flow/v2/state/NewPasswordRequiredStateV2.ts +71 -16
- package/src/custom_auth/reset_password/auth_flow/v2/state/ResetPasswordStateTransitionHandlerV2.ts +30 -0
- package/src/custom_auth/sign_in/auth_flow/v2/result/SignInContinuationResultV2.ts +4 -8
- package/src/custom_auth/sign_in/auth_flow/v2/result/SignInStartResultV2.ts +4 -5
- package/src/custom_auth/sign_in/auth_flow/v2/state/SignInContinuationStateV2.ts +3 -6
- package/src/custom_auth/sign_in/auth_flow/v2/state/SignInStateParametersV2.ts +0 -3
- package/src/custom_auth/sign_in/auth_flow/v2/state/SignInStateTransitionHandlerV2.ts +2 -3
- package/src/custom_auth/sign_up/auth_flow/v2/result/ExistingAccountActionResultsV2.ts +49 -0
- package/src/custom_auth/sign_up/auth_flow/v2/result/SignUpStartResultV2.ts +8 -4
- package/src/custom_auth/sign_up/auth_flow/v2/result/SubmitAttributesResultV2.ts +18 -4
- package/src/custom_auth/sign_up/auth_flow/v2/state/AttributesRequiredStateV2.ts +26 -5
- package/src/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountCodeRequiredStateV2.ts +101 -0
- package/src/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountPasswordRequiredStateV2.ts +53 -0
- package/src/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountStateTransitionHelperV2.ts +97 -0
- package/src/custom_auth/sign_up/auth_flow/v2/state/SignUpStateParametersV2.ts +0 -6
- package/src/custom_auth/sign_up/auth_flow/v2/state/SignUpStateTransitionHandlerV2.ts +33 -43
- package/src/interaction_client/PlatformAuthInteractionClient.ts +886 -148
- package/src/interaction_client/PopupClient.ts +104 -83
- package/src/interaction_client/RedirectClient.ts +88 -34
- package/src/interaction_client/SilentIframeClient.ts +121 -95
- package/src/packageMetadata.ts +1 -1
- package/src/protocol/Authorize.ts +46 -18
- package/src/request/RequestHelpers.ts +64 -11
- package/src/request/SilentRequestHelpers.ts +8 -9
- package/src/telemetry/BrowserPerformanceEvents.ts +1 -0
- package/types/broker/nativeBroker/PlatformAuthDOMHandler.d.ts.map +1 -1
- package/types/broker/nativeBroker/PlatformAuthExtensionHandler.d.ts.map +1 -1
- package/types/broker/nativeBroker/PlatformAuthProvider.d.ts.map +1 -1
- package/types/broker/nativeBroker/PlatformAuthRequest.d.ts +6 -1
- package/types/broker/nativeBroker/PlatformAuthRequest.d.ts.map +1 -1
- package/types/broker/nativeBroker/PlatformAuthResponse.d.ts +21 -0
- package/types/broker/nativeBroker/PlatformAuthResponse.d.ts.map +1 -1
- package/types/cache/AsyncMemoryStorage.d.ts +5 -0
- package/types/cache/AsyncMemoryStorage.d.ts.map +1 -1
- package/types/cache/BrowserCacheManager.d.ts +4 -0
- package/types/cache/BrowserCacheManager.d.ts.map +1 -1
- package/types/controllers/StandardController.d.ts +5 -0
- package/types/controllers/StandardController.d.ts.map +1 -1
- package/types/crypto/TokenBindingKeyManager.d.ts +9 -0
- package/types/crypto/TokenBindingKeyManager.d.ts.map +1 -1
- package/types/custom_auth/CustomAuthActionInputs.d.ts +12 -5
- package/types/custom_auth/CustomAuthActionInputs.d.ts.map +1 -1
- package/types/custom_auth/CustomAuthConstants.d.ts +1 -1
- package/types/custom_auth/CustomAuthPublicClientApplication.d.ts +5 -3
- package/types/custom_auth/CustomAuthPublicClientApplication.d.ts.map +1 -1
- package/types/custom_auth/ICustomAuthPublicClientApplicationV2.d.ts +5 -3
- package/types/custom_auth/ICustomAuthPublicClientApplicationV2.d.ts.map +1 -1
- package/types/custom_auth/controller/CustomAuthStandardController.d.ts +2 -0
- package/types/custom_auth/controller/CustomAuthStandardController.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/AuthenticationMethodRegistrationV2.d.ts +10 -0
- package/types/custom_auth/core/auth_flow/v2/AuthenticationMethodRegistrationV2.d.ts.map +1 -0
- package/types/custom_auth/core/auth_flow/v2/AuthenticationMethodV2.d.ts +1 -4
- package/types/custom_auth/core/auth_flow/v2/AuthenticationMethodV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/CustomAuthFlowScenarioV2.d.ts +5 -4
- package/types/custom_auth/core/auth_flow/v2/CustomAuthFlowScenarioV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/CustomAuthResultV2.d.ts +17 -8
- package/types/custom_auth/core/auth_flow/v2/CustomAuthResultV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/error/AuthFlowErrorSubcodesV2.d.ts +6 -0
- package/types/custom_auth/core/auth_flow/v2/error/AuthFlowErrorSubcodesV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/error/AuthFlowErrorV2.d.ts +23 -44
- package/types/custom_auth/core/auth_flow/v2/error/AuthFlowErrorV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/result/AuthMethodRegistrationChallengeResultV2.d.ts +14 -0
- package/types/custom_auth/core/auth_flow/v2/result/AuthMethodRegistrationChallengeResultV2.d.ts.map +1 -0
- package/types/custom_auth/core/auth_flow/v2/result/AuthMethodVerificationSubmitChallengeResultV2.d.ts +16 -0
- package/types/custom_auth/core/auth_flow/v2/result/AuthMethodVerificationSubmitChallengeResultV2.d.ts.map +1 -0
- package/types/custom_auth/core/auth_flow/v2/result/MFASubmitChallengeResultV2.d.ts +7 -6
- package/types/custom_auth/core/auth_flow/v2/result/MFASubmitChallengeResultV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/result/RequestChallengeResultV2.d.ts +8 -7
- package/types/custom_auth/core/auth_flow/v2/result/RequestChallengeResultV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/result/ResetPasswordStartResultV2.d.ts +4 -6
- package/types/custom_auth/core/auth_flow/v2/result/ResetPasswordStartResultV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/result/SubmitPasswordResultV2.d.ts +20 -0
- package/types/custom_auth/core/auth_flow/v2/result/SubmitPasswordResultV2.d.ts.map +1 -0
- package/types/custom_auth/core/auth_flow/v2/result/VerifyChallengeResultV2.d.ts +7 -8
- package/types/custom_auth/core/auth_flow/v2/result/VerifyChallengeResultV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/state/AuthMethodRegistrationRequiredStateV2.d.ts +22 -0
- package/types/custom_auth/core/auth_flow/v2/state/AuthMethodRegistrationRequiredStateV2.d.ts.map +1 -0
- package/types/custom_auth/core/auth_flow/v2/state/AuthMethodSelectionRequiredStateV2.d.ts +3 -6
- package/types/custom_auth/core/auth_flow/v2/state/AuthMethodSelectionRequiredStateV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/state/AuthMethodVerificationRequiredStateV2.d.ts +28 -0
- package/types/custom_auth/core/auth_flow/v2/state/AuthMethodVerificationRequiredStateV2.d.ts.map +1 -0
- package/types/custom_auth/core/auth_flow/v2/state/ChallengeVerificationStateBaseV2.d.ts +3 -2
- package/types/custom_auth/core/auth_flow/v2/state/ChallengeVerificationStateBaseV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/state/CodeRequiredStateV2.d.ts +6 -8
- package/types/custom_auth/core/auth_flow/v2/state/CodeRequiredStateV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/state/CompletedStateV2.d.ts +1 -3
- package/types/custom_auth/core/auth_flow/v2/state/CompletedStateV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/state/CustomAuthStateParametersV2.d.ts +18 -2
- package/types/custom_auth/core/auth_flow/v2/state/CustomAuthStateParametersV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/state/FailedStateV2.d.ts +1 -2
- package/types/custom_auth/core/auth_flow/v2/state/FailedStateV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/state/MFAVerificationRequiredStateV2.d.ts +5 -6
- package/types/custom_auth/core/auth_flow/v2/state/MFAVerificationRequiredStateV2.d.ts.map +1 -1
- package/types/custom_auth/core/auth_flow/v2/state/PasswordRequiredStateV2.d.ts +23 -0
- package/types/custom_auth/core/auth_flow/v2/state/PasswordRequiredStateV2.d.ts.map +1 -0
- package/types/custom_auth/core/error/InvalidArgumentError.d.ts +1 -0
- package/types/custom_auth/core/error/InvalidArgumentError.d.ts.map +1 -1
- package/types/custom_auth/core/interaction_client/v2/FlowContinuationStateV2.d.ts +9 -1
- package/types/custom_auth/core/interaction_client/v2/FlowContinuationStateV2.d.ts.map +1 -1
- package/types/custom_auth/core/interaction_client/v2/FlowInteractionClientV2.d.ts +19 -10
- package/types/custom_auth/core/interaction_client/v2/FlowInteractionClientV2.d.ts.map +1 -1
- package/types/custom_auth/core/interaction_client/v2/InteractionClientBaseV2.d.ts +1 -1
- package/types/custom_auth/core/interaction_client/v2/InteractionClientBaseV2.d.ts.map +1 -1
- package/types/custom_auth/core/interaction_client/v2/parameter/FlowParamsV2.d.ts +19 -5
- package/types/custom_auth/core/interaction_client/v2/parameter/FlowParamsV2.d.ts.map +1 -1
- package/types/custom_auth/core/interaction_client/v2/result/FlowActionResultV2.d.ts +39 -4
- package/types/custom_auth/core/interaction_client/v2/result/FlowActionResultV2.d.ts.map +1 -1
- package/types/custom_auth/core/network_client/custom_auth_api/v2/ApiClientConstantsV2.d.ts +8 -0
- package/types/custom_auth/core/network_client/custom_auth_api/v2/ApiClientConstantsV2.d.ts.map +1 -1
- package/types/custom_auth/core/network_client/custom_auth_api/v2/CustomAuthApiClientV2.d.ts +8 -2
- package/types/custom_auth/core/network_client/custom_auth_api/v2/CustomAuthApiClientV2.d.ts.map +1 -1
- package/types/custom_auth/core/network_client/custom_auth_api/v2/ResponseHandlerV2.d.ts +4 -3
- package/types/custom_auth/core/network_client/custom_auth_api/v2/ResponseHandlerV2.d.ts.map +1 -1
- package/types/custom_auth/core/network_client/custom_auth_api/v2/request/RequestsV2.d.ts +13 -1
- package/types/custom_auth/core/network_client/custom_auth_api/v2/request/RequestsV2.d.ts.map +1 -1
- package/types/custom_auth/core/network_client/custom_auth_api/v2/response/ErrorResponsesV2.d.ts.map +1 -1
- package/types/custom_auth/core/network_client/custom_auth_api/v2/response/ResponsesV2.d.ts +36 -9
- package/types/custom_auth/core/network_client/custom_auth_api/v2/response/ResponsesV2.d.ts.map +1 -1
- package/types/custom_auth/core/network_client/custom_auth_api/v2/result/BaseResultsV2.d.ts +30 -17
- package/types/custom_auth/core/network_client/custom_auth_api/v2/result/BaseResultsV2.d.ts.map +1 -1
- package/types/custom_auth/core/network_client/custom_auth_api/v2/result/ResetPasswordResultsV2.d.ts +18 -4
- package/types/custom_auth/core/network_client/custom_auth_api/v2/result/ResetPasswordResultsV2.d.ts.map +1 -1
- package/types/custom_auth/core/network_client/custom_auth_api/v2/result/SignUpResultsV2.d.ts +8 -11
- package/types/custom_auth/core/network_client/custom_auth_api/v2/result/SignUpResultsV2.d.ts.map +1 -1
- package/types/custom_auth/core/telemetry/FlowApiIdHelperV2.d.ts +2 -1
- package/types/custom_auth/core/telemetry/FlowApiIdHelperV2.d.ts.map +1 -1
- package/types/custom_auth/core/telemetry/PublicApiId.d.ts +7 -0
- package/types/custom_auth/core/telemetry/PublicApiId.d.ts.map +1 -1
- package/types/custom_auth/core/utils/ArgumentValidator.d.ts +3 -0
- package/types/custom_auth/core/utils/ArgumentValidator.d.ts.map +1 -1
- package/types/custom_auth/index.d.ts +10 -5
- package/types/custom_auth/index.d.ts.map +1 -1
- package/types/custom_auth/reset_password/auth_flow/v2/result/SubmitNewPasswordResultV2.d.ts +7 -11
- package/types/custom_auth/reset_password/auth_flow/v2/result/SubmitNewPasswordResultV2.d.ts.map +1 -1
- package/types/custom_auth/reset_password/auth_flow/v2/state/NewPasswordRequiredStateV2.d.ts +7 -5
- package/types/custom_auth/reset_password/auth_flow/v2/state/NewPasswordRequiredStateV2.d.ts.map +1 -1
- package/types/custom_auth/reset_password/auth_flow/v2/state/ResetPasswordStateTransitionHandlerV2.d.ts +7 -0
- package/types/custom_auth/reset_password/auth_flow/v2/state/ResetPasswordStateTransitionHandlerV2.d.ts.map +1 -0
- package/types/custom_auth/sign_in/auth_flow/v2/result/SignInContinuationResultV2.d.ts +4 -8
- package/types/custom_auth/sign_in/auth_flow/v2/result/SignInContinuationResultV2.d.ts.map +1 -1
- package/types/custom_auth/sign_in/auth_flow/v2/result/SignInStartResultV2.d.ts +5 -5
- package/types/custom_auth/sign_in/auth_flow/v2/result/SignInStartResultV2.d.ts.map +1 -1
- package/types/custom_auth/sign_in/auth_flow/v2/state/SignInContinuationStateV2.d.ts +3 -6
- package/types/custom_auth/sign_in/auth_flow/v2/state/SignInContinuationStateV2.d.ts.map +1 -1
- package/types/custom_auth/sign_in/auth_flow/v2/state/SignInStateParametersV2.d.ts +0 -1
- package/types/custom_auth/sign_in/auth_flow/v2/state/SignInStateParametersV2.d.ts.map +1 -1
- package/types/custom_auth/sign_in/auth_flow/v2/state/SignInStateTransitionHandlerV2.d.ts +3 -2
- package/types/custom_auth/sign_in/auth_flow/v2/state/SignInStateTransitionHandlerV2.d.ts.map +1 -1
- package/types/custom_auth/sign_up/auth_flow/v2/result/ExistingAccountActionResultsV2.d.ts +27 -0
- package/types/custom_auth/sign_up/auth_flow/v2/result/ExistingAccountActionResultsV2.d.ts.map +1 -0
- package/types/custom_auth/sign_up/auth_flow/v2/result/SignUpStartResultV2.d.ts +6 -3
- package/types/custom_auth/sign_up/auth_flow/v2/result/SignUpStartResultV2.d.ts.map +1 -1
- package/types/custom_auth/sign_up/auth_flow/v2/result/SubmitAttributesResultV2.d.ts +13 -3
- package/types/custom_auth/sign_up/auth_flow/v2/result/SubmitAttributesResultV2.d.ts.map +1 -1
- package/types/custom_auth/sign_up/auth_flow/v2/state/AttributesRequiredStateV2.d.ts +8 -3
- package/types/custom_auth/sign_up/auth_flow/v2/state/AttributesRequiredStateV2.d.ts.map +1 -1
- package/types/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountCodeRequiredStateV2.d.ts +24 -0
- package/types/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountCodeRequiredStateV2.d.ts.map +1 -0
- package/types/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountPasswordRequiredStateV2.d.ts +18 -0
- package/types/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountPasswordRequiredStateV2.d.ts.map +1 -0
- package/types/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountStateTransitionHelperV2.d.ts +7 -0
- package/types/custom_auth/sign_up/auth_flow/v2/state/ExistingAccountStateTransitionHelperV2.d.ts.map +1 -0
- package/types/custom_auth/sign_up/auth_flow/v2/state/SignUpStateParametersV2.d.ts +0 -4
- package/types/custom_auth/sign_up/auth_flow/v2/state/SignUpStateParametersV2.d.ts.map +1 -1
- package/types/custom_auth/sign_up/auth_flow/v2/state/SignUpStateTransitionHandlerV2.d.ts +5 -4
- package/types/custom_auth/sign_up/auth_flow/v2/state/SignUpStateTransitionHandlerV2.d.ts.map +1 -1
- package/types/interaction_client/PlatformAuthInteractionClient.d.ts +110 -8
- package/types/interaction_client/PlatformAuthInteractionClient.d.ts.map +1 -1
- package/types/interaction_client/PopupClient.d.ts.map +1 -1
- package/types/interaction_client/RedirectClient.d.ts.map +1 -1
- package/types/interaction_client/SilentIframeClient.d.ts.map +1 -1
- package/types/packageMetadata.d.ts +1 -1
- package/types/protocol/Authorize.d.ts +4 -4
- package/types/protocol/Authorize.d.ts.map +1 -1
- package/types/request/RequestHelpers.d.ts +21 -3
- package/types/request/RequestHelpers.d.ts.map +1 -1
- package/types/request/SilentRequestHelpers.d.ts.map +1 -1
- package/types/telemetry/BrowserPerformanceEvents.d.ts +1 -0
- package/types/telemetry/BrowserPerformanceEvents.d.ts.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/v2/state/PasswordRequiredStateV2.mjs +0 -70
- package/dist/custom_auth/sign_in/auth_flow/v2/state/PasswordRequiredStateV2.mjs.map +0 -1
- package/dist/custom_auth/sign_up/auth_flow/v2/state/SignUpAttributesRequiredStateBaseV2.mjs +0 -25
- package/dist/custom_auth/sign_up/auth_flow/v2/state/SignUpAttributesRequiredStateBaseV2.mjs.map +0 -1
- package/dist/custom_auth/sign_up/auth_flow/v2/state/SignUpPasswordRequiredStateV2.mjs +0 -45
- package/dist/custom_auth/sign_up/auth_flow/v2/state/SignUpPasswordRequiredStateV2.mjs.map +0 -1
- package/src/custom_auth/core/auth_flow/v2/result/MFAResendChallengeResultV2.ts +0 -23
- package/src/custom_auth/core/auth_flow/v2/result/ResendCodeResultV2.ts +0 -19
- package/src/custom_auth/sign_in/auth_flow/v2/result/SubmitPasswordResultV2.ts +0 -20
- package/src/custom_auth/sign_in/auth_flow/v2/state/PasswordRequiredStateV2.ts +0 -97
- package/src/custom_auth/sign_up/auth_flow/v2/state/SignUpAttributesRequiredStateBaseV2.ts +0 -34
- package/src/custom_auth/sign_up/auth_flow/v2/state/SignUpPasswordRequiredStateV2.ts +0 -61
- package/types/custom_auth/core/auth_flow/v2/result/MFAResendChallengeResultV2.d.ts +0 -14
- package/types/custom_auth/core/auth_flow/v2/result/MFAResendChallengeResultV2.d.ts.map +0 -1
- package/types/custom_auth/core/auth_flow/v2/result/ResendCodeResultV2.d.ts +0 -13
- package/types/custom_auth/core/auth_flow/v2/result/ResendCodeResultV2.d.ts.map +0 -1
- package/types/custom_auth/sign_in/auth_flow/v2/result/SubmitPasswordResultV2.d.ts +0 -8
- package/types/custom_auth/sign_in/auth_flow/v2/result/SubmitPasswordResultV2.d.ts.map +0 -1
- package/types/custom_auth/sign_in/auth_flow/v2/state/PasswordRequiredStateV2.d.ts +0 -17
- package/types/custom_auth/sign_in/auth_flow/v2/state/PasswordRequiredStateV2.d.ts.map +0 -1
- package/types/custom_auth/sign_up/auth_flow/v2/state/SignUpAttributesRequiredStateBaseV2.d.ts +0 -11
- package/types/custom_auth/sign_up/auth_flow/v2/state/SignUpAttributesRequiredStateBaseV2.d.ts.map +0 -1
- package/types/custom_auth/sign_up/auth_flow/v2/state/SignUpPasswordRequiredStateV2.d.ts +0 -19
- package/types/custom_auth/sign_up/auth_flow/v2/state/SignUpPasswordRequiredStateV2.d.ts.map +0 -1
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
/*! @azure/msal-browser v5.29.0 2026-11-06 */
|
|
2
|
+
'use strict';
|
|
3
|
+
import { AuthFlowActionRequiredStateBase } from '../../AuthFlowState.mjs';
|
|
4
|
+
import { CustomAuthResultV2 } from '../CustomAuthResultV2.mjs';
|
|
5
|
+
import { AuthMethodVerificationRequiredStateV2 } from './AuthMethodVerificationRequiredStateV2.mjs';
|
|
6
|
+
import { InvalidArgumentError } from '../../../error/InvalidArgumentError.mjs';
|
|
7
|
+
import { ensureArgumentIsNotEmptyString } from '../../../utils/ArgumentValidator.mjs';
|
|
8
|
+
|
|
9
|
+
/*
|
|
10
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
11
|
+
* Licensed under the MIT License.
|
|
12
|
+
*/
|
|
13
|
+
/**
|
|
14
|
+
* State returned when an authentication method must be registered.
|
|
15
|
+
* @warning This API is experimental. It may be changed in the future without notice. Do not use in production applications.
|
|
16
|
+
*/
|
|
17
|
+
class AuthMethodRegistrationRequiredStateV2 extends AuthFlowActionRequiredStateBase {
|
|
18
|
+
constructor(stateParameters) {
|
|
19
|
+
super(stateParameters);
|
|
20
|
+
this.stateType = "authMethodRegistrationRequired";
|
|
21
|
+
this.methods = stateParameters.methods;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Selects an authentication method for strong-auth registration and requests
|
|
25
|
+
* its activation challenge.
|
|
26
|
+
* @param method - A method from {@link methods}.
|
|
27
|
+
* @param verificationContact - The email address or phone number to register.
|
|
28
|
+
* @returns The registration activation result.
|
|
29
|
+
*/
|
|
30
|
+
async selectAuthMethod(method, verificationContact) {
|
|
31
|
+
const { correlationId, continuationState, flowClient, logger } = this.stateParameters;
|
|
32
|
+
try {
|
|
33
|
+
const selectedMethod = this.methods.find((candidate) => candidate.type === method.type);
|
|
34
|
+
if (!selectedMethod) {
|
|
35
|
+
throw new InvalidArgumentError("method", correlationId);
|
|
36
|
+
}
|
|
37
|
+
ensureArgumentIsNotEmptyString("verificationContact", verificationContact, correlationId);
|
|
38
|
+
logger.verbose("1lzpbc", correlationId);
|
|
39
|
+
const result = await flowClient.registerAuthMethod({
|
|
40
|
+
correlationId,
|
|
41
|
+
continuationState,
|
|
42
|
+
method: selectedMethod,
|
|
43
|
+
verificationContact,
|
|
44
|
+
});
|
|
45
|
+
return new CustomAuthResultV2(new AuthMethodVerificationRequiredStateV2({
|
|
46
|
+
correlationId: result.correlationId,
|
|
47
|
+
logger,
|
|
48
|
+
config: this.stateParameters.config,
|
|
49
|
+
flowClient,
|
|
50
|
+
cacheClient: this.stateParameters.cacheClient,
|
|
51
|
+
continuationState: result.continuationState,
|
|
52
|
+
type: selectedMethod.type,
|
|
53
|
+
sentTo: result.sentTo,
|
|
54
|
+
codeLength: result.codeLength,
|
|
55
|
+
}), undefined, result.continuationState.scenario);
|
|
56
|
+
}
|
|
57
|
+
catch (error) {
|
|
58
|
+
logger.errorPii(`03yx60 ${error}`, correlationId);
|
|
59
|
+
return CustomAuthResultV2.createWithError(error, {
|
|
60
|
+
scenario: continuationState.scenario,
|
|
61
|
+
correlationId,
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export { AuthMethodRegistrationRequiredStateV2 };
|
|
68
|
+
//# sourceMappingURL=AuthMethodRegistrationRequiredStateV2.mjs.map
|
package/dist/custom_auth/core/auth_flow/v2/state/AuthMethodRegistrationRequiredStateV2.mjs.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AuthMethodRegistrationRequiredStateV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/AuthMethodRegistrationRequiredStateV2.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;;;;AAAA;;;AAGG;AAWH;;;AAGG;AACG,MAAO,qCAAsC,SAAQ,+BAAgF,CAAA;AAIvI,IAAA,WAAA,CACI,eAAgE,EAAA;QAEhE,KAAK,CAAC,eAAe,CAAC,CAAC;QANlB,IAAA,CAAA,SAAS,GAAG,gCAAgC,CAAC;AAOlD,QAAA,IAAI,CAAC,OAAO,GAAG,eAAe,CAAC,OAAO,CAAC;IAC3C,CAAC;A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MAAM,CAAC,QAAQ,CACX,CAAA,OAAA,EAAA,KAAA,CAAA,CAAA,EAAA,aAAA,CAAA,CAAA;AAGJ,YAAA,OAAO,kBAAkB,CAAC,eAAe,CAAC,KAAK,EAAE;gBAC7C,QAAQ,EAAE,iBAAiB,CAAC,QAAQ;gBACpC,aAAa;AAChB,aAAA,CAAC,CAAC;AACN,QAAA,CAAA;IACL,CAAC;AACJ;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @azure/msal-browser v5.
|
|
1
|
+
/*! @azure/msal-browser v5.29.0 2026-11-06 */
|
|
2
2
|
'use strict';
|
|
3
3
|
import { CustomAuthResultV2 } from '../CustomAuthResultV2.mjs';
|
|
4
4
|
import { AuthFlowActionRequiredStateBase } from '../../AuthFlowState.mjs';
|
|
@@ -11,16 +11,16 @@ import { InvalidArgumentError } from '../../../error/InvalidArgumentError.mjs';
|
|
|
11
11
|
import { UNSUPPORTED_FLOW_TRANSITION } from '../../../network_client/custom_auth_api/v2/ErrorCodesV2.mjs';
|
|
12
12
|
import { AuthenticationFactorV2 } from '../../../network_client/custom_auth_api/v2/result/BaseResultsV2.mjs';
|
|
13
13
|
import { CustomAuthFlowScenarioV2 } from '../CustomAuthFlowScenarioV2.mjs';
|
|
14
|
+
import { ExistingAccountCodeRequiredStateV2 } from '../../../../sign_up/auth_flow/v2/state/ExistingAccountCodeRequiredStateV2.mjs';
|
|
15
|
+
import { ExistingAccountPasswordRequiredStateV2 } from '../../../../sign_up/auth_flow/v2/state/ExistingAccountPasswordRequiredStateV2.mjs';
|
|
14
16
|
|
|
15
17
|
/*
|
|
16
18
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
17
19
|
* Licensed under the MIT License.
|
|
18
20
|
*/
|
|
19
21
|
/**
|
|
20
|
-
* State returned when the user must select
|
|
21
|
-
*
|
|
22
|
-
* methods and lets the app request a challenge for the chosen one. The flow
|
|
23
|
-
* stays on this state until a challenge is successfully requested.
|
|
22
|
+
* State returned when the user must select an authentication method.
|
|
23
|
+
* @warning This API is experimental. It may be changed in the future without notice. Do not use in production applications.
|
|
24
24
|
*/
|
|
25
25
|
class AuthMethodSelectionRequiredStateV2 extends AuthFlowActionRequiredStateBase {
|
|
26
26
|
constructor(stateParameters) {
|
|
@@ -29,13 +29,12 @@ class AuthMethodSelectionRequiredStateV2 extends AuthFlowActionRequiredStateBase
|
|
|
29
29
|
this.methods = stateParameters.methods;
|
|
30
30
|
}
|
|
31
31
|
/**
|
|
32
|
-
* Selects an authentication method and requests its challenge.
|
|
33
|
-
* state identifies the credential the application must collect.
|
|
32
|
+
* Selects an authentication method and requests its challenge.
|
|
34
33
|
* @param method - The method to select, from {@link methods}.
|
|
35
34
|
* @returns The result of selecting the method and requesting its challenge.
|
|
36
35
|
*/
|
|
37
36
|
async selectAuthMethod(method) {
|
|
38
|
-
const { authenticationFactor, correlationId, logger, continuationState, flowClient, signInStateTransitionHandler, } = this.stateParameters;
|
|
37
|
+
const { authenticationFactor, correlationId, logger, continuationState, flowClient, signInStateTransitionHandler, resetPasswordStateTransitionHandler, } = this.stateParameters;
|
|
39
38
|
try {
|
|
40
39
|
logger.verbose("1r2ypl", correlationId);
|
|
41
40
|
const { result, selectedMethod } = await this.requestSelectedMethodChallenge(method);
|
|
@@ -46,22 +45,45 @@ class AuthMethodSelectionRequiredStateV2 extends AuthFlowActionRequiredStateBase
|
|
|
46
45
|
flowClient,
|
|
47
46
|
continuationState: result.continuationState,
|
|
48
47
|
cacheClient: this.stateParameters.cacheClient,
|
|
48
|
+
signInStateTransitionHandler,
|
|
49
49
|
};
|
|
50
|
-
|
|
50
|
+
const isExistingAccountSignUp = continuationState.scenario ===
|
|
51
|
+
CustomAuthFlowScenarioV2.SignUp &&
|
|
52
|
+
continuationState.signUp?.purpose === "existingAccount";
|
|
53
|
+
const channel = result.type === FLOW_CODE_REQUIRED_V2
|
|
54
|
+
? result.channel?.toLowerCase()
|
|
55
|
+
: undefined;
|
|
56
|
+
if (isExistingAccountSignUp &&
|
|
57
|
+
authenticationFactor === AuthenticationFactorV2.SINGLE_FACTOR &&
|
|
58
|
+
result.type === FLOW_CODE_REQUIRED_V2 &&
|
|
59
|
+
channel === AuthenticationMethodTypeV2.EMAIL) {
|
|
60
|
+
return new CustomAuthResultV2(new ExistingAccountCodeRequiredStateV2({
|
|
61
|
+
...commonStateParameters,
|
|
62
|
+
method: selectedMethod,
|
|
63
|
+
sentTo: result.sentTo,
|
|
64
|
+
channel: result.channel,
|
|
65
|
+
codeLength: result.codeLength,
|
|
66
|
+
}), undefined, result.continuationState.scenario);
|
|
67
|
+
}
|
|
68
|
+
if (!isExistingAccountSignUp &&
|
|
69
|
+
authenticationFactor === AuthenticationFactorV2.SINGLE_FACTOR &&
|
|
51
70
|
result.type === FLOW_CODE_REQUIRED_V2 &&
|
|
52
|
-
(
|
|
53
|
-
AuthenticationMethodTypeV2.
|
|
54
|
-
result.channel?.toLowerCase() ===
|
|
55
|
-
AuthenticationMethodTypeV2.SMS)) {
|
|
71
|
+
(channel === AuthenticationMethodTypeV2.EMAIL ||
|
|
72
|
+
channel === AuthenticationMethodTypeV2.SMS)) {
|
|
56
73
|
return new CustomAuthResultV2(new CodeRequiredStateV2({
|
|
57
74
|
...commonStateParameters,
|
|
58
|
-
|
|
75
|
+
resetPasswordStateTransitionHandler,
|
|
59
76
|
method: selectedMethod,
|
|
60
77
|
sentTo: result.sentTo,
|
|
61
78
|
channel: result.channel,
|
|
62
79
|
codeLength: result.codeLength,
|
|
63
80
|
}), undefined, result.continuationState.scenario);
|
|
64
81
|
}
|
|
82
|
+
if (isExistingAccountSignUp &&
|
|
83
|
+
authenticationFactor === AuthenticationFactorV2.SINGLE_FACTOR &&
|
|
84
|
+
result.type === FLOW_PASSWORD_REQUIRED_V2) {
|
|
85
|
+
return new CustomAuthResultV2(new ExistingAccountPasswordRequiredStateV2(commonStateParameters), undefined, result.continuationState.scenario);
|
|
86
|
+
}
|
|
65
87
|
if (continuationState.scenario ===
|
|
66
88
|
CustomAuthFlowScenarioV2.SignIn &&
|
|
67
89
|
authenticationFactor === AuthenticationFactorV2.SINGLE_FACTOR &&
|
|
@@ -81,12 +103,17 @@ class AuthMethodSelectionRequiredStateV2 extends AuthFlowActionRequiredStateBase
|
|
|
81
103
|
codeLength: result.codeLength,
|
|
82
104
|
}), undefined, result.continuationState.scenario);
|
|
83
105
|
}
|
|
84
|
-
|
|
106
|
+
let expectedChallenge = authenticationFactor === AuthenticationFactorV2.SINGLE_FACTOR
|
|
85
107
|
? continuationState.scenario ===
|
|
86
108
|
CustomAuthFlowScenarioV2.SignIn
|
|
87
109
|
? "an email or SMS code challenge or a password challenge for single-factor sign-in"
|
|
88
110
|
: "an email or SMS code challenge for single-factor authentication"
|
|
89
111
|
: "a code challenge for multi-factor authentication";
|
|
112
|
+
if (isExistingAccountSignUp &&
|
|
113
|
+
authenticationFactor === AuthenticationFactorV2.SINGLE_FACTOR) {
|
|
114
|
+
expectedChallenge =
|
|
115
|
+
"an email code challenge or a password challenge for existing-account sign-up";
|
|
116
|
+
}
|
|
90
117
|
const returnedChallenge = result.type === FLOW_CODE_REQUIRED_V2
|
|
91
118
|
? result.channel
|
|
92
119
|
? `a '${result.channel}' code challenge`
|
|
@@ -103,13 +130,14 @@ class AuthMethodSelectionRequiredStateV2 extends AuthFlowActionRequiredStateBase
|
|
|
103
130
|
}
|
|
104
131
|
}
|
|
105
132
|
async requestSelectedMethodChallenge(method) {
|
|
106
|
-
const { correlationId, continuationState, flowClient } = this.stateParameters;
|
|
133
|
+
const { correlationId, continuationState, flowClient, authenticationFactor, } = this.stateParameters;
|
|
107
134
|
const selectedMethod = this.methods.find((candidate) => candidate.id === method.id);
|
|
108
135
|
if (!selectedMethod) {
|
|
109
136
|
throw new InvalidArgumentError("method", correlationId);
|
|
110
137
|
}
|
|
111
138
|
const result = await flowClient.requestChallenge({
|
|
112
139
|
correlationId,
|
|
140
|
+
authenticationFactor,
|
|
113
141
|
continuationState: {
|
|
114
142
|
...continuationState,
|
|
115
143
|
links: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AuthMethodSelectionRequiredStateV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/AuthMethodSelectionRequiredStateV2.ts"],"sourcesContent":[null],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AuthMethodSelectionRequiredStateV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/AuthMethodSelectionRequiredStateV2.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA;;;AAGG;AAwBH;;;AAGG;AACG,MAAO,kCAAmC,SAAQ,+BAA6E,CAAA;AAIjI,IAAA,WAAA,CAAY,eAA6D,EAAA;QACrE,KAAK,CAAC,eAAe,CAAC,CAAC;QAJlB,IAAA,CAAA,SAAS,GAAG,6BAA6B,CAAC;AAK/C,QAAA,IAAI,CAAC,OAAO,GAAG,eAAe,CAAC,OAAO,CAAC;IAC3C,CAAC;AAED;;;;AAIG;IACH,MAAM,gBAAgB,CAClB,MAA8B,EAAA;AAE9B,QAAA,MAAM,EACF,oBAAoB,EACpB,aAAa,EACb,MAAM,EACN,iBAAiB,EACjB,UAAU,EACV,4BAA4B,EAC5B,mCAAmC,GACtC,GAAG,IAAI,CAAC,eAAe,CAAC;QAEzB,IAAI;AACA,YAAA,MAAM,CAAC,OAAO,CACV;AAIJ,YAAA,MAAM,EAAE,MAAM,EAAE,cAAc,EAAE,GAC5B,MAAM,IAAI,CAAC,8BAA8B,CAAC,MAAM,CAAC,CAAC;AAEtD,YAAA,MAAM,qBAAqB,GAAG;gBAC1B,aAAa,EAAE,MAAM,CAAC,aAAa;gBACnC,MAAM;AACN,gBAAA,MAAM,EAAE,IAAI,CAAC,eAAe,CAAC,MAAM;gBACnC,UAAU;gBACV,iBAAiB,EAAE,MAAM,CAAC,iBAAiB;AAC3C,gBAAA,WAAW,EAAE,IAAI,CAAC,eAAe,CAAC,WAAW;gBAC7C,4BAA4B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IAAI,CAAC,cAAc,EAAE;AACjB,YAAA,MAAM,IAAI,oBAAoB,CAAC,QAAQ,EAAE,aAAa,CAAC,CAAC;AAC3D,QAAA,CAAA;AAED,QAAA,MAAM,MAAM,GAAG,MAAM,UAAU,CAAC,gBAAgB,CAAC;YAC7C,aAAa;YACb,oBAAoB;AACpB,YAAA,iBAAiB,EAAE;AACf,gBAAA,GAAG,iBAAiB;AACpB,gBAAA,KAAK,EAAE;oBACH,GAAG,iBAAiB,CAAC,KAAK;oBAC1B,SAAS,EAAE,cAAc,CAAC,aAAa;AAC1C,iBAAA;AACJ,aAAA;AACJ,SAAA,CAAC,CAAC;AAEH,QAAA,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,CAAC;IACtC,CAAC;AACJ;;;;"}
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
/*! @azure/msal-browser v5.29.0 2026-11-06 */
|
|
2
|
+
'use strict';
|
|
3
|
+
import { AuthFlowActionRequiredStateBase } from '../../AuthFlowState.mjs';
|
|
4
|
+
import { CustomAuthResultV2 } from '../CustomAuthResultV2.mjs';
|
|
5
|
+
import { CompletedStateV2 } from './CompletedStateV2.mjs';
|
|
6
|
+
import { CustomAuthAccountData } from '../../../../get_account/auth_flow/CustomAuthAccountData.mjs';
|
|
7
|
+
import { ensureArgumentIsNotNullOrUndefined } from '../../../utils/ArgumentValidator.mjs';
|
|
8
|
+
import { FLOW_SIGN_IN_CONTINUATION_REQUIRED_V2 } from '../../../interaction_client/v2/result/FlowActionResultV2.mjs';
|
|
9
|
+
import { SignInContinuationStateV2 } from '../../../../sign_in/auth_flow/v2/state/SignInContinuationStateV2.mjs';
|
|
10
|
+
|
|
11
|
+
/*
|
|
12
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
13
|
+
* Licensed under the MIT License.
|
|
14
|
+
*/
|
|
15
|
+
/**
|
|
16
|
+
* State returned when a newly registered authentication method must be
|
|
17
|
+
* activated with the challenge sent by the service.
|
|
18
|
+
* @warning This API is experimental. It may be changed in the future without notice. Do not use in production applications.
|
|
19
|
+
*/
|
|
20
|
+
class AuthMethodVerificationRequiredStateV2 extends AuthFlowActionRequiredStateBase {
|
|
21
|
+
constructor(stateParameters) {
|
|
22
|
+
super(stateParameters);
|
|
23
|
+
this.stateType = "authMethodVerificationRequired";
|
|
24
|
+
this.type = stateParameters.type;
|
|
25
|
+
this.sentTo = stateParameters.sentTo;
|
|
26
|
+
this.codeLength = stateParameters.codeLength;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Submits the activation challenge for the registered method.
|
|
30
|
+
* @param challenge - The activation challenge to submit.
|
|
31
|
+
* @returns A sign-in continuation, completed authentication result, or failed state.
|
|
32
|
+
*/
|
|
33
|
+
async submitChallenge(challenge) {
|
|
34
|
+
const { correlationId, continuationState, flowClient, logger } = this.stateParameters;
|
|
35
|
+
try {
|
|
36
|
+
ensureArgumentIsNotNullOrUndefined("challenge", challenge, correlationId);
|
|
37
|
+
logger.verbose("0c4x62", correlationId);
|
|
38
|
+
const result = await flowClient.verifyAuthMethodRegistration({
|
|
39
|
+
correlationId,
|
|
40
|
+
continuationState,
|
|
41
|
+
code: challenge,
|
|
42
|
+
});
|
|
43
|
+
if (result.type === FLOW_SIGN_IN_CONTINUATION_REQUIRED_V2) {
|
|
44
|
+
return new CustomAuthResultV2(new SignInContinuationStateV2({
|
|
45
|
+
correlationId: result.correlationId,
|
|
46
|
+
logger,
|
|
47
|
+
config: this.stateParameters.config,
|
|
48
|
+
flowClient,
|
|
49
|
+
continuationState: result.continuationState,
|
|
50
|
+
cacheClient: this.stateParameters.cacheClient,
|
|
51
|
+
}), undefined, result.continuationState.scenario);
|
|
52
|
+
}
|
|
53
|
+
const account = new CustomAuthAccountData(result.authenticationResult.account, this.stateParameters.config, this.stateParameters.cacheClient, logger, correlationId);
|
|
54
|
+
return new CustomAuthResultV2(new CompletedStateV2(), account, continuationState.scenario);
|
|
55
|
+
}
|
|
56
|
+
catch (error) {
|
|
57
|
+
logger.errorPii(`1mwqno ${error}`, correlationId);
|
|
58
|
+
return CustomAuthResultV2.createWithError(error, {
|
|
59
|
+
scenario: continuationState.scenario,
|
|
60
|
+
correlationId,
|
|
61
|
+
errorContext: "authMethodRegistration",
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Requests a replacement activation challenge for the registered method.
|
|
67
|
+
* @returns Refreshed activation metadata or a failed state.
|
|
68
|
+
*/
|
|
69
|
+
async resendChallenge() {
|
|
70
|
+
const { correlationId, continuationState, flowClient, logger } = this.stateParameters;
|
|
71
|
+
try {
|
|
72
|
+
logger.verbose("04qvjc", correlationId);
|
|
73
|
+
const result = await flowClient.resendAuthMethodRegistrationChallenge({
|
|
74
|
+
correlationId,
|
|
75
|
+
continuationState,
|
|
76
|
+
});
|
|
77
|
+
return new CustomAuthResultV2(new AuthMethodVerificationRequiredStateV2({
|
|
78
|
+
correlationId: result.correlationId,
|
|
79
|
+
logger,
|
|
80
|
+
config: this.stateParameters.config,
|
|
81
|
+
flowClient,
|
|
82
|
+
cacheClient: this.stateParameters.cacheClient,
|
|
83
|
+
continuationState: result.continuationState,
|
|
84
|
+
type: this.type,
|
|
85
|
+
sentTo: result.sentTo ?? this.sentTo,
|
|
86
|
+
codeLength: result.codeLength,
|
|
87
|
+
}), undefined, result.continuationState.scenario);
|
|
88
|
+
}
|
|
89
|
+
catch (error) {
|
|
90
|
+
logger.errorPii(`1m3w34 ${error}`, correlationId);
|
|
91
|
+
return CustomAuthResultV2.createWithError(error, {
|
|
92
|
+
scenario: continuationState.scenario,
|
|
93
|
+
correlationId,
|
|
94
|
+
});
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
export { AuthMethodVerificationRequiredStateV2 };
|
|
100
|
+
//# sourceMappingURL=AuthMethodVerificationRequiredStateV2.mjs.map
|
package/dist/custom_auth/core/auth_flow/v2/state/AuthMethodVerificationRequiredStateV2.mjs.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AuthMethodVerificationRequiredStateV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/AuthMethodVerificationRequiredStateV2.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;;;;;;AAAA;;;AAGG;AAaH;;;;AAIG;AACG,MAAO,qCAAsC,SAAQ,+BAAgF,CAAA;AAMvI,IAAA,WAAA,CACI,eAAgE,EAAA;QAEhE,KAAK,CAAC,eAAe,CAAC,CAAC;QARlB,IAAA,CAAA,SAAS,GAAG,gCAAgC,CAAC;AASlD,QAAA,IAAI,CAAC,IAAI,GAAG,eAAe,CAAC,IAAI,CAAC;AACjC,QAAA,IAAI,CAAC,MAAM,GAAG,eAAe,CAAC,MAAM,CAAC;AACrC,QAAA,IAAI,CAAC,UAAU,GAAG,eAAe,CAAC,UAAU,CAAC;IACjD,CAAC;AAED;;;;AAIG;IACH,MAAM,eAAe,CACjB,SAAiB,EAAA;AAEjB,QAAA,MAAM,EAAE,aAAa,EAAE,iBAAiB,EAAE,UAAU,EAAE,MAAM,EAAE,GAC1D,IAAI,CAAC,eAAe,CAAC;QAEzB,IAAI;AACA,YAAA,kCAAkC,CAC9B,WAAW,EACX,SAAS,EACT,aAAa,CAChB,CAAC;AACF,YAAA,MAAM,CAAC,OAAO,CACV;AAGJ,YAAA,MAAM,MAAM,GAAG,MAAM,UAAU,CAAC,4BAA4B,CAAC;gBACzD,aAAa;gBACb,iBAAiB;AACjB,gBAAA,IAAI,EAAE,SAAS;AAClB,aAAA,CAAC,CAAC;AAEH,YAAA,IAAI,MAAM,CAAC,IAAI,KAAK,qCAAqC,EAAE;AACvD,gBAAA,OAAO,IAAI,kBAAkB,CACzB,IAAI,yBAAyB,CAAC;oBAC1B,aAAa,EAAE,MAAM,CAAC,aAAa;oBACnC,MAAM;AACN,oBAAA,MAAM,EAAE,IAAI,CAAC,eAAe,CAAC,MAAM;oBACnC,UAAU;oBAC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M;AACN,gBAAA,MAAM,EAAE,IAAI,CAAC,eAAe,CAAC,MAAM;gBACnC,UAAU;AACV,gBAAA,WAAW,EAAE,IAAI,CAAC,eAAe,CAAC,WAAW;gBAC7C,iBAAiB,EAAE,MAAM,CAAC,iBAAiB;gBAC3C,IAAI,EAAE,IAAI,CAAC,IAAI;AACf,gBAAA,MAAM,EAAE,MAAM,CAAC,MAAM,IAAI,IAAI,CAAC,MAAM;gBACpC,UAAU,EAAE,MAAM,CAAC,UAAU;aAChC,CAAC,EACF,SAAS,EACT,MAAM,CAAC,iBAAiB,CAAC,QAAQ,CACpC,CAAC;AACL,QAAA,CAAA;AAAC,QAAA,OAAO,KAAK,EAAE;YACZ,MAAM,CAAC,QAAQ,CACX,CAAA,OAAA,EAAA,KAAA,CAAA,CAAA,EAAA,aAAA,CAAA,CAAA;AAGJ,YAAA,OAAO,kBAAkB,CAAC,eAAe,CAAC,KAAK,EAAE;gBAC7C,QAAQ,EAAE,iBAAiB,CAAC,QAAQ;gBACpC,aAAa;AAChB,aAAA,CAAC,CAAC;AACN,QAAA,CAAA;IACL,CAAC;AACJ;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @azure/msal-browser v5.
|
|
1
|
+
/*! @azure/msal-browser v5.29.0 2026-11-06 */
|
|
2
2
|
'use strict';
|
|
3
3
|
import { AuthFlowActionRequiredStateBase } from '../../AuthFlowState.mjs';
|
|
4
4
|
import { ensureArgumentIsNotNullOrUndefined } from '../../../utils/ArgumentValidator.mjs';
|
|
@@ -15,18 +15,20 @@ class ChallengeVerificationStateBaseV2 extends AuthFlowActionRequiredStateBase {
|
|
|
15
15
|
this.channel = stateParameters.channel;
|
|
16
16
|
this.codeLength = stateParameters.codeLength;
|
|
17
17
|
}
|
|
18
|
-
async submitCodeCore(code) {
|
|
18
|
+
async submitCodeCore(code, authenticationFactor) {
|
|
19
19
|
ensureArgumentIsNotNullOrUndefined("code", code, this.stateParameters.correlationId);
|
|
20
20
|
return this.stateParameters.flowClient.submitCode({
|
|
21
21
|
correlationId: this.stateParameters.correlationId,
|
|
22
22
|
continuationState: this.stateParameters.continuationState,
|
|
23
|
+
authenticationFactor,
|
|
23
24
|
code,
|
|
24
25
|
});
|
|
25
26
|
}
|
|
26
|
-
async resendCodeCore() {
|
|
27
|
+
async resendCodeCore(authenticationFactor) {
|
|
27
28
|
return this.stateParameters.flowClient.resendCode({
|
|
28
29
|
correlationId: this.stateParameters.correlationId,
|
|
29
30
|
continuationState: this.stateParameters.continuationState,
|
|
31
|
+
authenticationFactor,
|
|
30
32
|
});
|
|
31
33
|
}
|
|
32
34
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChallengeVerificationStateBaseV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/ChallengeVerificationStateBaseV2.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;AAAA;;;AAGG;
|
|
1
|
+
{"version":3,"file":"ChallengeVerificationStateBaseV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/ChallengeVerificationStateBaseV2.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;AAAA;;;AAGG;AAYG,MAAgB,gCAEpB,SAAQ,+BAA4C,CAAA;AASlD,IAAA,WAAA,CAAY,eAA4B,EAAA;QACpC,KAAK,CAAC,eAAe,CAAC,CAAC;AACvB,QAAA,IAAI,CAAC,MAAM,GAAG,eAAe,CAAC,MAAM,CAAC;AACrC,QAAA,IAAI,CAAC,MAAM,GAAG,eAAe,CAAC,MAAM,CAAC;AACrC,QAAA,IAAI,CAAC,OAAO,GAAG,eAAe,CAAC,OAAO,CAAC;AACvC,QAAA,IAAI,CAAC,UAAU,GAAG,eAAe,CAAC,UAAU,CAAC;IACjD,CAAC;AAES,IAAA,MAAM,cAAc,CAC1B,IAAY,EACZ,oBAA6C,EAAA;QAE7C,kCAAkC,CAC9B,MAAM,EACN,IAAI,EACJ,IAAI,CAAC,eAAe,CAAC,aAAa,CACrC,CAAC;AAEF,QAAA,OAAO,IAAI,CAAC,eAAe,CAAC,UAAU,CAAC,UAAU,CAAC;AAC9C,YAAA,aAAa,EAAE,IAAI,CAAC,eAAe,CAAC,aAAa;AACjD,YAAA,iBAAiB,EAAE,IAAI,CAAC,eAAe,CAAC,iBAAiB;YACzD,oBAAoB;YACpB,IAAI;AACP,SAAA,CAAC,CAAC;IACP,CAAC;IAES,MAAM,cAAc,CAC1B,oBAA6C,EAAA;AAE7C,QAAA,OAAO,IAAI,CAAC,eAAe,CAAC,UAAU,CAAC,UAAU,CAAC;AAC9C,YAAA,aAAa,EAAE,IAAI,CAAC,eAAe,CAAC,aAAa;AACjD,YAAA,iBAAiB,EAAE,IAAI,CAAC,eAAe,CAAC,iBAAiB;YACzD,oBAAoB;AACvB,SAAA,CAAC,CAAC;IACP,CAAC;AACJ;;;;"}
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
/*! @azure/msal-browser v5.
|
|
1
|
+
/*! @azure/msal-browser v5.29.0 2026-11-06 */
|
|
2
2
|
'use strict';
|
|
3
3
|
import { CustomAuthResultV2 } from '../CustomAuthResultV2.mjs';
|
|
4
|
-
import { NewPasswordRequiredStateV2 } from '../../../../reset_password/auth_flow/v2/state/NewPasswordRequiredStateV2.mjs';
|
|
5
4
|
import { CompletedStateV2 } from './CompletedStateV2.mjs';
|
|
6
5
|
import { CustomAuthAccountData } from '../../../../get_account/auth_flow/CustomAuthAccountData.mjs';
|
|
7
|
-
import { FLOW_NEW_PASSWORD_REQUIRED_V2, FLOW_ATTRIBUTES_REQUIRED_V2, FLOW_SIGN_UP_PASSWORD_REQUIRED_V2, FLOW_SIGN_IN_CONTINUATION_REQUIRED_V2, FLOW_MFA_REQUIRED_V2, FLOW_COMPLETED_V2 } from '../../../interaction_client/v2/result/FlowActionResultV2.mjs';
|
|
6
|
+
import { FLOW_NEW_PASSWORD_REQUIRED_V2, FLOW_ATTRIBUTES_REQUIRED_V2, FLOW_SIGN_UP_PASSWORD_REQUIRED_V2, FLOW_SIGN_IN_CONTINUATION_REQUIRED_V2, FLOW_AUTH_METHOD_REGISTRATION_REQUIRED_V2, FLOW_MFA_REQUIRED_V2, FLOW_COMPLETED_V2 } from '../../../interaction_client/v2/result/FlowActionResultV2.mjs';
|
|
8
7
|
import { CustomAuthError } from '../../../error/CustomAuthError.mjs';
|
|
9
8
|
import { UNSUPPORTED_FLOW_TRANSITION } from '../../../network_client/custom_auth_api/v2/ErrorCodesV2.mjs';
|
|
10
9
|
import { SignInContinuationStateV2 } from '../../../../sign_in/auth_flow/v2/state/SignInContinuationStateV2.mjs';
|
|
11
10
|
import { ChallengeVerificationStateBaseV2 } from './ChallengeVerificationStateBaseV2.mjs';
|
|
11
|
+
import { AuthMethodRegistrationRequiredStateV2 } from './AuthMethodRegistrationRequiredStateV2.mjs';
|
|
12
12
|
|
|
13
13
|
/*
|
|
14
14
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
15
15
|
* Licensed under the MIT License.
|
|
16
16
|
*/
|
|
17
17
|
/**
|
|
18
|
-
* State returned when first-factor
|
|
19
|
-
*
|
|
18
|
+
* State returned when first-factor authentication requires a one-time code.
|
|
19
|
+
* @warning This API is experimental. It may be changed in the future without notice. Do not use in production applications.
|
|
20
20
|
*/
|
|
21
21
|
class CodeRequiredStateV2 extends ChallengeVerificationStateBaseV2 {
|
|
22
22
|
constructor() {
|
|
@@ -24,8 +24,7 @@ class CodeRequiredStateV2 extends ChallengeVerificationStateBaseV2 {
|
|
|
24
24
|
this.stateType = "codeRequired";
|
|
25
25
|
}
|
|
26
26
|
/**
|
|
27
|
-
* Submits the first-factor
|
|
28
|
-
* result may complete the operation or require another flow-specific step.
|
|
27
|
+
* Submits the first-factor code.
|
|
29
28
|
* @param code - The code to submit.
|
|
30
29
|
* @returns The result of submitting the first-factor code.
|
|
31
30
|
*/
|
|
@@ -36,14 +35,11 @@ class CodeRequiredStateV2 extends ChallengeVerificationStateBaseV2 {
|
|
|
36
35
|
const result = await this.submitCodeCore(code);
|
|
37
36
|
const resultType = result.type;
|
|
38
37
|
if (result.type === FLOW_NEW_PASSWORD_REQUIRED_V2) {
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
continuationState: result.continuationState,
|
|
45
|
-
cacheClient: this.stateParameters.cacheClient,
|
|
46
|
-
}), undefined, result.continuationState.scenario);
|
|
38
|
+
const resetPasswordStateTransitionHandler = this.stateParameters.resetPasswordStateTransitionHandler;
|
|
39
|
+
if (!resetPasswordStateTransitionHandler) {
|
|
40
|
+
throw new CustomAuthError(UNSUPPORTED_FLOW_TRANSITION, "Password-reset state transition handler is missing.", correlationId);
|
|
41
|
+
}
|
|
42
|
+
return resetPasswordStateTransitionHandler.handleNewPasswordRequired(result, this.stateParameters);
|
|
47
43
|
}
|
|
48
44
|
if (result.type === FLOW_ATTRIBUTES_REQUIRED_V2 ||
|
|
49
45
|
result.type === FLOW_SIGN_UP_PASSWORD_REQUIRED_V2) {
|
|
@@ -51,10 +47,10 @@ class CodeRequiredStateV2 extends ChallengeVerificationStateBaseV2 {
|
|
|
51
47
|
if (!signUpStateTransitionHandler) {
|
|
52
48
|
throw new CustomAuthError(UNSUPPORTED_FLOW_TRANSITION, "Sign-up state transition handler is missing.", correlationId);
|
|
53
49
|
}
|
|
54
|
-
return signUpStateTransitionHandler.
|
|
50
|
+
return signUpStateTransitionHandler.handleAttributeSubmission(result, {
|
|
55
51
|
...this.stateParameters,
|
|
56
52
|
signUpStateTransitionHandler,
|
|
57
|
-
});
|
|
53
|
+
}, "attribute");
|
|
58
54
|
}
|
|
59
55
|
if (result.type === FLOW_SIGN_IN_CONTINUATION_REQUIRED_V2) {
|
|
60
56
|
return new CustomAuthResultV2(new SignInContinuationStateV2({
|
|
@@ -66,6 +62,17 @@ class CodeRequiredStateV2 extends ChallengeVerificationStateBaseV2 {
|
|
|
66
62
|
cacheClient: this.stateParameters.cacheClient,
|
|
67
63
|
}), undefined, result.continuationState.scenario);
|
|
68
64
|
}
|
|
65
|
+
if (result.type === FLOW_AUTH_METHOD_REGISTRATION_REQUIRED_V2) {
|
|
66
|
+
return new CustomAuthResultV2(new AuthMethodRegistrationRequiredStateV2({
|
|
67
|
+
correlationId: result.correlationId,
|
|
68
|
+
logger,
|
|
69
|
+
config: this.stateParameters.config,
|
|
70
|
+
flowClient: this.stateParameters.flowClient,
|
|
71
|
+
continuationState: result.continuationState,
|
|
72
|
+
cacheClient: this.stateParameters.cacheClient,
|
|
73
|
+
methods: result.methods,
|
|
74
|
+
}), undefined, result.continuationState.scenario);
|
|
75
|
+
}
|
|
69
76
|
if (result.type === FLOW_MFA_REQUIRED_V2) {
|
|
70
77
|
const signInStateTransitionHandler = this.stateParameters.signInStateTransitionHandler;
|
|
71
78
|
if (!signInStateTransitionHandler) {
|
|
@@ -88,8 +95,7 @@ class CodeRequiredStateV2 extends ChallengeVerificationStateBaseV2 {
|
|
|
88
95
|
}
|
|
89
96
|
}
|
|
90
97
|
/**
|
|
91
|
-
* Requests a replacement first-factor
|
|
92
|
-
* contains the refreshed challenge metadata.
|
|
98
|
+
* Requests a replacement first-factor code.
|
|
93
99
|
* @returns The result of requesting a replacement code.
|
|
94
100
|
*/
|
|
95
101
|
async resendCode() {
|
|
@@ -106,6 +112,8 @@ class CodeRequiredStateV2 extends ChallengeVerificationStateBaseV2 {
|
|
|
106
112
|
cacheClient: this.stateParameters.cacheClient,
|
|
107
113
|
signUpStateTransitionHandler: this.stateParameters.signUpStateTransitionHandler,
|
|
108
114
|
signInStateTransitionHandler: this.stateParameters.signInStateTransitionHandler,
|
|
115
|
+
resetPasswordStateTransitionHandler: this.stateParameters
|
|
116
|
+
.resetPasswordStateTransitionHandler,
|
|
109
117
|
method: this.method,
|
|
110
118
|
sentTo: result.sentTo,
|
|
111
119
|
channel: result.channel,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CodeRequiredStateV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/CodeRequiredStateV2.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;AAGG;
|
|
1
|
+
{"version":3,"file":"CodeRequiredStateV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/CodeRequiredStateV2.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;AAGG;AAuBH;;;AAGG;AACG,MAAO,mBAAoB,SAAQ,gCAA+D,CAAA;AAAxG,IAAA,WAAA,GAAA;;QACa,IAAA,CAAA,SAAS,GAAG,cAAc,CAAC;IA0LxC,CAAC;AAxLG;;;;AAIG;IACH,MAAM,UAAU,CAAC,IAAY,EAAA;QACzB,MAAM,EAAE,aAAa,EAAE,MAAM,EAAE,iBAAiB,EAAE,GAC9C,IAAI,CAAC,eAAe,CAAC;QAEzB,IAAI;AACA,YAAA,MAAM,CAAC,OAAO,CAAC;YACf,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;AAC/C,YAAA,MAAM,UAAU,GAAW,MAAM,CAAC,IAAI,CAAC;AAEvC,YAAA,IAAI,MAAM,CAAC,IAAI,KAAK,6BAA6B,EAAE;AAC/C,gBAAA,MAAM,mCAAmC,GACrC,IAAI,CAAC,eAAe,CAAC,mCAAmC,CAAC;gBAC7D,IAAI,CAAC,mCAAmC,EAAE;oBACtC,MAAM,IAAI,eAAe,CACrB,2BAA2B,EAC3B,qDAAqD,EACrD,aAAa,CAChB,CAAC;AACL,gBAAA,CAAA;gBAED,OAAO,mCAAmC,CAAC,yBAAyB,CAChE,MAAM,EACN,IAAI,CAAC,eAAe,CACvB,CAAC;AACL,YAAA,CAAA;AAED,YAAA,IACI,MAAM,CAAC,IAAI,KAAK,2BAA2B;AAC3C,gBAAA,MAAM,CAAC,IAAI,KAAK,iCAAiC,EACnD;AACE,gBAAA,MAAM,4BAA4B,GAC9B,IAAI,CAAC,eAAe,CAAC,4BAA4B,CAAC;gBACtD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,4 +1,4 @@
|
|
|
1
|
-
/*! @azure/msal-browser v5.
|
|
1
|
+
/*! @azure/msal-browser v5.29.0 2026-11-06 */
|
|
2
2
|
'use strict';
|
|
3
3
|
import { AuthFlowStateBase } from '../../AuthFlowState.mjs';
|
|
4
4
|
|
|
@@ -8,9 +8,7 @@ import { AuthFlowStateBase } from '../../AuthFlowState.mjs';
|
|
|
8
8
|
*/
|
|
9
9
|
/**
|
|
10
10
|
* Terminal state indicating the operation completed successfully.
|
|
11
|
-
*
|
|
12
|
-
* Completion data (for example the signed-in account) is carried by the
|
|
13
|
-
* result's `data` payload, not by this state.
|
|
11
|
+
* @warning This API is experimental. It may be changed in the future without notice. Do not use in production applications.
|
|
14
12
|
*/
|
|
15
13
|
class CompletedStateV2 extends AuthFlowStateBase {
|
|
16
14
|
constructor() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CompletedStateV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/CompletedStateV2.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;AAAA;;;AAGG;AAIH
|
|
1
|
+
{"version":3,"file":"CompletedStateV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/CompletedStateV2.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;AAAA;;;AAGG;AAIH;;;AAGG;AACG,MAAO,gBAAiB,SAAQ,iBAAiB,CAAA;AAAvD,IAAA,WAAA,GAAA;;QACa,IAAA,CAAA,SAAS,GAAG,WAAW,CAAC;IACrC,CAAC;AAAA;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @azure/msal-browser v5.
|
|
1
|
+
/*! @azure/msal-browser v5.29.0 2026-11-06 */
|
|
2
2
|
'use strict';
|
|
3
3
|
import { AuthFlowStateBase } from '../../AuthFlowState.mjs';
|
|
4
4
|
|
|
@@ -8,8 +8,7 @@ import { AuthFlowStateBase } from '../../AuthFlowState.mjs';
|
|
|
8
8
|
*/
|
|
9
9
|
/**
|
|
10
10
|
* Terminal state indicating the operation failed.
|
|
11
|
-
*
|
|
12
|
-
* The error is carried by the result's `error` payload, not by this state.
|
|
11
|
+
* @warning This API is experimental. It may be changed in the future without notice. Do not use in production applications.
|
|
13
12
|
*/
|
|
14
13
|
class FailedStateV2 extends AuthFlowStateBase {
|
|
15
14
|
constructor() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FailedStateV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/FailedStateV2.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;AAAA;;;AAGG;AAIH
|
|
1
|
+
{"version":3,"file":"FailedStateV2.mjs","sources":["../../../../../../src/custom_auth/core/auth_flow/v2/state/FailedStateV2.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;AAAA;;;AAGG;AAIH;;;AAGG;AACG,MAAO,aAAc,SAAQ,iBAAiB,CAAA;AAApD,IAAA,WAAA,GAAA;;QACa,IAAA,CAAA,SAAS,GAAG,QAAQ,CAAC;IAClC,CAAC;AAAA;;;;"}
|
|
@@ -1,20 +1,23 @@
|
|
|
1
|
-
/*! @azure/msal-browser v5.
|
|
1
|
+
/*! @azure/msal-browser v5.29.0 2026-11-06 */
|
|
2
2
|
'use strict';
|
|
3
3
|
import { CustomAuthResultV2 } from '../CustomAuthResultV2.mjs';
|
|
4
4
|
import { CompletedStateV2 } from './CompletedStateV2.mjs';
|
|
5
5
|
import { CustomAuthAccountData } from '../../../../get_account/auth_flow/CustomAuthAccountData.mjs';
|
|
6
|
-
import { FLOW_COMPLETED_V2 } from '../../../interaction_client/v2/result/FlowActionResultV2.mjs';
|
|
6
|
+
import { FLOW_SIGN_IN_CONTINUATION_REQUIRED_V2, FLOW_COMPLETED_V2 } from '../../../interaction_client/v2/result/FlowActionResultV2.mjs';
|
|
7
|
+
import { SignInContinuationStateV2 } from '../../../../sign_in/auth_flow/v2/state/SignInContinuationStateV2.mjs';
|
|
7
8
|
import { CustomAuthError } from '../../../error/CustomAuthError.mjs';
|
|
8
9
|
import { UNSUPPORTED_FLOW_TRANSITION } from '../../../network_client/custom_auth_api/v2/ErrorCodesV2.mjs';
|
|
9
10
|
import { ChallengeVerificationStateBaseV2 } from './ChallengeVerificationStateBaseV2.mjs';
|
|
11
|
+
import { AuthenticationFactorV2 } from '../../../network_client/custom_auth_api/v2/result/BaseResultsV2.mjs';
|
|
10
12
|
|
|
11
13
|
/*
|
|
12
14
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
13
15
|
* Licensed under the MIT License.
|
|
14
16
|
*/
|
|
15
17
|
/**
|
|
16
|
-
* State returned when
|
|
18
|
+
* State returned when authentication requires verification of an email or SMS MFA
|
|
17
19
|
* challenge. It allows the app to submit the challenge or request a replacement.
|
|
20
|
+
* @warning This API is experimental. It may be changed in the future without notice. Do not use in production applications.
|
|
18
21
|
*/
|
|
19
22
|
class MFAVerificationRequiredStateV2 extends ChallengeVerificationStateBaseV2 {
|
|
20
23
|
constructor() {
|
|
@@ -23,7 +26,6 @@ class MFAVerificationRequiredStateV2 extends ChallengeVerificationStateBaseV2 {
|
|
|
23
26
|
}
|
|
24
27
|
/**
|
|
25
28
|
* Submits the email or SMS challenge as the second authentication factor.
|
|
26
|
-
* Successful verification completes sign-in.
|
|
27
29
|
* @param challenge - The challenge value to submit.
|
|
28
30
|
* @returns The result of submitting the MFA challenge.
|
|
29
31
|
*/
|
|
@@ -31,7 +33,17 @@ class MFAVerificationRequiredStateV2 extends ChallengeVerificationStateBaseV2 {
|
|
|
31
33
|
const { correlationId, logger, continuationState } = this.stateParameters;
|
|
32
34
|
try {
|
|
33
35
|
logger.verbose("10k0lc", correlationId);
|
|
34
|
-
const result = await this.submitCodeCore(challenge);
|
|
36
|
+
const result = await this.submitCodeCore(challenge, AuthenticationFactorV2.MULTI_FACTOR);
|
|
37
|
+
if (result.type === FLOW_SIGN_IN_CONTINUATION_REQUIRED_V2) {
|
|
38
|
+
return new CustomAuthResultV2(new SignInContinuationStateV2({
|
|
39
|
+
correlationId: result.correlationId,
|
|
40
|
+
logger,
|
|
41
|
+
config: this.stateParameters.config,
|
|
42
|
+
flowClient: this.stateParameters.flowClient,
|
|
43
|
+
continuationState: result.continuationState,
|
|
44
|
+
cacheClient: this.stateParameters.cacheClient,
|
|
45
|
+
}), undefined, result.continuationState.scenario);
|
|
46
|
+
}
|
|
35
47
|
if (result.type !== FLOW_COMPLETED_V2) {
|
|
36
48
|
throw new CustomAuthError(UNSUPPORTED_FLOW_TRANSITION, `MFA challenge submission result type '${result.type}' is not supported.`, correlationId);
|
|
37
49
|
}
|
|
@@ -43,19 +55,19 @@ class MFAVerificationRequiredStateV2 extends ChallengeVerificationStateBaseV2 {
|
|
|
43
55
|
return CustomAuthResultV2.createWithError(error, {
|
|
44
56
|
scenario: continuationState.scenario,
|
|
45
57
|
correlationId,
|
|
58
|
+
errorContext: "mfaVerification",
|
|
46
59
|
});
|
|
47
60
|
}
|
|
48
61
|
}
|
|
49
62
|
/**
|
|
50
|
-
* Requests a replacement challenge for the selected MFA method.
|
|
51
|
-
* returned state contains the refreshed email or SMS challenge metadata.
|
|
63
|
+
* Requests a replacement challenge for the selected MFA method.
|
|
52
64
|
* @returns The result of requesting a replacement MFA challenge.
|
|
53
65
|
*/
|
|
54
66
|
async resendChallenge() {
|
|
55
67
|
const { correlationId, logger, continuationState } = this.stateParameters;
|
|
56
68
|
try {
|
|
57
69
|
logger.verbose("13st9u", correlationId);
|
|
58
|
-
const result = await this.resendCodeCore();
|
|
70
|
+
const result = await this.resendCodeCore(AuthenticationFactorV2.MULTI_FACTOR);
|
|
59
71
|
return new CustomAuthResultV2(new MFAVerificationRequiredStateV2({
|
|
60
72
|
correlationId: result.correlationId,
|
|
61
73
|
logger,
|