@azure/msal-browser 5.14.0 → 5.15.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.
Files changed (448) hide show
  1. package/dist/app/IPublicClientApplication.mjs +16 -16
  2. package/dist/app/IPublicClientApplication.mjs.map +1 -1
  3. package/dist/app/PublicClientApplication.mjs +1 -1
  4. package/dist/app/PublicClientApplication.mjs.map +1 -1
  5. package/dist/broker/nativeBroker/NativeStatusCodes.mjs +1 -1
  6. package/dist/broker/nativeBroker/PlatformAuthDOMHandler.mjs +3 -3
  7. package/dist/broker/nativeBroker/PlatformAuthDOMHandler.mjs.map +1 -1
  8. package/dist/broker/nativeBroker/PlatformAuthExtensionHandler.mjs +7 -7
  9. package/dist/broker/nativeBroker/PlatformAuthExtensionHandler.mjs.map +1 -1
  10. package/dist/broker/nativeBroker/PlatformAuthProvider.mjs +2 -2
  11. package/dist/broker/nativeBroker/PlatformAuthProvider.mjs.map +1 -1
  12. package/dist/cache/AccountManager.mjs +1 -1
  13. package/dist/cache/AccountManager.mjs.map +1 -1
  14. package/dist/cache/AsyncMemoryStorage.mjs +1 -1
  15. package/dist/cache/AsyncMemoryStorage.mjs.map +1 -1
  16. package/dist/cache/BrowserCacheManager.mjs +10 -10
  17. package/dist/cache/BrowserCacheManager.mjs.map +1 -1
  18. package/dist/cache/CacheHelpers.mjs +1 -1
  19. package/dist/cache/CacheHelpers.mjs.map +1 -1
  20. package/dist/cache/CacheKeys.mjs +1 -1
  21. package/dist/cache/CacheKeys.mjs.map +1 -1
  22. package/dist/cache/CookieStorage.mjs +4 -4
  23. package/dist/cache/CookieStorage.mjs.map +1 -1
  24. package/dist/cache/DatabaseStorage.mjs +7 -7
  25. package/dist/cache/DatabaseStorage.mjs.map +1 -1
  26. package/dist/cache/EncryptedData.mjs +1 -1
  27. package/dist/cache/LocalStorage.mjs +5 -5
  28. package/dist/cache/LocalStorage.mjs.map +1 -1
  29. package/dist/cache/MemoryStorage.mjs +1 -1
  30. package/dist/cache/MemoryStorage.mjs.map +1 -1
  31. package/dist/cache/SessionStorage.mjs +2 -2
  32. package/dist/cache/SessionStorage.mjs.map +1 -1
  33. package/dist/cache/TokenCache.mjs +7 -7
  34. package/dist/cache/TokenCache.mjs.map +1 -1
  35. package/dist/config/Configuration.mjs +3 -3
  36. package/dist/config/Configuration.mjs.map +1 -1
  37. package/dist/controllers/NestedAppAuthController.mjs +14 -15
  38. package/dist/controllers/NestedAppAuthController.mjs.map +1 -1
  39. package/dist/controllers/StandardController.mjs +12 -12
  40. package/dist/controllers/StandardController.mjs.map +1 -1
  41. package/dist/crypto/BrowserCrypto.mjs +7 -7
  42. package/dist/crypto/BrowserCrypto.mjs.map +1 -1
  43. package/dist/crypto/CryptoOps.mjs +3 -3
  44. package/dist/crypto/CryptoOps.mjs.map +1 -1
  45. package/dist/crypto/PkceGenerator.mjs +3 -3
  46. package/dist/crypto/PkceGenerator.mjs.map +1 -1
  47. package/dist/crypto/SignedHttpRequest.mjs +1 -1
  48. package/dist/crypto/SignedHttpRequest.mjs.map +1 -1
  49. package/dist/custom_auth/CustomAuthConstants.mjs +1 -1
  50. package/dist/custom_auth/CustomAuthConstants.mjs.map +1 -1
  51. package/dist/custom_auth/CustomAuthPublicClientApplication.mjs +1 -1
  52. package/dist/custom_auth/CustomAuthPublicClientApplication.mjs.map +1 -1
  53. package/dist/custom_auth/controller/CustomAuthStandardController.mjs +1 -1
  54. package/dist/custom_auth/controller/CustomAuthStandardController.mjs.map +1 -1
  55. package/dist/custom_auth/core/CustomAuthAuthority.mjs +2 -2
  56. package/dist/custom_auth/core/CustomAuthAuthority.mjs.map +1 -1
  57. package/dist/custom_auth/core/auth_flow/AuthFlowErrorBase.mjs +1 -1
  58. package/dist/custom_auth/core/auth_flow/AuthFlowErrorBase.mjs.map +1 -1
  59. package/dist/custom_auth/core/auth_flow/AuthFlowResultBase.mjs +1 -1
  60. package/dist/custom_auth/core/auth_flow/AuthFlowResultBase.mjs.map +1 -1
  61. package/dist/custom_auth/core/auth_flow/AuthFlowState.mjs +1 -1
  62. package/dist/custom_auth/core/auth_flow/AuthFlowState.mjs.map +1 -1
  63. package/dist/custom_auth/core/auth_flow/AuthFlowStateTypes.mjs +1 -1
  64. package/dist/custom_auth/core/auth_flow/jit/error_type/AuthMethodRegistrationError.mjs +1 -1
  65. package/dist/custom_auth/core/auth_flow/jit/error_type/AuthMethodRegistrationError.mjs.map +1 -1
  66. package/dist/custom_auth/core/auth_flow/jit/result/AuthMethodRegistrationChallengeMethodResult.mjs +1 -1
  67. package/dist/custom_auth/core/auth_flow/jit/result/AuthMethodRegistrationChallengeMethodResult.mjs.map +1 -1
  68. package/dist/custom_auth/core/auth_flow/jit/result/AuthMethodRegistrationSubmitChallengeResult.mjs +1 -1
  69. package/dist/custom_auth/core/auth_flow/jit/result/AuthMethodRegistrationSubmitChallengeResult.mjs.map +1 -1
  70. package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationCompletedState.mjs +1 -1
  71. package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationCompletedState.mjs.map +1 -1
  72. package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationFailedState.mjs +1 -1
  73. package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationFailedState.mjs.map +1 -1
  74. package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationState.mjs +1 -1
  75. package/dist/custom_auth/core/auth_flow/jit/state/AuthMethodRegistrationState.mjs.map +1 -1
  76. package/dist/custom_auth/core/auth_flow/mfa/error_type/MfaError.mjs +1 -1
  77. package/dist/custom_auth/core/auth_flow/mfa/error_type/MfaError.mjs.map +1 -1
  78. package/dist/custom_auth/core/auth_flow/mfa/result/MfaRequestChallengeResult.mjs +1 -1
  79. package/dist/custom_auth/core/auth_flow/mfa/result/MfaRequestChallengeResult.mjs.map +1 -1
  80. package/dist/custom_auth/core/auth_flow/mfa/result/MfaSubmitChallengeResult.mjs +1 -1
  81. package/dist/custom_auth/core/auth_flow/mfa/result/MfaSubmitChallengeResult.mjs.map +1 -1
  82. package/dist/custom_auth/core/auth_flow/mfa/state/MfaCompletedState.mjs +1 -1
  83. package/dist/custom_auth/core/auth_flow/mfa/state/MfaCompletedState.mjs.map +1 -1
  84. package/dist/custom_auth/core/auth_flow/mfa/state/MfaFailedState.mjs +1 -1
  85. package/dist/custom_auth/core/auth_flow/mfa/state/MfaFailedState.mjs.map +1 -1
  86. package/dist/custom_auth/core/auth_flow/mfa/state/MfaState.mjs +1 -1
  87. package/dist/custom_auth/core/auth_flow/mfa/state/MfaState.mjs.map +1 -1
  88. package/dist/custom_auth/core/error/CustomAuthApiError.mjs +1 -1
  89. package/dist/custom_auth/core/error/CustomAuthApiError.mjs.map +1 -1
  90. package/dist/custom_auth/core/error/CustomAuthError.mjs +1 -1
  91. package/dist/custom_auth/core/error/CustomAuthError.mjs.map +1 -1
  92. package/dist/custom_auth/core/error/HttpError.mjs +1 -1
  93. package/dist/custom_auth/core/error/HttpError.mjs.map +1 -1
  94. package/dist/custom_auth/core/error/HttpErrorCodes.mjs +1 -1
  95. package/dist/custom_auth/core/error/InvalidArgumentError.mjs +1 -1
  96. package/dist/custom_auth/core/error/InvalidArgumentError.mjs.map +1 -1
  97. package/dist/custom_auth/core/error/InvalidConfigurationError.mjs +1 -1
  98. package/dist/custom_auth/core/error/InvalidConfigurationError.mjs.map +1 -1
  99. package/dist/custom_auth/core/error/InvalidConfigurationErrorCodes.mjs +1 -1
  100. package/dist/custom_auth/core/error/MethodNotImplementedError.mjs +1 -1
  101. package/dist/custom_auth/core/error/MethodNotImplementedError.mjs.map +1 -1
  102. package/dist/custom_auth/core/error/MsalCustomAuthError.mjs +1 -1
  103. package/dist/custom_auth/core/error/MsalCustomAuthError.mjs.map +1 -1
  104. package/dist/custom_auth/core/error/NoCachedAccountFoundError.mjs +1 -1
  105. package/dist/custom_auth/core/error/NoCachedAccountFoundError.mjs.map +1 -1
  106. package/dist/custom_auth/core/error/ParsedUrlError.mjs +1 -1
  107. package/dist/custom_auth/core/error/ParsedUrlError.mjs.map +1 -1
  108. package/dist/custom_auth/core/error/ParsedUrlErrorCodes.mjs +1 -1
  109. package/dist/custom_auth/core/error/UnexpectedError.mjs +1 -1
  110. package/dist/custom_auth/core/error/UnexpectedError.mjs.map +1 -1
  111. package/dist/custom_auth/core/error/UnsupportedEnvironmentError.mjs +1 -1
  112. package/dist/custom_auth/core/error/UnsupportedEnvironmentError.mjs.map +1 -1
  113. package/dist/custom_auth/core/error/UserAccountAttributeError.mjs +1 -1
  114. package/dist/custom_auth/core/error/UserAccountAttributeError.mjs.map +1 -1
  115. package/dist/custom_auth/core/error/UserAlreadySignedInError.mjs +1 -1
  116. package/dist/custom_auth/core/error/UserAlreadySignedInError.mjs.map +1 -1
  117. package/dist/custom_auth/core/interaction_client/CustomAuthInteractionClientBase.mjs +1 -1
  118. package/dist/custom_auth/core/interaction_client/CustomAuthInteractionClientBase.mjs.map +1 -1
  119. package/dist/custom_auth/core/interaction_client/CustomAuthInterationClientFactory.mjs +1 -1
  120. package/dist/custom_auth/core/interaction_client/CustomAuthInterationClientFactory.mjs.map +1 -1
  121. package/dist/custom_auth/core/interaction_client/jit/JitClient.mjs +1 -1
  122. package/dist/custom_auth/core/interaction_client/jit/JitClient.mjs.map +1 -1
  123. package/dist/custom_auth/core/interaction_client/jit/result/JitActionResult.mjs +1 -1
  124. package/dist/custom_auth/core/interaction_client/mfa/MfaClient.mjs +1 -1
  125. package/dist/custom_auth/core/interaction_client/mfa/MfaClient.mjs.map +1 -1
  126. package/dist/custom_auth/core/interaction_client/mfa/result/MfaActionResult.mjs +1 -1
  127. package/dist/custom_auth/core/network_client/custom_auth_api/BaseApiClient.mjs +1 -1
  128. package/dist/custom_auth/core/network_client/custom_auth_api/BaseApiClient.mjs.map +1 -1
  129. package/dist/custom_auth/core/network_client/custom_auth_api/CustomAuthApiClient.mjs +1 -1
  130. package/dist/custom_auth/core/network_client/custom_auth_api/CustomAuthApiClient.mjs.map +1 -1
  131. package/dist/custom_auth/core/network_client/custom_auth_api/CustomAuthApiEndpoint.mjs +1 -1
  132. package/dist/custom_auth/core/network_client/custom_auth_api/RegisterApiClient.mjs +1 -1
  133. package/dist/custom_auth/core/network_client/custom_auth_api/RegisterApiClient.mjs.map +1 -1
  134. package/dist/custom_auth/core/network_client/custom_auth_api/ResetPasswordApiClient.mjs +1 -1
  135. package/dist/custom_auth/core/network_client/custom_auth_api/ResetPasswordApiClient.mjs.map +1 -1
  136. package/dist/custom_auth/core/network_client/custom_auth_api/SignInApiClient.mjs +1 -1
  137. package/dist/custom_auth/core/network_client/custom_auth_api/SignInApiClient.mjs.map +1 -1
  138. package/dist/custom_auth/core/network_client/custom_auth_api/SignupApiClient.mjs +1 -1
  139. package/dist/custom_auth/core/network_client/custom_auth_api/SignupApiClient.mjs.map +1 -1
  140. package/dist/custom_auth/core/network_client/custom_auth_api/types/ApiErrorCodes.mjs +1 -1
  141. package/dist/custom_auth/core/network_client/custom_auth_api/types/ApiSuberrors.mjs +1 -1
  142. package/dist/custom_auth/core/network_client/http_client/FetchHttpClient.mjs +1 -1
  143. package/dist/custom_auth/core/network_client/http_client/FetchHttpClient.mjs.map +1 -1
  144. package/dist/custom_auth/core/network_client/http_client/IHttpClient.mjs +1 -1
  145. package/dist/custom_auth/core/network_client/http_client/IHttpClient.mjs.map +1 -1
  146. package/dist/custom_auth/core/telemetry/PublicApiId.mjs +1 -1
  147. package/dist/custom_auth/core/utils/ArgumentValidator.mjs +1 -1
  148. package/dist/custom_auth/core/utils/ArgumentValidator.mjs.map +1 -1
  149. package/dist/custom_auth/core/utils/CustomHeaderUtils.mjs +1 -1
  150. package/dist/custom_auth/core/utils/CustomHeaderUtils.mjs.map +1 -1
  151. package/dist/custom_auth/core/utils/UrlUtils.mjs +1 -1
  152. package/dist/custom_auth/core/utils/UrlUtils.mjs.map +1 -1
  153. package/dist/custom_auth/get_account/auth_flow/CustomAuthAccountData.mjs +1 -1
  154. package/dist/custom_auth/get_account/auth_flow/CustomAuthAccountData.mjs.map +1 -1
  155. package/dist/custom_auth/get_account/auth_flow/error_type/GetAccountError.mjs +1 -1
  156. package/dist/custom_auth/get_account/auth_flow/error_type/GetAccountError.mjs.map +1 -1
  157. package/dist/custom_auth/get_account/auth_flow/result/GetAccessTokenResult.mjs +1 -1
  158. package/dist/custom_auth/get_account/auth_flow/result/GetAccessTokenResult.mjs.map +1 -1
  159. package/dist/custom_auth/get_account/auth_flow/result/GetAccountResult.mjs +1 -1
  160. package/dist/custom_auth/get_account/auth_flow/result/GetAccountResult.mjs.map +1 -1
  161. package/dist/custom_auth/get_account/auth_flow/result/SignOutResult.mjs +1 -1
  162. package/dist/custom_auth/get_account/auth_flow/result/SignOutResult.mjs.map +1 -1
  163. package/dist/custom_auth/get_account/auth_flow/state/GetAccessTokenState.mjs +1 -1
  164. package/dist/custom_auth/get_account/auth_flow/state/GetAccessTokenState.mjs.map +1 -1
  165. package/dist/custom_auth/get_account/auth_flow/state/GetAccountState.mjs +1 -1
  166. package/dist/custom_auth/get_account/auth_flow/state/GetAccountState.mjs.map +1 -1
  167. package/dist/custom_auth/get_account/auth_flow/state/SignOutState.mjs +1 -1
  168. package/dist/custom_auth/get_account/auth_flow/state/SignOutState.mjs.map +1 -1
  169. package/dist/custom_auth/get_account/interaction_client/CustomAuthSilentCacheClient.mjs +2 -2
  170. package/dist/custom_auth/get_account/interaction_client/CustomAuthSilentCacheClient.mjs.map +1 -1
  171. package/dist/custom_auth/index.mjs +1 -1
  172. package/dist/custom_auth/operating_context/CustomAuthOperatingContext.mjs +1 -1
  173. package/dist/custom_auth/operating_context/CustomAuthOperatingContext.mjs.map +1 -1
  174. package/dist/custom_auth/reset_password/auth_flow/error_type/ResetPasswordError.mjs +1 -1
  175. package/dist/custom_auth/reset_password/auth_flow/error_type/ResetPasswordError.mjs.map +1 -1
  176. package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordResendCodeResult.mjs +1 -1
  177. package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordResendCodeResult.mjs.map +1 -1
  178. package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordStartResult.mjs +1 -1
  179. package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordStartResult.mjs.map +1 -1
  180. package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordSubmitCodeResult.mjs +1 -1
  181. package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordSubmitCodeResult.mjs.map +1 -1
  182. package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordSubmitPasswordResult.mjs +1 -1
  183. package/dist/custom_auth/reset_password/auth_flow/result/ResetPasswordSubmitPasswordResult.mjs.map +1 -1
  184. package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordCodeRequiredState.mjs +1 -1
  185. package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordCodeRequiredState.mjs.map +1 -1
  186. package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordCompletedState.mjs +1 -1
  187. package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordCompletedState.mjs.map +1 -1
  188. package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordFailedState.mjs +1 -1
  189. package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordFailedState.mjs.map +1 -1
  190. package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordPasswordRequiredState.mjs +1 -1
  191. package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordPasswordRequiredState.mjs.map +1 -1
  192. package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordState.mjs +1 -1
  193. package/dist/custom_auth/reset_password/auth_flow/state/ResetPasswordState.mjs.map +1 -1
  194. package/dist/custom_auth/reset_password/interaction_client/ResetPasswordClient.mjs +1 -1
  195. package/dist/custom_auth/reset_password/interaction_client/ResetPasswordClient.mjs.map +1 -1
  196. package/dist/custom_auth/sign_in/auth_flow/SignInScenario.mjs +1 -1
  197. package/dist/custom_auth/sign_in/auth_flow/SignInScenario.mjs.map +1 -1
  198. package/dist/custom_auth/sign_in/auth_flow/error_type/SignInError.mjs +1 -1
  199. package/dist/custom_auth/sign_in/auth_flow/error_type/SignInError.mjs.map +1 -1
  200. package/dist/custom_auth/sign_in/auth_flow/result/SignInResendCodeResult.mjs +1 -1
  201. package/dist/custom_auth/sign_in/auth_flow/result/SignInResendCodeResult.mjs.map +1 -1
  202. package/dist/custom_auth/sign_in/auth_flow/result/SignInResult.mjs +1 -1
  203. package/dist/custom_auth/sign_in/auth_flow/result/SignInResult.mjs.map +1 -1
  204. package/dist/custom_auth/sign_in/auth_flow/result/SignInSubmitCodeResult.mjs +1 -1
  205. package/dist/custom_auth/sign_in/auth_flow/result/SignInSubmitCodeResult.mjs.map +1 -1
  206. package/dist/custom_auth/sign_in/auth_flow/result/SignInSubmitPasswordResult.mjs +1 -1
  207. package/dist/custom_auth/sign_in/auth_flow/result/SignInSubmitPasswordResult.mjs.map +1 -1
  208. package/dist/custom_auth/sign_in/auth_flow/state/SignInCodeRequiredState.mjs +1 -1
  209. package/dist/custom_auth/sign_in/auth_flow/state/SignInCodeRequiredState.mjs.map +1 -1
  210. package/dist/custom_auth/sign_in/auth_flow/state/SignInCompletedState.mjs +1 -1
  211. package/dist/custom_auth/sign_in/auth_flow/state/SignInCompletedState.mjs.map +1 -1
  212. package/dist/custom_auth/sign_in/auth_flow/state/SignInContinuationState.mjs +1 -1
  213. package/dist/custom_auth/sign_in/auth_flow/state/SignInContinuationState.mjs.map +1 -1
  214. package/dist/custom_auth/sign_in/auth_flow/state/SignInFailedState.mjs +1 -1
  215. package/dist/custom_auth/sign_in/auth_flow/state/SignInFailedState.mjs.map +1 -1
  216. package/dist/custom_auth/sign_in/auth_flow/state/SignInPasswordRequiredState.mjs +1 -1
  217. package/dist/custom_auth/sign_in/auth_flow/state/SignInPasswordRequiredState.mjs.map +1 -1
  218. package/dist/custom_auth/sign_in/auth_flow/state/SignInState.mjs +1 -1
  219. package/dist/custom_auth/sign_in/auth_flow/state/SignInState.mjs.map +1 -1
  220. package/dist/custom_auth/sign_in/interaction_client/SignInClient.mjs +1 -1
  221. package/dist/custom_auth/sign_in/interaction_client/SignInClient.mjs.map +1 -1
  222. package/dist/custom_auth/sign_in/interaction_client/result/SignInActionResult.mjs +1 -1
  223. package/dist/custom_auth/sign_up/auth_flow/error_type/SignUpError.mjs +1 -1
  224. package/dist/custom_auth/sign_up/auth_flow/error_type/SignUpError.mjs.map +1 -1
  225. package/dist/custom_auth/sign_up/auth_flow/result/SignUpResendCodeResult.mjs +1 -1
  226. package/dist/custom_auth/sign_up/auth_flow/result/SignUpResendCodeResult.mjs.map +1 -1
  227. package/dist/custom_auth/sign_up/auth_flow/result/SignUpResult.mjs +1 -1
  228. package/dist/custom_auth/sign_up/auth_flow/result/SignUpResult.mjs.map +1 -1
  229. package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitAttributesResult.mjs +1 -1
  230. package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitAttributesResult.mjs.map +1 -1
  231. package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitCodeResult.mjs +1 -1
  232. package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitCodeResult.mjs.map +1 -1
  233. package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitPasswordResult.mjs +1 -1
  234. package/dist/custom_auth/sign_up/auth_flow/result/SignUpSubmitPasswordResult.mjs.map +1 -1
  235. package/dist/custom_auth/sign_up/auth_flow/state/SignUpAttributesRequiredState.mjs +1 -1
  236. package/dist/custom_auth/sign_up/auth_flow/state/SignUpAttributesRequiredState.mjs.map +1 -1
  237. package/dist/custom_auth/sign_up/auth_flow/state/SignUpCodeRequiredState.mjs +1 -1
  238. package/dist/custom_auth/sign_up/auth_flow/state/SignUpCodeRequiredState.mjs.map +1 -1
  239. package/dist/custom_auth/sign_up/auth_flow/state/SignUpCompletedState.mjs +1 -1
  240. package/dist/custom_auth/sign_up/auth_flow/state/SignUpCompletedState.mjs.map +1 -1
  241. package/dist/custom_auth/sign_up/auth_flow/state/SignUpFailedState.mjs +1 -1
  242. package/dist/custom_auth/sign_up/auth_flow/state/SignUpFailedState.mjs.map +1 -1
  243. package/dist/custom_auth/sign_up/auth_flow/state/SignUpPasswordRequiredState.mjs +1 -1
  244. package/dist/custom_auth/sign_up/auth_flow/state/SignUpPasswordRequiredState.mjs.map +1 -1
  245. package/dist/custom_auth/sign_up/auth_flow/state/SignUpState.mjs +1 -1
  246. package/dist/custom_auth/sign_up/auth_flow/state/SignUpState.mjs.map +1 -1
  247. package/dist/custom_auth/sign_up/interaction_client/SignUpClient.mjs +1 -1
  248. package/dist/custom_auth/sign_up/interaction_client/SignUpClient.mjs.map +1 -1
  249. package/dist/custom_auth/sign_up/interaction_client/result/SignUpActionResult.mjs +1 -1
  250. package/dist/encode/Base64Decode.mjs +2 -2
  251. package/dist/encode/Base64Decode.mjs.map +1 -1
  252. package/dist/encode/Base64Encode.mjs +1 -1
  253. package/dist/error/BrowserAuthError.mjs +5 -5
  254. package/dist/error/BrowserAuthError.mjs.map +1 -1
  255. package/dist/error/BrowserAuthErrorCodes.mjs +1 -1
  256. package/dist/error/BrowserConfigurationAuthError.mjs +5 -5
  257. package/dist/error/BrowserConfigurationAuthError.mjs.map +1 -1
  258. package/dist/error/BrowserConfigurationAuthErrorCodes.mjs +1 -1
  259. package/dist/error/NativeAuthError.mjs +20 -10
  260. package/dist/error/NativeAuthError.mjs.map +1 -1
  261. package/dist/error/NativeAuthErrorCodes.mjs +1 -1
  262. package/dist/error/NestedAppAuthError.mjs +9 -5
  263. package/dist/error/NestedAppAuthError.mjs.map +1 -1
  264. package/dist/event/EventHandler.mjs +1 -1
  265. package/dist/event/EventHandler.mjs.map +1 -1
  266. package/dist/event/EventMessage.mjs +1 -1
  267. package/dist/event/EventMessage.mjs.map +1 -1
  268. package/dist/event/EventType.mjs +1 -1
  269. package/dist/event/EventType.mjs.map +1 -1
  270. package/dist/index.mjs +1 -1
  271. package/dist/index.mjs.map +1 -1
  272. package/dist/interaction_client/BaseInteractionClient.mjs +4 -4
  273. package/dist/interaction_client/BaseInteractionClient.mjs.map +1 -1
  274. package/dist/interaction_client/HybridSpaAuthorizationCodeClient.mjs +1 -1
  275. package/dist/interaction_client/HybridSpaAuthorizationCodeClient.mjs.map +1 -1
  276. package/dist/interaction_client/PlatformAuthInteractionClient.mjs +23 -19
  277. package/dist/interaction_client/PlatformAuthInteractionClient.mjs.map +1 -1
  278. package/dist/interaction_client/PopupClient.mjs +9 -9
  279. package/dist/interaction_client/PopupClient.mjs.map +1 -1
  280. package/dist/interaction_client/RedirectClient.mjs +13 -13
  281. package/dist/interaction_client/RedirectClient.mjs.map +1 -1
  282. package/dist/interaction_client/SilentAuthCodeClient.mjs +4 -4
  283. package/dist/interaction_client/SilentAuthCodeClient.mjs.map +1 -1
  284. package/dist/interaction_client/SilentCacheClient.mjs +1 -1
  285. package/dist/interaction_client/SilentCacheClient.mjs.map +1 -1
  286. package/dist/interaction_client/SilentIframeClient.mjs +4 -4
  287. package/dist/interaction_client/SilentIframeClient.mjs.map +1 -1
  288. package/dist/interaction_client/SilentRefreshClient.mjs +3 -3
  289. package/dist/interaction_client/SilentRefreshClient.mjs.map +1 -1
  290. package/dist/interaction_client/StandardInteractionClient.mjs +5 -5
  291. package/dist/interaction_client/StandardInteractionClient.mjs.map +1 -1
  292. package/dist/interaction_handler/InteractionHandler.mjs +3 -3
  293. package/dist/interaction_handler/InteractionHandler.mjs.map +1 -1
  294. package/dist/interaction_handler/SilentHandler.mjs +2 -2
  295. package/dist/interaction_handler/SilentHandler.mjs.map +1 -1
  296. package/dist/log-strings-mapping.json +2 -2
  297. package/dist/naa/BridgeError.mjs +1 -1
  298. package/dist/naa/BridgeProxy.mjs +2 -2
  299. package/dist/naa/BridgeProxy.mjs.map +1 -1
  300. package/dist/naa/BridgeStatusCode.mjs +1 -1
  301. package/dist/naa/BridgeStatusCode.mjs.map +1 -1
  302. package/dist/naa/mapping/NestedAppAuthAdapter.mjs +18 -17
  303. package/dist/naa/mapping/NestedAppAuthAdapter.mjs.map +1 -1
  304. package/dist/navigation/NavigationClient.mjs +2 -2
  305. package/dist/navigation/NavigationClient.mjs.map +1 -1
  306. package/dist/network/FetchClient.mjs +7 -7
  307. package/dist/network/FetchClient.mjs.map +1 -1
  308. package/dist/operatingcontext/BaseOperatingContext.mjs +1 -1
  309. package/dist/operatingcontext/BaseOperatingContext.mjs.map +1 -1
  310. package/dist/operatingcontext/NestedAppOperatingContext.mjs +1 -1
  311. package/dist/operatingcontext/NestedAppOperatingContext.mjs.map +1 -1
  312. package/dist/operatingcontext/StandardOperatingContext.mjs +1 -1
  313. package/dist/operatingcontext/StandardOperatingContext.mjs.map +1 -1
  314. package/dist/packageMetadata.mjs +2 -2
  315. package/dist/protocol/Authorize.mjs +8 -8
  316. package/dist/protocol/Authorize.mjs.map +1 -1
  317. package/dist/redirect_bridge/index.mjs +1 -1
  318. package/dist/redirect_bridge/index.mjs.map +1 -1
  319. package/dist/request/RequestHelpers.mjs +4 -4
  320. package/dist/request/RequestHelpers.mjs.map +1 -1
  321. package/dist/response/ResponseHandler.mjs +8 -8
  322. package/dist/response/ResponseHandler.mjs.map +1 -1
  323. package/dist/telemetry/BrowserPerformanceClient.mjs +1 -1
  324. package/dist/telemetry/BrowserPerformanceClient.mjs.map +1 -1
  325. package/dist/telemetry/BrowserPerformanceEvents.mjs +1 -1
  326. package/dist/telemetry/BrowserPerformanceEvents.mjs.map +1 -1
  327. package/dist/telemetry/BrowserPerformanceMeasurement.mjs +1 -1
  328. package/dist/telemetry/BrowserPerformanceMeasurement.mjs.map +1 -1
  329. package/dist/telemetry/BrowserRootPerformanceEvents.mjs +1 -1
  330. package/dist/utils/BrowserConstants.mjs +1 -1
  331. package/dist/utils/BrowserConstants.mjs.map +1 -1
  332. package/dist/utils/BrowserProtocolUtils.mjs +4 -4
  333. package/dist/utils/BrowserProtocolUtils.mjs.map +1 -1
  334. package/dist/utils/BrowserUtils.mjs +24 -20
  335. package/dist/utils/BrowserUtils.mjs.map +1 -1
  336. package/dist/utils/Helpers.mjs +1 -1
  337. package/dist/utils/Helpers.mjs.map +1 -1
  338. package/dist/utils/MsalFrameStatsUtils.mjs +1 -1
  339. package/dist/utils/MsalFrameStatsUtils.mjs.map +1 -1
  340. package/lib/custom-auth-path/log-strings-mapping.json +2 -2
  341. package/lib/custom-auth-path/msal-custom-auth.cjs +4837 -4772
  342. package/lib/custom-auth-path/msal-custom-auth.cjs.map +1 -1
  343. package/lib/custom-auth-path/msal-custom-auth.js +4837 -4772
  344. package/lib/custom-auth-path/msal-custom-auth.js.map +1 -1
  345. package/lib/log-strings-mapping.json +2 -2
  346. package/lib/msal-browser.cjs +7079 -7012
  347. package/lib/msal-browser.cjs.map +1 -1
  348. package/lib/msal-browser.js +7079 -7012
  349. package/lib/msal-browser.js.map +1 -1
  350. package/lib/msal-browser.min.js +2 -2
  351. package/lib/redirect-bridge/msal-redirect-bridge.cjs +80 -76
  352. package/lib/redirect-bridge/msal-redirect-bridge.cjs.map +1 -1
  353. package/lib/redirect-bridge/msal-redirect-bridge.js +80 -76
  354. package/lib/redirect-bridge/msal-redirect-bridge.js.map +1 -1
  355. package/lib/redirect-bridge/msal-redirect-bridge.min.js +2 -2
  356. package/package.json +2 -2
  357. package/src/app/IPublicClientApplication.ts +30 -15
  358. package/src/broker/nativeBroker/PlatformAuthDOMHandler.ts +2 -0
  359. package/src/broker/nativeBroker/PlatformAuthExtensionHandler.ts +8 -2
  360. package/src/broker/nativeBroker/PlatformAuthProvider.ts +2 -1
  361. package/src/cache/BrowserCacheManager.ts +19 -7
  362. package/src/cache/CookieStorage.ts +13 -3
  363. package/src/cache/DatabaseStorage.ts +12 -6
  364. package/src/cache/LocalStorage.ts +8 -4
  365. package/src/cache/SessionStorage.ts +2 -1
  366. package/src/cache/TokenCache.ts +15 -6
  367. package/src/config/Configuration.ts +4 -2
  368. package/src/controllers/NestedAppAuthController.ts +19 -11
  369. package/src/controllers/StandardController.ts +20 -9
  370. package/src/crypto/BrowserCrypto.ts +10 -2
  371. package/src/crypto/CryptoOps.ts +4 -2
  372. package/src/crypto/PkceGenerator.ts +8 -2
  373. package/src/custom_auth/core/CustomAuthAuthority.ts +4 -2
  374. package/src/custom_auth/get_account/interaction_client/CustomAuthSilentCacheClient.ts +2 -1
  375. package/src/encode/Base64Decode.ts +2 -1
  376. package/src/error/BrowserAuthError.ts +9 -3
  377. package/src/error/BrowserConfigurationAuthError.ts +9 -3
  378. package/src/error/NativeAuthError.ts +44 -11
  379. package/src/error/NestedAppAuthError.ts +14 -4
  380. package/src/interaction_client/BaseInteractionClient.ts +8 -3
  381. package/src/interaction_client/PlatformAuthInteractionClient.ts +49 -21
  382. package/src/interaction_client/PopupClient.ts +14 -8
  383. package/src/interaction_client/RedirectClient.ts +21 -10
  384. package/src/interaction_client/SilentAuthCodeClient.ts +5 -3
  385. package/src/interaction_client/SilentIframeClient.ts +5 -3
  386. package/src/interaction_client/SilentRefreshClient.ts +3 -2
  387. package/src/interaction_client/StandardInteractionClient.ts +8 -4
  388. package/src/interaction_handler/InteractionHandler.ts +4 -2
  389. package/src/interaction_handler/SilentHandler.ts +4 -1
  390. package/src/naa/mapping/NestedAppAuthAdapter.ts +43 -14
  391. package/src/navigation/NavigationClient.ts +1 -0
  392. package/src/network/FetchClient.ts +14 -6
  393. package/src/packageMetadata.ts +1 -1
  394. package/src/protocol/Authorize.ts +23 -7
  395. package/src/request/RequestHelpers.ts +6 -3
  396. package/src/response/ResponseHandler.ts +20 -7
  397. package/src/utils/BrowserProtocolUtils.ts +11 -3
  398. package/src/utils/BrowserUtils.ts +41 -16
  399. package/types/app/IPublicClientApplication.d.ts.map +1 -1
  400. package/types/broker/nativeBroker/PlatformAuthDOMHandler.d.ts.map +1 -1
  401. package/types/broker/nativeBroker/PlatformAuthExtensionHandler.d.ts.map +1 -1
  402. package/types/broker/nativeBroker/PlatformAuthProvider.d.ts.map +1 -1
  403. package/types/cache/BrowserCacheManager.d.ts.map +1 -1
  404. package/types/cache/CookieStorage.d.ts +1 -1
  405. package/types/cache/CookieStorage.d.ts.map +1 -1
  406. package/types/cache/DatabaseStorage.d.ts.map +1 -1
  407. package/types/cache/LocalStorage.d.ts.map +1 -1
  408. package/types/cache/SessionStorage.d.ts.map +1 -1
  409. package/types/cache/TokenCache.d.ts.map +1 -1
  410. package/types/config/Configuration.d.ts.map +1 -1
  411. package/types/controllers/NestedAppAuthController.d.ts.map +1 -1
  412. package/types/controllers/StandardController.d.ts.map +1 -1
  413. package/types/crypto/BrowserCrypto.d.ts.map +1 -1
  414. package/types/crypto/CryptoOps.d.ts.map +1 -1
  415. package/types/custom_auth/CustomAuthConstants.d.ts +1 -1
  416. package/types/custom_auth/core/CustomAuthAuthority.d.ts.map +1 -1
  417. package/types/custom_auth/get_account/interaction_client/CustomAuthSilentCacheClient.d.ts.map +1 -1
  418. package/types/encode/Base64Decode.d.ts.map +1 -1
  419. package/types/error/BrowserAuthError.d.ts +2 -2
  420. package/types/error/BrowserAuthError.d.ts.map +1 -1
  421. package/types/error/BrowserConfigurationAuthError.d.ts +2 -2
  422. package/types/error/BrowserConfigurationAuthError.d.ts.map +1 -1
  423. package/types/error/NativeAuthError.d.ts +2 -2
  424. package/types/error/NativeAuthError.d.ts.map +1 -1
  425. package/types/error/NestedAppAuthError.d.ts +2 -2
  426. package/types/error/NestedAppAuthError.d.ts.map +1 -1
  427. package/types/interaction_client/BaseInteractionClient.d.ts.map +1 -1
  428. package/types/interaction_client/PlatformAuthInteractionClient.d.ts.map +1 -1
  429. package/types/interaction_client/PopupClient.d.ts.map +1 -1
  430. package/types/interaction_client/RedirectClient.d.ts.map +1 -1
  431. package/types/interaction_client/SilentAuthCodeClient.d.ts.map +1 -1
  432. package/types/interaction_client/SilentIframeClient.d.ts.map +1 -1
  433. package/types/interaction_client/SilentRefreshClient.d.ts.map +1 -1
  434. package/types/interaction_client/StandardInteractionClient.d.ts.map +1 -1
  435. package/types/interaction_handler/InteractionHandler.d.ts.map +1 -1
  436. package/types/interaction_handler/SilentHandler.d.ts.map +1 -1
  437. package/types/naa/mapping/NestedAppAuthAdapter.d.ts.map +1 -1
  438. package/types/navigation/NavigationClient.d.ts.map +1 -1
  439. package/types/network/FetchClient.d.ts.map +1 -1
  440. package/types/packageMetadata.d.ts +1 -1
  441. package/types/protocol/Authorize.d.ts.map +1 -1
  442. package/types/request/RequestHelpers.d.ts.map +1 -1
  443. package/types/response/ResponseHandler.d.ts +1 -1
  444. package/types/response/ResponseHandler.d.ts.map +1 -1
  445. package/types/utils/BrowserProtocolUtils.d.ts +1 -1
  446. package/types/utils/BrowserProtocolUtils.d.ts.map +1 -1
  447. package/types/utils/BrowserUtils.d.ts +2 -2
  448. package/types/utils/BrowserUtils.d.ts.map +1 -1
@@ -176,7 +176,7 @@ export class RedirectClient extends StandardInteractionClient {
176
176
  }
177
177
  } catch (e) {
178
178
  if (e instanceof AuthError) {
179
- e.setCorrelationId(this.correlationId);
179
+ e.correlationId = this.correlationId;
180
180
  }
181
181
  window.removeEventListener("pageshow", handleBackButton);
182
182
  throw e;
@@ -260,7 +260,7 @@ export class RedirectClient extends StandardInteractionClient {
260
260
  }
261
261
  } catch (e) {
262
262
  if (e instanceof AuthError) {
263
- e.setCorrelationId(this.correlationId);
263
+ e.correlationId = this.correlationId;
264
264
  serverTelemetryManager.cacheFailedRequest(e);
265
265
  }
266
266
  throw e;
@@ -341,6 +341,7 @@ export class RedirectClient extends StandardInteractionClient {
341
341
  reject(
342
342
  createBrowserAuthError(
343
343
  BrowserAuthErrorCodes.timedOut,
344
+ "",
344
345
  "failed_to_redirect"
345
346
  )
346
347
  );
@@ -388,6 +389,7 @@ export class RedirectClient extends StandardInteractionClient {
388
389
  reject(
389
390
  createBrowserAuthError(
390
391
  BrowserAuthErrorCodes.timedOut,
392
+ "",
391
393
  "failed_to_redirect"
392
394
  )
393
395
  );
@@ -530,7 +532,9 @@ export class RedirectClient extends StandardInteractionClient {
530
532
  let processHashOnRedirect: boolean = true;
531
533
  if (!loginRequestUrl) {
532
534
  // Redirect to home page if login request url is empty
533
- const homepage = BrowserUtils.getHomepage();
535
+ const homepage = BrowserUtils.getHomepage(
536
+ this.correlationId
537
+ );
534
538
  // Cache the homepage under ORIGIN_URI to ensure cached hash is processed on homepage
535
539
  this.browserStorage.setTemporaryCache(
536
540
  TemporaryCacheKeys.ORIGIN_URI,
@@ -573,7 +577,7 @@ export class RedirectClient extends StandardInteractionClient {
573
577
  return null;
574
578
  } catch (e) {
575
579
  if (e instanceof AuthError) {
576
- (e as AuthError).setCorrelationId(this.correlationId);
580
+ (e as AuthError).correlationId = this.correlationId;
577
581
  serverTelemetryManager.cacheFailedRequest(e);
578
582
  }
579
583
  throw e;
@@ -613,7 +617,8 @@ export class RedirectClient extends StandardInteractionClient {
613
617
  ResponseHandler.validateInteractionType(
614
618
  response,
615
619
  this.browserCrypto,
616
- InteractionType.Redirect
620
+ InteractionType.Redirect,
621
+ this.correlationId
617
622
  );
618
623
  } catch (e) {
619
624
  if (e instanceof AuthError) {
@@ -669,7 +674,10 @@ export class RedirectClient extends StandardInteractionClient {
669
674
  ): Promise<AuthenticationResult> {
670
675
  const state = serverParams.state;
671
676
  if (!state) {
672
- throw createBrowserAuthError(BrowserAuthErrorCodes.noStateInHash);
677
+ throw createBrowserAuthError(
678
+ BrowserAuthErrorCodes.noStateInHash,
679
+ request.correlationId
680
+ );
673
681
  }
674
682
 
675
683
  const { authority, azureCloudOptions, extraQueryParameters, account } =
@@ -812,7 +820,8 @@ export class RedirectClient extends StandardInteractionClient {
812
820
  this.correlationId
813
821
  );
814
822
  throw createBrowserAuthError(
815
- BrowserAuthErrorCodes.emptyNavigateUri
823
+ BrowserAuthErrorCodes.emptyNavigateUri,
824
+ this.correlationId
816
825
  );
817
826
  }
818
827
  }
@@ -894,7 +903,8 @@ export class RedirectClient extends StandardInteractionClient {
894
903
  validLogoutRequest.state || "",
895
904
  {
896
905
  interactionType: InteractionType.Redirect,
897
- }
906
+ },
907
+ validLogoutRequest.correlationId
898
908
  );
899
909
 
900
910
  // Create logout string and navigate user window to logout.
@@ -955,7 +965,7 @@ export class RedirectClient extends StandardInteractionClient {
955
965
  }
956
966
  } catch (e) {
957
967
  if (e instanceof AuthError) {
958
- (e as AuthError).setCorrelationId(this.correlationId);
968
+ (e as AuthError).correlationId = this.correlationId;
959
969
  serverTelemetryManager.cacheFailedRequest(e);
960
970
  }
961
971
  this.eventHandler.emitEvent(
@@ -988,7 +998,8 @@ export class RedirectClient extends StandardInteractionClient {
988
998
  const redirectStartPage = requestStartPage || window.location.href;
989
999
  const absoluteRedirectStartPage = UrlString.getAbsoluteUrl(
990
1000
  redirectStartPage,
991
- BrowserUtils.getCurrentUri()
1001
+ BrowserUtils.getCurrentUri(),
1002
+ this.correlationId
992
1003
  );
993
1004
  // Sanity check the URL before it is cached so we never persist a malformed value (e.g. the literal string "null")
994
1005
  UrlUtils.validateUrl(
@@ -73,7 +73,8 @@ export class SilentAuthCodeClient extends StandardInteractionClient {
73
73
  // Auth code payload is required
74
74
  if (!request.code) {
75
75
  throw createBrowserAuthError(
76
- BrowserAuthErrorCodes.authCodeRequired
76
+ BrowserAuthErrorCodes.authCodeRequired,
77
+ this.correlationId
77
78
  );
78
79
  }
79
80
 
@@ -168,7 +169,7 @@ export class SilentAuthCodeClient extends StandardInteractionClient {
168
169
  );
169
170
  } catch (e) {
170
171
  if (e instanceof AuthError) {
171
- (e as AuthError).setCorrelationId(this.correlationId);
172
+ (e as AuthError).correlationId = this.correlationId;
172
173
  serverTelemetryManager.cacheFailedRequest(e);
173
174
  }
174
175
  throw e;
@@ -182,7 +183,8 @@ export class SilentAuthCodeClient extends StandardInteractionClient {
182
183
  // Synchronous so we must reject
183
184
  return Promise.reject(
184
185
  createBrowserAuthError(
185
- BrowserAuthErrorCodes.silentLogoutUnsupported
186
+ BrowserAuthErrorCodes.silentLogoutUnsupported,
187
+ ""
186
188
  )
187
189
  );
188
190
  }
@@ -230,7 +230,7 @@ export class SilentIframeClient extends StandardInteractionClient {
230
230
  )(authClient, request);
231
231
  } catch (e) {
232
232
  if (e instanceof AuthError) {
233
- (e as AuthError).setCorrelationId(this.correlationId);
233
+ (e as AuthError).correlationId = this.correlationId;
234
234
  serverTelemetryManager.cacheFailedRequest(e);
235
235
  }
236
236
 
@@ -497,7 +497,8 @@ export class SilentIframeClient extends StandardInteractionClient {
497
497
  // Validate the response - this checks for errors and validates state
498
498
  AuthorizeProtocol.validateAuthorizationResponse(
499
499
  serverParams,
500
- silentRequest.state
500
+ silentRequest.state,
501
+ correlationId
501
502
  );
502
503
 
503
504
  // Verify a valid authorization code is present
@@ -523,7 +524,8 @@ export class SilentIframeClient extends StandardInteractionClient {
523
524
  // Synchronous so we must reject
524
525
  return Promise.reject(
525
526
  createBrowserAuthError(
526
- BrowserAuthErrorCodes.silentLogoutUnsupported
527
+ BrowserAuthErrorCodes.silentLogoutUnsupported,
528
+ ""
527
529
  )
528
530
  );
529
531
  }
@@ -90,7 +90,7 @@ export class SilentRefreshClient extends StandardInteractionClient {
90
90
  request.correlationId
91
91
  )(silentRequest, ApiId.acquireTokenSilent_silentFlow).catch(
92
92
  (e: AuthError) => {
93
- (e as AuthError).setCorrelationId(this.correlationId);
93
+ (e as AuthError).correlationId = this.correlationId;
94
94
  serverTelemetryManager.cacheFailedRequest(e);
95
95
  throw e;
96
96
  }
@@ -104,7 +104,8 @@ export class SilentRefreshClient extends StandardInteractionClient {
104
104
  // Synchronous so we must reject
105
105
  return Promise.reject(
106
106
  createBrowserAuthError(
107
- BrowserAuthErrorCodes.silentLogoutUnsupported
107
+ BrowserAuthErrorCodes.silentLogoutUnsupported,
108
+ ""
108
109
  )
109
110
  );
110
111
  }
@@ -120,7 +120,8 @@ export abstract class StandardInteractionClient extends BaseInteractionClient {
120
120
  validLogoutRequest.postLogoutRedirectUri =
121
121
  UrlString.getAbsoluteUrl(
122
122
  logoutRequest.postLogoutRedirectUri,
123
- BrowserUtils.getCurrentUri()
123
+ BrowserUtils.getCurrentUri(),
124
+ validLogoutRequest.correlationId
124
125
  );
125
126
  } else if (this.config.auth.postLogoutRedirectUri === null) {
126
127
  this.logger.verbose(
@@ -135,7 +136,8 @@ export abstract class StandardInteractionClient extends BaseInteractionClient {
135
136
  validLogoutRequest.postLogoutRedirectUri =
136
137
  UrlString.getAbsoluteUrl(
137
138
  this.config.auth.postLogoutRedirectUri,
138
- BrowserUtils.getCurrentUri()
139
+ BrowserUtils.getCurrentUri(),
140
+ validLogoutRequest.correlationId
139
141
  );
140
142
  } else {
141
143
  this.logger.verbose(
@@ -145,7 +147,8 @@ export abstract class StandardInteractionClient extends BaseInteractionClient {
145
147
  validLogoutRequest.postLogoutRedirectUri =
146
148
  UrlString.getAbsoluteUrl(
147
149
  BrowserUtils.getCurrentUri(),
148
- BrowserUtils.getCurrentUri()
150
+ BrowserUtils.getCurrentUri(),
151
+ validLogoutRequest.correlationId
149
152
  );
150
153
  }
151
154
  } else {
@@ -349,7 +352,8 @@ export async function initializeAuthorizationRequest(
349
352
  const state = ProtocolUtils.setRequestState(
350
353
  browserCrypto,
351
354
  (request && request.state) || "",
352
- browserState
355
+ browserState,
356
+ correlationId
353
357
  );
354
358
 
355
359
  const baseRequest: BaseAuthRequest = await invokeAsync(
@@ -64,7 +64,8 @@ export class InteractionHandler {
64
64
  try {
65
65
  authCodeResponse = AuthorizeProtocol.getAuthorizationCodePayload(
66
66
  response,
67
- request.state
67
+ request.state,
68
+ request.correlationId
68
69
  );
69
70
  } catch (e) {
70
71
  if (
@@ -73,7 +74,8 @@ export class InteractionHandler {
73
74
  ) {
74
75
  // Translate server error caused by user closing native prompt to corresponding first class MSAL error
75
76
  throw createBrowserAuthError(
76
- BrowserAuthErrorCodes.userCancelled
77
+ BrowserAuthErrorCodes.userCancelled,
78
+ request.correlationId
77
79
  );
78
80
  } else {
79
81
  throw e;
@@ -30,7 +30,10 @@ export async function initiateCodeRequest(
30
30
  if (!requestUrl) {
31
31
  // Throw error if request URL is empty.
32
32
  logger.info("Navigate url is empty", correlationId);
33
- throw createBrowserAuthError(BrowserAuthErrorCodes.emptyNavigateUri);
33
+ throw createBrowserAuthError(
34
+ BrowserAuthErrorCodes.emptyNavigateUri,
35
+ correlationId
36
+ );
34
37
  }
35
38
 
36
39
  frame.src = requestUrl;
@@ -75,7 +75,7 @@ export class NestedAppAuthAdapter {
75
75
 
76
76
  const correlationId =
77
77
  request.correlationId || this.crypto.createNewGuid();
78
- const claims = RequestParameterBuilder.addClientCapabilitiesToClaims(
78
+ const claims = RequestParameterBuilder.buildMergedClaims(
79
79
  request.claims,
80
80
  this.clientCapabilities
81
81
  );
@@ -104,7 +104,10 @@ export class NestedAppAuthAdapter {
104
104
  reqTimestamp: number
105
105
  ): AuthenticationResult {
106
106
  if (!response.token.id_token || !response.token.access_token) {
107
- throw createClientAuthError(ClientAuthErrorCodes.nullOrEmptyToken);
107
+ throw createClientAuthError(
108
+ ClientAuthErrorCodes.nullOrEmptyToken,
109
+ request.correlationId
110
+ );
108
111
  }
109
112
 
110
113
  // Request timestamp and AuthResult expires_in are in seconds, converting to Date for AuthenticationResult
@@ -113,7 +116,8 @@ export class NestedAppAuthAdapter {
113
116
  );
114
117
  const idTokenClaims = AuthToken.extractTokenClaims(
115
118
  response.token.id_token,
116
- this.crypto.base64Decode
119
+ this.crypto.base64Decode,
120
+ request.correlationId
117
121
  );
118
122
  const account = this.fromNaaAccountInfo(
119
123
  response.account,
@@ -196,7 +200,8 @@ export class NestedAppAuthAdapter {
196
200
  const environment = fromAccount.environment;
197
201
  if (!environment) {
198
202
  throw createClientAuthError(
199
- ClientAuthErrorCodes.invalidCacheEnvironment
203
+ ClientAuthErrorCodes.invalidCacheEnvironment,
204
+ ""
200
205
  );
201
206
  }
202
207
 
@@ -225,6 +230,7 @@ export class NestedAppAuthAdapter {
225
230
  homeAccountId,
226
231
  localAccountId,
227
232
  tenantId,
233
+ fromAccount.platformBrokerId,
228
234
  effectiveIdTokenClaims
229
235
  );
230
236
  tenantProfiles.set(tenantId, tenantProfile);
@@ -239,6 +245,7 @@ export class NestedAppAuthAdapter {
239
245
  loginHint,
240
246
  idToken: idToken,
241
247
  idTokenClaims: effectiveIdTokenClaims,
248
+ nativeAccountId: fromAccount.platformBrokerId,
242
249
  tenantProfiles,
243
250
  };
244
251
 
@@ -262,39 +269,57 @@ export class NestedAppAuthAdapter {
262
269
  switch (error.status) {
263
270
  case BridgeStatusCode.UserCancel:
264
271
  return new ClientAuthError(
265
- ClientAuthErrorCodes.userCanceled
272
+ ClientAuthErrorCodes.userCanceled,
273
+ ""
266
274
  );
267
275
  case BridgeStatusCode.NoNetwork:
268
276
  return new ClientAuthError(
269
- ClientAuthErrorCodes.noNetworkConnectivity
277
+ ClientAuthErrorCodes.noNetworkConnectivity,
278
+ ""
270
279
  );
271
280
  case BridgeStatusCode.AccountUnavailable:
272
281
  return new ClientAuthError(
273
- ClientAuthErrorCodes.noAccountFound
282
+ ClientAuthErrorCodes.noAccountFound,
283
+ ""
274
284
  );
275
285
  case BridgeStatusCode.Disabled:
276
286
  return new ClientAuthError(
277
- ClientAuthErrorCodes.nestedAppAuthBridgeDisabled
287
+ ClientAuthErrorCodes.nestedAppAuthBridgeDisabled,
288
+ ""
278
289
  );
279
290
  case BridgeStatusCode.NestedAppAuthUnavailable:
280
291
  return new ClientAuthError(
281
292
  error.code ||
282
293
  ClientAuthErrorCodes.nestedAppAuthBridgeDisabled,
294
+ "",
283
295
  error.description
284
296
  );
285
297
  case BridgeStatusCode.TransientError:
286
298
  case BridgeStatusCode.PersistentError:
287
- return new ServerError(error.code, error.description);
299
+ return new ServerError(
300
+ error.code || "",
301
+ "",
302
+ error.description
303
+ );
288
304
  case BridgeStatusCode.UserInteractionRequired:
289
305
  return new InteractionRequiredAuthError(
290
- error.code,
306
+ error.code || "",
307
+ "",
291
308
  error.description
292
309
  );
293
310
  default:
294
- return new AuthError(error.code, error.description);
311
+ return new AuthError(
312
+ error.code || "",
313
+ "",
314
+ error.description
315
+ );
295
316
  }
296
317
  } else {
297
- return new AuthError("unknown_error", "An unknown error occurred");
318
+ return new AuthError(
319
+ "unknown_error",
320
+ "",
321
+ "An unknown error occurred"
322
+ );
298
323
  }
299
324
  }
300
325
 
@@ -315,12 +340,16 @@ export class NestedAppAuthAdapter {
315
340
  correlationId: string
316
341
  ): AuthenticationResult {
317
342
  if (!idToken || !accessToken) {
318
- throw createClientAuthError(ClientAuthErrorCodes.nullOrEmptyToken);
343
+ throw createClientAuthError(
344
+ ClientAuthErrorCodes.nullOrEmptyToken,
345
+ correlationId
346
+ );
319
347
  }
320
348
 
321
349
  const idTokenClaims = AuthToken.extractTokenClaims(
322
350
  idToken.secret,
323
- this.crypto.base64Decode
351
+ this.crypto.base64Decode,
352
+ correlationId
324
353
  );
325
354
 
326
355
  const scopes = accessToken.target || request.scopes.join(" ");
@@ -55,6 +55,7 @@ export class NavigationClient implements INavigationClient {
55
55
  reject(
56
56
  createBrowserAuthError(
57
57
  BrowserAuthErrorCodes.timedOut,
58
+ "",
58
59
  "failed_to_redirect"
59
60
  )
60
61
  );
@@ -43,7 +43,8 @@ export class FetchClient implements INetworkModule {
43
43
  createBrowserAuthError(
44
44
  window.navigator.onLine
45
45
  ? BrowserAuthErrorCodes.getRequestFailed
46
- : BrowserAuthErrorCodes.noNetworkConnectivity
46
+ : BrowserAuthErrorCodes.noNetworkConnectivity,
47
+ ""
47
48
  ),
48
49
  undefined,
49
50
  undefined,
@@ -62,7 +63,8 @@ export class FetchClient implements INetworkModule {
62
63
  } catch (e) {
63
64
  throw createNetworkError(
64
65
  createBrowserAuthError(
65
- BrowserAuthErrorCodes.failedToParseResponse
66
+ BrowserAuthErrorCodes.failedToParseResponse,
67
+ ""
66
68
  ),
67
69
  responseStatus,
68
70
  responseHeaders,
@@ -98,7 +100,8 @@ export class FetchClient implements INetworkModule {
98
100
  createBrowserAuthError(
99
101
  window.navigator.onLine
100
102
  ? BrowserAuthErrorCodes.postRequestFailed
101
- : BrowserAuthErrorCodes.noNetworkConnectivity
103
+ : BrowserAuthErrorCodes.noNetworkConnectivity,
104
+ ""
102
105
  ),
103
106
  undefined,
104
107
  undefined,
@@ -117,7 +120,8 @@ export class FetchClient implements INetworkModule {
117
120
  } catch (e) {
118
121
  throw createNetworkError(
119
122
  createBrowserAuthError(
120
- BrowserAuthErrorCodes.failedToParseResponse
123
+ BrowserAuthErrorCodes.failedToParseResponse,
124
+ ""
121
125
  ),
122
126
  responseStatus,
123
127
  responseHeaders,
@@ -144,7 +148,10 @@ function getFetchHeaders(options?: NetworkRequestOptions): Headers {
144
148
  return headers;
145
149
  } catch (e) {
146
150
  throw createNetworkError(
147
- createBrowserAuthError(BrowserAuthErrorCodes.failedToBuildHeaders),
151
+ createBrowserAuthError(
152
+ BrowserAuthErrorCodes.failedToBuildHeaders,
153
+ ""
154
+ ),
148
155
  undefined,
149
156
  undefined,
150
157
  e as Error
@@ -166,7 +173,8 @@ function getHeaderDict(headers: Headers): Record<string, string> {
166
173
  return headerDict;
167
174
  } catch (e) {
168
175
  throw createBrowserAuthError(
169
- BrowserAuthErrorCodes.failedToParseHeaders
176
+ BrowserAuthErrorCodes.failedToParseHeaders,
177
+ ""
170
178
  );
171
179
  }
172
180
  }
@@ -1,3 +1,3 @@
1
1
  /* eslint-disable header/header */
2
2
  export const name = "@azure/msal-browser";
3
- export const version = "5.14.0";
3
+ export const version = "5.15.0";
@@ -239,7 +239,8 @@ export async function getAuthCodeRequestUrl(
239
239
  ): Promise<string> {
240
240
  if (!request.codeChallenge) {
241
241
  throw createClientConfigurationError(
242
- ClientConfigurationErrorCodes.pkceParamsMissing
242
+ ClientConfigurationErrorCodes.pkceParamsMissing,
243
+ request.correlationId
243
244
  );
244
245
  }
245
246
 
@@ -282,7 +283,10 @@ export async function getEARForm(
282
283
  performanceClient: IPerformanceClient
283
284
  ): Promise<HTMLFormElement> {
284
285
  if (!request.earJwk) {
285
- throw createBrowserAuthError(BrowserAuthErrorCodes.earJwkEmpty);
286
+ throw createBrowserAuthError(
287
+ BrowserAuthErrorCodes.earJwkEmpty,
288
+ request.correlationId
289
+ );
286
290
  }
287
291
 
288
292
  const parameters = await getStandardParameters(
@@ -442,7 +446,8 @@ export async function handleResponsePlatformBroker(
442
446
 
443
447
  if (!platformAuthProvider) {
444
448
  throw createBrowserAuthError(
445
- BrowserAuthErrorCodes.nativeConnectionNotEstablished
449
+ BrowserAuthErrorCodes.nativeConnectionNotEstablished,
450
+ request.correlationId
446
451
  );
447
452
  }
448
453
  const browserCrypto = new CryptoOps(logger, performanceClient);
@@ -462,7 +467,8 @@ export async function handleResponsePlatformBroker(
462
467
  );
463
468
  const { userRequestState } = ProtocolUtils.parseRequestState(
464
469
  browserCrypto.base64Decode,
465
- request.state
470
+ request.state,
471
+ request.correlationId
466
472
  );
467
473
  return invokeAsync(
468
474
  nativeInteractionClient.acquireToken.bind(nativeInteractionClient),
@@ -596,14 +602,24 @@ export async function handleResponseEAR(
596
602
  instrumentClientData(response, request.correlationId, performanceClient);
597
603
 
598
604
  // Validate state & check response for errors
599
- AuthorizeProtocol.validateAuthorizationResponse(response, request.state);
605
+ AuthorizeProtocol.validateAuthorizationResponse(
606
+ response,
607
+ request.state,
608
+ request.correlationId
609
+ );
600
610
 
601
611
  if (!response.ear_jwe) {
602
- throw createBrowserAuthError(BrowserAuthErrorCodes.earJweEmpty);
612
+ throw createBrowserAuthError(
613
+ BrowserAuthErrorCodes.earJweEmpty,
614
+ request.correlationId
615
+ );
603
616
  }
604
617
 
605
618
  if (!request.earJwk) {
606
- throw createBrowserAuthError(BrowserAuthErrorCodes.earJwkEmpty);
619
+ throw createBrowserAuthError(
620
+ BrowserAuthErrorCodes.earJwkEmpty,
621
+ request.correlationId
622
+ );
607
623
  }
608
624
 
609
625
  const decryptedData = JSON.parse(
@@ -62,12 +62,14 @@ export async function initializeBaseRequest(
62
62
  ) {
63
63
  if (!request.sshJwk) {
64
64
  throw createClientConfigurationError(
65
- ClientConfigurationErrorCodes.missingSshJwk
65
+ ClientConfigurationErrorCodes.missingSshJwk,
66
+ ""
66
67
  );
67
68
  }
68
69
  if (!request.sshKid) {
69
70
  throw createClientConfigurationError(
70
- ClientConfigurationErrorCodes.missingSshKid
71
+ ClientConfigurationErrorCodes.missingSshKid,
72
+ ""
71
73
  );
72
74
  }
73
75
  }
@@ -120,7 +122,8 @@ export function validateRequestMethod(
120
122
  // Validate that method can only be POST when protocol mode is EAR
121
123
  if (requestMethod && requestMethod !== Constants.HttpMethod.POST) {
122
124
  throw createClientConfigurationError(
123
- ClientConfigurationErrorCodes.invalidRequestMethodForEAR
125
+ ClientConfigurationErrorCodes.invalidRequestMethodForEAR,
126
+ ""
124
127
  );
125
128
  } else {
126
129
  httpMethod = Constants.HttpMethod.POST;
@@ -31,7 +31,10 @@ export function deserializeResponse(
31
31
  `The request has returned to the redirectUri but a '${responseLocation}' is not present. It's likely that the '${responseLocation}' has been removed or the page has been redirected by code running on the redirectUri page.`,
32
32
  correlationId
33
33
  );
34
- throw createBrowserAuthError(BrowserAuthErrorCodes.hashEmptyError);
34
+ throw createBrowserAuthError(
35
+ BrowserAuthErrorCodes.hashEmptyError,
36
+ correlationId
37
+ );
35
38
  } else {
36
39
  logger.error(
37
40
  `A '${responseLocation}' is present in the iframe but it does not contain known properties. It's likely that the '${responseLocation}' has been replaced by code running on the redirectUri page.`,
@@ -42,7 +45,8 @@ export function deserializeResponse(
42
45
  correlationId
43
46
  );
44
47
  throw createBrowserAuthError(
45
- BrowserAuthErrorCodes.hashDoesNotContainKnownProperties
48
+ BrowserAuthErrorCodes.hashDoesNotContainKnownProperties,
49
+ correlationId
46
50
  );
47
51
  }
48
52
  }
@@ -55,23 +59,32 @@ export function deserializeResponse(
55
59
  export function validateInteractionType(
56
60
  response: AuthorizeResponse,
57
61
  browserCrypto: ICrypto,
58
- interactionType: InteractionType
62
+ interactionType: InteractionType,
63
+ correlationId: string
59
64
  ): void {
60
65
  if (!response.state) {
61
- throw createBrowserAuthError(BrowserAuthErrorCodes.noStateInHash);
66
+ throw createBrowserAuthError(
67
+ BrowserAuthErrorCodes.noStateInHash,
68
+ correlationId
69
+ );
62
70
  }
63
71
 
64
72
  const platformStateObj = extractBrowserRequestState(
65
73
  browserCrypto,
66
- response.state
74
+ response.state,
75
+ correlationId
67
76
  );
68
77
  if (!platformStateObj) {
69
- throw createBrowserAuthError(BrowserAuthErrorCodes.unableToParseState);
78
+ throw createBrowserAuthError(
79
+ BrowserAuthErrorCodes.unableToParseState,
80
+ correlationId
81
+ );
70
82
  }
71
83
 
72
84
  if (platformStateObj.interactionType !== interactionType) {
73
85
  throw createBrowserAuthError(
74
- BrowserAuthErrorCodes.stateInteractionTypeMismatch
86
+ BrowserAuthErrorCodes.stateInteractionTypeMismatch,
87
+ correlationId
75
88
  );
76
89
  }
77
90
  }
@@ -23,7 +23,8 @@ export type BrowserStateObject = {
23
23
  */
24
24
  export function extractBrowserRequestState(
25
25
  browserCrypto: ICrypto,
26
- state: string
26
+ state: string,
27
+ correlationId: string
27
28
  ): BrowserStateObject | null {
28
29
  if (!state) {
29
30
  return null;
@@ -31,9 +32,16 @@ export function extractBrowserRequestState(
31
32
 
32
33
  try {
33
34
  const requestStateObj: RequestStateObject =
34
- ProtocolUtils.parseRequestState(browserCrypto.base64Decode, state);
35
+ ProtocolUtils.parseRequestState(
36
+ browserCrypto.base64Decode,
37
+ state,
38
+ correlationId
39
+ );
35
40
  return requestStateObj.libraryState.meta as BrowserStateObject;
36
41
  } catch (e) {
37
- throw createClientAuthError(ClientAuthErrorCodes.invalidState);
42
+ throw createClientAuthError(
43
+ ClientAuthErrorCodes.invalidState,
44
+ correlationId
45
+ );
38
46
  }
39
47
  }