@azure/msal-browser 5.12.0 → 5.14.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/README.md +1 -0
- package/dist/app/IPublicClientApplication.mjs +1 -1
- package/dist/app/IPublicClientApplication.mjs.map +1 -1
- package/dist/app/PublicClientApplication.mjs +1 -1
- package/dist/app/PublicClientApplication.mjs.map +1 -1
- package/dist/broker/nativeBroker/NativeStatusCodes.mjs +1 -1
- package/dist/broker/nativeBroker/PlatformAuthDOMHandler.mjs +9 -9
- package/dist/broker/nativeBroker/PlatformAuthDOMHandler.mjs.map +1 -1
- package/dist/broker/nativeBroker/PlatformAuthExtensionHandler.mjs +15 -15
- package/dist/broker/nativeBroker/PlatformAuthExtensionHandler.mjs.map +1 -1
- package/dist/broker/nativeBroker/PlatformAuthProvider.mjs +2 -2
- package/dist/broker/nativeBroker/PlatformAuthProvider.mjs.map +1 -1
- package/dist/cache/AccountManager.mjs +1 -1
- package/dist/cache/AccountManager.mjs.map +1 -1
- package/dist/cache/AsyncMemoryStorage.mjs +1 -1
- package/dist/cache/AsyncMemoryStorage.mjs.map +1 -1
- package/dist/cache/BrowserCacheManager.mjs +97 -24
- package/dist/cache/BrowserCacheManager.mjs.map +1 -1
- package/dist/cache/CacheHelpers.mjs +1 -1
- package/dist/cache/CacheHelpers.mjs.map +1 -1
- package/dist/cache/CacheKeys.mjs +1 -1
- package/dist/cache/CacheKeys.mjs.map +1 -1
- package/dist/cache/CookieStorage.mjs +1 -1
- package/dist/cache/CookieStorage.mjs.map +1 -1
- package/dist/cache/DatabaseStorage.mjs +1 -1
- package/dist/cache/DatabaseStorage.mjs.map +1 -1
- package/dist/cache/EncryptedData.mjs +1 -1
- package/dist/cache/LocalStorage.mjs +2 -2
- package/dist/cache/LocalStorage.mjs.map +1 -1
- package/dist/cache/MemoryStorage.mjs +1 -1
- package/dist/cache/MemoryStorage.mjs.map +1 -1
- package/dist/cache/SessionStorage.mjs +1 -1
- package/dist/cache/SessionStorage.mjs.map +1 -1
- package/dist/cache/TokenCache.mjs +4 -2
- package/dist/cache/TokenCache.mjs.map +1 -1
- package/dist/config/Configuration.mjs +4 -2
- package/dist/config/Configuration.mjs.map +1 -1
- package/dist/controllers/NestedAppAuthController.mjs +3 -3
- package/dist/controllers/NestedAppAuthController.mjs.map +1 -1
- package/dist/controllers/StandardController.mjs +17 -17
- package/dist/controllers/StandardController.mjs.map +1 -1
- package/dist/crypto/BrowserCrypto.mjs +1 -1
- package/dist/crypto/BrowserCrypto.mjs.map +1 -1
- package/dist/crypto/CryptoOps.mjs +2 -2
- package/dist/crypto/CryptoOps.mjs.map +1 -1
- package/dist/crypto/PkceGenerator.mjs +1 -1
- package/dist/crypto/PkceGenerator.mjs.map +1 -1
- package/dist/crypto/SignedHttpRequest.mjs +1 -1
- package/dist/crypto/SignedHttpRequest.mjs.map +1 -1
- package/dist/custom_auth/CustomAuthConstants.mjs +1 -1
- package/dist/custom_auth/CustomAuthConstants.mjs.map +1 -1
- package/dist/custom_auth/CustomAuthPublicClientApplication.mjs +1 -1
- package/dist/custom_auth/CustomAuthPublicClientApplication.mjs.map +1 -1
- package/dist/custom_auth/controller/CustomAuthStandardController.mjs +13 -8
- package/dist/custom_auth/controller/CustomAuthStandardController.mjs.map +1 -1
- package/dist/custom_auth/core/CustomAuthAuthority.mjs +1 -1
- package/dist/custom_auth/core/CustomAuthAuthority.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/AuthFlowErrorBase.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/AuthFlowErrorBase.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/AuthFlowResultBase.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/AuthFlowResultBase.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/AuthFlowState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/AuthFlowState.mjs.map +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/error_type/AuthMethodRegistrationError.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/jit/result/AuthMethodRegistrationChallengeMethodResult.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/jit/result/AuthMethodRegistrationChallengeMethodResult.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/jit/result/AuthMethodRegistrationSubmitChallengeResult.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/jit/result/AuthMethodRegistrationSubmitChallengeResult.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationCompletedState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationCompletedState.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationFailedState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationFailedState.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationState.mjs +4 -4
- package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationState.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/error_type/MfaError.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/error_type/MfaError.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/result/MfaRequestChallengeResult.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/result/MfaRequestChallengeResult.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/result/MfaSubmitChallengeResult.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/result/MfaSubmitChallengeResult.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/state/MfaCompletedState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/state/MfaCompletedState.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/state/MfaFailedState.mjs +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/state/MfaFailedState.mjs.map +1 -1
- package/dist/custom_auth/core/auth_flow/mfa/state/MfaState.mjs +4 -4
- package/dist/custom_auth/core/auth_flow/mfa/state/MfaState.mjs.map +1 -1
- package/dist/custom_auth/core/error/CustomAuthApiError.mjs +1 -1
- package/dist/custom_auth/core/error/CustomAuthApiError.mjs.map +1 -1
- package/dist/custom_auth/core/error/CustomAuthError.mjs +1 -1
- package/dist/custom_auth/core/error/CustomAuthError.mjs.map +1 -1
- package/dist/custom_auth/core/error/HttpError.mjs +1 -1
- package/dist/custom_auth/core/error/HttpError.mjs.map +1 -1
- package/dist/custom_auth/core/error/HttpErrorCodes.mjs +1 -1
- package/dist/custom_auth/core/error/InvalidArgumentError.mjs +1 -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/InvalidConfigurationError.mjs.map +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/MethodNotImplementedError.mjs.map +1 -1
- package/dist/custom_auth/core/error/MsalCustomAuthError.mjs +1 -1
- package/dist/custom_auth/core/error/MsalCustomAuthError.mjs.map +1 -1
- package/dist/custom_auth/core/error/NoCachedAccountFoundError.mjs +1 -1
- package/dist/custom_auth/core/error/NoCachedAccountFoundError.mjs.map +1 -1
- package/dist/custom_auth/core/error/ParsedUrlError.mjs +1 -1
- package/dist/custom_auth/core/error/ParsedUrlError.mjs.map +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/UnexpectedError.mjs.map +1 -1
- package/dist/custom_auth/core/error/UnsupportedEnvironmentError.mjs +1 -1
- package/dist/custom_auth/core/error/UnsupportedEnvironmentError.mjs.map +1 -1
- package/dist/custom_auth/core/error/UserAccountAttributeError.mjs +1 -1
- package/dist/custom_auth/core/error/UserAccountAttributeError.mjs.map +1 -1
- package/dist/custom_auth/core/error/UserAlreadySignedInError.mjs +1 -1
- package/dist/custom_auth/core/error/UserAlreadySignedInError.mjs.map +1 -1
- package/dist/custom_auth/core/interaction_client/CustomAuthInteractionClientBase.mjs +1 -1
- package/dist/custom_auth/core/interaction_client/CustomAuthInteractionClientBase.mjs.map +1 -1
- package/dist/custom_auth/core/interaction_client/CustomAuthInterationClientFactory.mjs +1 -1
- package/dist/custom_auth/core/interaction_client/CustomAuthInterationClientFactory.mjs.map +1 -1
- package/dist/custom_auth/core/interaction_client/jit/JitClient.mjs +1 -1
- package/dist/custom_auth/core/interaction_client/jit/JitClient.mjs.map +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 +2 -2
- package/dist/custom_auth/core/interaction_client/mfa/MfaClient.mjs.map +1 -1
- package/dist/custom_auth/core/interaction_client/mfa/result/MfaActionResult.mjs +1 -1
- package/dist/custom_auth/core/network_client/custom_auth_api/BaseApiClient.mjs +2 -2
- package/dist/custom_auth/core/network_client/custom_auth_api/BaseApiClient.mjs.map +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/CustomAuthApiClient.mjs.map +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/RegisterApiClient.mjs.map +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/ResetPasswordApiClient.mjs.map +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/SignInApiClient.mjs.map +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/SignupApiClient.mjs.map +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/http_client/FetchHttpClient.mjs +4 -4
- package/dist/custom_auth/core/network_client/http_client/FetchHttpClient.mjs.map +1 -1
- package/dist/custom_auth/core/network_client/http_client/IHttpClient.mjs +1 -1
- package/dist/custom_auth/core/network_client/http_client/IHttpClient.mjs.map +1 -1
- package/dist/custom_auth/core/telemetry/PublicApiId.mjs +1 -1
- package/dist/custom_auth/core/utils/ArgumentValidator.mjs +1 -1
- package/dist/custom_auth/core/utils/ArgumentValidator.mjs.map +1 -1
- package/dist/custom_auth/core/utils/CustomHeaderUtils.mjs +3 -3
- package/dist/custom_auth/core/utils/CustomHeaderUtils.mjs.map +1 -1
- package/dist/custom_auth/core/utils/UrlUtils.mjs +1 -1
- package/dist/custom_auth/core/utils/UrlUtils.mjs.map +1 -1
- package/dist/custom_auth/get_account/auth_flow/CustomAuthAccountData.mjs +2 -2
- package/dist/custom_auth/get_account/auth_flow/CustomAuthAccountData.mjs.map +1 -1
- package/dist/custom_auth/get_account/auth_flow/error_type/GetAccountError.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/error_type/GetAccountError.mjs.map +1 -1
- package/dist/custom_auth/get_account/auth_flow/result/GetAccessTokenResult.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/result/GetAccessTokenResult.mjs.map +1 -1
- package/dist/custom_auth/get_account/auth_flow/result/GetAccountResult.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/result/GetAccountResult.mjs.map +1 -1
- package/dist/custom_auth/get_account/auth_flow/result/SignOutResult.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/result/SignOutResult.mjs.map +1 -1
- package/dist/custom_auth/get_account/auth_flow/state/GetAccessTokenState.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/state/GetAccessTokenState.mjs.map +1 -1
- package/dist/custom_auth/get_account/auth_flow/state/GetAccountState.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/state/GetAccountState.mjs.map +1 -1
- package/dist/custom_auth/get_account/auth_flow/state/SignOutState.mjs +1 -1
- package/dist/custom_auth/get_account/auth_flow/state/SignOutState.mjs.map +1 -1
- package/dist/custom_auth/get_account/interaction_client/CustomAuthSilentCacheClient.mjs +1 -1
- package/dist/custom_auth/get_account/interaction_client/CustomAuthSilentCacheClient.mjs.map +1 -1
- package/dist/custom_auth/index.mjs +1 -1
- package/dist/custom_auth/operating_context/CustomAuthOperatingContext.mjs +1 -1
- package/dist/custom_auth/operating_context/CustomAuthOperatingContext.mjs.map +1 -1
- package/dist/custom_auth/reset_password/auth_flow/error_type/ResetPasswordError.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/error_type/ResetPasswordError.mjs.map +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordResendCodeResult.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordResendCodeResult.mjs.map +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordStartResult.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordStartResult.mjs.map +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordSubmitCodeResult.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordSubmitCodeResult.mjs.map +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordSubmitPasswordResult.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordSubmitPasswordResult.mjs.map +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordCodeRequiredState.mjs +3 -3
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordCodeRequiredState.mjs.map +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordCompletedState.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordCompletedState.mjs.map +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordFailedState.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordFailedState.mjs.map +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordPasswordRequiredState.mjs +2 -2
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordPasswordRequiredState.mjs.map +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordState.mjs +1 -1
- package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordState.mjs.map +1 -1
- package/dist/custom_auth/reset_password/interaction_client/ResetPasswordClient.mjs +3 -3
- package/dist/custom_auth/reset_password/interaction_client/ResetPasswordClient.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/SignInScenario.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/SignInScenario.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/error_type/SignInError.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/error_type/SignInError.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInResendCodeResult.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInResendCodeResult.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInResult.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInResult.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInSubmitCodeResult.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInSubmitCodeResult.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInSubmitPasswordResult.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/result/SignInSubmitPasswordResult.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInCodeRequiredState.mjs +2 -2
- package/dist/custom_auth/sign_in/auth_flow/state/SignInCodeRequiredState.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInCompletedState.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInCompletedState.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInContinuationState.mjs +2 -2
- package/dist/custom_auth/sign_in/auth_flow/state/SignInContinuationState.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInFailedState.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInFailedState.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInPasswordRequiredState.mjs +2 -2
- package/dist/custom_auth/sign_in/auth_flow/state/SignInPasswordRequiredState.mjs.map +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInState.mjs +1 -1
- package/dist/custom_auth/sign_in/auth_flow/state/SignInState.mjs.map +1 -1
- package/dist/custom_auth/sign_in/interaction_client/SignInClient.mjs +2 -2
- package/dist/custom_auth/sign_in/interaction_client/SignInClient.mjs.map +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/error_type/SignUpError.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpResendCodeResult.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpResendCodeResult.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpResult.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpResult.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitAttributesResult.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitAttributesResult.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitCodeResult.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitCodeResult.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitPasswordResult.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitPasswordResult.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpAttributesRequiredState.mjs +2 -2
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpAttributesRequiredState.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpCodeRequiredState.mjs +3 -3
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpCodeRequiredState.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpCompletedState.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpCompletedState.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpFailedState.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpFailedState.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpPasswordRequiredState.mjs +2 -2
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpPasswordRequiredState.mjs.map +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpState.mjs +1 -1
- package/dist/custom_auth/sign_up/auth_flow/state/SignUpState.mjs.map +1 -1
- package/dist/custom_auth/sign_up/interaction_client/SignUpClient.mjs +5 -5
- package/dist/custom_auth/sign_up/interaction_client/SignUpClient.mjs.map +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/BrowserAuthError.mjs.map +1 -1
- package/dist/error/BrowserAuthErrorCodes.mjs +1 -1
- package/dist/error/BrowserConfigurationAuthError.mjs +1 -1
- package/dist/error/BrowserConfigurationAuthError.mjs.map +1 -1
- package/dist/error/BrowserConfigurationAuthErrorCodes.mjs +1 -1
- package/dist/error/NativeAuthError.mjs +1 -1
- package/dist/error/NativeAuthError.mjs.map +1 -1
- package/dist/error/NativeAuthErrorCodes.mjs +1 -1
- package/dist/error/NestedAppAuthError.mjs +1 -1
- package/dist/error/NestedAppAuthError.mjs.map +1 -1
- package/dist/event/EventHandler.mjs +7 -6
- package/dist/event/EventHandler.mjs.map +1 -1
- package/dist/event/EventMessage.mjs +1 -1
- package/dist/event/EventMessage.mjs.map +1 -1
- package/dist/event/EventType.mjs +1 -1
- package/dist/event/EventType.mjs.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/dist/interaction_client/BaseInteractionClient.mjs +10 -6
- package/dist/interaction_client/BaseInteractionClient.mjs.map +1 -1
- package/dist/interaction_client/HybridSpaAuthorizationCodeClient.mjs +1 -1
- package/dist/interaction_client/HybridSpaAuthorizationCodeClient.mjs.map +1 -1
- package/dist/interaction_client/PlatformAuthInteractionClient.mjs +5 -5
- package/dist/interaction_client/PlatformAuthInteractionClient.mjs.map +1 -1
- package/dist/interaction_client/PopupClient.mjs +9 -9
- package/dist/interaction_client/PopupClient.mjs.map +1 -1
- package/dist/interaction_client/RedirectClient.mjs +16 -13
- package/dist/interaction_client/RedirectClient.mjs.map +1 -1
- package/dist/interaction_client/SilentAuthCodeClient.mjs +2 -2
- package/dist/interaction_client/SilentAuthCodeClient.mjs.map +1 -1
- package/dist/interaction_client/SilentCacheClient.mjs +2 -2
- package/dist/interaction_client/SilentCacheClient.mjs.map +1 -1
- package/dist/interaction_client/SilentIframeClient.mjs +42 -20
- package/dist/interaction_client/SilentIframeClient.mjs.map +1 -1
- package/dist/interaction_client/SilentRefreshClient.mjs +2 -2
- package/dist/interaction_client/SilentRefreshClient.mjs.map +1 -1
- package/dist/interaction_client/StandardInteractionClient.mjs +2 -2
- package/dist/interaction_client/StandardInteractionClient.mjs.map +1 -1
- package/dist/interaction_handler/InteractionHandler.mjs +1 -1
- package/dist/interaction_handler/InteractionHandler.mjs.map +1 -1
- package/dist/interaction_handler/SilentHandler.mjs +12 -26
- package/dist/interaction_handler/SilentHandler.mjs.map +1 -1
- package/dist/log-strings-mapping.json +7 -3
- package/dist/naa/BridgeError.mjs +1 -1
- package/dist/naa/BridgeProxy.mjs +2 -2
- package/dist/naa/BridgeProxy.mjs.map +1 -1
- package/dist/naa/BridgeStatusCode.mjs +1 -1
- package/dist/naa/BridgeStatusCode.mjs.map +1 -1
- package/dist/naa/mapping/NestedAppAuthAdapter.mjs +1 -1
- package/dist/naa/mapping/NestedAppAuthAdapter.mjs.map +1 -1
- package/dist/navigation/NavigationClient.mjs +1 -1
- package/dist/navigation/NavigationClient.mjs.map +1 -1
- package/dist/network/FetchClient.mjs +1 -1
- package/dist/network/FetchClient.mjs.map +1 -1
- package/dist/operatingcontext/BaseOperatingContext.mjs +1 -1
- package/dist/operatingcontext/BaseOperatingContext.mjs.map +1 -1
- package/dist/operatingcontext/NestedAppOperatingContext.mjs +3 -3
- package/dist/operatingcontext/NestedAppOperatingContext.mjs.map +1 -1
- package/dist/operatingcontext/StandardOperatingContext.mjs +1 -1
- package/dist/operatingcontext/StandardOperatingContext.mjs.map +1 -1
- package/dist/packageMetadata.mjs +2 -2
- package/dist/protocol/Authorize.mjs +1 -1
- package/dist/protocol/Authorize.mjs.map +1 -1
- package/dist/redirect_bridge/index.mjs +1 -1
- package/dist/redirect_bridge/index.mjs.map +1 -1
- package/dist/request/RequestHelpers.mjs +2 -2
- package/dist/request/RequestHelpers.mjs.map +1 -1
- package/dist/response/ResponseHandler.mjs +4 -4
- package/dist/response/ResponseHandler.mjs.map +1 -1
- package/dist/telemetry/BrowserPerformanceClient.mjs +1 -1
- package/dist/telemetry/BrowserPerformanceClient.mjs.map +1 -1
- package/dist/telemetry/BrowserPerformanceEvents.mjs +2 -3
- package/dist/telemetry/BrowserPerformanceEvents.mjs.map +1 -1
- package/dist/telemetry/BrowserPerformanceMeasurement.mjs +1 -1
- package/dist/telemetry/BrowserPerformanceMeasurement.mjs.map +1 -1
- package/dist/telemetry/BrowserRootPerformanceEvents.mjs +1 -1
- package/dist/utils/BrowserConstants.mjs +1 -1
- package/dist/utils/BrowserConstants.mjs.map +1 -1
- package/dist/utils/BrowserProtocolUtils.mjs +1 -1
- package/dist/utils/BrowserProtocolUtils.mjs.map +1 -1
- package/dist/utils/BrowserUtils.mjs +5 -3
- package/dist/utils/BrowserUtils.mjs.map +1 -1
- package/dist/utils/Helpers.mjs +1 -1
- package/dist/utils/Helpers.mjs.map +1 -1
- package/dist/utils/MsalFrameStatsUtils.mjs +1 -1
- package/dist/utils/MsalFrameStatsUtils.mjs.map +1 -1
- package/lib/custom-auth-path/log-strings-mapping.json +7 -3
- package/lib/custom-auth-path/msal-custom-auth.cjs +6174 -5994
- package/lib/custom-auth-path/msal-custom-auth.cjs.map +1 -1
- package/lib/custom-auth-path/msal-custom-auth.js +6065 -5889
- package/lib/custom-auth-path/msal-custom-auth.js.map +1 -1
- package/lib/log-strings-mapping.json +7 -3
- package/lib/msal-browser.cjs +6880 -6690
- package/lib/msal-browser.cjs.map +1 -1
- package/lib/msal-browser.js +6880 -6690
- package/lib/msal-browser.js.map +1 -1
- package/lib/msal-browser.min.js +2 -2
- package/lib/redirect-bridge/msal-redirect-bridge.cjs +39 -39
- package/lib/redirect-bridge/msal-redirect-bridge.cjs.map +1 -1
- package/lib/redirect-bridge/msal-redirect-bridge.js +39 -39
- package/lib/redirect-bridge/msal-redirect-bridge.js.map +1 -1
- package/lib/redirect-bridge/msal-redirect-bridge.min.js +2 -2
- package/package.json +5 -6
- package/src/cache/BrowserCacheManager.ts +141 -34
- package/src/cache/TokenCache.ts +7 -1
- package/src/config/Configuration.ts +17 -2
- package/src/controllers/StandardController.ts +6 -6
- package/src/custom_auth/controller/CustomAuthStandardController.ts +2 -4
- package/src/event/EventHandler.ts +2 -1
- package/src/interaction_client/BaseInteractionClient.ts +14 -4
- package/src/interaction_client/PlatformAuthInteractionClient.ts +9 -3
- package/src/interaction_client/PopupClient.ts +9 -3
- package/src/interaction_client/RedirectClient.ts +27 -8
- package/src/interaction_client/SilentAuthCodeClient.ts +3 -1
- package/src/interaction_client/SilentCacheClient.ts +3 -1
- package/src/interaction_client/SilentIframeClient.ts +94 -58
- package/src/interaction_client/SilentRefreshClient.ts +3 -1
- package/src/interaction_handler/SilentHandler.ts +11 -32
- package/src/packageMetadata.ts +1 -1
- package/src/telemetry/BrowserPerformanceEvents.ts +0 -1
- package/src/utils/BrowserUtils.ts +3 -1
- package/types/cache/BrowserCacheManager.d.ts +18 -1
- package/types/cache/BrowserCacheManager.d.ts.map +1 -1
- package/types/cache/TokenCache.d.ts.map +1 -1
- package/types/config/Configuration.d.ts +10 -1
- package/types/config/Configuration.d.ts.map +1 -1
- package/types/custom_auth/CustomAuthConstants.d.ts +1 -1
- package/types/custom_auth/controller/CustomAuthStandardController.d.ts.map +1 -1
- package/types/event/EventHandler.d.ts.map +1 -1
- package/types/interaction_client/BaseInteractionClient.d.ts +2 -1
- package/types/interaction_client/BaseInteractionClient.d.ts.map +1 -1
- 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/SilentAuthCodeClient.d.ts.map +1 -1
- package/types/interaction_client/SilentCacheClient.d.ts.map +1 -1
- package/types/interaction_client/SilentIframeClient.d.ts.map +1 -1
- package/types/interaction_client/SilentRefreshClient.d.ts.map +1 -1
- package/types/interaction_handler/SilentHandler.d.ts +13 -6
- package/types/interaction_handler/SilentHandler.d.ts.map +1 -1
- package/types/packageMetadata.d.ts +1 -1
- package/types/telemetry/BrowserPerformanceEvents.d.ts +0 -1
- package/types/telemetry/BrowserPerformanceEvents.d.ts.map +1 -1
- package/types/utils/BrowserUtils.d.ts +3 -1
- package/types/utils/BrowserUtils.d.ts.map +1 -1
package/src/cache/TokenCache.ts
CHANGED
|
@@ -43,6 +43,7 @@ import * as BrowserRootPerformanceEvents from "../telemetry/BrowserRootPerforman
|
|
|
43
43
|
import { ApiId } from "../utils/BrowserConstants.js";
|
|
44
44
|
import * as BrowserUtils from "../utils/BrowserUtils.js";
|
|
45
45
|
import { BrowserCacheManager } from "./BrowserCacheManager.js";
|
|
46
|
+
import { name, version } from "../packageMetadata.js";
|
|
46
47
|
|
|
47
48
|
export type LoadTokenOptions = {
|
|
48
49
|
clientInfo?: string;
|
|
@@ -91,7 +92,11 @@ export async function loadExternalTokens(
|
|
|
91
92
|
authorityMetadata: browserConfig.auth.authorityMetadata,
|
|
92
93
|
};
|
|
93
94
|
|
|
94
|
-
const logger = new Logger(
|
|
95
|
+
const logger = new Logger(
|
|
96
|
+
browserConfig.system.loggerOptions || {},
|
|
97
|
+
name,
|
|
98
|
+
version
|
|
99
|
+
);
|
|
95
100
|
const cryptoOps = new CryptoOps(logger, browserConfig.telemetry.client);
|
|
96
101
|
const storage = new BrowserCacheManager(
|
|
97
102
|
browserConfig.auth.clientId,
|
|
@@ -102,6 +107,7 @@ export async function loadExternalTokens(
|
|
|
102
107
|
new EventHandler(logger),
|
|
103
108
|
buildStaticAuthorityOptions(browserConfig.auth)
|
|
104
109
|
);
|
|
110
|
+
await storage.initialize(correlationId);
|
|
105
111
|
|
|
106
112
|
const authorityString =
|
|
107
113
|
request.authority || browserConfig.auth.authority;
|
|
@@ -26,6 +26,7 @@ import { BrowserCacheLocation } from "../utils/BrowserConstants.js";
|
|
|
26
26
|
import { INavigationClient } from "../navigation/INavigationClient.js";
|
|
27
27
|
import { NavigationClient } from "../navigation/NavigationClient.js";
|
|
28
28
|
import { FetchClient } from "../network/FetchClient.js";
|
|
29
|
+
import { name, version } from "../packageMetadata.js";
|
|
29
30
|
|
|
30
31
|
// Default timeout for popup windows and iframes in milliseconds
|
|
31
32
|
export const DEFAULT_POPUP_TIMEOUT_MS = 60000;
|
|
@@ -167,9 +168,18 @@ export type BrowserSystemOptions = SystemOptions & {
|
|
|
167
168
|
* Enum that represents the protocol that msal follows. Used for configuring proper endpoints.
|
|
168
169
|
*/
|
|
169
170
|
protocolMode?: ProtocolMode;
|
|
171
|
+
/**
|
|
172
|
+
* @deprecated This option will be removed in a future release.
|
|
173
|
+
* Flag to enable emitting telemetry to the STS. When disabled, failed requests are not cached to browser storage and x-client-current-telemetry, x-client-last-telemetry parameters are not sent to the STS. Defaults to false.
|
|
174
|
+
*/
|
|
175
|
+
serverTelemetryEnabled?: boolean;
|
|
170
176
|
};
|
|
171
177
|
|
|
172
|
-
/**
|
|
178
|
+
/**
|
|
179
|
+
* Options for configuring experimental features. These features do not follow
|
|
180
|
+
* semver and may be changed or removed without a major version bump. Use with caution.
|
|
181
|
+
* @public
|
|
182
|
+
*/
|
|
173
183
|
export type BrowserExperimentalOptions = {
|
|
174
184
|
/**
|
|
175
185
|
* Enables iframe timeout telemetry experiment for silent iframe bridge monitoring.
|
|
@@ -315,6 +325,7 @@ export function buildConfiguration(
|
|
|
315
325
|
userInputSystem?.nativeBrokerHandshakeTimeout ||
|
|
316
326
|
DEFAULT_NATIVE_BROKER_HANDSHAKE_TIMEOUT_MS,
|
|
317
327
|
protocolMode: ProtocolMode.AAD,
|
|
328
|
+
serverTelemetryEnabled: false,
|
|
318
329
|
};
|
|
319
330
|
|
|
320
331
|
const providedSystemOptions: Required<BrowserSystemOptions> = {
|
|
@@ -341,7 +352,11 @@ export function buildConfiguration(
|
|
|
341
352
|
userInputSystem?.protocolMode !== ProtocolMode.OIDC &&
|
|
342
353
|
userInputAuth?.OIDCOptions
|
|
343
354
|
) {
|
|
344
|
-
const logger = new Logger(
|
|
355
|
+
const logger = new Logger(
|
|
356
|
+
providedSystemOptions.loggerOptions,
|
|
357
|
+
name,
|
|
358
|
+
version
|
|
359
|
+
);
|
|
345
360
|
logger.warning(
|
|
346
361
|
JSON.stringify(
|
|
347
362
|
createClientConfigurationError(
|
|
@@ -657,6 +657,12 @@ export class StandardController implements IController {
|
|
|
657
657
|
const correlationId = this.getRequestCorrelationId(request);
|
|
658
658
|
this.logger.verbose("acquireTokenRedirect called", correlationId);
|
|
659
659
|
|
|
660
|
+
BrowserUtils.redirectPreflightCheck(this.initialized, this.config);
|
|
661
|
+
this.browserStorage.setInteractionInProgress(
|
|
662
|
+
true,
|
|
663
|
+
INTERACTION_TYPE.SIGNIN
|
|
664
|
+
);
|
|
665
|
+
|
|
660
666
|
const atrMeasurement = this.performanceClient.startMeasurement(
|
|
661
667
|
BrowserRootPerformanceEvents.AcquireTokenPreRedirect,
|
|
662
668
|
correlationId
|
|
@@ -684,13 +690,7 @@ export class StandardController implements IController {
|
|
|
684
690
|
};
|
|
685
691
|
|
|
686
692
|
try {
|
|
687
|
-
BrowserUtils.redirectPreflightCheck(this.initialized, this.config);
|
|
688
693
|
enforceResourceParameter(this.config.auth.isMcp, request);
|
|
689
|
-
this.browserStorage.setInteractionInProgress(
|
|
690
|
-
true,
|
|
691
|
-
INTERACTION_TYPE.SIGNIN
|
|
692
|
-
);
|
|
693
|
-
|
|
694
694
|
this.eventHandler.emitEvent(
|
|
695
695
|
EventType.ACQUIRE_TOKEN_START,
|
|
696
696
|
correlationId,
|
|
@@ -59,6 +59,7 @@ import { SignUpCodeRequiredState } from "../sign_up/auth_flow/state/SignUpCodeRe
|
|
|
59
59
|
import { SignUpPasswordRequiredState } from "../sign_up/auth_flow/state/SignUpPasswordRequiredState.js";
|
|
60
60
|
import { ResetPasswordCodeRequiredState } from "../reset_password/auth_flow/state/ResetPasswordCodeRequiredState.js";
|
|
61
61
|
import { StandardController } from "../../controllers/StandardController.js";
|
|
62
|
+
import { name } from "../../packageMetadata.js";
|
|
62
63
|
|
|
63
64
|
/*
|
|
64
65
|
* Controller for standard native auth operations.
|
|
@@ -95,10 +96,7 @@ export class CustomAuthStandardController
|
|
|
95
96
|
throw new UnsupportedEnvironmentError();
|
|
96
97
|
}
|
|
97
98
|
|
|
98
|
-
this.logger = this.logger.clone(
|
|
99
|
-
DefaultPackageInfo.SKU,
|
|
100
|
-
DefaultPackageInfo.VERSION
|
|
101
|
-
);
|
|
99
|
+
this.logger = this.logger.clone(name, DefaultPackageInfo.VERSION);
|
|
102
100
|
this.customAuthConfig = operatingContext.getCustomAuthConfig();
|
|
103
101
|
|
|
104
102
|
this.authority = new CustomAuthAuthority(
|
|
@@ -13,6 +13,7 @@ import {
|
|
|
13
13
|
} from "./EventMessage.js";
|
|
14
14
|
import { EventType } from "./EventType.js";
|
|
15
15
|
import { createGuid } from "../utils/BrowserUtils.js";
|
|
16
|
+
import { version, name } from "../packageMetadata.js";
|
|
16
17
|
|
|
17
18
|
const BROADCAST_CHANNEL_NAME = "msal.broadcast.event";
|
|
18
19
|
|
|
@@ -27,7 +28,7 @@ export class EventHandler {
|
|
|
27
28
|
|
|
28
29
|
constructor(logger?: Logger) {
|
|
29
30
|
this.eventCallbacks = new Map();
|
|
30
|
-
this.logger = logger || new Logger({});
|
|
31
|
+
this.logger = logger || new Logger({}, name, version);
|
|
31
32
|
if (typeof BroadcastChannel !== "undefined") {
|
|
32
33
|
this.broadcastChannel = new BroadcastChannel(
|
|
33
34
|
BROADCAST_CHANNEL_NAME
|
|
@@ -10,6 +10,7 @@ import {
|
|
|
10
10
|
AccountInfo,
|
|
11
11
|
UrlString,
|
|
12
12
|
ServerTelemetryManager,
|
|
13
|
+
StubServerTelemetryManager,
|
|
13
14
|
ServerTelemetryRequest,
|
|
14
15
|
createClientConfigurationError,
|
|
15
16
|
ClientConfigurationErrorCodes,
|
|
@@ -29,8 +30,7 @@ import { EndSessionRequest } from "../request/EndSessionRequest.js";
|
|
|
29
30
|
import { RedirectRequest } from "../request/RedirectRequest.js";
|
|
30
31
|
import { PopupRequest } from "../request/PopupRequest.js";
|
|
31
32
|
import { SsoSilentRequest } from "../request/SsoSilentRequest.js";
|
|
32
|
-
import { version } from "../packageMetadata.js";
|
|
33
|
-
import { BrowserConstants } from "../utils/BrowserConstants.js";
|
|
33
|
+
import { version, name } from "../packageMetadata.js";
|
|
34
34
|
import * as BrowserUtils from "../utils/BrowserUtils.js";
|
|
35
35
|
import { INavigationClient } from "../navigation/INavigationClient.js";
|
|
36
36
|
import { AuthenticationResult } from "../response/AuthenticationResult.js";
|
|
@@ -68,7 +68,7 @@ export abstract class BaseInteractionClient {
|
|
|
68
68
|
this.navigationClient = navigationClient;
|
|
69
69
|
this.platformAuthProvider = platformAuthProvider;
|
|
70
70
|
this.correlationId = correlationId;
|
|
71
|
-
this.logger = logger.clone(
|
|
71
|
+
this.logger = logger.clone(name, version);
|
|
72
72
|
this.performanceClient = performanceClient;
|
|
73
73
|
}
|
|
74
74
|
|
|
@@ -108,6 +108,7 @@ export function getRedirectUri(
|
|
|
108
108
|
* @param browserStorage - Browser cache manager instance for storing telemetry data
|
|
109
109
|
* @param logger - Optional logger instance for verbose logging
|
|
110
110
|
* @param forceRefresh - Optional flag to force refresh of telemetry data
|
|
111
|
+
* @param enabled - Optional flag to enable or disable server telemetry (default: true for custom_auth flows, false for standard flows)
|
|
111
112
|
* @returns Configured ServerTelemetryManager instance
|
|
112
113
|
*/
|
|
113
114
|
export function initializeServerTelemetryManager(
|
|
@@ -116,9 +117,18 @@ export function initializeServerTelemetryManager(
|
|
|
116
117
|
correlationId: string,
|
|
117
118
|
browserStorage: BrowserCacheManager,
|
|
118
119
|
logger: Logger,
|
|
119
|
-
forceRefresh?: boolean
|
|
120
|
+
forceRefresh?: boolean,
|
|
121
|
+
enabled: boolean = true
|
|
120
122
|
): ServerTelemetryManager {
|
|
121
123
|
logger.verbose("initializeServerTelemetryManager called", correlationId);
|
|
124
|
+
if (!enabled) {
|
|
125
|
+
logger.verbose(
|
|
126
|
+
"Server telemetry is disabled in configuration. Skipping telemetry manager initialization.",
|
|
127
|
+
correlationId
|
|
128
|
+
);
|
|
129
|
+
return new StubServerTelemetryManager();
|
|
130
|
+
}
|
|
131
|
+
|
|
122
132
|
const telemetryPayload: ServerTelemetryRequest = {
|
|
123
133
|
clientId: clientId,
|
|
124
134
|
correlationId: correlationId,
|
|
@@ -177,7 +177,9 @@ export class PlatformAuthInteractionClient extends BaseInteractionClient {
|
|
|
177
177
|
this.config.auth.clientId,
|
|
178
178
|
this.correlationId,
|
|
179
179
|
this.browserStorage,
|
|
180
|
-
this.logger
|
|
180
|
+
this.logger,
|
|
181
|
+
undefined,
|
|
182
|
+
this.config.system.serverTelemetryEnabled
|
|
181
183
|
);
|
|
182
184
|
|
|
183
185
|
try {
|
|
@@ -369,7 +371,9 @@ export class PlatformAuthInteractionClient extends BaseInteractionClient {
|
|
|
369
371
|
this.config.auth.clientId,
|
|
370
372
|
this.correlationId,
|
|
371
373
|
this.browserStorage,
|
|
372
|
-
this.logger
|
|
374
|
+
this.logger,
|
|
375
|
+
undefined,
|
|
376
|
+
this.config.system.serverTelemetryEnabled
|
|
373
377
|
);
|
|
374
378
|
serverTelemetryManager.setNativeBrokerErrorCode(e.errorCode);
|
|
375
379
|
if (isFatalNativeAuthError(e)) {
|
|
@@ -472,7 +476,9 @@ export class PlatformAuthInteractionClient extends BaseInteractionClient {
|
|
|
472
476
|
this.config.auth.clientId,
|
|
473
477
|
this.correlationId,
|
|
474
478
|
this.browserStorage,
|
|
475
|
-
this.logger
|
|
479
|
+
this.logger,
|
|
480
|
+
undefined,
|
|
481
|
+
this.config.system.serverTelemetryEnabled
|
|
476
482
|
);
|
|
477
483
|
serverTelemetryManager.clearNativeBrokerErrorCode();
|
|
478
484
|
this.performanceClient?.addFields(
|
|
@@ -316,7 +316,9 @@ export class PopupClient extends StandardInteractionClient {
|
|
|
316
316
|
this.config.auth.clientId,
|
|
317
317
|
this.correlationId,
|
|
318
318
|
this.browserStorage,
|
|
319
|
-
this.logger
|
|
319
|
+
this.logger,
|
|
320
|
+
undefined,
|
|
321
|
+
this.config.system.serverTelemetryEnabled
|
|
320
322
|
);
|
|
321
323
|
|
|
322
324
|
const pkce =
|
|
@@ -543,7 +545,9 @@ export class PopupClient extends StandardInteractionClient {
|
|
|
543
545
|
this.config.auth.clientId,
|
|
544
546
|
correlationId,
|
|
545
547
|
this.browserStorage,
|
|
546
|
-
this.logger
|
|
548
|
+
this.logger,
|
|
549
|
+
undefined,
|
|
550
|
+
this.config.system.serverTelemetryEnabled
|
|
547
551
|
),
|
|
548
552
|
requestAuthority: request.authority,
|
|
549
553
|
requestAzureCloudOptions: request.azureCloudOptions,
|
|
@@ -703,7 +707,9 @@ export class PopupClient extends StandardInteractionClient {
|
|
|
703
707
|
this.config.auth.clientId,
|
|
704
708
|
this.correlationId,
|
|
705
709
|
this.browserStorage,
|
|
706
|
-
this.logger
|
|
710
|
+
this.logger,
|
|
711
|
+
undefined,
|
|
712
|
+
this.config.system.serverTelemetryEnabled
|
|
707
713
|
);
|
|
708
714
|
|
|
709
715
|
try {
|
|
@@ -197,7 +197,9 @@ export class RedirectClient extends StandardInteractionClient {
|
|
|
197
197
|
this.config.auth.clientId,
|
|
198
198
|
this.correlationId,
|
|
199
199
|
this.browserStorage,
|
|
200
|
-
this.logger
|
|
200
|
+
this.logger,
|
|
201
|
+
undefined,
|
|
202
|
+
this.config.system.serverTelemetryEnabled
|
|
201
203
|
);
|
|
202
204
|
|
|
203
205
|
const pkceCodes = await invokeAsync(
|
|
@@ -417,7 +419,9 @@ export class RedirectClient extends StandardInteractionClient {
|
|
|
417
419
|
this.config.auth.clientId,
|
|
418
420
|
this.correlationId,
|
|
419
421
|
this.browserStorage,
|
|
420
|
-
this.logger
|
|
422
|
+
this.logger,
|
|
423
|
+
undefined,
|
|
424
|
+
this.config.system.serverTelemetryEnabled
|
|
421
425
|
);
|
|
422
426
|
|
|
423
427
|
const navigateToLoginRequestUrl =
|
|
@@ -455,9 +459,15 @@ export class RedirectClient extends StandardInteractionClient {
|
|
|
455
459
|
true
|
|
456
460
|
) || "";
|
|
457
461
|
const loginRequestUrlNormalized =
|
|
458
|
-
UrlUtils.normalizeUrlForComparison(
|
|
462
|
+
UrlUtils.normalizeUrlForComparison(
|
|
463
|
+
loginRequestUrl,
|
|
464
|
+
this.logger,
|
|
465
|
+
this.correlationId
|
|
466
|
+
);
|
|
459
467
|
const currentUrlNormalized = UrlUtils.normalizeUrlForComparison(
|
|
460
|
-
window.location.href
|
|
468
|
+
window.location.href,
|
|
469
|
+
this.logger,
|
|
470
|
+
this.correlationId
|
|
461
471
|
);
|
|
462
472
|
|
|
463
473
|
if (
|
|
@@ -518,8 +528,8 @@ export class RedirectClient extends StandardInteractionClient {
|
|
|
518
528
|
* The start page is expected to also call handleRedirectPromise which will process the hash in one of the checks above.
|
|
519
529
|
*/
|
|
520
530
|
let processHashOnRedirect: boolean = true;
|
|
521
|
-
if (!loginRequestUrl
|
|
522
|
-
// Redirect to home page if login request url is
|
|
531
|
+
if (!loginRequestUrl) {
|
|
532
|
+
// Redirect to home page if login request url is empty
|
|
523
533
|
const homepage = BrowserUtils.getHomepage();
|
|
524
534
|
// Cache the homepage under ORIGIN_URI to ensure cached hash is processed on homepage
|
|
525
535
|
this.browserStorage.setTemporaryCache(
|
|
@@ -820,7 +830,9 @@ export class RedirectClient extends StandardInteractionClient {
|
|
|
820
830
|
this.config.auth.clientId,
|
|
821
831
|
this.correlationId,
|
|
822
832
|
this.browserStorage,
|
|
823
|
-
this.logger
|
|
833
|
+
this.logger,
|
|
834
|
+
undefined,
|
|
835
|
+
this.config.system.serverTelemetryEnabled
|
|
824
836
|
);
|
|
825
837
|
|
|
826
838
|
try {
|
|
@@ -974,9 +986,16 @@ export class RedirectClient extends StandardInteractionClient {
|
|
|
974
986
|
*/
|
|
975
987
|
protected getRedirectStartPage(requestStartPage?: string): string {
|
|
976
988
|
const redirectStartPage = requestStartPage || window.location.href;
|
|
977
|
-
|
|
989
|
+
const absoluteRedirectStartPage = UrlString.getAbsoluteUrl(
|
|
978
990
|
redirectStartPage,
|
|
979
991
|
BrowserUtils.getCurrentUri()
|
|
980
992
|
);
|
|
993
|
+
// Sanity check the URL before it is cached so we never persist a malformed value (e.g. the literal string "null")
|
|
994
|
+
UrlUtils.validateUrl(
|
|
995
|
+
absoluteRedirectStartPage,
|
|
996
|
+
this.logger,
|
|
997
|
+
this.correlationId
|
|
998
|
+
);
|
|
999
|
+
return absoluteRedirectStartPage;
|
|
981
1000
|
}
|
|
982
1001
|
}
|
|
@@ -104,7 +104,9 @@ export class SilentAuthCodeClient extends StandardInteractionClient {
|
|
|
104
104
|
this.config.auth.clientId,
|
|
105
105
|
this.correlationId,
|
|
106
106
|
this.browserStorage,
|
|
107
|
-
this.logger
|
|
107
|
+
this.logger,
|
|
108
|
+
undefined,
|
|
109
|
+
this.config.system.serverTelemetryEnabled
|
|
108
110
|
);
|
|
109
111
|
|
|
110
112
|
try {
|
|
@@ -36,7 +36,9 @@ export class SilentCacheClient extends StandardInteractionClient {
|
|
|
36
36
|
this.config.auth.clientId,
|
|
37
37
|
this.correlationId,
|
|
38
38
|
this.browserStorage,
|
|
39
|
-
this.logger
|
|
39
|
+
this.logger,
|
|
40
|
+
undefined,
|
|
41
|
+
this.config.system.serverTelemetryEnabled
|
|
40
42
|
);
|
|
41
43
|
|
|
42
44
|
const clientConfig = await invokeAsync(
|
|
@@ -37,6 +37,7 @@ import {
|
|
|
37
37
|
BrowserConstants,
|
|
38
38
|
} from "../utils/BrowserConstants.js";
|
|
39
39
|
import {
|
|
40
|
+
createHiddenIframe,
|
|
40
41
|
initiateCodeRequest,
|
|
41
42
|
initiateCodeFlowWithPost,
|
|
42
43
|
initiateEarRequest,
|
|
@@ -199,7 +200,9 @@ export class SilentIframeClient extends StandardInteractionClient {
|
|
|
199
200
|
this.config.auth.clientId,
|
|
200
201
|
this.correlationId,
|
|
201
202
|
this.browserStorage,
|
|
202
|
-
this.logger
|
|
203
|
+
this.logger,
|
|
204
|
+
undefined,
|
|
205
|
+
this.config.system.serverTelemetryEnabled
|
|
203
206
|
);
|
|
204
207
|
|
|
205
208
|
try {
|
|
@@ -307,30 +310,45 @@ export class SilentIframeClient extends StandardInteractionClient {
|
|
|
307
310
|
earJwk: earJwk,
|
|
308
311
|
codeChallenge: pkceCodes.challenge,
|
|
309
312
|
};
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
this.logger,
|
|
314
|
-
this.performanceClient,
|
|
315
|
-
correlationId
|
|
316
|
-
)(
|
|
317
|
-
this.config,
|
|
318
|
-
discoveredAuthority,
|
|
319
|
-
silentRequest,
|
|
320
|
-
this.logger,
|
|
321
|
-
this.performanceClient
|
|
322
|
-
);
|
|
313
|
+
|
|
314
|
+
// Create the iframe, register the response listener, then navigate, so the listener is active before the iframe can respond.
|
|
315
|
+
const iframe = createHiddenIframe();
|
|
323
316
|
|
|
324
317
|
const responseType = this.config.auth.OIDCOptions.responseMode;
|
|
325
318
|
let responseString: string;
|
|
326
319
|
try {
|
|
327
|
-
|
|
320
|
+
const responsePromise = invokeAsync(
|
|
328
321
|
this.waitForIframeResponse.bind(this),
|
|
329
322
|
BrowserPerformanceEvents.SilentHandlerMonitorIframeForHash,
|
|
330
323
|
this.logger,
|
|
331
324
|
this.performanceClient,
|
|
332
325
|
correlationId
|
|
333
326
|
)(iframe, request);
|
|
327
|
+
responsePromise.catch(() => {
|
|
328
|
+
/*
|
|
329
|
+
* If navigation below throws before responsePromise is awaited,
|
|
330
|
+
* the listener still rejects on timeout. Swallow it here so it
|
|
331
|
+
* does not surface as an unhandled rejection; the navigation
|
|
332
|
+
* error is propagated instead.
|
|
333
|
+
*/
|
|
334
|
+
});
|
|
335
|
+
|
|
336
|
+
await invokeAsync(
|
|
337
|
+
initiateEarRequest,
|
|
338
|
+
BrowserPerformanceEvents.SilentHandlerInitiateAuthRequest,
|
|
339
|
+
this.logger,
|
|
340
|
+
this.performanceClient,
|
|
341
|
+
correlationId
|
|
342
|
+
)(
|
|
343
|
+
iframe,
|
|
344
|
+
this.config,
|
|
345
|
+
discoveredAuthority,
|
|
346
|
+
silentRequest,
|
|
347
|
+
this.logger,
|
|
348
|
+
this.performanceClient
|
|
349
|
+
);
|
|
350
|
+
|
|
351
|
+
responseString = await responsePromise;
|
|
334
352
|
} finally {
|
|
335
353
|
invoke(
|
|
336
354
|
removeHiddenIframe,
|
|
@@ -363,7 +381,9 @@ export class SilentIframeClient extends StandardInteractionClient {
|
|
|
363
381
|
this.config.auth.clientId,
|
|
364
382
|
correlationId,
|
|
365
383
|
this.browserStorage,
|
|
366
|
-
this.logger
|
|
384
|
+
this.logger,
|
|
385
|
+
undefined,
|
|
386
|
+
this.config.system.serverTelemetryEnabled
|
|
367
387
|
),
|
|
368
388
|
requestAuthority: request.authority,
|
|
369
389
|
requestAzureCloudOptions: request.azureCloudOptions,
|
|
@@ -457,7 +477,9 @@ export class SilentIframeClient extends StandardInteractionClient {
|
|
|
457
477
|
this.config.auth.clientId,
|
|
458
478
|
this.correlationId,
|
|
459
479
|
this.browserStorage,
|
|
460
|
-
this.logger
|
|
480
|
+
this.logger,
|
|
481
|
+
undefined,
|
|
482
|
+
this.config.system.serverTelemetryEnabled
|
|
461
483
|
),
|
|
462
484
|
requestAuthority: silentRequest.authority,
|
|
463
485
|
requestAzureCloudOptions: silentRequest.azureCloudOptions,
|
|
@@ -571,58 +593,72 @@ export class SilentIframeClient extends StandardInteractionClient {
|
|
|
571
593
|
codeChallenge: pkceCodes.challenge,
|
|
572
594
|
};
|
|
573
595
|
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
iframe = await invokeAsync(
|
|
577
|
-
initiateCodeFlowWithPost,
|
|
578
|
-
BrowserPerformanceEvents.SilentHandlerInitiateAuthRequest,
|
|
579
|
-
this.logger,
|
|
580
|
-
this.performanceClient,
|
|
581
|
-
correlationId
|
|
582
|
-
)(
|
|
583
|
-
this.config,
|
|
584
|
-
authClient.authority,
|
|
585
|
-
silentRequest,
|
|
586
|
-
this.logger,
|
|
587
|
-
this.performanceClient
|
|
588
|
-
);
|
|
589
|
-
} else {
|
|
590
|
-
// Create authorize request url
|
|
591
|
-
const navigateUrl = await invokeAsync(
|
|
592
|
-
Authorize.getAuthCodeRequestUrl,
|
|
593
|
-
PerformanceEvents.GetAuthCodeUrl,
|
|
594
|
-
this.logger,
|
|
595
|
-
this.performanceClient,
|
|
596
|
-
correlationId
|
|
597
|
-
)(
|
|
598
|
-
this.config,
|
|
599
|
-
authClient.authority,
|
|
600
|
-
silentRequest,
|
|
601
|
-
this.logger,
|
|
602
|
-
this.performanceClient
|
|
603
|
-
);
|
|
604
|
-
|
|
605
|
-
// Get the frame handle for the silent request
|
|
606
|
-
iframe = await invokeAsync(
|
|
607
|
-
initiateCodeRequest,
|
|
608
|
-
BrowserPerformanceEvents.SilentHandlerInitiateAuthRequest,
|
|
609
|
-
this.logger,
|
|
610
|
-
this.performanceClient,
|
|
611
|
-
correlationId
|
|
612
|
-
)(navigateUrl, this.performanceClient, this.logger, correlationId);
|
|
613
|
-
}
|
|
596
|
+
// Create the iframe, register the response listener, then navigate, so the listener is active before the iframe can respond.
|
|
597
|
+
const iframe = createHiddenIframe();
|
|
614
598
|
|
|
615
599
|
const responseType = this.config.auth.OIDCOptions.responseMode;
|
|
616
600
|
// Wait for response from the redirect bridge.
|
|
617
601
|
let responseString: string;
|
|
618
602
|
try {
|
|
619
|
-
|
|
603
|
+
const responsePromise = invokeAsync(
|
|
620
604
|
this.waitForIframeResponse.bind(this),
|
|
621
605
|
BrowserPerformanceEvents.SilentHandlerMonitorIframeForHash,
|
|
622
606
|
this.logger,
|
|
623
607
|
this.performanceClient,
|
|
624
608
|
correlationId
|
|
625
609
|
)(iframe, request);
|
|
610
|
+
responsePromise.catch(() => {
|
|
611
|
+
/*
|
|
612
|
+
* If URL creation or navigation below throws before
|
|
613
|
+
* responsePromise is awaited, the listener still rejects on
|
|
614
|
+
* timeout. Swallow it here so it does not surface as an
|
|
615
|
+
* unhandled rejection; the navigation error is propagated
|
|
616
|
+
* instead.
|
|
617
|
+
*/
|
|
618
|
+
});
|
|
619
|
+
|
|
620
|
+
if (request.httpMethod === Constants.HttpMethod.POST) {
|
|
621
|
+
await invokeAsync(
|
|
622
|
+
initiateCodeFlowWithPost,
|
|
623
|
+
BrowserPerformanceEvents.SilentHandlerInitiateAuthRequest,
|
|
624
|
+
this.logger,
|
|
625
|
+
this.performanceClient,
|
|
626
|
+
correlationId
|
|
627
|
+
)(
|
|
628
|
+
iframe,
|
|
629
|
+
this.config,
|
|
630
|
+
authClient.authority,
|
|
631
|
+
silentRequest,
|
|
632
|
+
this.logger,
|
|
633
|
+
this.performanceClient
|
|
634
|
+
);
|
|
635
|
+
} else {
|
|
636
|
+
// Create authorize request url
|
|
637
|
+
const navigateUrl = await invokeAsync(
|
|
638
|
+
Authorize.getAuthCodeRequestUrl,
|
|
639
|
+
PerformanceEvents.GetAuthCodeUrl,
|
|
640
|
+
this.logger,
|
|
641
|
+
this.performanceClient,
|
|
642
|
+
correlationId
|
|
643
|
+
)(
|
|
644
|
+
this.config,
|
|
645
|
+
authClient.authority,
|
|
646
|
+
silentRequest,
|
|
647
|
+
this.logger,
|
|
648
|
+
this.performanceClient
|
|
649
|
+
);
|
|
650
|
+
|
|
651
|
+
// Navigate the iframe to the authorize request url
|
|
652
|
+
await invokeAsync(
|
|
653
|
+
initiateCodeRequest,
|
|
654
|
+
BrowserPerformanceEvents.SilentHandlerInitiateAuthRequest,
|
|
655
|
+
this.logger,
|
|
656
|
+
this.performanceClient,
|
|
657
|
+
correlationId
|
|
658
|
+
)(iframe, navigateUrl, this.logger, correlationId);
|
|
659
|
+
}
|
|
660
|
+
|
|
661
|
+
responseString = await responsePromise;
|
|
626
662
|
} finally {
|
|
627
663
|
invoke(
|
|
628
664
|
removeHiddenIframe,
|
|
@@ -68,7 +68,9 @@ export class SilentRefreshClient extends StandardInteractionClient {
|
|
|
68
68
|
this.config.auth.clientId,
|
|
69
69
|
this.correlationId,
|
|
70
70
|
this.browserStorage,
|
|
71
|
-
this.logger
|
|
71
|
+
this.logger,
|
|
72
|
+
undefined,
|
|
73
|
+
this.config.system.serverTelemetryEnabled
|
|
72
74
|
);
|
|
73
75
|
|
|
74
76
|
const refreshTokenClient = await this.createRefreshTokenClient({
|