@azure/msal-common 14.14.2 → 14.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/browser/README.md +1 -0
- package/browser/package.json +5 -0
- package/dist/account/AccountInfo.d.ts +1 -1
- package/dist/account/AccountInfo.d.ts.map +1 -1
- package/dist/account/AccountInfo.mjs +1 -1
- package/dist/account/AuthToken.d.ts +1 -1
- package/dist/account/AuthToken.d.ts.map +1 -1
- package/dist/account/AuthToken.mjs +1 -1
- package/dist/account/CcsCredential.mjs +1 -1
- package/dist/account/ClientInfo.mjs +1 -1
- package/dist/account/TokenClaims.mjs +1 -1
- package/dist/authority/Authority.d.ts +12 -12
- package/dist/authority/Authority.d.ts.map +1 -1
- package/dist/authority/Authority.mjs +1 -1
- package/dist/authority/AuthorityFactory.d.ts +6 -6
- package/dist/authority/AuthorityFactory.d.ts.map +1 -1
- package/dist/authority/AuthorityFactory.mjs +1 -1
- package/dist/authority/AuthorityMetadata.d.ts +6 -6
- package/dist/authority/AuthorityMetadata.d.ts.map +1 -1
- package/dist/authority/AuthorityMetadata.mjs +1 -1
- package/dist/authority/AuthorityOptions.d.ts +4 -4
- package/dist/authority/AuthorityOptions.d.ts.map +1 -1
- package/dist/authority/AuthorityOptions.mjs +1 -1
- package/dist/authority/AuthorityType.mjs +1 -1
- package/dist/authority/AzureRegionConfiguration.d.ts +1 -1
- package/dist/authority/AzureRegionConfiguration.d.ts.map +1 -1
- package/dist/authority/CloudInstanceDiscoveryErrorResponse.mjs +1 -1
- package/dist/authority/CloudInstanceDiscoveryResponse.d.ts +1 -1
- package/dist/authority/CloudInstanceDiscoveryResponse.d.ts.map +1 -1
- package/dist/authority/CloudInstanceDiscoveryResponse.mjs +1 -1
- package/dist/authority/OIDCOptions.d.ts +1 -1
- package/dist/authority/OIDCOptions.d.ts.map +1 -1
- package/dist/authority/OpenIdConfigResponse.mjs +1 -1
- package/dist/authority/ProtocolMode.mjs +1 -1
- package/dist/authority/RegionDiscovery.d.ts +5 -5
- package/dist/authority/RegionDiscovery.d.ts.map +1 -1
- package/dist/authority/RegionDiscovery.mjs +1 -1
- package/dist/authority/RegionDiscoveryMetadata.d.ts +1 -1
- package/dist/authority/RegionDiscoveryMetadata.d.ts.map +1 -1
- package/dist/broker/nativeBroker/INativeBrokerPlugin.d.ts +6 -6
- package/dist/broker/nativeBroker/INativeBrokerPlugin.d.ts.map +1 -1
- package/dist/cache/CacheManager.d.ts +18 -23
- package/dist/cache/CacheManager.d.ts.map +1 -1
- package/dist/cache/CacheManager.mjs +1 -4
- package/dist/cache/CacheManager.mjs.map +1 -1
- package/dist/cache/entities/AccessTokenEntity.d.ts +2 -2
- package/dist/cache/entities/AccessTokenEntity.d.ts.map +1 -1
- package/dist/cache/entities/AccountEntity.d.ts +6 -6
- package/dist/cache/entities/AccountEntity.d.ts.map +1 -1
- package/dist/cache/entities/AccountEntity.mjs +1 -1
- package/dist/cache/entities/CacheRecord.d.ts +5 -5
- package/dist/cache/entities/CacheRecord.d.ts.map +1 -1
- package/dist/cache/entities/CredentialEntity.d.ts +1 -1
- package/dist/cache/entities/CredentialEntity.d.ts.map +1 -1
- package/dist/cache/entities/IdTokenEntity.d.ts +1 -1
- package/dist/cache/entities/IdTokenEntity.d.ts.map +1 -1
- package/dist/cache/entities/RefreshTokenEntity.d.ts +1 -1
- package/dist/cache/entities/RefreshTokenEntity.d.ts.map +1 -1
- package/dist/cache/interface/ICacheManager.d.ts +12 -12
- package/dist/cache/interface/ICacheManager.d.ts.map +1 -1
- package/dist/cache/interface/ICachePlugin.d.ts +1 -1
- package/dist/cache/interface/ICachePlugin.d.ts.map +1 -1
- package/dist/cache/persistence/TokenCacheContext.d.ts +1 -1
- package/dist/cache/persistence/TokenCacheContext.d.ts.map +1 -1
- package/dist/cache/persistence/TokenCacheContext.mjs +1 -1
- package/dist/cache/utils/CacheHelpers.d.ts +9 -9
- package/dist/cache/utils/CacheHelpers.d.ts.map +1 -1
- package/dist/cache/utils/CacheHelpers.mjs +1 -1
- package/dist/cache/utils/CacheTypes.d.ts +11 -11
- package/dist/cache/utils/CacheTypes.d.ts.map +1 -1
- package/dist/client/AuthorizationCodeClient.d.ts +10 -9
- package/dist/client/AuthorizationCodeClient.d.ts.map +1 -1
- package/dist/client/AuthorizationCodeClient.mjs +35 -16
- package/dist/client/AuthorizationCodeClient.mjs.map +1 -1
- package/dist/client/BaseClient.d.ts +21 -14
- package/dist/client/BaseClient.d.ts.map +1 -1
- package/dist/client/BaseClient.mjs +62 -10
- package/dist/client/BaseClient.mjs.map +1 -1
- package/dist/client/RefreshTokenClient.d.ts +6 -6
- package/dist/client/RefreshTokenClient.d.ts.map +1 -1
- package/dist/client/RefreshTokenClient.mjs +10 -4
- package/dist/client/RefreshTokenClient.mjs.map +1 -1
- package/dist/client/SilentFlowClient.d.ts +6 -6
- package/dist/client/SilentFlowClient.d.ts.map +1 -1
- package/dist/client/SilentFlowClient.mjs +1 -1
- package/dist/config/ClientConfiguration.d.ts +15 -11
- package/dist/config/ClientConfiguration.d.ts.map +1 -1
- package/dist/config/ClientConfiguration.mjs +2 -1
- package/dist/config/ClientConfiguration.mjs.map +1 -1
- package/dist/constants/AADServerParamKeys.d.ts +2 -0
- package/dist/constants/AADServerParamKeys.d.ts.map +1 -1
- package/dist/constants/AADServerParamKeys.mjs +5 -3
- package/dist/constants/AADServerParamKeys.mjs.map +1 -1
- package/dist/crypto/ICrypto.d.ts +2 -2
- package/dist/crypto/ICrypto.d.ts.map +1 -1
- package/dist/crypto/ICrypto.mjs +1 -1
- package/dist/crypto/JoseHeader.d.ts +1 -1
- package/dist/crypto/JoseHeader.d.ts.map +1 -1
- package/dist/crypto/JoseHeader.mjs +1 -1
- package/dist/crypto/PopTokenGenerator.d.ts +3 -3
- package/dist/crypto/PopTokenGenerator.d.ts.map +1 -1
- package/dist/crypto/PopTokenGenerator.mjs +1 -1
- package/dist/crypto/SignedHttpRequest.d.ts +1 -1
- package/dist/crypto/SignedHttpRequest.d.ts.map +1 -1
- package/dist/error/AuthError.d.ts +1 -1
- package/dist/error/AuthError.d.ts.map +1 -1
- package/dist/error/AuthError.mjs +1 -1
- package/dist/error/AuthErrorCodes.mjs +1 -1
- package/dist/error/CacheError.d.ts +1 -1
- package/dist/error/CacheError.d.ts.map +1 -1
- package/dist/error/CacheError.mjs +1 -1
- package/dist/error/CacheErrorCodes.mjs +1 -1
- package/dist/error/ClientAuthError.d.ts +2 -2
- package/dist/error/ClientAuthError.d.ts.map +1 -1
- package/dist/error/ClientAuthError.mjs +1 -1
- package/dist/error/ClientAuthErrorCodes.mjs +1 -1
- package/dist/error/ClientConfigurationError.d.ts +2 -2
- package/dist/error/ClientConfigurationError.d.ts.map +1 -1
- package/dist/error/ClientConfigurationError.mjs +1 -1
- package/dist/error/ClientConfigurationErrorCodes.mjs +1 -1
- package/dist/error/InteractionRequiredAuthError.d.ts +2 -2
- package/dist/error/InteractionRequiredAuthError.d.ts.map +1 -1
- package/dist/error/InteractionRequiredAuthError.mjs +1 -1
- package/dist/error/InteractionRequiredAuthErrorCodes.mjs +1 -1
- package/dist/error/JoseHeaderError.d.ts +2 -2
- package/dist/error/JoseHeaderError.d.ts.map +1 -1
- package/dist/error/JoseHeaderError.mjs +1 -1
- package/dist/error/JoseHeaderErrorCodes.mjs +1 -1
- package/dist/error/NetworkError.d.ts +19 -0
- package/dist/error/NetworkError.d.ts.map +1 -0
- package/dist/error/NetworkError.mjs +34 -0
- package/dist/error/NetworkError.mjs.map +1 -0
- package/dist/error/ServerError.d.ts +1 -1
- package/dist/error/ServerError.d.ts.map +1 -1
- package/dist/error/ServerError.mjs +1 -1
- package/dist/exports-browser-only.d.ts +10 -0
- package/dist/exports-browser-only.d.ts.map +1 -0
- package/dist/exports-common.d.ts +81 -0
- package/dist/exports-common.d.ts.map +1 -0
- package/dist/exports-node-only.d.ts +18 -0
- package/dist/exports-node-only.d.ts.map +1 -0
- package/dist/index-browser.d.ts +7 -0
- package/dist/index-browser.d.ts.map +1 -0
- package/dist/index-browser.mjs +67 -0
- package/dist/index-browser.mjs.map +1 -0
- package/dist/index-node.d.ts +7 -0
- package/dist/index-node.d.ts.map +1 -0
- package/dist/index-node.mjs +66 -0
- package/dist/index-node.mjs.map +1 -0
- package/dist/index.d.ts +7 -103
- package/dist/index.d.ts.map +1 -1
- package/dist/index.mjs +31 -31
- package/dist/logger/Logger.d.ts +1 -1
- package/dist/logger/Logger.d.ts.map +1 -1
- package/dist/logger/Logger.mjs +1 -1
- package/dist/network/INetworkModule.d.ts +1 -1
- package/dist/network/INetworkModule.d.ts.map +1 -1
- package/dist/network/INetworkModule.mjs +1 -1
- package/dist/network/NetworkResponse.d.ts +6 -0
- package/dist/network/NetworkResponse.d.ts.map +1 -0
- package/dist/network/RequestThumbprint.d.ts +2 -2
- package/dist/network/RequestThumbprint.d.ts.map +1 -1
- package/dist/network/ThrottlingUtils.d.ts +5 -5
- package/dist/network/ThrottlingUtils.d.ts.map +1 -1
- package/dist/network/ThrottlingUtils.mjs +1 -1
- package/dist/packageMetadata.d.ts +1 -1
- package/dist/packageMetadata.mjs +2 -2
- package/dist/request/AuthenticationHeaderParser.mjs +1 -1
- package/dist/request/BaseAuthRequest.d.ts +7 -5
- package/dist/request/BaseAuthRequest.d.ts.map +1 -1
- package/dist/request/CommonAuthorizationCodeRequest.d.ts +3 -3
- package/dist/request/CommonAuthorizationCodeRequest.d.ts.map +1 -1
- package/dist/request/CommonAuthorizationUrlRequest.d.ts +4 -4
- package/dist/request/CommonAuthorizationUrlRequest.d.ts.map +1 -1
- package/dist/request/CommonClientCredentialRequest.d.ts +3 -3
- package/dist/request/CommonClientCredentialRequest.d.ts.map +1 -1
- package/dist/request/CommonDeviceCodeRequest.d.ts +3 -3
- package/dist/request/CommonDeviceCodeRequest.d.ts.map +1 -1
- package/dist/request/CommonEndSessionRequest.d.ts +2 -2
- package/dist/request/CommonEndSessionRequest.d.ts.map +1 -1
- package/dist/request/CommonOnBehalfOfRequest.d.ts +1 -1
- package/dist/request/CommonOnBehalfOfRequest.d.ts.map +1 -1
- package/dist/request/CommonRefreshTokenRequest.d.ts +3 -3
- package/dist/request/CommonRefreshTokenRequest.d.ts.map +1 -1
- package/dist/request/CommonSilentFlowRequest.d.ts +3 -3
- package/dist/request/CommonSilentFlowRequest.d.ts.map +1 -1
- package/dist/request/CommonUsernamePasswordRequest.d.ts +1 -1
- package/dist/request/CommonUsernamePasswordRequest.d.ts.map +1 -1
- package/dist/request/NativeRequest.d.ts +1 -1
- package/dist/request/NativeRequest.d.ts.map +1 -1
- package/dist/request/RequestParameterBuilder.d.ts +13 -6
- package/dist/request/RequestParameterBuilder.d.ts.map +1 -1
- package/dist/request/RequestParameterBuilder.mjs +26 -3
- package/dist/request/RequestParameterBuilder.mjs.map +1 -1
- package/dist/request/RequestValidator.mjs +1 -1
- package/dist/request/ScopeSet.mjs +1 -1
- package/dist/response/AuthenticationResult.d.ts +1 -1
- package/dist/response/AuthenticationResult.d.ts.map +1 -1
- package/dist/response/ExternalTokenResponse.d.ts +1 -1
- package/dist/response/ExternalTokenResponse.d.ts.map +1 -1
- package/dist/response/ResponseHandler.d.ts +16 -16
- package/dist/response/ResponseHandler.d.ts.map +1 -1
- package/dist/response/ResponseHandler.mjs +1 -1
- package/dist/response/ServerAuthorizationTokenResponse.d.ts +1 -1
- package/dist/response/ServerAuthorizationTokenResponse.d.ts.map +1 -1
- package/dist/telemetry/performance/IPerformanceClient.d.ts +2 -2
- package/dist/telemetry/performance/IPerformanceClient.d.ts.map +1 -1
- package/dist/telemetry/performance/PerformanceClient.d.ts +5 -5
- package/dist/telemetry/performance/PerformanceClient.d.ts.map +1 -1
- package/dist/telemetry/performance/PerformanceClient.mjs +29 -10
- package/dist/telemetry/performance/PerformanceClient.mjs.map +1 -1
- package/dist/telemetry/performance/PerformanceEvent.d.ts +9 -0
- package/dist/telemetry/performance/PerformanceEvent.d.ts.map +1 -1
- package/dist/telemetry/performance/PerformanceEvent.mjs +6 -1
- package/dist/telemetry/performance/PerformanceEvent.mjs.map +1 -1
- package/dist/telemetry/performance/StubPerformanceClient.d.ts +3 -3
- package/dist/telemetry/performance/StubPerformanceClient.d.ts.map +1 -1
- package/dist/telemetry/performance/StubPerformanceClient.mjs +1 -1
- package/dist/telemetry/performance/StubPerformanceClient.mjs.map +1 -1
- package/dist/telemetry/server/ServerTelemetryManager.d.ts +5 -5
- package/dist/telemetry/server/ServerTelemetryManager.d.ts.map +1 -1
- package/dist/telemetry/server/ServerTelemetryManager.mjs +1 -1
- package/dist/url/UrlString.d.ts +1 -1
- package/dist/url/UrlString.d.ts.map +1 -1
- package/dist/url/UrlString.mjs +1 -1
- package/dist/utils/ClientAssertionUtils.d.ts +1 -1
- package/dist/utils/ClientAssertionUtils.d.ts.map +1 -1
- package/dist/utils/ClientAssertionUtils.mjs +1 -1
- package/dist/utils/Constants.d.ts +1 -0
- package/dist/utils/Constants.d.ts.map +1 -1
- package/dist/utils/Constants.mjs +2 -1
- package/dist/utils/Constants.mjs.map +1 -1
- package/dist/utils/FunctionWrappers.d.ts +2 -2
- package/dist/utils/FunctionWrappers.d.ts.map +1 -1
- package/dist/utils/FunctionWrappers.mjs +1 -1
- package/dist/utils/ProtocolUtils.d.ts +1 -1
- package/dist/utils/ProtocolUtils.d.ts.map +1 -1
- package/dist/utils/ProtocolUtils.mjs +1 -1
- package/dist/utils/StringUtils.mjs +1 -1
- package/dist/utils/TimeUtils.mjs +1 -1
- package/dist/utils/UrlUtils.d.ts +1 -1
- package/dist/utils/UrlUtils.d.ts.map +1 -1
- package/dist/utils/UrlUtils.mjs +1 -1
- package/lib/index-browser.cjs +858 -0
- package/lib/index-browser.cjs.map +1 -0
- package/{dist/index.cjs → lib/index-node-C9XsExml.js} +352 -990
- package/lib/index-node-C9XsExml.js.map +1 -0
- package/lib/index-node.cjs +104 -0
- package/lib/index-node.cjs.map +1 -0
- package/lib/index.cjs +112 -0
- package/lib/index.cjs.map +1 -0
- package/lib/package.json +1 -0
- package/lib/types/account/AccountInfo.d.ts +67 -0
- package/lib/types/account/AccountInfo.d.ts.map +1 -0
- package/lib/types/account/AuthToken.d.ts +18 -0
- package/lib/types/account/AuthToken.d.ts.map +1 -0
- package/lib/types/account/CcsCredential.d.ts +10 -0
- package/lib/types/account/CcsCredential.d.ts.map +1 -0
- package/lib/types/account/ClientCredentials.d.ts +20 -0
- package/lib/types/account/ClientCredentials.d.ts.map +1 -0
- package/lib/types/account/ClientInfo.d.ts +19 -0
- package/lib/types/account/ClientInfo.d.ts.map +1 -0
- package/lib/types/account/TokenClaims.d.ts +84 -0
- package/lib/types/account/TokenClaims.d.ts.map +1 -0
- package/lib/types/authority/Authority.d.ts +255 -0
- package/lib/types/authority/Authority.d.ts.map +1 -0
- package/lib/types/authority/AuthorityFactory.d.ts +19 -0
- package/lib/types/authority/AuthorityFactory.d.ts.map +1 -0
- package/lib/types/authority/AuthorityMetadata.d.ts +44 -0
- package/lib/types/authority/AuthorityMetadata.d.ts.map +1 -0
- package/lib/types/authority/AuthorityOptions.d.ts +28 -0
- package/lib/types/authority/AuthorityOptions.d.ts.map +1 -0
- package/lib/types/authority/AuthorityType.d.ts +11 -0
- package/lib/types/authority/AuthorityType.d.ts.map +1 -0
- package/lib/types/authority/AzureRegion.d.ts +2 -0
- package/lib/types/authority/AzureRegion.d.ts.map +1 -0
- package/lib/types/authority/AzureRegionConfiguration.d.ts +6 -0
- package/lib/types/authority/AzureRegionConfiguration.d.ts.map +1 -0
- package/lib/types/authority/CloudDiscoveryMetadata.d.ts +6 -0
- package/lib/types/authority/CloudDiscoveryMetadata.d.ts.map +1 -0
- package/lib/types/authority/CloudInstanceDiscoveryErrorResponse.d.ts +14 -0
- package/lib/types/authority/CloudInstanceDiscoveryErrorResponse.d.ts.map +1 -0
- package/lib/types/authority/CloudInstanceDiscoveryResponse.d.ts +10 -0
- package/lib/types/authority/CloudInstanceDiscoveryResponse.d.ts.map +1 -0
- package/lib/types/authority/ImdsOptions.d.ts +6 -0
- package/lib/types/authority/ImdsOptions.d.ts.map +1 -0
- package/lib/types/authority/OIDCOptions.d.ts +9 -0
- package/lib/types/authority/OIDCOptions.d.ts.map +1 -0
- package/lib/types/authority/OpenIdConfigResponse.d.ts +12 -0
- package/lib/types/authority/OpenIdConfigResponse.d.ts.map +1 -0
- package/lib/types/authority/ProtocolMode.d.ts +9 -0
- package/lib/types/authority/ProtocolMode.d.ts.map +1 -0
- package/lib/types/authority/RegionDiscovery.d.ts +33 -0
- package/lib/types/authority/RegionDiscovery.d.ts.map +1 -0
- package/lib/types/authority/RegionDiscoveryMetadata.d.ts +7 -0
- package/lib/types/authority/RegionDiscoveryMetadata.d.ts.map +1 -0
- package/lib/types/broker/nativeBroker/INativeBrokerPlugin.d.ts +16 -0
- package/lib/types/broker/nativeBroker/INativeBrokerPlugin.d.ts.map +1 -0
- package/lib/types/cache/CacheManager.d.ts +493 -0
- package/lib/types/cache/CacheManager.d.ts.map +1 -0
- package/lib/types/cache/entities/AccessTokenEntity.d.ts +26 -0
- package/lib/types/cache/entities/AccessTokenEntity.d.ts.map +1 -0
- package/lib/types/cache/entities/AccountEntity.d.ts +107 -0
- package/lib/types/cache/entities/AccountEntity.d.ts.map +1 -0
- package/lib/types/cache/entities/AppMetadataEntity.d.ts +12 -0
- package/lib/types/cache/entities/AppMetadataEntity.d.ts.map +1 -0
- package/lib/types/cache/entities/AuthorityMetadataEntity.d.ts +16 -0
- package/lib/types/cache/entities/AuthorityMetadataEntity.d.ts.map +1 -0
- package/lib/types/cache/entities/CacheRecord.d.ts +14 -0
- package/lib/types/cache/entities/CacheRecord.d.ts.map +1 -0
- package/lib/types/cache/entities/CredentialEntity.d.ts +31 -0
- package/lib/types/cache/entities/CredentialEntity.d.ts.map +1 -0
- package/lib/types/cache/entities/IdTokenEntity.d.ts +9 -0
- package/lib/types/cache/entities/IdTokenEntity.d.ts.map +1 -0
- package/lib/types/cache/entities/RefreshTokenEntity.d.ts +8 -0
- package/lib/types/cache/entities/RefreshTokenEntity.d.ts.map +1 -0
- package/lib/types/cache/entities/ServerTelemetryEntity.d.ts +7 -0
- package/lib/types/cache/entities/ServerTelemetryEntity.d.ts.map +1 -0
- package/lib/types/cache/entities/ThrottlingEntity.d.ts +8 -0
- package/lib/types/cache/entities/ThrottlingEntity.d.ts.map +1 -0
- package/lib/types/cache/interface/ICacheManager.d.ts +167 -0
- package/lib/types/cache/interface/ICacheManager.d.ts.map +1 -0
- package/lib/types/cache/interface/ICachePlugin.d.ts +6 -0
- package/lib/types/cache/interface/ICachePlugin.d.ts.map +1 -0
- package/lib/types/cache/interface/ISerializableTokenCache.d.ts +5 -0
- package/lib/types/cache/interface/ISerializableTokenCache.d.ts.map +1 -0
- package/lib/types/cache/persistence/TokenCacheContext.d.ts +24 -0
- package/lib/types/cache/persistence/TokenCacheContext.d.ts.map +1 -0
- package/lib/types/cache/utils/CacheHelpers.d.ts +95 -0
- package/lib/types/cache/utils/CacheHelpers.d.ts.map +1 -0
- package/lib/types/cache/utils/CacheTypes.d.ts +70 -0
- package/lib/types/cache/utils/CacheTypes.d.ts.map +1 -0
- package/lib/types/client/AuthorizationCodeClient.d.ts +76 -0
- package/lib/types/client/AuthorizationCodeClient.d.ts.map +1 -0
- package/lib/types/client/BaseClient.d.ts +59 -0
- package/lib/types/client/BaseClient.d.ts.map +1 -0
- package/lib/types/client/RefreshTokenClient.d.ts +36 -0
- package/lib/types/client/RefreshTokenClient.d.ts.map +1 -0
- package/lib/types/client/SilentFlowClient.d.ts +28 -0
- package/lib/types/client/SilentFlowClient.d.ts.map +1 -0
- package/lib/types/config/AppTokenProvider.d.ts +39 -0
- package/lib/types/config/AppTokenProvider.d.ts.map +1 -0
- package/lib/types/config/ClientConfiguration.d.ts +155 -0
- package/lib/types/config/ClientConfiguration.d.ts.map +1 -0
- package/lib/types/constants/AADServerParamKeys.d.ts +56 -0
- package/lib/types/constants/AADServerParamKeys.d.ts.map +1 -0
- package/lib/types/crypto/ICrypto.d.ts +69 -0
- package/lib/types/crypto/ICrypto.d.ts.map +1 -0
- package/lib/types/crypto/IGuidGenerator.d.ts +5 -0
- package/lib/types/crypto/IGuidGenerator.d.ts.map +1 -0
- package/lib/types/crypto/JoseHeader.d.ts +23 -0
- package/lib/types/crypto/JoseHeader.d.ts.map +1 -0
- package/lib/types/crypto/PopTokenGenerator.d.ts +60 -0
- package/lib/types/crypto/PopTokenGenerator.d.ts.map +1 -0
- package/lib/types/crypto/SignedHttpRequest.d.ts +16 -0
- package/lib/types/crypto/SignedHttpRequest.d.ts.map +1 -0
- package/lib/types/error/AuthError.d.ts +45 -0
- package/lib/types/error/AuthError.d.ts.map +1 -0
- package/lib/types/error/AuthErrorCodes.d.ts +6 -0
- package/lib/types/error/AuthErrorCodes.d.ts.map +1 -0
- package/lib/types/error/CacheError.d.ts +21 -0
- package/lib/types/error/CacheError.d.ts.map +1 -0
- package/lib/types/error/CacheErrorCodes.d.ts +3 -0
- package/lib/types/error/CacheErrorCodes.d.ts.map +1 -0
- package/lib/types/error/ClientAuthError.d.ts +238 -0
- package/lib/types/error/ClientAuthError.d.ts.map +1 -0
- package/lib/types/error/ClientAuthErrorCodes.d.ts +45 -0
- package/lib/types/error/ClientAuthErrorCodes.d.ts.map +1 -0
- package/lib/types/error/ClientConfigurationError.d.ts +129 -0
- package/lib/types/error/ClientConfigurationError.d.ts.map +1 -0
- package/lib/types/error/ClientConfigurationErrorCodes.d.ts +23 -0
- package/lib/types/error/ClientConfigurationErrorCodes.d.ts.map +1 -0
- package/lib/types/error/InteractionRequiredAuthError.d.ts +66 -0
- package/lib/types/error/InteractionRequiredAuthError.d.ts.map +1 -0
- package/lib/types/error/InteractionRequiredAuthErrorCodes.d.ts +8 -0
- package/lib/types/error/InteractionRequiredAuthErrorCodes.d.ts.map +1 -0
- package/lib/types/error/JoseHeaderError.d.ts +16 -0
- package/lib/types/error/JoseHeaderError.d.ts.map +1 -0
- package/lib/types/error/JoseHeaderErrorCodes.d.ts +3 -0
- package/lib/types/error/JoseHeaderErrorCodes.d.ts.map +1 -0
- package/lib/types/error/NetworkError.d.ts +19 -0
- package/lib/types/error/NetworkError.d.ts.map +1 -0
- package/lib/types/error/ServerError.d.ts +16 -0
- package/lib/types/error/ServerError.d.ts.map +1 -0
- package/lib/types/exports-browser-only.d.ts +10 -0
- package/lib/types/exports-browser-only.d.ts.map +1 -0
- package/lib/types/exports-common.d.ts +81 -0
- package/lib/types/exports-common.d.ts.map +1 -0
- package/lib/types/exports-node-only.d.ts +18 -0
- package/lib/types/exports-node-only.d.ts.map +1 -0
- package/lib/types/index-browser.d.ts +7 -0
- package/lib/types/index-browser.d.ts.map +1 -0
- package/lib/types/index-node.d.ts +7 -0
- package/lib/types/index-node.d.ts.map +1 -0
- package/lib/types/index.d.ts +12 -0
- package/lib/types/index.d.ts.map +1 -0
- package/lib/types/logger/Logger.d.ts +96 -0
- package/lib/types/logger/Logger.d.ts.map +1 -0
- package/lib/types/network/INetworkModule.d.ts +30 -0
- package/lib/types/network/INetworkModule.d.ts.map +1 -0
- package/lib/types/network/NetworkResponse.d.ts +6 -0
- package/lib/types/network/NetworkResponse.d.ts.map +1 -0
- package/lib/types/network/RequestThumbprint.d.ts +19 -0
- package/lib/types/network/RequestThumbprint.d.ts.map +1 -0
- package/lib/types/network/ThrottlingUtils.d.ts +43 -0
- package/lib/types/network/ThrottlingUtils.d.ts.map +1 -0
- package/lib/types/packageMetadata.d.ts +3 -0
- package/lib/types/packageMetadata.d.ts.map +1 -0
- package/lib/types/request/AuthenticationHeaderParser.d.ts +20 -0
- package/lib/types/request/AuthenticationHeaderParser.d.ts.map +1 -0
- package/lib/types/request/BaseAuthRequest.d.ts +50 -0
- package/lib/types/request/BaseAuthRequest.d.ts.map +1 -0
- package/lib/types/request/CommonAuthorizationCodeRequest.d.ts +28 -0
- package/lib/types/request/CommonAuthorizationCodeRequest.d.ts.map +1 -0
- package/lib/types/request/CommonAuthorizationUrlRequest.d.ts +51 -0
- package/lib/types/request/CommonAuthorizationUrlRequest.d.ts.map +1 -0
- package/lib/types/request/CommonClientCredentialRequest.d.ts +18 -0
- package/lib/types/request/CommonClientCredentialRequest.d.ts.map +1 -0
- package/lib/types/request/CommonDeviceCodeRequest.d.ts +22 -0
- package/lib/types/request/CommonDeviceCodeRequest.d.ts.map +1 -0
- package/lib/types/request/CommonEndSessionRequest.d.ts +22 -0
- package/lib/types/request/CommonEndSessionRequest.d.ts.map +1 -0
- package/lib/types/request/CommonOnBehalfOfRequest.d.ts +14 -0
- package/lib/types/request/CommonOnBehalfOfRequest.d.ts.map +1 -0
- package/lib/types/request/CommonRefreshTokenRequest.d.ts +23 -0
- package/lib/types/request/CommonRefreshTokenRequest.d.ts.map +1 -0
- package/lib/types/request/CommonSilentFlowRequest.d.ts +28 -0
- package/lib/types/request/CommonSilentFlowRequest.d.ts.map +1 -0
- package/lib/types/request/CommonUsernamePasswordRequest.d.ts +18 -0
- package/lib/types/request/CommonUsernamePasswordRequest.d.ts.map +1 -0
- package/lib/types/request/NativeRequest.d.ts +20 -0
- package/lib/types/request/NativeRequest.d.ts.map +1 -0
- package/lib/types/request/NativeSignOutRequest.d.ts +6 -0
- package/lib/types/request/NativeSignOutRequest.d.ts.map +1 -0
- package/lib/types/request/RequestParameterBuilder.d.ts +225 -0
- package/lib/types/request/RequestParameterBuilder.d.ts.map +1 -0
- package/lib/types/request/RequestValidator.d.ts +28 -0
- package/lib/types/request/RequestValidator.d.ts.map +1 -0
- package/lib/types/request/ScopeSet.d.ts +89 -0
- package/lib/types/request/ScopeSet.d.ts.map +1 -0
- package/lib/types/request/StoreInCache.d.ts +9 -0
- package/lib/types/request/StoreInCache.d.ts.map +1 -0
- package/lib/types/response/AuthenticationResult.d.ts +42 -0
- package/lib/types/response/AuthenticationResult.d.ts.map +1 -0
- package/lib/types/response/AuthorizationCodePayload.d.ts +14 -0
- package/lib/types/response/AuthorizationCodePayload.d.ts.map +1 -0
- package/lib/types/response/DeviceCodeResponse.d.ts +26 -0
- package/lib/types/response/DeviceCodeResponse.d.ts.map +1 -0
- package/lib/types/response/ExternalTokenResponse.d.ts +16 -0
- package/lib/types/response/ExternalTokenResponse.d.ts.map +1 -0
- package/lib/types/response/IMDSBadResponse.d.ts +5 -0
- package/lib/types/response/IMDSBadResponse.d.ts.map +1 -0
- package/lib/types/response/ResponseHandler.d.ts +70 -0
- package/lib/types/response/ResponseHandler.d.ts.map +1 -0
- package/lib/types/response/ServerAuthorizationCodeResponse.d.ts +27 -0
- package/lib/types/response/ServerAuthorizationCodeResponse.d.ts.map +1 -0
- package/lib/types/response/ServerAuthorizationTokenResponse.d.ts +48 -0
- package/lib/types/response/ServerAuthorizationTokenResponse.d.ts.map +1 -0
- package/lib/types/telemetry/performance/IPerformanceClient.d.ts +58 -0
- package/lib/types/telemetry/performance/IPerformanceClient.d.ts.map +1 -0
- package/lib/types/telemetry/performance/IPerformanceMeasurement.d.ts +6 -0
- package/lib/types/telemetry/performance/IPerformanceMeasurement.d.ts.map +1 -0
- package/lib/types/telemetry/performance/PerformanceClient.d.ts +243 -0
- package/lib/types/telemetry/performance/PerformanceClient.d.ts.map +1 -0
- package/lib/types/telemetry/performance/PerformanceEvent.d.ts +521 -0
- package/lib/types/telemetry/performance/PerformanceEvent.d.ts.map +1 -0
- package/lib/types/telemetry/performance/StubPerformanceClient.d.ts +25 -0
- package/lib/types/telemetry/performance/StubPerformanceClient.d.ts.map +1 -0
- package/lib/types/telemetry/server/ServerTelemetryManager.d.ts +79 -0
- package/lib/types/telemetry/server/ServerTelemetryManager.d.ts.map +1 -0
- package/lib/types/telemetry/server/ServerTelemetryRequest.d.ts +9 -0
- package/lib/types/telemetry/server/ServerTelemetryRequest.d.ts.map +1 -0
- package/lib/types/url/IUri.d.ts +13 -0
- package/lib/types/url/IUri.d.ts.map +1 -0
- package/lib/types/url/UrlString.d.ts +49 -0
- package/lib/types/url/UrlString.d.ts.map +1 -0
- package/lib/types/utils/ClientAssertionUtils.d.ts +3 -0
- package/lib/types/utils/ClientAssertionUtils.d.ts.map +1 -0
- package/lib/types/utils/Constants.d.ts +311 -0
- package/lib/types/utils/Constants.d.ts.map +1 -0
- package/lib/types/utils/FunctionWrappers.d.ts +28 -0
- package/lib/types/utils/FunctionWrappers.d.ts.map +1 -0
- package/lib/types/utils/MsalTypes.d.ts +7 -0
- package/lib/types/utils/MsalTypes.d.ts.map +1 -0
- package/lib/types/utils/ProtocolUtils.d.ts +43 -0
- package/lib/types/utils/ProtocolUtils.d.ts.map +1 -0
- package/lib/types/utils/StringUtils.d.ts +41 -0
- package/lib/types/utils/StringUtils.d.ts.map +1 -0
- package/lib/types/utils/TimeUtils.d.ts +26 -0
- package/lib/types/utils/TimeUtils.d.ts.map +1 -0
- package/lib/types/utils/UrlUtils.d.ts +11 -0
- package/lib/types/utils/UrlUtils.d.ts.map +1 -0
- package/node/README.md +1 -0
- package/node/package.json +5 -0
- package/package.json +38 -11
- package/src/account/AccountInfo.ts +1 -1
- package/src/account/AuthToken.ts +2 -2
- package/src/account/ClientInfo.ts +2 -2
- package/src/authority/Authority.ts +26 -26
- package/src/authority/AuthorityFactory.ts +9 -9
- package/src/authority/AuthorityMetadata.ts +7 -7
- package/src/authority/AuthorityOptions.ts +4 -4
- package/src/authority/AzureRegionConfiguration.ts +1 -1
- package/src/authority/CloudInstanceDiscoveryResponse.ts +1 -1
- package/src/authority/OIDCOptions.ts +1 -1
- package/src/authority/RegionDiscovery.ts +10 -10
- package/src/authority/RegionDiscoveryMetadata.ts +1 -1
- package/src/broker/nativeBroker/INativeBrokerPlugin.ts +5 -5
- package/src/cache/CacheManager.ts +28 -36
- package/src/cache/entities/AccessTokenEntity.ts +2 -2
- package/src/cache/entities/AccountEntity.ts +10 -10
- package/src/cache/entities/CacheRecord.ts +5 -5
- package/src/cache/entities/CredentialEntity.ts +1 -1
- package/src/cache/entities/IdTokenEntity.ts +1 -1
- package/src/cache/entities/RefreshTokenEntity.ts +1 -1
- package/src/cache/interface/ICacheManager.ts +12 -12
- package/src/cache/interface/ICachePlugin.ts +1 -1
- package/src/cache/persistence/TokenCacheContext.ts +1 -1
- package/src/cache/utils/CacheHelpers.ts +13 -13
- package/src/cache/utils/CacheTypes.ts +11 -11
- package/src/client/AuthorizationCodeClient.ts +86 -52
- package/src/client/BaseClient.ts +121 -39
- package/src/client/RefreshTokenClient.ts +42 -33
- package/src/client/SilentFlowClient.ts +17 -17
- package/src/config/ClientConfiguration.ts +20 -15
- package/src/constants/AADServerParamKeys.ts +2 -0
- package/src/crypto/ICrypto.ts +3 -3
- package/src/crypto/JoseHeader.ts +2 -2
- package/src/crypto/PopTokenGenerator.ts +7 -7
- package/src/crypto/SignedHttpRequest.ts +1 -1
- package/src/error/AuthError.ts +2 -2
- package/src/error/CacheError.ts +1 -1
- package/src/error/ClientAuthError.ts +2 -2
- package/src/error/ClientConfigurationError.ts +2 -2
- package/src/error/InteractionRequiredAuthError.ts +3 -3
- package/src/error/JoseHeaderError.ts +2 -2
- package/src/error/NetworkError.ts +44 -0
- package/src/error/ServerError.ts +1 -1
- package/src/exports-browser-only.ts +29 -0
- package/src/exports-common.ts +189 -0
- package/src/exports-node-only.ts +35 -0
- package/src/index-browser.ts +11 -0
- package/src/index-node.ts +11 -0
- package/src/index.ts +7 -250
- package/src/logger/Logger.ts +2 -2
- package/src/network/INetworkModule.ts +2 -2
- package/src/network/NetworkResponse.ts +10 -0
- package/src/network/RequestThumbprint.ts +2 -2
- package/src/network/ThrottlingUtils.ts +8 -8
- package/src/packageMetadata.ts +1 -1
- package/src/request/AuthenticationHeaderParser.ts +2 -2
- package/src/request/BaseAuthRequest.ts +7 -5
- package/src/request/CommonAuthorizationCodeRequest.ts +3 -3
- package/src/request/CommonAuthorizationUrlRequest.ts +4 -4
- package/src/request/CommonClientCredentialRequest.ts +3 -3
- package/src/request/CommonDeviceCodeRequest.ts +3 -3
- package/src/request/CommonEndSessionRequest.ts +2 -2
- package/src/request/CommonOnBehalfOfRequest.ts +1 -1
- package/src/request/CommonRefreshTokenRequest.ts +3 -3
- package/src/request/CommonSilentFlowRequest.ts +3 -3
- package/src/request/CommonUsernamePasswordRequest.ts +1 -1
- package/src/request/NativeRequest.ts +1 -1
- package/src/request/RequestParameterBuilder.ts +60 -10
- package/src/request/RequestValidator.ts +2 -2
- package/src/request/ScopeSet.ts +4 -4
- package/src/response/AuthenticationResult.ts +1 -1
- package/src/response/ExternalTokenResponse.ts +1 -1
- package/src/response/ResponseHandler.ts +31 -31
- package/src/response/ServerAuthorizationTokenResponse.ts +1 -1
- package/src/telemetry/performance/IPerformanceClient.ts +2 -2
- package/src/telemetry/performance/PerformanceClient.ts +52 -22
- package/src/telemetry/performance/PerformanceEvent.ts +15 -0
- package/src/telemetry/performance/StubPerformanceClient.ts +6 -3
- package/src/telemetry/server/ServerTelemetryManager.ts +6 -6
- package/src/url/UrlString.ts +5 -5
- package/src/utils/ClientAssertionUtils.ts +1 -1
- package/src/utils/Constants.ts +1 -0
- package/src/utils/FunctionWrappers.ts +2 -2
- package/src/utils/ProtocolUtils.ts +3 -3
- package/src/utils/UrlUtils.ts +2 -2
- package/dist/index.cjs.map +0 -1
- package/dist/network/NetworkManager.d.ts +0 -34
- package/dist/network/NetworkManager.d.ts.map +0 -1
- package/dist/network/NetworkManager.mjs +0 -44
- package/dist/network/NetworkManager.mjs.map +0 -1
- package/src/network/NetworkManager.ts +0 -76
|
@@ -3,26 +3,26 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { INetworkModule } from "../network/INetworkModule";
|
|
7
|
-
import { DEFAULT_CRYPTO_IMPLEMENTATION, ICrypto } from "../crypto/ICrypto";
|
|
8
|
-
import { ILoggerCallback, Logger, LogLevel } from "../logger/Logger";
|
|
6
|
+
import { INetworkModule } from "../network/INetworkModule.js";
|
|
7
|
+
import { DEFAULT_CRYPTO_IMPLEMENTATION, ICrypto } from "../crypto/ICrypto.js";
|
|
8
|
+
import { ILoggerCallback, Logger, LogLevel } from "../logger/Logger.js";
|
|
9
9
|
import {
|
|
10
10
|
Constants,
|
|
11
11
|
DEFAULT_TOKEN_RENEWAL_OFFSET_SEC,
|
|
12
|
-
} from "../utils/Constants";
|
|
13
|
-
import { version } from "../packageMetadata";
|
|
14
|
-
import { Authority } from "../authority/Authority";
|
|
15
|
-
import { AzureCloudInstance } from "../authority/AuthorityOptions";
|
|
16
|
-
import { CacheManager, DefaultStorageClass } from "../cache/CacheManager";
|
|
17
|
-
import { ServerTelemetryManager } from "../telemetry/server/ServerTelemetryManager";
|
|
18
|
-
import { ICachePlugin } from "../cache/interface/ICachePlugin";
|
|
19
|
-
import { ISerializableTokenCache } from "../cache/interface/ISerializableTokenCache";
|
|
20
|
-
import { ClientCredentials } from "../account/ClientCredentials";
|
|
21
|
-
import { ProtocolMode } from "../authority/ProtocolMode";
|
|
12
|
+
} from "../utils/Constants.js";
|
|
13
|
+
import { version } from "../packageMetadata.js";
|
|
14
|
+
import { Authority } from "../authority/Authority.js";
|
|
15
|
+
import { AzureCloudInstance } from "../authority/AuthorityOptions.js";
|
|
16
|
+
import { CacheManager, DefaultStorageClass } from "../cache/CacheManager.js";
|
|
17
|
+
import { ServerTelemetryManager } from "../telemetry/server/ServerTelemetryManager.js";
|
|
18
|
+
import { ICachePlugin } from "../cache/interface/ICachePlugin.js";
|
|
19
|
+
import { ISerializableTokenCache } from "../cache/interface/ISerializableTokenCache.js";
|
|
20
|
+
import { ClientCredentials } from "../account/ClientCredentials.js";
|
|
21
|
+
import { ProtocolMode } from "../authority/ProtocolMode.js";
|
|
22
22
|
import {
|
|
23
23
|
ClientAuthErrorCodes,
|
|
24
24
|
createClientAuthError,
|
|
25
|
-
} from "../error/ClientAuthError";
|
|
25
|
+
} from "../error/ClientAuthError.js";
|
|
26
26
|
|
|
27
27
|
/**
|
|
28
28
|
* Use the configuration object to configure MSAL Modules and initialize the base interfaces for MSAL.
|
|
@@ -80,15 +80,19 @@ export type CommonClientConfiguration = {
|
|
|
80
80
|
* - cloudDiscoveryMetadata - A string containing the cloud discovery response. Used in AAD scenarios.
|
|
81
81
|
* - clientCapabilities - Array of capabilities which will be added to the claims.access_token.xms_cc request property on every network request.
|
|
82
82
|
* - protocolMode - Enum that represents the protocol that msal follows. Used for configuring proper endpoints.
|
|
83
|
-
* - skipAuthorityMetadataCache
|
|
83
|
+
* - skipAuthorityMetadataCache - A flag to choose whether to use or not use the local metadata cache during authority initialization. Defaults to false.
|
|
84
|
+
* - instanceAware - A flag of whether the STS will send back additional parameters to specify where the tokens should be retrieved from.
|
|
85
|
+
* - redirectUri - The redirect URI where authentication responses can be received by your application. It must exactly match one of the redirect URIs registered in the Azure portal.
|
|
84
86
|
* @internal
|
|
85
87
|
*/
|
|
86
88
|
export type AuthOptions = {
|
|
87
89
|
clientId: string;
|
|
88
90
|
authority: Authority;
|
|
91
|
+
redirectUri: string;
|
|
89
92
|
clientCapabilities?: Array<string>;
|
|
90
93
|
azureCloudOptions?: AzureCloudOptions;
|
|
91
94
|
skipAuthorityMetadataCache?: boolean;
|
|
95
|
+
instanceAware?: boolean;
|
|
92
96
|
};
|
|
93
97
|
|
|
94
98
|
/**
|
|
@@ -271,6 +275,7 @@ function buildAuthOptions(authOptions: AuthOptions): Required<AuthOptions> {
|
|
|
271
275
|
clientCapabilities: [],
|
|
272
276
|
azureCloudOptions: DEFAULT_AZURE_CLOUD_OPTIONS,
|
|
273
277
|
skipAuthorityMetadataCache: false,
|
|
278
|
+
instanceAware: false,
|
|
274
279
|
...authOptions,
|
|
275
280
|
};
|
|
276
281
|
}
|
|
@@ -56,3 +56,5 @@ export const SID = "sid";
|
|
|
56
56
|
export const LOGIN_HINT = "login_hint";
|
|
57
57
|
export const DOMAIN_HINT = "domain_hint";
|
|
58
58
|
export const X_CLIENT_EXTRA_SKU = "x-client-xtra-sku";
|
|
59
|
+
export const BROKER_CLIENT_ID = "brk_client_id";
|
|
60
|
+
export const BROKER_REDIRECT_URI = "brk_redirect_uri";
|
package/src/crypto/ICrypto.ts
CHANGED
|
@@ -6,9 +6,9 @@
|
|
|
6
6
|
import {
|
|
7
7
|
ClientAuthErrorCodes,
|
|
8
8
|
createClientAuthError,
|
|
9
|
-
} from "../error/ClientAuthError";
|
|
10
|
-
import { BaseAuthRequest } from "../request/BaseAuthRequest";
|
|
11
|
-
import { ShrOptions, SignedHttpRequest } from "./SignedHttpRequest";
|
|
9
|
+
} from "../error/ClientAuthError.js";
|
|
10
|
+
import { BaseAuthRequest } from "../request/BaseAuthRequest.js";
|
|
11
|
+
import { ShrOptions, SignedHttpRequest } from "./SignedHttpRequest.js";
|
|
12
12
|
|
|
13
13
|
/**
|
|
14
14
|
* The PkceCodes type describes the structure
|
package/src/crypto/JoseHeader.ts
CHANGED
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
import {
|
|
7
7
|
JoseHeaderErrorCodes,
|
|
8
8
|
createJoseHeaderError,
|
|
9
|
-
} from "../error/JoseHeaderError";
|
|
10
|
-
import { JsonWebTokenTypes } from "../utils/Constants";
|
|
9
|
+
} from "../error/JoseHeaderError.js";
|
|
10
|
+
import { JsonWebTokenTypes } from "../utils/Constants.js";
|
|
11
11
|
|
|
12
12
|
export type JoseHeaderOptions = {
|
|
13
13
|
typ?: JsonWebTokenTypes;
|
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { ICrypto, SignedHttpRequestParameters } from "./ICrypto";
|
|
7
|
-
import * as TimeUtils from "../utils/TimeUtils";
|
|
8
|
-
import { UrlString } from "../url/UrlString";
|
|
9
|
-
import { IPerformanceClient } from "../telemetry/performance/IPerformanceClient";
|
|
10
|
-
import { PerformanceEvents } from "../telemetry/performance/PerformanceEvent";
|
|
11
|
-
import { invokeAsync } from "../utils/FunctionWrappers";
|
|
12
|
-
import { Logger } from "../logger/Logger";
|
|
6
|
+
import { ICrypto, SignedHttpRequestParameters } from "./ICrypto.js";
|
|
7
|
+
import * as TimeUtils from "../utils/TimeUtils.js";
|
|
8
|
+
import { UrlString } from "../url/UrlString.js";
|
|
9
|
+
import { IPerformanceClient } from "../telemetry/performance/IPerformanceClient.js";
|
|
10
|
+
import { PerformanceEvents } from "../telemetry/performance/PerformanceEvent.js";
|
|
11
|
+
import { invokeAsync } from "../utils/FunctionWrappers.js";
|
|
12
|
+
import { Logger } from "../logger/Logger.js";
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* See eSTS docs for more info.
|
package/src/error/AuthError.ts
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { Constants } from "../utils/Constants";
|
|
7
|
-
import * as AuthErrorCodes from "./AuthErrorCodes";
|
|
6
|
+
import { Constants } from "../utils/Constants.js";
|
|
7
|
+
import * as AuthErrorCodes from "./AuthErrorCodes.js";
|
|
8
8
|
export { AuthErrorCodes };
|
|
9
9
|
|
|
10
10
|
export const AuthErrorMessages = {
|
package/src/error/CacheError.ts
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { AuthError } from "./AuthError";
|
|
7
|
-
import * as ClientAuthErrorCodes from "./ClientAuthErrorCodes";
|
|
6
|
+
import { AuthError } from "./AuthError.js";
|
|
7
|
+
import * as ClientAuthErrorCodes from "./ClientAuthErrorCodes.js";
|
|
8
8
|
export { ClientAuthErrorCodes }; // Allow importing as "ClientAuthErrorCodes";
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { AuthError } from "./AuthError";
|
|
7
|
-
import * as ClientConfigurationErrorCodes from "./ClientConfigurationErrorCodes";
|
|
6
|
+
import { AuthError } from "./AuthError.js";
|
|
7
|
+
import * as ClientConfigurationErrorCodes from "./ClientConfigurationErrorCodes.js";
|
|
8
8
|
export { ClientConfigurationErrorCodes };
|
|
9
9
|
|
|
10
10
|
export const ClientConfigurationErrorMessages = {
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { Constants } from "../utils/Constants";
|
|
7
|
-
import { AuthError } from "./AuthError";
|
|
8
|
-
import * as InteractionRequiredAuthErrorCodes from "./InteractionRequiredAuthErrorCodes";
|
|
6
|
+
import { Constants } from "../utils/Constants.js";
|
|
7
|
+
import { AuthError } from "./AuthError.js";
|
|
8
|
+
import * as InteractionRequiredAuthErrorCodes from "./InteractionRequiredAuthErrorCodes.js";
|
|
9
9
|
export { InteractionRequiredAuthErrorCodes };
|
|
10
10
|
|
|
11
11
|
/**
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { AuthError } from "./AuthError";
|
|
7
|
-
import * as JoseHeaderErrorCodes from "./JoseHeaderErrorCodes";
|
|
6
|
+
import { AuthError } from "./AuthError.js";
|
|
7
|
+
import * as JoseHeaderErrorCodes from "./JoseHeaderErrorCodes.js";
|
|
8
8
|
export { JoseHeaderErrorCodes };
|
|
9
9
|
|
|
10
10
|
export const JoseHeaderErrorMessages = {
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
import { AuthError } from "./AuthError.js";
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Represents network related errors
|
|
10
|
+
*/
|
|
11
|
+
export class NetworkError extends AuthError {
|
|
12
|
+
error: AuthError;
|
|
13
|
+
httpStatus?: number;
|
|
14
|
+
responseHeaders?: Record<string, string>;
|
|
15
|
+
|
|
16
|
+
constructor(
|
|
17
|
+
error: AuthError,
|
|
18
|
+
httpStatus?: number,
|
|
19
|
+
responseHeaders?: Record<string, string>
|
|
20
|
+
) {
|
|
21
|
+
super(error.errorCode, error.errorMessage, error.subError);
|
|
22
|
+
|
|
23
|
+
Object.setPrototypeOf(this, NetworkError.prototype);
|
|
24
|
+
this.name = "NetworkError";
|
|
25
|
+
this.error = error;
|
|
26
|
+
this.httpStatus = httpStatus;
|
|
27
|
+
this.responseHeaders = responseHeaders;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Creates NetworkError object for a failed network request
|
|
33
|
+
* @param error - Error to be thrown back to the caller
|
|
34
|
+
* @param httpStatus - Status code of the network request
|
|
35
|
+
* @param responseHeaders - Response headers of the network request, when available
|
|
36
|
+
* @returns NetworkError object
|
|
37
|
+
*/
|
|
38
|
+
export function createNetworkError(
|
|
39
|
+
error: AuthError,
|
|
40
|
+
httpStatus?: number,
|
|
41
|
+
responseHeaders?: Record<string, string>
|
|
42
|
+
): NetworkError {
|
|
43
|
+
return new NetworkError(error, httpStatus, responseHeaders);
|
|
44
|
+
}
|
package/src/error/ServerError.ts
CHANGED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
export { SignedHttpRequest, ShrOptions } from "./crypto/SignedHttpRequest.js";
|
|
7
|
+
export { JoseHeader } from "./crypto/JoseHeader.js";
|
|
8
|
+
export { ExternalTokenResponse } from "./response/ExternalTokenResponse.js";
|
|
9
|
+
export {
|
|
10
|
+
IPerformanceClient,
|
|
11
|
+
PerformanceCallbackFunction,
|
|
12
|
+
InProgressPerformanceEvent,
|
|
13
|
+
QueueMeasurement,
|
|
14
|
+
} from "./telemetry/performance/IPerformanceClient.js";
|
|
15
|
+
export {
|
|
16
|
+
IntFields,
|
|
17
|
+
PerformanceEvent,
|
|
18
|
+
PerformanceEvents,
|
|
19
|
+
PerformanceEventStatus,
|
|
20
|
+
SubMeasurement,
|
|
21
|
+
} from "./telemetry/performance/PerformanceEvent.js";
|
|
22
|
+
export { IPerformanceMeasurement } from "./telemetry/performance/IPerformanceMeasurement.js";
|
|
23
|
+
export {
|
|
24
|
+
PerformanceClient,
|
|
25
|
+
PreQueueEvent,
|
|
26
|
+
} from "./telemetry/performance/PerformanceClient.js";
|
|
27
|
+
export { StubPerformanceClient } from "./telemetry/performance/StubPerformanceClient.js";
|
|
28
|
+
|
|
29
|
+
export { PopTokenGenerator } from "./crypto/PopTokenGenerator.js";
|
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
import * as AuthToken from "./account/AuthToken.js";
|
|
7
|
+
import * as AuthorityFactory from "./authority/AuthorityFactory.js";
|
|
8
|
+
import * as CacheHelpers from "./cache/utils/CacheHelpers.js";
|
|
9
|
+
import * as TimeUtils from "./utils/TimeUtils.js";
|
|
10
|
+
import * as UrlUtils from "./utils/UrlUtils.js";
|
|
11
|
+
import * as AADServerParamKeys from "./constants/AADServerParamKeys.js";
|
|
12
|
+
|
|
13
|
+
export { AuthToken };
|
|
14
|
+
export { AuthorityFactory };
|
|
15
|
+
export { CacheHelpers };
|
|
16
|
+
export { TimeUtils };
|
|
17
|
+
export { UrlUtils };
|
|
18
|
+
export { AADServerParamKeys };
|
|
19
|
+
|
|
20
|
+
export { AuthorizationCodeClient } from "./client/AuthorizationCodeClient.js";
|
|
21
|
+
export { RefreshTokenClient } from "./client/RefreshTokenClient.js";
|
|
22
|
+
export { SilentFlowClient } from "./client/SilentFlowClient.js";
|
|
23
|
+
export { BaseClient } from "./client/BaseClient.js";
|
|
24
|
+
export {
|
|
25
|
+
AuthOptions,
|
|
26
|
+
SystemOptions,
|
|
27
|
+
LoggerOptions,
|
|
28
|
+
CacheOptions,
|
|
29
|
+
DEFAULT_SYSTEM_OPTIONS,
|
|
30
|
+
AzureCloudOptions,
|
|
31
|
+
ApplicationTelemetry,
|
|
32
|
+
} from "./config/ClientConfiguration.js";
|
|
33
|
+
export { ClientConfiguration } from "./config/ClientConfiguration.js";
|
|
34
|
+
export {
|
|
35
|
+
AccountInfo,
|
|
36
|
+
ActiveAccountFilters,
|
|
37
|
+
TenantProfile,
|
|
38
|
+
updateAccountTenantProfileData,
|
|
39
|
+
tenantIdMatchesHomeTenant,
|
|
40
|
+
buildTenantProfile,
|
|
41
|
+
} from "./account/AccountInfo.js";
|
|
42
|
+
export {
|
|
43
|
+
TokenClaims,
|
|
44
|
+
getTenantIdFromIdTokenClaims,
|
|
45
|
+
} from "./account/TokenClaims.js";
|
|
46
|
+
export { TokenClaims as IdTokenClaims } from "./account/TokenClaims.js";
|
|
47
|
+
export { CcsCredential, CcsCredentialType } from "./account/CcsCredential.js";
|
|
48
|
+
export {
|
|
49
|
+
ClientInfo,
|
|
50
|
+
buildClientInfo,
|
|
51
|
+
buildClientInfoFromHomeAccountId,
|
|
52
|
+
} from "./account/ClientInfo.js";
|
|
53
|
+
export {
|
|
54
|
+
Authority,
|
|
55
|
+
formatAuthorityUri,
|
|
56
|
+
buildStaticAuthorityOptions,
|
|
57
|
+
} from "./authority/Authority.js";
|
|
58
|
+
export {
|
|
59
|
+
AuthorityOptions,
|
|
60
|
+
AzureCloudInstance,
|
|
61
|
+
StaticAuthorityOptions,
|
|
62
|
+
} from "./authority/AuthorityOptions.js";
|
|
63
|
+
export { AuthorityType } from "./authority/AuthorityType.js";
|
|
64
|
+
export { ProtocolMode } from "./authority/ProtocolMode.js";
|
|
65
|
+
export { OIDCOptions } from "./authority/OIDCOptions.js";
|
|
66
|
+
export { CacheManager, DefaultStorageClass } from "./cache/CacheManager.js";
|
|
67
|
+
export {
|
|
68
|
+
AccountCache,
|
|
69
|
+
AccountFilter,
|
|
70
|
+
AccessTokenCache,
|
|
71
|
+
IdTokenCache,
|
|
72
|
+
RefreshTokenCache,
|
|
73
|
+
AppMetadataCache,
|
|
74
|
+
CredentialFilter,
|
|
75
|
+
ValidCacheType,
|
|
76
|
+
ValidCredentialType,
|
|
77
|
+
TokenKeys,
|
|
78
|
+
} from "./cache/utils/CacheTypes.js";
|
|
79
|
+
export { CacheRecord } from "./cache/entities/CacheRecord.js";
|
|
80
|
+
export { CredentialEntity } from "./cache/entities/CredentialEntity.js";
|
|
81
|
+
export { AppMetadataEntity } from "./cache/entities/AppMetadataEntity.js";
|
|
82
|
+
export { AccountEntity } from "./cache/entities/AccountEntity.js";
|
|
83
|
+
export { IdTokenEntity } from "./cache/entities/IdTokenEntity.js";
|
|
84
|
+
export { AccessTokenEntity } from "./cache/entities/AccessTokenEntity.js";
|
|
85
|
+
export { RefreshTokenEntity } from "./cache/entities/RefreshTokenEntity.js";
|
|
86
|
+
export { ServerTelemetryEntity } from "./cache/entities/ServerTelemetryEntity.js";
|
|
87
|
+
export { AuthorityMetadataEntity } from "./cache/entities/AuthorityMetadataEntity.js";
|
|
88
|
+
export { ThrottlingEntity } from "./cache/entities/ThrottlingEntity.js";
|
|
89
|
+
export {
|
|
90
|
+
INetworkModule,
|
|
91
|
+
NetworkRequestOptions,
|
|
92
|
+
StubbedNetworkModule,
|
|
93
|
+
} from "./network/INetworkModule.js";
|
|
94
|
+
export { NetworkResponse } from "./network/NetworkResponse.js";
|
|
95
|
+
export { ThrottlingUtils } from "./network/ThrottlingUtils.js";
|
|
96
|
+
export { RequestThumbprint } from "./network/RequestThumbprint.js";
|
|
97
|
+
export { IUri } from "./url/IUri.js";
|
|
98
|
+
export { UrlString } from "./url/UrlString.js";
|
|
99
|
+
export {
|
|
100
|
+
ICrypto,
|
|
101
|
+
PkceCodes,
|
|
102
|
+
DEFAULT_CRYPTO_IMPLEMENTATION,
|
|
103
|
+
SignedHttpRequestParameters,
|
|
104
|
+
} from "./crypto/ICrypto.js";
|
|
105
|
+
export { BaseAuthRequest } from "./request/BaseAuthRequest.js";
|
|
106
|
+
export { CommonAuthorizationUrlRequest } from "./request/CommonAuthorizationUrlRequest.js";
|
|
107
|
+
export { CommonAuthorizationCodeRequest } from "./request/CommonAuthorizationCodeRequest.js";
|
|
108
|
+
export { CommonRefreshTokenRequest } from "./request/CommonRefreshTokenRequest.js";
|
|
109
|
+
export { CommonSilentFlowRequest } from "./request/CommonSilentFlowRequest.js";
|
|
110
|
+
export { CommonEndSessionRequest } from "./request/CommonEndSessionRequest.js";
|
|
111
|
+
export { RequestParameterBuilder } from "./request/RequestParameterBuilder.js";
|
|
112
|
+
export { StoreInCache } from "./request/StoreInCache.js";
|
|
113
|
+
export { AzureRegion } from "./authority/AzureRegion.js";
|
|
114
|
+
export { AzureRegionConfiguration } from "./authority/AzureRegionConfiguration.js";
|
|
115
|
+
export { AuthenticationResult } from "./response/AuthenticationResult.js";
|
|
116
|
+
export { AuthorizationCodePayload } from "./response/AuthorizationCodePayload.js";
|
|
117
|
+
export { ServerAuthorizationCodeResponse } from "./response/ServerAuthorizationCodeResponse.js";
|
|
118
|
+
export { ServerAuthorizationTokenResponse } from "./response/ServerAuthorizationTokenResponse.js";
|
|
119
|
+
export {
|
|
120
|
+
ResponseHandler,
|
|
121
|
+
buildAccountToCache,
|
|
122
|
+
} from "./response/ResponseHandler.js";
|
|
123
|
+
export { ScopeSet } from "./request/ScopeSet.js";
|
|
124
|
+
export { AuthenticationHeaderParser } from "./request/AuthenticationHeaderParser.js";
|
|
125
|
+
export { ILoggerCallback, LogLevel, Logger } from "./logger/Logger.js";
|
|
126
|
+
export {
|
|
127
|
+
InteractionRequiredAuthError,
|
|
128
|
+
InteractionRequiredAuthErrorCodes,
|
|
129
|
+
InteractionRequiredAuthErrorMessage,
|
|
130
|
+
createInteractionRequiredAuthError,
|
|
131
|
+
} from "./error/InteractionRequiredAuthError.js";
|
|
132
|
+
export {
|
|
133
|
+
AuthError,
|
|
134
|
+
AuthErrorMessage,
|
|
135
|
+
AuthErrorCodes,
|
|
136
|
+
createAuthError,
|
|
137
|
+
} from "./error/AuthError.js";
|
|
138
|
+
export { ServerError } from "./error/ServerError.js";
|
|
139
|
+
export { NetworkError, createNetworkError } from "./error/NetworkError.js";
|
|
140
|
+
export { CacheError, CacheErrorCodes } from "./error/CacheError.js";
|
|
141
|
+
export {
|
|
142
|
+
ClientAuthError,
|
|
143
|
+
ClientAuthErrorMessage,
|
|
144
|
+
ClientAuthErrorCodes,
|
|
145
|
+
createClientAuthError,
|
|
146
|
+
} from "./error/ClientAuthError.js";
|
|
147
|
+
export {
|
|
148
|
+
ClientConfigurationError,
|
|
149
|
+
ClientConfigurationErrorMessage,
|
|
150
|
+
ClientConfigurationErrorCodes,
|
|
151
|
+
createClientConfigurationError,
|
|
152
|
+
} from "./error/ClientConfigurationError.js";
|
|
153
|
+
export {
|
|
154
|
+
Constants,
|
|
155
|
+
OIDC_DEFAULT_SCOPES,
|
|
156
|
+
PromptValue,
|
|
157
|
+
PersistentCacheKeys,
|
|
158
|
+
ServerResponseType,
|
|
159
|
+
ResponseMode,
|
|
160
|
+
CacheOutcome,
|
|
161
|
+
CredentialType,
|
|
162
|
+
CacheType,
|
|
163
|
+
CacheAccountType,
|
|
164
|
+
AuthenticationScheme,
|
|
165
|
+
CodeChallengeMethodValues,
|
|
166
|
+
PasswordGrantConstants,
|
|
167
|
+
ThrottlingConstants,
|
|
168
|
+
ClaimsRequestKeys,
|
|
169
|
+
HeaderNames,
|
|
170
|
+
Errors,
|
|
171
|
+
THE_FAMILY_ID,
|
|
172
|
+
ONE_DAY_IN_MS,
|
|
173
|
+
GrantType,
|
|
174
|
+
AADAuthorityConstants,
|
|
175
|
+
HttpStatus,
|
|
176
|
+
DEFAULT_TOKEN_RENEWAL_OFFSET_SEC,
|
|
177
|
+
JsonWebTokenTypes,
|
|
178
|
+
} from "./utils/Constants.js";
|
|
179
|
+
export { StringUtils } from "./utils/StringUtils.js";
|
|
180
|
+
export { StringDict } from "./utils/MsalTypes.js";
|
|
181
|
+
export {
|
|
182
|
+
ProtocolUtils,
|
|
183
|
+
RequestStateObject,
|
|
184
|
+
LibraryStateObject,
|
|
185
|
+
} from "./utils/ProtocolUtils.js";
|
|
186
|
+
export * from "./utils/FunctionWrappers.js";
|
|
187
|
+
export { ServerTelemetryManager } from "./telemetry/server/ServerTelemetryManager.js";
|
|
188
|
+
export { ServerTelemetryRequest } from "./telemetry/server/ServerTelemetryRequest.js";
|
|
189
|
+
export { version } from "./packageMetadata.js";
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
import * as ClientAssertionUtils from "./utils/ClientAssertionUtils.js";
|
|
7
|
+
|
|
8
|
+
export { ClientAssertionUtils };
|
|
9
|
+
|
|
10
|
+
export {
|
|
11
|
+
IAppTokenProvider,
|
|
12
|
+
AppTokenProviderParameters,
|
|
13
|
+
AppTokenProviderResult,
|
|
14
|
+
} from "./config/AppTokenProvider.js";
|
|
15
|
+
export { INativeBrokerPlugin } from "./broker/nativeBroker/INativeBrokerPlugin.js";
|
|
16
|
+
export { ICachePlugin } from "./cache/interface/ICachePlugin.js";
|
|
17
|
+
export { TokenCacheContext } from "./cache/persistence/TokenCacheContext.js";
|
|
18
|
+
export { ISerializableTokenCache } from "./cache/interface/ISerializableTokenCache.js";
|
|
19
|
+
export { CommonClientCredentialRequest } from "./request/CommonClientCredentialRequest.js";
|
|
20
|
+
export { CommonOnBehalfOfRequest } from "./request/CommonOnBehalfOfRequest.js";
|
|
21
|
+
export { CommonDeviceCodeRequest } from "./request/CommonDeviceCodeRequest.js";
|
|
22
|
+
export { CommonUsernamePasswordRequest } from "./request/CommonUsernamePasswordRequest.js";
|
|
23
|
+
export { NativeRequest } from "./request/NativeRequest.js";
|
|
24
|
+
export { NativeSignOutRequest } from "./request/NativeSignOutRequest.js";
|
|
25
|
+
export {
|
|
26
|
+
ClientAssertion,
|
|
27
|
+
ClientAssertionConfig,
|
|
28
|
+
ClientAssertionCallback,
|
|
29
|
+
} from "./account/ClientCredentials.js";
|
|
30
|
+
export {
|
|
31
|
+
DeviceCodeResponse,
|
|
32
|
+
ServerDeviceCodeResponse,
|
|
33
|
+
} from "./response/DeviceCodeResponse.js";
|
|
34
|
+
export { getClientAssertion } from "./utils/ClientAssertionUtils.js";
|
|
35
|
+
export { IGuidGenerator } from "./crypto/IGuidGenerator.js";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* This file is the entrypoint when importing with the browser subpath e.g. "import { someExport } from @azure/msal-common/browser"
|
|
8
|
+
* Additional exports should be added to the applicable exports-*.ts files
|
|
9
|
+
*/
|
|
10
|
+
export * from "./exports-common.js";
|
|
11
|
+
export * from "./exports-browser-only.js";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* This file is the entrypoint when importing with the node subpath e.g. "import { someExport } from @azure/msal-common/node"
|
|
8
|
+
* Additional exports should be added to the applicable exports-*.ts files
|
|
9
|
+
*/
|
|
10
|
+
export * from "./exports-common.js";
|
|
11
|
+
export * from "./exports-node-only.js";
|