@azure/msal-browser 3.23.0 → 3.24.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 (519) hide show
  1. package/dist/app/IPublicClientApplication.d.ts +16 -16
  2. package/dist/app/IPublicClientApplication.d.ts.map +1 -1
  3. package/dist/app/IPublicClientApplication.mjs +1 -1
  4. package/dist/app/PublicClientApplication.d.ts +18 -18
  5. package/dist/app/PublicClientApplication.d.ts.map +1 -1
  6. package/dist/app/PublicClientApplication.mjs +1 -1
  7. package/dist/app/PublicClientApplication.mjs.map +1 -1
  8. package/dist/app/PublicClientNext.d.ts +16 -16
  9. package/dist/app/PublicClientNext.d.ts.map +1 -1
  10. package/dist/app/PublicClientNext.mjs +1 -1
  11. package/dist/app/PublicClientNext.mjs.map +1 -1
  12. package/dist/broker/nativeBroker/NativeMessageHandler.d.ts +3 -3
  13. package/dist/broker/nativeBroker/NativeMessageHandler.d.ts.map +1 -1
  14. package/dist/broker/nativeBroker/NativeMessageHandler.mjs +2 -2
  15. package/dist/broker/nativeBroker/NativeRequest.d.ts +2 -2
  16. package/dist/broker/nativeBroker/NativeRequest.d.ts.map +1 -1
  17. package/dist/broker/nativeBroker/NativeStatusCodes.mjs +1 -1
  18. package/dist/cache/AccountManager.d.ts +2 -2
  19. package/dist/cache/AccountManager.d.ts.map +1 -1
  20. package/dist/cache/AccountManager.mjs +1 -1
  21. package/dist/cache/AsyncMemoryStorage.d.ts +2 -2
  22. package/dist/cache/AsyncMemoryStorage.d.ts.map +1 -1
  23. package/dist/cache/AsyncMemoryStorage.mjs +1 -1
  24. package/dist/cache/BrowserCacheManager.d.ts +11 -11
  25. package/dist/cache/BrowserCacheManager.d.ts.map +1 -1
  26. package/dist/cache/BrowserCacheManager.mjs +2 -2
  27. package/dist/cache/BrowserStorage.d.ts +1 -1
  28. package/dist/cache/BrowserStorage.d.ts.map +1 -1
  29. package/dist/cache/BrowserStorage.mjs +1 -1
  30. package/dist/cache/DatabaseStorage.d.ts +1 -1
  31. package/dist/cache/DatabaseStorage.d.ts.map +1 -1
  32. package/dist/cache/DatabaseStorage.mjs +1 -1
  33. package/dist/cache/DatabaseStorage.mjs.map +1 -1
  34. package/dist/cache/ITokenCache.d.ts +4 -4
  35. package/dist/cache/ITokenCache.d.ts.map +1 -1
  36. package/dist/cache/MemoryStorage.d.ts +1 -1
  37. package/dist/cache/MemoryStorage.d.ts.map +1 -1
  38. package/dist/cache/MemoryStorage.mjs +1 -1
  39. package/dist/cache/TokenCache.d.ts +6 -6
  40. package/dist/cache/TokenCache.d.ts.map +1 -1
  41. package/dist/cache/TokenCache.mjs +2 -2
  42. package/dist/config/Configuration.d.ts +7 -3
  43. package/dist/config/Configuration.d.ts.map +1 -1
  44. package/dist/config/Configuration.mjs +3 -2
  45. package/dist/config/Configuration.mjs.map +1 -1
  46. package/dist/controllers/ControllerFactory.d.ts +3 -3
  47. package/dist/controllers/ControllerFactory.d.ts.map +1 -1
  48. package/dist/controllers/ControllerFactory.mjs +1 -1
  49. package/dist/controllers/IController.d.ts +17 -17
  50. package/dist/controllers/IController.d.ts.map +1 -1
  51. package/dist/controllers/NestedAppAuthController.d.ts +21 -21
  52. package/dist/controllers/NestedAppAuthController.d.ts.map +1 -1
  53. package/dist/controllers/NestedAppAuthController.mjs +2 -2
  54. package/dist/controllers/StandardController.d.ts +28 -28
  55. package/dist/controllers/StandardController.d.ts.map +1 -1
  56. package/dist/controllers/StandardController.mjs +2 -2
  57. package/dist/controllers/UnknownOperatingContextController.d.ts +19 -19
  58. package/dist/controllers/UnknownOperatingContextController.d.ts.map +1 -1
  59. package/dist/controllers/UnknownOperatingContextController.mjs +2 -2
  60. package/dist/crypto/BrowserCrypto.d.ts +1 -1
  61. package/dist/crypto/BrowserCrypto.d.ts.map +1 -1
  62. package/dist/crypto/BrowserCrypto.mjs +2 -2
  63. package/dist/crypto/CryptoOps.d.ts +1 -1
  64. package/dist/crypto/CryptoOps.d.ts.map +1 -1
  65. package/dist/crypto/CryptoOps.mjs +2 -2
  66. package/dist/crypto/CryptoOps.mjs.map +1 -1
  67. package/dist/crypto/PkceGenerator.d.ts +1 -1
  68. package/dist/crypto/PkceGenerator.d.ts.map +1 -1
  69. package/dist/crypto/PkceGenerator.mjs +2 -2
  70. package/dist/crypto/SignedHttpRequest.d.ts +1 -1
  71. package/dist/crypto/SignedHttpRequest.d.ts.map +1 -1
  72. package/dist/crypto/SignedHttpRequest.mjs +2 -2
  73. package/dist/encode/Base64Decode.mjs +1 -1
  74. package/dist/encode/Base64Encode.mjs +1 -1
  75. package/dist/error/BrowserAuthError.d.ts +2 -2
  76. package/dist/error/BrowserAuthError.d.ts.map +1 -1
  77. package/dist/error/BrowserAuthError.mjs +2 -2
  78. package/dist/error/BrowserAuthErrorCodes.mjs +1 -1
  79. package/dist/error/BrowserConfigurationAuthError.d.ts +2 -2
  80. package/dist/error/BrowserConfigurationAuthError.d.ts.map +1 -1
  81. package/dist/error/BrowserConfigurationAuthError.mjs +2 -2
  82. package/dist/error/BrowserConfigurationAuthErrorCodes.mjs +1 -1
  83. package/dist/error/NativeAuthError.d.ts +2 -2
  84. package/dist/error/NativeAuthError.d.ts.map +1 -1
  85. package/dist/error/NativeAuthError.mjs +2 -2
  86. package/dist/error/NativeAuthErrorCodes.mjs +1 -1
  87. package/dist/error/NestedAppAuthError.d.ts +1 -1
  88. package/dist/error/NestedAppAuthError.d.ts.map +1 -1
  89. package/dist/error/NestedAppAuthError.mjs +2 -2
  90. package/dist/event/EventHandler.d.ts +4 -4
  91. package/dist/event/EventHandler.d.ts.map +1 -1
  92. package/dist/event/EventHandler.mjs +2 -2
  93. package/dist/event/EventMessage.d.ts +9 -4
  94. package/dist/event/EventMessage.d.ts.map +1 -1
  95. package/dist/event/EventMessage.mjs +1 -1
  96. package/dist/event/EventMessage.mjs.map +1 -1
  97. package/dist/event/EventType.mjs +1 -1
  98. package/dist/index.d.ts +35 -35
  99. package/dist/index.d.ts.map +1 -1
  100. package/dist/index.mjs +2 -2
  101. package/dist/interaction_client/BaseInteractionClient.d.ts +24 -16
  102. package/dist/interaction_client/BaseInteractionClient.d.ts.map +1 -1
  103. package/dist/interaction_client/BaseInteractionClient.mjs +23 -10
  104. package/dist/interaction_client/BaseInteractionClient.mjs.map +1 -1
  105. package/dist/interaction_client/HybridSpaAuthorizationCodeClient.d.ts +1 -1
  106. package/dist/interaction_client/HybridSpaAuthorizationCodeClient.d.ts.map +1 -1
  107. package/dist/interaction_client/HybridSpaAuthorizationCodeClient.mjs +2 -2
  108. package/dist/interaction_client/NativeInteractionClient.d.ts +16 -16
  109. package/dist/interaction_client/NativeInteractionClient.d.ts.map +1 -1
  110. package/dist/interaction_client/NativeInteractionClient.mjs +12 -6
  111. package/dist/interaction_client/NativeInteractionClient.mjs.map +1 -1
  112. package/dist/interaction_client/PopupClient.d.ts +17 -16
  113. package/dist/interaction_client/PopupClient.d.ts.map +1 -1
  114. package/dist/interaction_client/PopupClient.mjs +59 -56
  115. package/dist/interaction_client/PopupClient.mjs.map +1 -1
  116. package/dist/interaction_client/RedirectClient.d.ts +10 -10
  117. package/dist/interaction_client/RedirectClient.d.ts.map +1 -1
  118. package/dist/interaction_client/RedirectClient.mjs +16 -6
  119. package/dist/interaction_client/RedirectClient.mjs.map +1 -1
  120. package/dist/interaction_client/SilentAuthCodeClient.d.ts +10 -10
  121. package/dist/interaction_client/SilentAuthCodeClient.d.ts.map +1 -1
  122. package/dist/interaction_client/SilentAuthCodeClient.mjs +9 -3
  123. package/dist/interaction_client/SilentAuthCodeClient.mjs.map +1 -1
  124. package/dist/interaction_client/SilentCacheClient.d.ts +4 -4
  125. package/dist/interaction_client/SilentCacheClient.d.ts.map +1 -1
  126. package/dist/interaction_client/SilentCacheClient.mjs +8 -3
  127. package/dist/interaction_client/SilentCacheClient.mjs.map +1 -1
  128. package/dist/interaction_client/SilentIframeClient.d.ts +11 -11
  129. package/dist/interaction_client/SilentIframeClient.d.ts.map +1 -1
  130. package/dist/interaction_client/SilentIframeClient.mjs +9 -3
  131. package/dist/interaction_client/SilentIframeClient.mjs.map +1 -1
  132. package/dist/interaction_client/SilentRefreshClient.d.ts +17 -6
  133. package/dist/interaction_client/SilentRefreshClient.d.ts.map +1 -1
  134. package/dist/interaction_client/SilentRefreshClient.mjs +23 -7
  135. package/dist/interaction_client/SilentRefreshClient.mjs.map +1 -1
  136. package/dist/interaction_client/StandardInteractionClient.d.ts +36 -15
  137. package/dist/interaction_client/StandardInteractionClient.d.ts.map +1 -1
  138. package/dist/interaction_client/StandardInteractionClient.mjs +26 -11
  139. package/dist/interaction_client/StandardInteractionClient.mjs.map +1 -1
  140. package/dist/interaction_handler/InteractionHandler.d.ts +4 -4
  141. package/dist/interaction_handler/InteractionHandler.d.ts.map +1 -1
  142. package/dist/interaction_handler/InteractionHandler.mjs +2 -2
  143. package/dist/interaction_handler/RedirectHandler.d.ts +4 -4
  144. package/dist/interaction_handler/RedirectHandler.d.ts.map +1 -1
  145. package/dist/interaction_handler/RedirectHandler.mjs +2 -2
  146. package/dist/interaction_handler/SilentHandler.d.ts +1 -1
  147. package/dist/interaction_handler/SilentHandler.d.ts.map +1 -1
  148. package/dist/interaction_handler/SilentHandler.mjs +2 -2
  149. package/dist/naa/AuthResult.d.ts +2 -2
  150. package/dist/naa/AuthResult.d.ts.map +1 -1
  151. package/dist/naa/BridgeError.d.ts +1 -1
  152. package/dist/naa/BridgeError.d.ts.map +1 -1
  153. package/dist/naa/BridgeError.mjs +1 -1
  154. package/dist/naa/BridgeProxy.d.ts +9 -8
  155. package/dist/naa/BridgeProxy.d.ts.map +1 -1
  156. package/dist/naa/BridgeProxy.mjs +16 -14
  157. package/dist/naa/BridgeProxy.mjs.map +1 -1
  158. package/dist/naa/BridgeRequest.d.ts +1 -1
  159. package/dist/naa/BridgeRequest.d.ts.map +1 -1
  160. package/dist/naa/BridgeRequestEnvelope.d.ts +1 -1
  161. package/dist/naa/BridgeRequestEnvelope.d.ts.map +1 -1
  162. package/dist/naa/BridgeResponseEnvelope.d.ts +4 -4
  163. package/dist/naa/BridgeResponseEnvelope.d.ts.map +1 -1
  164. package/dist/naa/BridgeStatusCode.mjs +1 -1
  165. package/dist/naa/IBridgeProxy.d.ts +4 -4
  166. package/dist/naa/IBridgeProxy.d.ts.map +1 -1
  167. package/dist/naa/InitContext.d.ts +2 -2
  168. package/dist/naa/InitContext.d.ts.map +1 -1
  169. package/dist/naa/mapping/NestedAppAuthAdapter.d.ts +9 -9
  170. package/dist/naa/mapping/NestedAppAuthAdapter.d.ts.map +1 -1
  171. package/dist/naa/mapping/NestedAppAuthAdapter.mjs +2 -2
  172. package/dist/navigation/INavigationClient.d.ts +1 -1
  173. package/dist/navigation/INavigationClient.d.ts.map +1 -1
  174. package/dist/navigation/NavigationClient.d.ts +2 -2
  175. package/dist/navigation/NavigationClient.d.ts.map +1 -1
  176. package/dist/navigation/NavigationClient.mjs +1 -1
  177. package/dist/navigation/NavigationOptions.d.ts +1 -1
  178. package/dist/navigation/NavigationOptions.d.ts.map +1 -1
  179. package/dist/network/FetchClient.d.ts +1 -1
  180. package/dist/network/FetchClient.d.ts.map +1 -1
  181. package/dist/network/FetchClient.mjs +2 -2
  182. package/dist/operatingcontext/BaseOperatingContext.d.ts +2 -2
  183. package/dist/operatingcontext/BaseOperatingContext.d.ts.map +1 -1
  184. package/dist/operatingcontext/BaseOperatingContext.mjs +2 -2
  185. package/dist/operatingcontext/NestedAppOperatingContext.d.ts +8 -3
  186. package/dist/operatingcontext/NestedAppOperatingContext.d.ts.map +1 -1
  187. package/dist/operatingcontext/NestedAppOperatingContext.mjs +4 -5
  188. package/dist/operatingcontext/NestedAppOperatingContext.mjs.map +1 -1
  189. package/dist/operatingcontext/StandardOperatingContext.d.ts +1 -1
  190. package/dist/operatingcontext/StandardOperatingContext.d.ts.map +1 -1
  191. package/dist/operatingcontext/StandardOperatingContext.mjs +1 -1
  192. package/dist/operatingcontext/UnknownOperatingContext.d.ts +1 -1
  193. package/dist/operatingcontext/UnknownOperatingContext.d.ts.map +1 -1
  194. package/dist/operatingcontext/UnknownOperatingContext.mjs +1 -1
  195. package/dist/packageMetadata.d.ts +1 -1
  196. package/dist/packageMetadata.mjs +2 -2
  197. package/dist/request/AuthorizationCodeRequest.d.ts +1 -1
  198. package/dist/request/AuthorizationCodeRequest.d.ts.map +1 -1
  199. package/dist/request/AuthorizationUrlRequest.d.ts +1 -1
  200. package/dist/request/AuthorizationUrlRequest.d.ts.map +1 -1
  201. package/dist/request/ClearCacheRequest.d.ts +1 -1
  202. package/dist/request/ClearCacheRequest.d.ts.map +1 -1
  203. package/dist/request/EndSessionPopupRequest.d.ts +4 -2
  204. package/dist/request/EndSessionPopupRequest.d.ts.map +1 -1
  205. package/dist/request/EndSessionRequest.d.ts +1 -1
  206. package/dist/request/EndSessionRequest.d.ts.map +1 -1
  207. package/dist/request/PopupRequest.d.ts +4 -2
  208. package/dist/request/PopupRequest.d.ts.map +1 -1
  209. package/dist/request/RedirectRequest.d.ts +1 -1
  210. package/dist/request/RedirectRequest.d.ts.map +1 -1
  211. package/dist/request/RequestHelpers.d.ts +3 -3
  212. package/dist/request/RequestHelpers.d.ts.map +1 -1
  213. package/dist/request/RequestHelpers.mjs +2 -2
  214. package/dist/request/SilentRequest.d.ts +2 -2
  215. package/dist/request/SilentRequest.d.ts.map +1 -1
  216. package/dist/request/SsoSilentRequest.d.ts +1 -1
  217. package/dist/request/SsoSilentRequest.d.ts.map +1 -1
  218. package/dist/response/AuthenticationResult.d.ts +1 -1
  219. package/dist/response/AuthenticationResult.d.ts.map +1 -1
  220. package/dist/response/ResponseHandler.d.ts +2 -2
  221. package/dist/response/ResponseHandler.d.ts.map +1 -1
  222. package/dist/response/ResponseHandler.mjs +2 -2
  223. package/dist/telemetry/BrowserPerformanceClient.d.ts +2 -2
  224. package/dist/telemetry/BrowserPerformanceClient.d.ts.map +1 -1
  225. package/dist/telemetry/BrowserPerformanceClient.mjs +2 -2
  226. package/dist/telemetry/BrowserPerformanceClient.mjs.map +1 -1
  227. package/dist/telemetry/BrowserPerformanceMeasurement.d.ts +1 -1
  228. package/dist/telemetry/BrowserPerformanceMeasurement.d.ts.map +1 -1
  229. package/dist/telemetry/BrowserPerformanceMeasurement.mjs +1 -1
  230. package/dist/telemetry/BrowserPerformanceMeasurement.mjs.map +1 -1
  231. package/dist/utils/BrowserConstants.d.ts +2 -2
  232. package/dist/utils/BrowserConstants.d.ts.map +1 -1
  233. package/dist/utils/BrowserConstants.mjs +2 -2
  234. package/dist/utils/BrowserProtocolUtils.d.ts +2 -2
  235. package/dist/utils/BrowserProtocolUtils.d.ts.map +1 -1
  236. package/dist/utils/BrowserProtocolUtils.mjs +2 -2
  237. package/dist/utils/BrowserUtils.d.ts +2 -2
  238. package/dist/utils/BrowserUtils.d.ts.map +1 -1
  239. package/dist/utils/BrowserUtils.mjs +3 -3
  240. package/lib/msal-browser.cjs +5045 -4956
  241. package/lib/msal-browser.cjs.map +1 -1
  242. package/lib/msal-browser.js +5045 -4956
  243. package/lib/msal-browser.js.map +1 -1
  244. package/lib/msal-browser.min.js +66 -68
  245. package/lib/package.json +1 -0
  246. package/lib/types/app/IPublicClientApplication.d.ts +54 -0
  247. package/lib/types/app/IPublicClientApplication.d.ts.map +1 -0
  248. package/lib/types/app/PublicClientApplication.d.ts +294 -0
  249. package/lib/types/app/PublicClientApplication.d.ts.map +1 -0
  250. package/lib/types/app/PublicClientNext.d.ts +277 -0
  251. package/lib/types/app/PublicClientNext.d.ts.map +1 -0
  252. package/lib/types/broker/nativeBroker/NativeMessageHandler.d.ts +63 -0
  253. package/lib/types/broker/nativeBroker/NativeMessageHandler.d.ts.map +1 -0
  254. package/lib/types/broker/nativeBroker/NativeRequest.d.ts +46 -0
  255. package/lib/types/broker/nativeBroker/NativeRequest.d.ts.map +1 -0
  256. package/lib/types/broker/nativeBroker/NativeResponse.d.ts +49 -0
  257. package/lib/types/broker/nativeBroker/NativeResponse.d.ts.map +1 -0
  258. package/lib/types/broker/nativeBroker/NativeStatusCodes.d.ts +8 -0
  259. package/lib/types/broker/nativeBroker/NativeStatusCodes.d.ts.map +1 -0
  260. package/lib/types/cache/AccountManager.d.ts +49 -0
  261. package/lib/types/cache/AccountManager.d.ts.map +1 -0
  262. package/lib/types/cache/AsyncMemoryStorage.d.ts +51 -0
  263. package/lib/types/cache/AsyncMemoryStorage.d.ts.map +1 -0
  264. package/lib/types/cache/BrowserCacheManager.d.ts +386 -0
  265. package/lib/types/cache/BrowserCacheManager.d.ts.map +1 -0
  266. package/lib/types/cache/BrowserStorage.d.ts +12 -0
  267. package/lib/types/cache/BrowserStorage.d.ts.map +1 -0
  268. package/lib/types/cache/DatabaseStorage.d.ts +57 -0
  269. package/lib/types/cache/DatabaseStorage.d.ts.map +1 -0
  270. package/lib/types/cache/IAsyncStorage.d.ts +28 -0
  271. package/lib/types/cache/IAsyncStorage.d.ts.map +1 -0
  272. package/lib/types/cache/ITokenCache.d.ts +12 -0
  273. package/lib/types/cache/ITokenCache.d.ts.map +1 -0
  274. package/lib/types/cache/IWindowStorage.d.ts +28 -0
  275. package/lib/types/cache/IWindowStorage.d.ts.map +1 -0
  276. package/lib/types/cache/MemoryStorage.d.ts +12 -0
  277. package/lib/types/cache/MemoryStorage.d.ts.map +1 -0
  278. package/lib/types/cache/TokenCache.d.ts +78 -0
  279. package/lib/types/cache/TokenCache.d.ts.map +1 -0
  280. package/lib/types/config/Configuration.d.ts +218 -0
  281. package/lib/types/config/Configuration.d.ts.map +1 -0
  282. package/lib/types/controllers/ControllerFactory.d.ts +6 -0
  283. package/lib/types/controllers/ControllerFactory.d.ts.map +1 -0
  284. package/lib/types/controllers/IController.d.ts +61 -0
  285. package/lib/types/controllers/IController.d.ts.map +1 -0
  286. package/lib/types/controllers/NestedAppAuthController.d.ts +203 -0
  287. package/lib/types/controllers/NestedAppAuthController.d.ts.map +1 -0
  288. package/lib/types/controllers/StandardController.d.ts +406 -0
  289. package/lib/types/controllers/StandardController.d.ts.map +1 -0
  290. package/lib/types/controllers/UnknownOperatingContextController.d.ts +87 -0
  291. package/lib/types/controllers/UnknownOperatingContextController.d.ts.map +1 -0
  292. package/lib/types/crypto/BrowserCrypto.d.ts +53 -0
  293. package/lib/types/crypto/BrowserCrypto.d.ts.map +1 -0
  294. package/lib/types/crypto/CryptoOps.d.ts +75 -0
  295. package/lib/types/crypto/CryptoOps.d.ts.map +1 -0
  296. package/lib/types/crypto/PkceGenerator.d.ts +9 -0
  297. package/lib/types/crypto/PkceGenerator.d.ts.map +1 -0
  298. package/lib/types/crypto/SignedHttpRequest.d.ts +31 -0
  299. package/lib/types/crypto/SignedHttpRequest.d.ts.map +1 -0
  300. package/lib/types/encode/Base64Decode.d.ts +10 -0
  301. package/lib/types/encode/Base64Decode.d.ts.map +1 -0
  302. package/lib/types/encode/Base64Encode.d.ts +20 -0
  303. package/lib/types/encode/Base64Encode.d.ts.map +1 -0
  304. package/lib/types/error/BrowserAuthError.d.ts +256 -0
  305. package/lib/types/error/BrowserAuthError.d.ts.map +1 -0
  306. package/lib/types/error/BrowserAuthErrorCodes.d.ts +47 -0
  307. package/lib/types/error/BrowserAuthErrorCodes.d.ts.map +1 -0
  308. package/lib/types/error/BrowserConfigurationAuthError.d.ts +34 -0
  309. package/lib/types/error/BrowserConfigurationAuthError.d.ts.map +1 -0
  310. package/lib/types/error/BrowserConfigurationAuthErrorCodes.d.ts +4 -0
  311. package/lib/types/error/BrowserConfigurationAuthErrorCodes.d.ts.map +1 -0
  312. package/lib/types/error/NativeAuthError.d.ts +30 -0
  313. package/lib/types/error/NativeAuthError.d.ts.map +1 -0
  314. package/lib/types/error/NativeAuthErrorCodes.d.ts +3 -0
  315. package/lib/types/error/NativeAuthErrorCodes.d.ts.map +1 -0
  316. package/lib/types/error/NestedAppAuthError.d.ts +15 -0
  317. package/lib/types/error/NestedAppAuthError.d.ts.map +1 -0
  318. package/lib/types/event/EventHandler.d.ts +42 -0
  319. package/lib/types/event/EventHandler.d.ts.map +1 -0
  320. package/lib/types/event/EventMessage.d.ts +31 -0
  321. package/lib/types/event/EventMessage.d.ts.map +1 -0
  322. package/lib/types/event/EventType.d.ts +30 -0
  323. package/lib/types/event/EventType.d.ts.map +1 -0
  324. package/lib/types/index.d.ts +41 -0
  325. package/lib/types/index.d.ts.map +1 -0
  326. package/lib/types/interaction_client/BaseInteractionClient.d.ts +59 -0
  327. package/lib/types/interaction_client/BaseInteractionClient.d.ts.map +1 -0
  328. package/lib/types/interaction_client/HybridSpaAuthorizationCodeClient.d.ts +5 -0
  329. package/lib/types/interaction_client/HybridSpaAuthorizationCodeClient.d.ts.map +1 -0
  330. package/lib/types/interaction_client/NativeInteractionClient.d.ts +152 -0
  331. package/lib/types/interaction_client/NativeInteractionClient.d.ts.map +1 -0
  332. package/lib/types/interaction_client/PopupClient.d.ts +107 -0
  333. package/lib/types/interaction_client/PopupClient.d.ts.map +1 -0
  334. package/lib/types/interaction_client/RedirectClient.d.ts +51 -0
  335. package/lib/types/interaction_client/RedirectClient.d.ts.map +1 -0
  336. package/lib/types/interaction_client/SilentAuthCodeClient.d.ts +24 -0
  337. package/lib/types/interaction_client/SilentAuthCodeClient.d.ts.map +1 -0
  338. package/lib/types/interaction_client/SilentCacheClient.d.ts +17 -0
  339. package/lib/types/interaction_client/SilentCacheClient.d.ts.map +1 -0
  340. package/lib/types/interaction_client/SilentIframeClient.d.ts +33 -0
  341. package/lib/types/interaction_client/SilentIframeClient.d.ts.map +1 -0
  342. package/lib/types/interaction_client/SilentRefreshClient.d.ts +32 -0
  343. package/lib/types/interaction_client/SilentRefreshClient.d.ts.map +1 -0
  344. package/lib/types/interaction_client/StandardInteractionClient.d.ts +70 -0
  345. package/lib/types/interaction_client/StandardInteractionClient.d.ts.map +1 -0
  346. package/lib/types/interaction_handler/InteractionHandler.d.ts +34 -0
  347. package/lib/types/interaction_handler/InteractionHandler.d.ts.map +1 -0
  348. package/lib/types/interaction_handler/RedirectHandler.d.ts +33 -0
  349. package/lib/types/interaction_handler/RedirectHandler.d.ts.map +1 -0
  350. package/lib/types/interaction_handler/SilentHandler.d.ts +14 -0
  351. package/lib/types/interaction_handler/SilentHandler.d.ts.map +1 -0
  352. package/lib/types/naa/AccountInfo.d.ts +12 -0
  353. package/lib/types/naa/AccountInfo.d.ts.map +1 -0
  354. package/lib/types/naa/AuthBridge.d.ts +9 -0
  355. package/lib/types/naa/AuthBridge.d.ts.map +1 -0
  356. package/lib/types/naa/AuthResult.d.ts +7 -0
  357. package/lib/types/naa/AuthResult.d.ts.map +1 -0
  358. package/lib/types/naa/BridgeAccountContext.d.ts +13 -0
  359. package/lib/types/naa/BridgeAccountContext.d.ts.map +1 -0
  360. package/lib/types/naa/BridgeCapabilities.d.ts +4 -0
  361. package/lib/types/naa/BridgeCapabilities.d.ts.map +1 -0
  362. package/lib/types/naa/BridgeError.d.ts +10 -0
  363. package/lib/types/naa/BridgeError.d.ts.map +1 -0
  364. package/lib/types/naa/BridgeProxy.d.ts +69 -0
  365. package/lib/types/naa/BridgeProxy.d.ts.map +1 -0
  366. package/lib/types/naa/BridgeRequest.d.ts +8 -0
  367. package/lib/types/naa/BridgeRequest.d.ts.map +1 -0
  368. package/lib/types/naa/BridgeRequestEnvelope.d.ts +13 -0
  369. package/lib/types/naa/BridgeRequestEnvelope.d.ts.map +1 -0
  370. package/lib/types/naa/BridgeResponseEnvelope.d.ts +14 -0
  371. package/lib/types/naa/BridgeResponseEnvelope.d.ts.map +1 -0
  372. package/lib/types/naa/BridgeStatusCode.d.ts +12 -0
  373. package/lib/types/naa/BridgeStatusCode.d.ts.map +1 -0
  374. package/lib/types/naa/IBridgeProxy.d.ts +11 -0
  375. package/lib/types/naa/IBridgeProxy.d.ts.map +1 -0
  376. package/lib/types/naa/InitContext.d.ts +9 -0
  377. package/lib/types/naa/InitContext.d.ts.map +1 -0
  378. package/lib/types/naa/TokenRequest.d.ts +19 -0
  379. package/lib/types/naa/TokenRequest.d.ts.map +1 -0
  380. package/lib/types/naa/TokenResponse.d.ts +14 -0
  381. package/lib/types/naa/TokenResponse.d.ts.map +1 -0
  382. package/lib/types/naa/mapping/NestedAppAuthAdapter.d.ts +36 -0
  383. package/lib/types/naa/mapping/NestedAppAuthAdapter.d.ts.map +1 -0
  384. package/lib/types/navigation/INavigationClient.d.ts +17 -0
  385. package/lib/types/navigation/INavigationClient.d.ts.map +1 -0
  386. package/lib/types/navigation/NavigationClient.d.ts +23 -0
  387. package/lib/types/navigation/NavigationClient.d.ts.map +1 -0
  388. package/lib/types/navigation/NavigationOptions.d.ts +13 -0
  389. package/lib/types/navigation/NavigationOptions.d.ts.map +1 -0
  390. package/lib/types/network/FetchClient.d.ts +27 -0
  391. package/lib/types/network/FetchClient.d.ts.map +1 -0
  392. package/lib/types/operatingcontext/BaseOperatingContext.d.ts +42 -0
  393. package/lib/types/operatingcontext/BaseOperatingContext.d.ts.map +1 -0
  394. package/lib/types/operatingcontext/NestedAppOperatingContext.d.ts +40 -0
  395. package/lib/types/operatingcontext/NestedAppOperatingContext.d.ts.map +1 -0
  396. package/lib/types/operatingcontext/StandardOperatingContext.d.ts +26 -0
  397. package/lib/types/operatingcontext/StandardOperatingContext.d.ts.map +1 -0
  398. package/lib/types/operatingcontext/UnknownOperatingContext.d.ts +26 -0
  399. package/lib/types/operatingcontext/UnknownOperatingContext.d.ts.map +1 -0
  400. package/lib/types/packageMetadata.d.ts +3 -0
  401. package/lib/types/packageMetadata.d.ts.map +1 -0
  402. package/lib/types/request/AuthorizationCodeRequest.d.ts +9 -0
  403. package/lib/types/request/AuthorizationCodeRequest.d.ts.map +1 -0
  404. package/lib/types/request/AuthorizationUrlRequest.d.ts +9 -0
  405. package/lib/types/request/AuthorizationUrlRequest.d.ts.map +1 -0
  406. package/lib/types/request/ClearCacheRequest.d.ts +11 -0
  407. package/lib/types/request/ClearCacheRequest.d.ts.map +1 -0
  408. package/lib/types/request/EndSessionPopupRequest.d.ts +21 -0
  409. package/lib/types/request/EndSessionPopupRequest.d.ts.map +1 -0
  410. package/lib/types/request/EndSessionRequest.d.ts +16 -0
  411. package/lib/types/request/EndSessionRequest.d.ts.map +1 -0
  412. package/lib/types/request/InitializeApplicationRequest.d.ts +9 -0
  413. package/lib/types/request/InitializeApplicationRequest.d.ts.map +1 -0
  414. package/lib/types/request/PopupRequest.d.ts +37 -0
  415. package/lib/types/request/PopupRequest.d.ts.map +1 -0
  416. package/lib/types/request/PopupWindowAttributes.d.ts +16 -0
  417. package/lib/types/request/PopupWindowAttributes.d.ts.map +1 -0
  418. package/lib/types/request/RedirectRequest.d.ts +41 -0
  419. package/lib/types/request/RedirectRequest.d.ts.map +1 -0
  420. package/lib/types/request/RequestHelpers.d.ts +14 -0
  421. package/lib/types/request/RequestHelpers.d.ts.map +1 -0
  422. package/lib/types/request/SilentRequest.d.ts +34 -0
  423. package/lib/types/request/SilentRequest.d.ts.map +1 -0
  424. package/lib/types/request/SsoSilentRequest.d.ts +30 -0
  425. package/lib/types/request/SsoSilentRequest.d.ts.map +1 -0
  426. package/lib/types/response/AuthenticationResult.d.ts +5 -0
  427. package/lib/types/response/AuthenticationResult.d.ts.map +1 -0
  428. package/lib/types/response/ResponseHandler.d.ts +8 -0
  429. package/lib/types/response/ResponseHandler.d.ts.map +1 -0
  430. package/lib/types/telemetry/BrowserPerformanceClient.d.ts +35 -0
  431. package/lib/types/telemetry/BrowserPerformanceClient.d.ts.map +1 -0
  432. package/lib/types/telemetry/BrowserPerformanceMeasurement.d.ts +22 -0
  433. package/lib/types/telemetry/BrowserPerformanceMeasurement.d.ts.map +1 -0
  434. package/lib/types/utils/BrowserConstants.d.ts +181 -0
  435. package/lib/types/utils/BrowserConstants.d.ts.map +1 -0
  436. package/lib/types/utils/BrowserProtocolUtils.d.ts +12 -0
  437. package/lib/types/utils/BrowserProtocolUtils.d.ts.map +1 -0
  438. package/lib/types/utils/BrowserUtils.d.ts +76 -0
  439. package/lib/types/utils/BrowserUtils.d.ts.map +1 -0
  440. package/package.json +14 -13
  441. package/src/app/IPublicClientApplication.ts +17 -17
  442. package/src/app/PublicClientApplication.ts +26 -23
  443. package/src/app/PublicClientNext.ts +22 -19
  444. package/src/broker/nativeBroker/NativeMessageHandler.ts +7 -7
  445. package/src/broker/nativeBroker/NativeRequest.ts +2 -2
  446. package/src/cache/AccountManager.ts +2 -2
  447. package/src/cache/AsyncMemoryStorage.ts +5 -5
  448. package/src/cache/BrowserCacheManager.ts +16 -16
  449. package/src/cache/BrowserStorage.ts +3 -3
  450. package/src/cache/DatabaseStorage.ts +7 -3
  451. package/src/cache/ITokenCache.ts +4 -4
  452. package/src/cache/MemoryStorage.ts +1 -1
  453. package/src/cache/TokenCache.ts +9 -9
  454. package/src/config/Configuration.ts +10 -5
  455. package/src/controllers/ControllerFactory.ts +7 -7
  456. package/src/controllers/IController.ts +17 -17
  457. package/src/controllers/NestedAppAuthController.ts +25 -25
  458. package/src/controllers/StandardController.ts +39 -39
  459. package/src/controllers/UnknownOperatingContextController.ts +21 -21
  460. package/src/crypto/BrowserCrypto.ts +4 -4
  461. package/src/crypto/CryptoOps.ts +10 -6
  462. package/src/crypto/PkceGenerator.ts +4 -4
  463. package/src/crypto/SignedHttpRequest.ts +3 -3
  464. package/src/encode/Base64Decode.ts +1 -1
  465. package/src/error/BrowserAuthError.ts +2 -2
  466. package/src/error/BrowserConfigurationAuthError.ts +2 -2
  467. package/src/error/NativeAuthError.ts +4 -4
  468. package/src/error/NestedAppAuthError.ts +1 -1
  469. package/src/event/EventHandler.ts +5 -5
  470. package/src/event/EventMessage.ts +11 -10
  471. package/src/index.ts +35 -35
  472. package/src/interaction_client/BaseInteractionClient.ts +51 -28
  473. package/src/interaction_client/HybridSpaAuthorizationCodeClient.ts +1 -1
  474. package/src/interaction_client/NativeInteractionClient.ts +32 -29
  475. package/src/interaction_client/PopupClient.ts +95 -109
  476. package/src/interaction_client/RedirectClient.ts +32 -30
  477. package/src/interaction_client/SilentAuthCodeClient.ts +20 -19
  478. package/src/interaction_client/SilentCacheClient.ts +11 -11
  479. package/src/interaction_client/SilentIframeClient.ts +23 -22
  480. package/src/interaction_client/SilentRefreshClient.ts +33 -20
  481. package/src/interaction_client/StandardInteractionClient.ts +62 -38
  482. package/src/interaction_handler/InteractionHandler.ts +5 -5
  483. package/src/interaction_handler/RedirectHandler.ts +7 -7
  484. package/src/interaction_handler/SilentHandler.ts +3 -3
  485. package/src/naa/AuthResult.ts +2 -2
  486. package/src/naa/BridgeError.ts +1 -1
  487. package/src/naa/BridgeProxy.ts +36 -26
  488. package/src/naa/BridgeRequest.ts +1 -1
  489. package/src/naa/BridgeRequestEnvelope.ts +1 -1
  490. package/src/naa/BridgeResponseEnvelope.ts +4 -4
  491. package/src/naa/IBridgeProxy.ts +4 -4
  492. package/src/naa/InitContext.ts +2 -2
  493. package/src/naa/mapping/NestedAppAuthAdapter.ts +12 -12
  494. package/src/navigation/INavigationClient.ts +1 -1
  495. package/src/navigation/NavigationClient.ts +2 -2
  496. package/src/navigation/NavigationOptions.ts +1 -1
  497. package/src/network/FetchClient.ts +3 -3
  498. package/src/operatingcontext/BaseOperatingContext.ts +4 -4
  499. package/src/operatingcontext/NestedAppOperatingContext.ts +14 -9
  500. package/src/operatingcontext/StandardOperatingContext.ts +1 -1
  501. package/src/operatingcontext/UnknownOperatingContext.ts +1 -1
  502. package/src/packageMetadata.ts +1 -1
  503. package/src/request/AuthorizationCodeRequest.ts +1 -1
  504. package/src/request/AuthorizationUrlRequest.ts +1 -1
  505. package/src/request/ClearCacheRequest.ts +1 -1
  506. package/src/request/EndSessionPopupRequest.ts +4 -2
  507. package/src/request/EndSessionRequest.ts +1 -1
  508. package/src/request/PopupRequest.ts +7 -2
  509. package/src/request/RedirectRequest.ts +4 -1
  510. package/src/request/RequestHelpers.ts +4 -4
  511. package/src/request/SilentRequest.ts +2 -2
  512. package/src/request/SsoSilentRequest.ts +4 -1
  513. package/src/response/AuthenticationResult.ts +1 -1
  514. package/src/response/ResponseHandler.ts +4 -4
  515. package/src/telemetry/BrowserPerformanceClient.ts +6 -6
  516. package/src/telemetry/BrowserPerformanceMeasurement.ts +4 -1
  517. package/src/utils/BrowserConstants.ts +3 -3
  518. package/src/utils/BrowserProtocolUtils.ts +2 -2
  519. package/src/utils/BrowserUtils.ts +6 -6
@@ -0,0 +1,70 @@
1
+ import { ServerTelemetryManager, CommonAuthorizationCodeRequest, AuthorizationCodeClient, ClientConfiguration, CommonEndSessionRequest, AccountInfo, AzureCloudOptions, StringDict } from "@azure/msal-common/browser";
2
+ import { BaseInteractionClient } from "./BaseInteractionClient.js";
3
+ import { AuthorizationUrlRequest } from "../request/AuthorizationUrlRequest.js";
4
+ import { InteractionType } from "../utils/BrowserConstants.js";
5
+ import { EndSessionRequest } from "../request/EndSessionRequest.js";
6
+ import { RedirectRequest } from "../request/RedirectRequest.js";
7
+ import { PopupRequest } from "../request/PopupRequest.js";
8
+ import { SsoSilentRequest } from "../request/SsoSilentRequest.js";
9
+ /**
10
+ * Defines the class structure and helper functions used by the "standard", non-brokered auth flows (popup, redirect, silent (RT), silent (iframe))
11
+ */
12
+ export declare abstract class StandardInteractionClient extends BaseInteractionClient {
13
+ /**
14
+ * Generates an auth code request tied to the url request.
15
+ * @param request
16
+ */
17
+ protected initializeAuthorizationCodeRequest(request: AuthorizationUrlRequest): Promise<CommonAuthorizationCodeRequest>;
18
+ /**
19
+ * Initializer for the logout request.
20
+ * @param logoutRequest
21
+ */
22
+ protected initializeLogoutRequest(logoutRequest?: EndSessionRequest): CommonEndSessionRequest;
23
+ /**
24
+ * Parses login_hint ID Token Claim out of AccountInfo object to be used as
25
+ * logout_hint in end session request.
26
+ * @param account
27
+ */
28
+ protected getLogoutHintFromIdTokenClaims(account: AccountInfo): string | null;
29
+ /**
30
+ * Creates an Authorization Code Client with the given authority, or the default authority.
31
+ * @param params {
32
+ * serverTelemetryManager: ServerTelemetryManager;
33
+ * authorityUrl?: string;
34
+ * requestAzureCloudOptions?: AzureCloudOptions;
35
+ * requestExtraQueryParameters?: StringDict;
36
+ * account?: AccountInfo;
37
+ * }
38
+ */
39
+ protected createAuthCodeClient(params: {
40
+ serverTelemetryManager: ServerTelemetryManager;
41
+ requestAuthority?: string;
42
+ requestAzureCloudOptions?: AzureCloudOptions;
43
+ requestExtraQueryParameters?: StringDict;
44
+ account?: AccountInfo;
45
+ }): Promise<AuthorizationCodeClient>;
46
+ /**
47
+ * Creates a Client Configuration object with the given request authority, or the default authority.
48
+ * @param params {
49
+ * serverTelemetryManager: ServerTelemetryManager;
50
+ * requestAuthority?: string;
51
+ * requestAzureCloudOptions?: AzureCloudOptions;
52
+ * requestExtraQueryParameters?: boolean;
53
+ * account?: AccountInfo;
54
+ * }
55
+ */
56
+ protected getClientConfiguration(params: {
57
+ serverTelemetryManager: ServerTelemetryManager;
58
+ requestAuthority?: string;
59
+ requestAzureCloudOptions?: AzureCloudOptions;
60
+ requestExtraQueryParameters?: StringDict;
61
+ account?: AccountInfo;
62
+ }): Promise<ClientConfiguration>;
63
+ /**
64
+ * Helper to initialize required request parameters for interactive APIs and ssoSilent()
65
+ * @param request
66
+ * @param interactionType
67
+ */
68
+ protected initializeAuthorizationRequest(request: RedirectRequest | PopupRequest | SsoSilentRequest, interactionType: InteractionType): Promise<AuthorizationUrlRequest>;
69
+ }
70
+ //# sourceMappingURL=StandardInteractionClient.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"StandardInteractionClient.d.ts","sourceRoot":"","sources":["../../../src/interaction_client/StandardInteractionClient.ts"],"names":[],"mappings":"AAKA,OAAO,EACH,sBAAsB,EACtB,8BAA8B,EAE9B,uBAAuB,EACvB,mBAAmB,EAEnB,uBAAuB,EAIvB,WAAW,EACX,iBAAiB,EAIjB,UAAU,EACb,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AACnE,OAAO,EAAE,uBAAuB,EAAE,MAAM,uCAAuC,CAAC;AAChF,OAAO,EAEH,eAAe,EAClB,MAAM,8BAA8B,CAAC;AAGtC,OAAO,EAAE,iBAAiB,EAAE,MAAM,iCAAiC,CAAC;AAEpE,OAAO,EAAE,eAAe,EAAE,MAAM,+BAA+B,CAAC;AAChE,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAC;AAKlE;;GAEG;AACH,8BAAsB,yBAA0B,SAAQ,qBAAqB;IACzE;;;OAGG;cACa,kCAAkC,CAC9C,OAAO,EAAE,uBAAuB,GACjC,OAAO,CAAC,8BAA8B,CAAC;IA0B1C;;;OAGG;IACH,SAAS,CAAC,uBAAuB,CAC7B,aAAa,CAAC,EAAE,iBAAiB,GAClC,uBAAuB;IA+F1B;;;;OAIG;IACH,SAAS,CAAC,8BAA8B,CACpC,OAAO,EAAE,WAAW,GACrB,MAAM,GAAG,IAAI;IAmBhB;;;;;;;;;OASG;cACa,oBAAoB,CAAC,MAAM,EAAE;QACzC,sBAAsB,EAAE,sBAAsB,CAAC;QAC/C,gBAAgB,CAAC,EAAE,MAAM,CAAC;QAC1B,wBAAwB,CAAC,EAAE,iBAAiB,CAAC;QAC7C,2BAA2B,CAAC,EAAE,UAAU,CAAC;QACzC,OAAO,CAAC,EAAE,WAAW,CAAC;KACzB,GAAG,OAAO,CAAC,uBAAuB,CAAC;IAoBpC;;;;;;;;;OASG;cACa,sBAAsB,CAAC,MAAM,EAAE;QAC3C,sBAAsB,EAAE,sBAAsB,CAAC;QAC/C,gBAAgB,CAAC,EAAE,MAAM,CAAC;QAC1B,wBAAwB,CAAC,EAAE,iBAAiB,CAAC;QAC7C,2BAA2B,CAAC,EAAE,UAAU,CAAC;QACzC,OAAO,CAAC,EAAE,WAAW,CAAC;KACzB,GAAG,OAAO,CAAC,mBAAmB,CAAC;IA8DhC;;;;OAIG;cACa,8BAA8B,CAC1C,OAAO,EAAE,eAAe,GAAG,YAAY,GAAG,gBAAgB,EAC1D,eAAe,EAAE,eAAe,GACjC,OAAO,CAAC,uBAAuB,CAAC;CA8DtC"}
@@ -0,0 +1,34 @@
1
+ import { AuthorizationCodePayload, CommonAuthorizationCodeRequest, AuthorizationCodeClient, CcsCredential, Logger, IPerformanceClient, ServerAuthorizationCodeResponse } from "@azure/msal-common/browser";
2
+ import { BrowserCacheManager } from "../cache/BrowserCacheManager.js";
3
+ import { AuthenticationResult } from "../response/AuthenticationResult.js";
4
+ import { AuthorizationUrlRequest } from "../request/AuthorizationUrlRequest.js";
5
+ /**
6
+ * Abstract class which defines operations for a browser interaction handling class.
7
+ */
8
+ export declare class InteractionHandler {
9
+ protected authModule: AuthorizationCodeClient;
10
+ protected browserStorage: BrowserCacheManager;
11
+ protected authCodeRequest: CommonAuthorizationCodeRequest;
12
+ protected logger: Logger;
13
+ protected performanceClient: IPerformanceClient;
14
+ constructor(authCodeModule: AuthorizationCodeClient, storageImpl: BrowserCacheManager, authCodeRequest: CommonAuthorizationCodeRequest, logger: Logger, performanceClient: IPerformanceClient);
15
+ /**
16
+ * Function to handle response parameters from hash.
17
+ * @param locationHash
18
+ */
19
+ handleCodeResponse(response: ServerAuthorizationCodeResponse, request: AuthorizationUrlRequest): Promise<AuthenticationResult>;
20
+ /**
21
+ * Process auth code response from AAD
22
+ * @param authCodeResponse
23
+ * @param state
24
+ * @param authority
25
+ * @param networkModule
26
+ * @returns
27
+ */
28
+ handleCodeResponseFromServer(authCodeResponse: AuthorizationCodePayload, request: AuthorizationUrlRequest, validateNonce?: boolean): Promise<AuthenticationResult>;
29
+ /**
30
+ * Build ccs creds if available
31
+ */
32
+ protected createCcsCredentials(request: AuthorizationUrlRequest): CcsCredential | null;
33
+ }
34
+ //# sourceMappingURL=InteractionHandler.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InteractionHandler.d.ts","sourceRoot":"","sources":["../../../src/interaction_handler/InteractionHandler.ts"],"names":[],"mappings":"AAKA,OAAO,EACH,wBAAwB,EACxB,8BAA8B,EAC9B,uBAAuB,EACvB,aAAa,EACb,MAAM,EAEN,kBAAkB,EAIlB,+BAA+B,EAClC,MAAM,4BAA4B,CAAC;AAEpC,OAAO,EAAE,mBAAmB,EAAE,MAAM,iCAAiC,CAAC;AAKtE,OAAO,EAAE,oBAAoB,EAAE,MAAM,qCAAqC,CAAC;AAC3E,OAAO,EAAE,uBAAuB,EAAE,MAAM,uCAAuC,CAAC;AAEhF;;GAEG;AACH,qBAAa,kBAAkB;IAC3B,SAAS,CAAC,UAAU,EAAE,uBAAuB,CAAC;IAC9C,SAAS,CAAC,cAAc,EAAE,mBAAmB,CAAC;IAC9C,SAAS,CAAC,eAAe,EAAE,8BAA8B,CAAC;IAC1D,SAAS,CAAC,MAAM,EAAE,MAAM,CAAC;IACzB,SAAS,CAAC,iBAAiB,EAAE,kBAAkB,CAAC;gBAG5C,cAAc,EAAE,uBAAuB,EACvC,WAAW,EAAE,mBAAmB,EAChC,eAAe,EAAE,8BAA8B,EAC/C,MAAM,EAAE,MAAM,EACd,iBAAiB,EAAE,kBAAkB;IASzC;;;OAGG;IACG,kBAAkB,CACpB,QAAQ,EAAE,+BAA+B,EACzC,OAAO,EAAE,uBAAuB,GACjC,OAAO,CAAC,oBAAoB,CAAC;IAmChC;;;;;;;OAOG;IACG,4BAA4B,CAC9B,gBAAgB,EAAE,wBAAwB,EAC1C,OAAO,EAAE,uBAAuB,EAChC,aAAa,GAAE,OAAc,GAC9B,OAAO,CAAC,oBAAoB,CAAC;IAoDhC;;OAEG;IACH,SAAS,CAAC,oBAAoB,CAC1B,OAAO,EAAE,uBAAuB,GACjC,aAAa,GAAG,IAAI;CAe1B"}
@@ -0,0 +1,33 @@
1
+ import { AuthorizationCodeClient, CommonAuthorizationCodeRequest, Logger, IPerformanceClient, CcsCredential, ServerAuthorizationCodeResponse } from "@azure/msal-common/browser";
2
+ import { BrowserCacheManager } from "../cache/BrowserCacheManager.js";
3
+ import { INavigationClient } from "../navigation/INavigationClient.js";
4
+ import { AuthenticationResult } from "../response/AuthenticationResult.js";
5
+ export type RedirectParams = {
6
+ navigationClient: INavigationClient;
7
+ redirectTimeout: number;
8
+ redirectStartPage: string;
9
+ onRedirectNavigate?: (url: string) => void | boolean;
10
+ };
11
+ export declare class RedirectHandler {
12
+ authModule: AuthorizationCodeClient;
13
+ browserStorage: BrowserCacheManager;
14
+ authCodeRequest: CommonAuthorizationCodeRequest;
15
+ logger: Logger;
16
+ performanceClient: IPerformanceClient;
17
+ constructor(authCodeModule: AuthorizationCodeClient, storageImpl: BrowserCacheManager, authCodeRequest: CommonAuthorizationCodeRequest, logger: Logger, performanceClient: IPerformanceClient);
18
+ /**
19
+ * Redirects window to given URL.
20
+ * @param urlNavigate
21
+ */
22
+ initiateAuthRequest(requestUrl: string, params: RedirectParams): Promise<void>;
23
+ /**
24
+ * Handle authorization code response in the window.
25
+ * @param hash
26
+ */
27
+ handleCodeResponse(response: ServerAuthorizationCodeResponse, state: string): Promise<AuthenticationResult>;
28
+ /**
29
+ * Looks up ccs creds in the cache
30
+ */
31
+ protected checkCcsCredentials(): CcsCredential | null;
32
+ }
33
+ //# sourceMappingURL=RedirectHandler.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RedirectHandler.d.ts","sourceRoot":"","sources":["../../../src/interaction_handler/RedirectHandler.ts"],"names":[],"mappings":"AAKA,OAAO,EACH,uBAAuB,EACvB,8BAA8B,EAC9B,MAAM,EAEN,kBAAkB,EAGlB,aAAa,EAGb,+BAA+B,EAClC,MAAM,4BAA4B,CAAC;AAMpC,OAAO,EAAE,mBAAmB,EAAE,MAAM,iCAAiC,CAAC;AACtE,OAAO,EAAE,iBAAiB,EAAE,MAAM,oCAAoC,CAAC;AAEvE,OAAO,EAAE,oBAAoB,EAAE,MAAM,qCAAqC,CAAC;AAE3E,MAAM,MAAM,cAAc,GAAG;IACzB,gBAAgB,EAAE,iBAAiB,CAAC;IACpC,eAAe,EAAE,MAAM,CAAC;IACxB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,kBAAkB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC;CACxD,CAAC;AAEF,qBAAa,eAAe;IACxB,UAAU,EAAE,uBAAuB,CAAC;IACpC,cAAc,EAAE,mBAAmB,CAAC;IACpC,eAAe,EAAE,8BAA8B,CAAC;IAChD,MAAM,EAAE,MAAM,CAAC;IACf,iBAAiB,EAAE,kBAAkB,CAAC;gBAGlC,cAAc,EAAE,uBAAuB,EACvC,WAAW,EAAE,mBAAmB,EAChC,eAAe,EAAE,8BAA8B,EAC/C,MAAM,EAAE,MAAM,EACd,iBAAiB,EAAE,kBAAkB;IASzC;;;OAGG;IACG,mBAAmB,CACrB,UAAU,EAAE,MAAM,EAClB,MAAM,EAAE,cAAc,GACvB,OAAO,CAAC,IAAI,CAAC;IA6EhB;;;OAGG;IACG,kBAAkB,CACpB,QAAQ,EAAE,+BAA+B,EACzC,KAAK,EAAE,MAAM,GACd,OAAO,CAAC,oBAAoB,CAAC;IAgFhC;;OAEG;IACH,SAAS,CAAC,mBAAmB,IAAI,aAAa,GAAG,IAAI;CAoBxD"}
@@ -0,0 +1,14 @@
1
+ import { Logger, IPerformanceClient, ServerResponseType } from "@azure/msal-common/browser";
2
+ /**
3
+ * Creates a hidden iframe to given URL using user-requested scopes as an id.
4
+ * @param urlNavigate
5
+ * @param userRequestScopes
6
+ */
7
+ export declare function initiateAuthRequest(requestUrl: string, performanceClient: IPerformanceClient, logger: Logger, correlationId: string, navigateFrameWait?: number): Promise<HTMLIFrameElement>;
8
+ /**
9
+ * Monitors an iframe content window until it loads a url with a known hash, or hits a specified timeout.
10
+ * @param iframe
11
+ * @param timeout
12
+ */
13
+ export declare function monitorIframeForHash(iframe: HTMLIFrameElement, timeout: number, pollIntervalMilliseconds: number, performanceClient: IPerformanceClient, logger: Logger, correlationId: string, responseType: ServerResponseType): Promise<string>;
14
+ //# sourceMappingURL=SilentHandler.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SilentHandler.d.ts","sourceRoot":"","sources":["../../../src/interaction_handler/SilentHandler.ts"],"names":[],"mappings":"AAKA,OAAO,EACH,MAAM,EACN,kBAAkB,EAIlB,kBAAkB,EACrB,MAAM,4BAA4B,CAAC;AAOpC;;;;GAIG;AACH,wBAAsB,mBAAmB,CACrC,UAAU,EAAE,MAAM,EAClB,iBAAiB,EAAE,kBAAkB,EACrC,MAAM,EAAE,MAAM,EACd,aAAa,EAAE,MAAM,EACrB,iBAAiB,CAAC,EAAE,MAAM,GAC3B,OAAO,CAAC,iBAAiB,CAAC,CA2B5B;AAED;;;;GAIG;AACH,wBAAsB,oBAAoB,CACtC,MAAM,EAAE,iBAAiB,EACzB,OAAO,EAAE,MAAM,EACf,wBAAwB,EAAE,MAAM,EAChC,iBAAiB,EAAE,kBAAkB,EACrC,MAAM,EAAE,MAAM,EACd,aAAa,EAAE,MAAM,EACrB,YAAY,EAAE,kBAAkB,GACjC,OAAO,CAAC,MAAM,CAAC,CA+DjB"}
@@ -0,0 +1,12 @@
1
+ export type AccountInfo = {
2
+ homeAccountId?: string;
3
+ environment: string;
4
+ tenantId?: string;
5
+ username: string;
6
+ localAccountId?: string;
7
+ name?: string;
8
+ idToken?: string;
9
+ platformBrokerId?: string;
10
+ idTokenClaims?: object;
11
+ };
12
+ //# sourceMappingURL=AccountInfo.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AccountInfo.d.ts","sourceRoot":"","sources":["../../../src/naa/AccountInfo.ts"],"names":[],"mappings":"AAKA,MAAM,MAAM,WAAW,GAAG;IACtB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,aAAa,CAAC,EAAE,MAAM,CAAC;CAC1B,CAAC"}
@@ -0,0 +1,9 @@
1
+ export type AuthBridgeResponse = string | {
2
+ data: string;
3
+ };
4
+ export interface AuthBridge {
5
+ addEventListener: (eventName: string, callback: (response: AuthBridgeResponse) => void) => void;
6
+ postMessage: (message: string) => void;
7
+ removeEventListener: (eventName: string, callback: (response: AuthBridgeResponse) => void) => void;
8
+ }
9
+ //# sourceMappingURL=AuthBridge.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AuthBridge.d.ts","sourceRoot":"","sources":["../../../src/naa/AuthBridge.ts"],"names":[],"mappings":"AAKA,MAAM,MAAM,kBAAkB,GAAG,MAAM,GAAG;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC;AAC3D,MAAM,WAAW,UAAU;IACvB,gBAAgB,EAAE,CACd,SAAS,EAAE,MAAM,EACjB,QAAQ,EAAE,CAAC,QAAQ,EAAE,kBAAkB,KAAK,IAAI,KAC/C,IAAI,CAAC;IACV,WAAW,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACvC,mBAAmB,EAAE,CACjB,SAAS,EAAE,MAAM,EACjB,QAAQ,EAAE,CAAC,QAAQ,EAAE,kBAAkB,KAAK,IAAI,KAC/C,IAAI,CAAC;CACb"}
@@ -0,0 +1,7 @@
1
+ import { AccountInfo } from "./AccountInfo.js";
2
+ import { TokenResponse } from "./TokenResponse.js";
3
+ export type AuthResult = {
4
+ token: TokenResponse;
5
+ account: AccountInfo;
6
+ };
7
+ //# sourceMappingURL=AuthResult.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AuthResult.d.ts","sourceRoot":"","sources":["../../../src/naa/AuthResult.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAEnD,MAAM,MAAM,UAAU,GAAG;IACrB,KAAK,EAAE,aAAa,CAAC;IACrB,OAAO,EAAE,WAAW,CAAC;CACxB,CAAC"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * AccountContext is used to pass account information when the bridge is initialized
3
+ *
4
+ * NAA (MetaOS) apps are created and destroyed for the same session multiple times.
5
+ * `AccountContext` helps in booting up the cached account when the bridge
6
+ * is recreated for a new NAA instance in the same auth session.
7
+ */
8
+ export interface AccountContext {
9
+ homeAccountId: string;
10
+ environment: string;
11
+ tenantId: string;
12
+ }
13
+ //# sourceMappingURL=BridgeAccountContext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BridgeAccountContext.d.ts","sourceRoot":"","sources":["../../../src/naa/BridgeAccountContext.ts"],"names":[],"mappings":"AAKA;;;;;;GAMG;AACH,MAAM,WAAW,cAAc;IAC3B,aAAa,EAAE,MAAM,CAAC;IACtB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;CACpB"}
@@ -0,0 +1,4 @@
1
+ export interface BridgeCapabilities {
2
+ queryAccount?: boolean;
3
+ }
4
+ //# sourceMappingURL=BridgeCapabilities.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BridgeCapabilities.d.ts","sourceRoot":"","sources":["../../../src/naa/BridgeCapabilities.ts"],"names":[],"mappings":"AAMA,MAAM,WAAW,kBAAkB;IAC/B,YAAY,CAAC,EAAE,OAAO,CAAC;CAC1B"}
@@ -0,0 +1,10 @@
1
+ import { BridgeStatusCode } from "./BridgeStatusCode.js";
2
+ export type BridgeError = {
3
+ status: BridgeStatusCode;
4
+ code?: string;
5
+ subError?: string;
6
+ description?: string;
7
+ properties?: object;
8
+ };
9
+ export declare function isBridgeError(error: unknown): error is BridgeError;
10
+ //# sourceMappingURL=BridgeError.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BridgeError.d.ts","sourceRoot":"","sources":["../../../src/naa/BridgeError.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAEzD,MAAM,MAAM,WAAW,GAAG;IACtB,MAAM,EAAE,gBAAgB,CAAC;IACzB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,MAAM,CAAC;CACvB,CAAC;AAEF,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,WAAW,CAElE"}
@@ -0,0 +1,69 @@
1
+ import { AuthBridge } from "./AuthBridge.js";
2
+ import { AuthResult } from "./AuthResult.js";
3
+ import { BridgeCapabilities } from "./BridgeCapabilities.js";
4
+ import { AccountContext } from "./BridgeAccountContext.js";
5
+ import { BridgeRequest } from "./BridgeRequest.js";
6
+ import { IBridgeProxy } from "./IBridgeProxy.js";
7
+ import { InitContext } from "./InitContext.js";
8
+ import { TokenRequest } from "./TokenRequest.js";
9
+ declare global {
10
+ interface Window {
11
+ nestedAppAuthBridge: AuthBridge;
12
+ }
13
+ }
14
+ /**
15
+ * BridgeProxy
16
+ * Provides a proxy for accessing a bridge to a host app and/or
17
+ * platform broker
18
+ */
19
+ export declare class BridgeProxy implements IBridgeProxy {
20
+ static bridgeRequests: BridgeRequest[];
21
+ sdkName: string;
22
+ sdkVersion: string;
23
+ capabilities?: BridgeCapabilities;
24
+ accountContext?: AccountContext;
25
+ /**
26
+ * initializeNestedAppAuthBridge - Initializes the bridge to the host app
27
+ * @returns a promise that resolves to an InitializeBridgeResponse or rejects with an Error
28
+ * @remarks This method will be called by the create factory method
29
+ * @remarks If the bridge is not available, this method will throw an error
30
+ */
31
+ protected static initializeNestedAppAuthBridge(): Promise<InitContext>;
32
+ /**
33
+ * getTokenInteractive - Attempts to get a token interactively from the bridge
34
+ * @param request A token request
35
+ * @returns a promise that resolves to an auth result or rejects with a BridgeError
36
+ */
37
+ getTokenInteractive(request: TokenRequest): Promise<AuthResult>;
38
+ /**
39
+ * getTokenSilent Attempts to get a token silently from the bridge
40
+ * @param request A token request
41
+ * @returns a promise that resolves to an auth result or rejects with a BridgeError
42
+ */
43
+ getTokenSilent(request: TokenRequest): Promise<AuthResult>;
44
+ private getToken;
45
+ getHostCapabilities(): BridgeCapabilities | null;
46
+ getAccountContext(): AccountContext | null;
47
+ private static buildRequest;
48
+ /**
49
+ * A method used to send a request to the bridge
50
+ * @param request A token request
51
+ * @returns a promise that resolves to a response of provided type or rejects with a BridgeError
52
+ */
53
+ private sendRequest;
54
+ private static validateBridgeResultOrThrow;
55
+ /**
56
+ * Private constructor for BridgeProxy
57
+ * @param sdkName The name of the SDK being used to make requests on behalf of the app
58
+ * @param sdkVersion The version of the SDK being used to make requests on behalf of the app
59
+ * @param capabilities The capabilities of the bridge / SDK / platform broker
60
+ */
61
+ private constructor();
62
+ /**
63
+ * Factory method for creating an implementation of IBridgeProxy
64
+ * @returns A promise that resolves to a BridgeProxy implementation
65
+ */
66
+ static create(): Promise<IBridgeProxy>;
67
+ }
68
+ export default BridgeProxy;
69
+ //# sourceMappingURL=BridgeProxy.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BridgeProxy.d.ts","sourceRoot":"","sources":["../../../src/naa/BridgeProxy.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,UAAU,EAAsB,MAAM,iBAAiB,CAAC;AACjE,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAE3D,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAOnD,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAKjD,OAAO,CAAC,MAAM,CAAC;IACX,UAAU,MAAM;QACZ,mBAAmB,EAAE,UAAU,CAAC;KACnC;CACJ;AAED;;;;GAIG;AACH,qBAAa,WAAY,YAAW,YAAY;IAC5C,MAAM,CAAC,cAAc,EAAE,aAAa,EAAE,CAAM;IAC5C,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,kBAAkB,CAAC;IAClC,cAAc,CAAC,EAAE,cAAc,CAAC;IAEhC;;;;;OAKG;qBACoB,6BAA6B,IAAI,OAAO,CAAC,WAAW,CAAC;IA4D5E;;;;OAIG;IACI,mBAAmB,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,UAAU,CAAC;IAItE;;;;OAIG;IACI,cAAc,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,UAAU,CAAC;YAInD,QAAQ;IAaf,mBAAmB,IAAI,kBAAkB,GAAG,IAAI;IAIhD,iBAAiB,IAAI,cAAc,GAAG,IAAI;IAIjD,OAAO,CAAC,MAAM,CAAC,YAAY;IAe3B;;;;OAIG;IACH,OAAO,CAAC,WAAW;IAsBnB,OAAO,CAAC,MAAM,CAAC,2BAA2B;IAU1C;;;;;OAKG;IACH,OAAO;IAYP;;;OAGG;WACiB,MAAM,IAAI,OAAO,CAAC,YAAY,CAAC;CAStD;AAED,eAAe,WAAW,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { BridgeResponseEnvelope } from "./BridgeResponseEnvelope.js";
2
+ export type BridgeRequest = {
3
+ requestId: string;
4
+ method: string;
5
+ resolve: (value: BridgeResponseEnvelope | PromiseLike<BridgeResponseEnvelope>) => void;
6
+ reject: (reason?: any) => void;
7
+ };
8
+ //# sourceMappingURL=BridgeRequest.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BridgeRequest.d.ts","sourceRoot":"","sources":["../../../src/naa/BridgeRequest.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AAErE,MAAM,MAAM,aAAa,GAAG;IACxB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,CACL,KAAK,EAAE,sBAAsB,GAAG,WAAW,CAAC,sBAAsB,CAAC,KAClE,IAAI,CAAC;IAEV,MAAM,EAAE,CAAC,MAAM,CAAC,EAAE,GAAG,KAAK,IAAI,CAAC;CAClC,CAAC"}
@@ -0,0 +1,13 @@
1
+ import { TokenRequest } from "./TokenRequest.js";
2
+ export type BridgeMethods = "GetToken" | "GetInitContext" | "GetTokenPopup";
3
+ export type BridgeRequestEnvelope = {
4
+ messageType: "NestedAppAuthRequest";
5
+ method: BridgeMethods;
6
+ sendTime?: number;
7
+ clientLibrary?: string;
8
+ clientLibraryVersion?: string;
9
+ requestId: string;
10
+ tokenParams?: TokenRequest;
11
+ };
12
+ export declare function isBridgeRequestEnvelope(obj: unknown): obj is BridgeRequestEnvelope;
13
+ //# sourceMappingURL=BridgeRequestEnvelope.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BridgeRequestEnvelope.d.ts","sourceRoot":"","sources":["../../../src/naa/BridgeRequestEnvelope.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEjD,MAAM,MAAM,aAAa,GAAG,UAAU,GAAG,gBAAgB,GAAG,eAAe,CAAC;AAE5E,MAAM,MAAM,qBAAqB,GAAG;IAChC,WAAW,EAAE,sBAAsB,CAAC;IACpC,MAAM,EAAE,aAAa,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,YAAY,CAAC;CAC9B,CAAC;AAEF,wBAAgB,uBAAuB,CACnC,GAAG,EAAE,OAAO,GACb,GAAG,IAAI,qBAAqB,CAO9B"}
@@ -0,0 +1,14 @@
1
+ import { BridgeError } from "./BridgeError.js";
2
+ import { TokenResponse } from "./TokenResponse.js";
3
+ import { AccountInfo } from "./AccountInfo.js";
4
+ import { InitContext } from "./InitContext.js";
5
+ export type BridgeResponseEnvelope = {
6
+ messageType: "NestedAppAuthResponse";
7
+ requestId: string;
8
+ success: boolean;
9
+ token?: TokenResponse;
10
+ error?: BridgeError;
11
+ account?: AccountInfo;
12
+ initContext?: InitContext;
13
+ };
14
+ //# sourceMappingURL=BridgeResponseEnvelope.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BridgeResponseEnvelope.d.ts","sourceRoot":"","sources":["../../../src/naa/BridgeResponseEnvelope.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAE/C,MAAM,MAAM,sBAAsB,GAAG;IACjC,WAAW,EAAE,uBAAuB,CAAC;IACrC,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,OAAO,CAAC;IACjB,KAAK,CAAC,EAAE,aAAa,CAAC;IACtB,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB,WAAW,CAAC,EAAE,WAAW,CAAC;CAC7B,CAAC"}
@@ -0,0 +1,12 @@
1
+ export declare const BridgeStatusCode: {
2
+ readonly UserInteractionRequired: "USER_INTERACTION_REQUIRED";
3
+ readonly UserCancel: "USER_CANCEL";
4
+ readonly NoNetwork: "NO_NETWORK";
5
+ readonly TransientError: "TRANSIENT_ERROR";
6
+ readonly PersistentError: "PERSISTENT_ERROR";
7
+ readonly Disabled: "DISABLED";
8
+ readonly AccountUnavailable: "ACCOUNT_UNAVAILABLE";
9
+ readonly NestedAppAuthUnavailable: "NESTED_APP_AUTH_UNAVAILABLE";
10
+ };
11
+ export type BridgeStatusCode = (typeof BridgeStatusCode)[keyof typeof BridgeStatusCode];
12
+ //# sourceMappingURL=BridgeStatusCode.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BridgeStatusCode.d.ts","sourceRoot":"","sources":["../../../src/naa/BridgeStatusCode.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,gBAAgB;;;;;;;;;CASnB,CAAC;AACX,MAAM,MAAM,gBAAgB,GACxB,CAAC,OAAO,gBAAgB,CAAC,CAAC,MAAM,OAAO,gBAAgB,CAAC,CAAC"}
@@ -0,0 +1,11 @@
1
+ import { AuthResult } from "./AuthResult.js";
2
+ import { AccountContext } from "./BridgeAccountContext.js";
3
+ import { BridgeCapabilities } from "./BridgeCapabilities.js";
4
+ import { TokenRequest } from "./TokenRequest.js";
5
+ export interface IBridgeProxy {
6
+ getTokenInteractive(request: TokenRequest): Promise<AuthResult>;
7
+ getTokenSilent(request: TokenRequest): Promise<AuthResult>;
8
+ getHostCapabilities(): BridgeCapabilities | null;
9
+ getAccountContext(): AccountContext | null;
10
+ }
11
+ //# sourceMappingURL=IBridgeProxy.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IBridgeProxy.d.ts","sourceRoot":"","sources":["../../../src/naa/IBridgeProxy.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEjD,MAAM,WAAW,YAAY;IACzB,mBAAmB,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;IAChE,cAAc,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;IAC3D,mBAAmB,IAAI,kBAAkB,GAAG,IAAI,CAAC;IACjD,iBAAiB,IAAI,cAAc,GAAG,IAAI,CAAC;CAC9C"}
@@ -0,0 +1,9 @@
1
+ import { BridgeCapabilities } from "./BridgeCapabilities.js";
2
+ import { AccountContext } from "./BridgeAccountContext.js";
3
+ export interface InitContext {
4
+ capabilities?: BridgeCapabilities;
5
+ sdkName: string;
6
+ sdkVersion: string;
7
+ accountContext?: AccountContext;
8
+ }
9
+ //# sourceMappingURL=InitContext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InitContext.d.ts","sourceRoot":"","sources":["../../../src/naa/InitContext.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAE3D,MAAM,WAAW,WAAW;IACxB,YAAY,CAAC,EAAE,kBAAkB,CAAC;IAClC,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,CAAC,EAAE,cAAc,CAAC;CACnC"}
@@ -0,0 +1,19 @@
1
+ export type TokenRequest = {
2
+ platformBrokerId?: string;
3
+ clientId: string;
4
+ authority?: string;
5
+ scope: string;
6
+ correlationId: string;
7
+ claims?: string;
8
+ state?: string;
9
+ reqCnf?: string;
10
+ keyId?: string;
11
+ authenticationScheme?: string;
12
+ shrClaims?: string;
13
+ shrNonce?: string;
14
+ resourceRequestMethod?: string;
15
+ resourceRequestUri?: string;
16
+ extendedExpiryToken?: boolean;
17
+ extraParameters?: Map<string, string>;
18
+ };
19
+ //# sourceMappingURL=TokenRequest.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TokenRequest.d.ts","sourceRoot":"","sources":["../../../src/naa/TokenRequest.ts"],"names":[],"mappings":"AAKA,MAAM,MAAM,YAAY,GAAG;IACvB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,aAAa,EAAE,MAAM,CAAC;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,eAAe,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACzC,CAAC"}
@@ -0,0 +1,14 @@
1
+ export type TokenResponse = {
2
+ access_token: string;
3
+ expires_in: number;
4
+ id_token: string;
5
+ properties: TokenResponseProperties | null;
6
+ scope?: string;
7
+ shr?: string;
8
+ extendedLifetimeToken?: boolean;
9
+ authority?: string;
10
+ };
11
+ export type TokenResponseProperties = {
12
+ MATS?: string;
13
+ };
14
+ //# sourceMappingURL=TokenResponse.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TokenResponse.d.ts","sourceRoot":"","sources":["../../../src/naa/TokenResponse.ts"],"names":[],"mappings":"AAKA,MAAM,MAAM,aAAa,GAAG;IACxB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,uBAAuB,GAAG,IAAI,CAAC;IAC3C,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,MAAM,MAAM,uBAAuB,GAAG;IAClC,IAAI,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC"}
@@ -0,0 +1,36 @@
1
+ import { TokenRequest } from "../TokenRequest.js";
2
+ import { AccountInfo as NaaAccountInfo } from "../AccountInfo.js";
3
+ import { RedirectRequest } from "../../request/RedirectRequest.js";
4
+ import { PopupRequest } from "../../request/PopupRequest.js";
5
+ import { AccountInfo as MsalAccountInfo, AuthError, ClientAuthError, ClientConfigurationError, InteractionRequiredAuthError, ServerError, ICrypto, Logger, TokenClaims, AccountInfo, IdTokenEntity, AccessTokenEntity } from "@azure/msal-common/browser";
6
+ import { AuthenticationResult } from "../../response/AuthenticationResult.js";
7
+ import { AuthResult } from "../AuthResult.js";
8
+ import { SsoSilentRequest } from "../../request/SsoSilentRequest.js";
9
+ import { SilentRequest } from "../../request/SilentRequest.js";
10
+ export declare class NestedAppAuthAdapter {
11
+ protected crypto: ICrypto;
12
+ protected logger: Logger;
13
+ protected clientId: string;
14
+ protected clientCapabilities: string[];
15
+ constructor(clientId: string, clientCapabilities: string[], crypto: ICrypto, logger: Logger);
16
+ toNaaTokenRequest(request: PopupRequest | RedirectRequest | SilentRequest | SsoSilentRequest): TokenRequest;
17
+ fromNaaTokenResponse(request: TokenRequest, response: AuthResult, reqTimestamp: number): AuthenticationResult;
18
+ fromNaaAccountInfo(fromAccount: NaaAccountInfo, idToken?: string, idTokenClaims?: TokenClaims): MsalAccountInfo;
19
+ /**
20
+ *
21
+ * @param error BridgeError
22
+ * @returns AuthError, ClientAuthError, ClientConfigurationError, ServerError, InteractionRequiredError
23
+ */
24
+ fromBridgeError(error: unknown): AuthError | ClientAuthError | ClientConfigurationError | ServerError | InteractionRequiredAuthError;
25
+ /**
26
+ * Returns an AuthenticationResult from the given cache items
27
+ *
28
+ * @param account
29
+ * @param idToken
30
+ * @param accessToken
31
+ * @param reqTimestamp
32
+ * @returns
33
+ */
34
+ toAuthenticationResultFromCache(account: AccountInfo, idToken: IdTokenEntity, accessToken: AccessTokenEntity, request: SilentRequest, correlationId: string): AuthenticationResult;
35
+ }
36
+ //# sourceMappingURL=NestedAppAuthAdapter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NestedAppAuthAdapter.d.ts","sourceRoot":"","sources":["../../../../src/naa/mapping/NestedAppAuthAdapter.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,WAAW,IAAI,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAClE,OAAO,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAC;AACnE,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAC7D,OAAO,EACH,WAAW,IAAI,eAAe,EAC9B,SAAS,EACT,eAAe,EACf,wBAAwB,EACxB,4BAA4B,EAC5B,WAAW,EACX,OAAO,EACP,MAAM,EAEN,WAAW,EAOX,WAAW,EACX,aAAa,EACb,iBAAiB,EAGpB,MAAM,4BAA4B,CAAC;AAGpC,OAAO,EAAE,oBAAoB,EAAE,MAAM,wCAAwC,CAAC;AAE9E,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAE/D,qBAAa,oBAAoB;IAC7B,SAAS,CAAC,MAAM,EAAE,OAAO,CAAC;IAC1B,SAAS,CAAC,MAAM,EAAE,MAAM,CAAC;IACzB,SAAS,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC3B,SAAS,CAAC,kBAAkB,EAAE,MAAM,EAAE,CAAC;gBAGnC,QAAQ,EAAE,MAAM,EAChB,kBAAkB,EAAE,MAAM,EAAE,EAC5B,MAAM,EAAE,OAAO,EACf,MAAM,EAAE,MAAM;IAQX,iBAAiB,CACpB,OAAO,EACD,YAAY,GACZ,eAAe,GACf,aAAa,GACb,gBAAgB,GACvB,YAAY;IAmCR,oBAAoB,CACvB,OAAO,EAAE,YAAY,EACrB,QAAQ,EAAE,UAAU,EACpB,YAAY,EAAE,MAAM,GACrB,oBAAoB;IA8DhB,kBAAkB,CACrB,WAAW,EAAE,cAAc,EAC3B,OAAO,CAAC,EAAE,MAAM,EAChB,aAAa,CAAC,EAAE,WAAW,GAC5B,eAAe;IAgDlB;;;;OAIG;IACI,eAAe,CAClB,KAAK,EAAE,OAAO,GAEZ,SAAS,GACT,eAAe,GACf,wBAAwB,GACxB,WAAW,GACX,4BAA4B;IAyClC;;;;;;;;OAQG;IACI,+BAA+B,CAClC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,aAAa,EACtB,WAAW,EAAE,iBAAiB,EAC9B,OAAO,EAAE,aAAa,EACtB,aAAa,EAAE,MAAM,GACtB,oBAAoB;CAkC1B"}
@@ -0,0 +1,17 @@
1
+ import { NavigationOptions } from "./NavigationOptions.js";
2
+ export interface INavigationClient {
3
+ /**
4
+ * Navigates to other pages within the same web application
5
+ * Return false if this doesn't cause the page to reload i.e. Client-side navigation
6
+ * @param url
7
+ * @param options
8
+ */
9
+ navigateInternal(url: string, options: NavigationOptions): Promise<boolean>;
10
+ /**
11
+ * Navigates to other pages outside the web application i.e. the Identity Provider
12
+ * @param url
13
+ * @param options
14
+ */
15
+ navigateExternal(url: string, options: NavigationOptions): Promise<boolean>;
16
+ }
17
+ //# sourceMappingURL=INavigationClient.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"INavigationClient.d.ts","sourceRoot":"","sources":["../../../src/navigation/INavigationClient.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAE3D,MAAM,WAAW,iBAAiB;IAC9B;;;;;OAKG;IACH,gBAAgB,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE,iBAAiB,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;IAE5E;;;;OAIG;IACH,gBAAgB,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE,iBAAiB,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;CAC/E"}
@@ -0,0 +1,23 @@
1
+ import { INavigationClient } from "./INavigationClient.js";
2
+ import { NavigationOptions } from "./NavigationOptions.js";
3
+ export declare class NavigationClient implements INavigationClient {
4
+ /**
5
+ * Navigates to other pages within the same web application
6
+ * @param url
7
+ * @param options
8
+ */
9
+ navigateInternal(url: string, options: NavigationOptions): Promise<boolean>;
10
+ /**
11
+ * Navigates to other pages outside the web application i.e. the Identity Provider
12
+ * @param url
13
+ * @param options
14
+ */
15
+ navigateExternal(url: string, options: NavigationOptions): Promise<boolean>;
16
+ /**
17
+ * Default navigation implementation invoked by the internal and external functions
18
+ * @param url
19
+ * @param options
20
+ */
21
+ private static defaultNavigateWindow;
22
+ }
23
+ //# sourceMappingURL=NavigationClient.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NavigationClient.d.ts","sourceRoot":"","sources":["../../../src/navigation/NavigationClient.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAE3D,qBAAa,gBAAiB,YAAW,iBAAiB;IACtD;;;;OAIG;IACH,gBAAgB,CACZ,GAAG,EAAE,MAAM,EACX,OAAO,EAAE,iBAAiB,GAC3B,OAAO,CAAC,OAAO,CAAC;IAInB;;;;OAIG;IACH,gBAAgB,CACZ,GAAG,EAAE,MAAM,EACX,OAAO,EAAE,iBAAiB,GAC3B,OAAO,CAAC,OAAO,CAAC;IAInB;;;;OAIG;IACH,OAAO,CAAC,MAAM,CAAC,qBAAqB;CAgBvC"}
@@ -0,0 +1,13 @@
1
+ import { ApiId } from "../utils/BrowserConstants.js";
2
+ /**
3
+ * Additional information passed to the navigateInternal and navigateExternal functions
4
+ */
5
+ export type NavigationOptions = {
6
+ /** The Id of the API that initiated navigation */
7
+ apiId: ApiId;
8
+ /** Suggested timeout (ms) based on the configuration provided to PublicClientApplication */
9
+ timeout: number;
10
+ /** When set to true the url should not be added to the browser history */
11
+ noHistory: boolean;
12
+ };
13
+ //# sourceMappingURL=NavigationOptions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"NavigationOptions.d.ts","sourceRoot":"","sources":["../../../src/navigation/NavigationOptions.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAC;AAErD;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC5B,kDAAkD;IAClD,KAAK,EAAE,KAAK,CAAC;IACb,4FAA4F;IAC5F,OAAO,EAAE,MAAM,CAAC;IAChB,0EAA0E;IAC1E,SAAS,EAAE,OAAO,CAAC;CACtB,CAAC"}