@azure/msal-common 14.6.0-alpha.0 → 14.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/account/AccountInfo.d.ts +58 -58
- package/dist/account/AccountInfo.mjs +59 -59
- package/dist/account/AuthToken.d.ts +17 -17
- package/dist/account/AuthToken.mjs +58 -58
- package/dist/account/CcsCredential.d.ts +9 -9
- package/dist/account/CcsCredential.mjs +8 -8
- package/dist/account/ClientCredentials.d.ts +14 -14
- package/dist/account/ClientInfo.d.ts +18 -18
- package/dist/account/ClientInfo.mjs +37 -37
- package/dist/account/TokenClaims.d.ts +83 -83
- package/dist/account/TokenClaims.mjs +20 -20
- package/dist/authority/Authority.d.ts +253 -254
- package/dist/authority/Authority.d.ts.map +1 -1
- package/dist/authority/Authority.mjs +831 -816
- package/dist/authority/Authority.mjs.map +1 -1
- package/dist/authority/AuthorityFactory.d.ts +18 -31
- package/dist/authority/AuthorityFactory.d.ts.map +1 -1
- package/dist/authority/AuthorityFactory.mjs +29 -50
- package/dist/authority/AuthorityFactory.mjs.map +1 -1
- package/dist/authority/AuthorityMetadata.d.ts +43 -503
- package/dist/authority/AuthorityMetadata.d.ts.map +1 -1
- package/dist/authority/AuthorityMetadata.mjs +137 -603
- package/dist/authority/AuthorityMetadata.mjs.map +1 -1
- package/dist/authority/AuthorityOptions.d.ts +27 -27
- package/dist/authority/AuthorityOptions.mjs +18 -18
- package/dist/authority/AuthorityType.d.ts +10 -10
- package/dist/authority/AuthorityType.mjs +13 -13
- package/dist/authority/AzureRegion.d.ts +1 -1
- package/dist/authority/AzureRegionConfiguration.d.ts +5 -5
- package/dist/authority/CloudDiscoveryMetadata.d.ts +5 -5
- package/dist/authority/CloudInstanceDiscoveryErrorResponse.d.ts +13 -13
- package/dist/authority/CloudInstanceDiscoveryErrorResponse.mjs +8 -8
- package/dist/authority/CloudInstanceDiscoveryResponse.d.ts +9 -9
- package/dist/authority/CloudInstanceDiscoveryResponse.mjs +8 -8
- package/dist/authority/ImdsOptions.d.ts +5 -5
- package/dist/authority/OIDCOptions.d.ts +8 -8
- package/dist/authority/OpenIdConfigResponse.d.ts +11 -11
- package/dist/authority/OpenIdConfigResponse.mjs +10 -10
- package/dist/authority/ProtocolMode.d.ts +8 -8
- package/dist/authority/ProtocolMode.mjs +11 -11
- package/dist/authority/RegionDiscovery.d.ts +32 -32
- package/dist/authority/RegionDiscovery.mjs +106 -106
- package/dist/authority/RegionDiscoveryMetadata.d.ts +6 -6
- package/dist/broker/nativeBroker/INativeBrokerPlugin.d.ts +15 -15
- package/dist/cache/CacheManager.d.ts +508 -508
- package/dist/cache/CacheManager.mjs +1237 -1237
- package/dist/cache/entities/AccessTokenEntity.d.ts +25 -25
- package/dist/cache/entities/AccountEntity.d.ts +106 -106
- package/dist/cache/entities/AccountEntity.mjs +244 -244
- package/dist/cache/entities/AppMetadataEntity.d.ts +11 -39
- package/dist/cache/entities/AppMetadataEntity.d.ts.map +1 -1
- package/dist/cache/entities/AuthorityMetadataEntity.d.ts +15 -48
- package/dist/cache/entities/AuthorityMetadataEntity.d.ts.map +1 -1
- package/dist/cache/entities/CacheRecord.d.ts +14 -14
- package/dist/cache/entities/CacheRecord.mjs +14 -14
- package/dist/cache/entities/CredentialEntity.d.ts +30 -30
- package/dist/cache/entities/IdTokenEntity.d.ts +8 -8
- package/dist/cache/entities/RefreshTokenEntity.d.ts +7 -7
- package/dist/cache/entities/ServerTelemetryEntity.d.ts +5 -5
- package/dist/cache/entities/ThrottlingEntity.d.ts +7 -7
- package/dist/cache/interface/ICacheManager.d.ts +166 -166
- package/dist/cache/interface/ICachePlugin.d.ts +5 -5
- package/dist/cache/interface/ISerializableTokenCache.d.ts +4 -4
- package/dist/cache/persistence/TokenCacheContext.d.ts +23 -23
- package/dist/cache/persistence/TokenCacheContext.mjs +25 -25
- package/dist/cache/utils/CacheHelpers.d.ts +94 -70
- package/dist/cache/utils/CacheHelpers.d.ts.map +1 -1
- package/dist/cache/utils/CacheHelpers.mjs +326 -252
- package/dist/cache/utils/CacheHelpers.mjs.map +1 -1
- package/dist/cache/utils/CacheTypes.d.ts +69 -69
- package/dist/client/AuthorizationCodeClient.d.ts +74 -74
- package/dist/client/AuthorizationCodeClient.mjs +402 -402
- package/dist/client/BaseClient.d.ts +51 -51
- package/dist/client/BaseClient.d.ts.map +1 -1
- package/dist/client/BaseClient.mjs +101 -101
- package/dist/client/BaseClient.mjs.map +1 -1
- package/dist/client/RefreshTokenClient.d.ts +35 -35
- package/dist/client/RefreshTokenClient.mjs +204 -204
- package/dist/client/SilentFlowClient.d.ts +27 -27
- package/dist/client/SilentFlowClient.mjs +128 -128
- package/dist/config/AppTokenProvider.d.ts +38 -38
- package/dist/config/ClientConfiguration.d.ts +150 -150
- package/dist/config/ClientConfiguration.d.ts.map +1 -1
- package/dist/config/ClientConfiguration.mjs +98 -96
- package/dist/config/ClientConfiguration.mjs.map +1 -1
- package/dist/constants/AADServerParamKeys.d.ts +52 -52
- package/dist/constants/AADServerParamKeys.mjs +56 -56
- package/dist/crypto/ICrypto.d.ts +58 -58
- package/dist/crypto/ICrypto.mjs +30 -30
- package/dist/crypto/IGuidGenerator.d.ts +4 -4
- package/dist/crypto/JoseHeader.d.ts +22 -22
- package/dist/crypto/JoseHeader.mjs +37 -37
- package/dist/crypto/PopTokenGenerator.d.ts +60 -60
- package/dist/crypto/PopTokenGenerator.mjs +82 -82
- package/dist/crypto/SignedHttpRequest.d.ts +15 -15
- package/dist/error/AuthError.d.ts +44 -44
- package/dist/error/AuthError.mjs +46 -46
- package/dist/error/AuthErrorCodes.d.ts +5 -5
- package/dist/error/AuthErrorCodes.mjs +9 -9
- package/dist/error/ClientAuthError.d.ts +237 -237
- package/dist/error/ClientAuthError.mjs +249 -249
- package/dist/error/ClientAuthErrorCodes.d.ts +44 -44
- package/dist/error/ClientAuthErrorCodes.mjs +48 -48
- package/dist/error/ClientConfigurationError.d.ts +128 -128
- package/dist/error/ClientConfigurationError.mjs +135 -135
- package/dist/error/ClientConfigurationErrorCodes.d.ts +22 -22
- package/dist/error/ClientConfigurationErrorCodes.mjs +26 -26
- package/dist/error/InteractionRequiredAuthError.d.ts +61 -61
- package/dist/error/InteractionRequiredAuthError.mjs +84 -84
- package/dist/error/InteractionRequiredAuthErrorCodes.d.ts +7 -7
- package/dist/error/InteractionRequiredAuthErrorCodes.mjs +13 -13
- package/dist/error/JoseHeaderError.d.ts +15 -15
- package/dist/error/JoseHeaderError.mjs +22 -22
- package/dist/error/JoseHeaderErrorCodes.d.ts +2 -2
- package/dist/error/JoseHeaderErrorCodes.mjs +6 -6
- package/dist/error/ServerError.d.ts +7 -7
- package/dist/error/ServerError.mjs +14 -14
- package/dist/index.cjs +8081 -8611
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +99 -99
- package/dist/index.d.ts.map +1 -1
- package/dist/index.mjs +4 -5
- package/dist/index.mjs.map +1 -1
- package/dist/logger/Logger.d.ts +95 -95
- package/dist/logger/Logger.mjs +188 -188
- package/dist/network/INetworkModule.d.ts +29 -29
- package/dist/network/INetworkModule.mjs +12 -12
- package/dist/network/NetworkManager.d.ts +33 -33
- package/dist/network/NetworkManager.mjs +34 -34
- package/dist/network/RequestThumbprint.d.ts +18 -18
- package/dist/network/ThrottlingUtils.d.ts +42 -42
- package/dist/network/ThrottlingUtils.mjs +95 -95
- package/dist/packageMetadata.d.ts +2 -2
- package/dist/packageMetadata.d.ts.map +1 -1
- package/dist/packageMetadata.mjs +4 -4
- package/dist/request/AuthenticationHeaderParser.d.ts +19 -19
- package/dist/request/AuthenticationHeaderParser.mjs +55 -55
- package/dist/request/BaseAuthRequest.d.ts +43 -43
- package/dist/request/CommonAuthorizationCodeRequest.d.ts +27 -27
- package/dist/request/CommonAuthorizationUrlRequest.d.ts +50 -50
- package/dist/request/CommonClientCredentialRequest.d.ts +17 -17
- package/dist/request/CommonDeviceCodeRequest.d.ts +21 -21
- package/dist/request/CommonEndSessionRequest.d.ts +21 -21
- package/dist/request/CommonOnBehalfOfRequest.d.ts +13 -13
- package/dist/request/CommonRefreshTokenRequest.d.ts +22 -22
- package/dist/request/CommonSilentFlowRequest.d.ts +27 -27
- package/dist/request/CommonUsernamePasswordRequest.d.ts +17 -17
- package/dist/request/NativeRequest.d.ts +19 -19
- package/dist/request/NativeSignOutRequest.d.ts +5 -5
- package/dist/request/RequestParameterBuilder.d.ts +217 -217
- package/dist/request/RequestParameterBuilder.mjs +381 -381
- package/dist/request/RequestValidator.d.ts +33 -33
- package/dist/request/RequestValidator.mjs +81 -81
- package/dist/request/ScopeSet.d.ts +88 -88
- package/dist/request/ScopeSet.mjs +197 -197
- package/dist/request/StoreInCache.d.ts +8 -8
- package/dist/response/AuthenticationResult.d.ts +41 -41
- package/dist/response/AuthorizationCodePayload.d.ts +13 -13
- package/dist/response/DeviceCodeResponse.d.ts +25 -25
- package/dist/response/ExternalTokenResponse.d.ts +15 -15
- package/dist/response/IMDSBadResponse.d.ts +4 -4
- package/dist/response/ResponseHandler.d.ts +69 -69
- package/dist/response/ResponseHandler.mjs +350 -347
- package/dist/response/ResponseHandler.mjs.map +1 -1
- package/dist/response/ServerAuthorizationCodeResponse.d.ts +25 -25
- package/dist/response/ServerAuthorizationTokenResponse.d.ts +47 -47
- package/dist/telemetry/performance/IPerformanceClient.d.ts +57 -57
- package/dist/telemetry/performance/IPerformanceMeasurement.d.ts +5 -5
- package/dist/telemetry/performance/PerformanceClient.d.ts +198 -198
- package/dist/telemetry/performance/PerformanceClient.mjs +412 -412
- package/dist/telemetry/performance/PerformanceEvent.d.ts +464 -464
- package/dist/telemetry/performance/PerformanceEvent.mjs +253 -253
- package/dist/telemetry/performance/StubPerformanceClient.d.ts +24 -24
- package/dist/telemetry/performance/StubPerformanceClient.mjs +76 -76
- package/dist/telemetry/server/ServerTelemetryManager.d.ts +66 -66
- package/dist/telemetry/server/ServerTelemetryManager.mjs +201 -201
- package/dist/telemetry/server/ServerTelemetryRequest.d.ts +8 -8
- package/dist/url/IUri.d.ts +12 -12
- package/dist/url/UrlString.d.ts +48 -48
- package/dist/url/UrlString.mjs +161 -161
- package/dist/utils/Constants.d.ts +296 -298
- package/dist/utils/Constants.d.ts.map +1 -1
- package/dist/utils/Constants.mjs +310 -313
- package/dist/utils/Constants.mjs.map +1 -1
- package/dist/utils/FunctionWrappers.d.ts +27 -27
- package/dist/utils/FunctionWrappers.mjs +84 -84
- package/dist/utils/MsalTypes.d.ts +6 -6
- package/dist/utils/ProtocolUtils.d.ts +42 -42
- package/dist/utils/ProtocolUtils.mjs +69 -69
- package/dist/utils/StringUtils.d.ts +40 -40
- package/dist/utils/StringUtils.mjs +95 -95
- package/dist/utils/TimeUtils.d.ts +27 -27
- package/dist/utils/TimeUtils.mjs +45 -45
- package/dist/utils/UrlUtils.d.ts +10 -10
- package/dist/utils/UrlUtils.mjs +44 -44
- package/package.json +1 -1
- package/src/authority/Authority.ts +69 -29
- package/src/authority/AuthorityFactory.ts +48 -92
- package/src/authority/AuthorityMetadata.ts +23 -526
- package/src/cache/entities/AppMetadataEntity.ts +6 -81
- package/src/cache/entities/AuthorityMetadataEntity.ts +2 -94
- package/src/cache/utils/CacheHelpers.ts +111 -0
- package/src/client/BaseClient.ts +10 -11
- package/src/config/ClientConfiguration.ts +4 -4
- package/src/index.ts +1 -2
- package/src/packageMetadata.ts +1 -1
- package/src/response/ResponseHandler.ts +5 -5
- package/src/utils/Constants.ts +0 -4
- package/dist/cache/entities/AppMetadataEntity.mjs +0 -73
- package/dist/cache/entities/AppMetadataEntity.mjs.map +0 -1
- package/dist/cache/entities/AuthorityMetadataEntity.mjs +0 -86
- package/dist/cache/entities/AuthorityMetadataEntity.mjs.map +0 -1
|
@@ -8,556 +8,53 @@ import { UrlString } from "../url/UrlString";
|
|
|
8
8
|
import { AuthorityMetadataSource } from "../utils/Constants";
|
|
9
9
|
import { StaticAuthorityOptions } from "./AuthorityOptions";
|
|
10
10
|
import { CloudDiscoveryMetadata } from "./CloudDiscoveryMetadata";
|
|
11
|
+
import { CloudInstanceDiscoveryResponse } from "./CloudInstanceDiscoveryResponse";
|
|
12
|
+
import { OpenIdConfigResponse } from "./OpenIdConfigResponse";
|
|
11
13
|
|
|
12
|
-
|
|
14
|
+
type RawMetadata = {
|
|
15
|
+
endpointMetadata: { [key: string]: OpenIdConfigResponse };
|
|
16
|
+
instanceDiscoveryMetadata: CloudInstanceDiscoveryResponse;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
export const rawMetdataJSON: RawMetadata = {
|
|
13
20
|
endpointMetadata: {
|
|
14
|
-
"
|
|
15
|
-
token_endpoint:
|
|
16
|
-
"https://login.microsoftonline.com/common/oauth2/v2.0/token",
|
|
17
|
-
token_endpoint_auth_methods_supported: [
|
|
18
|
-
"client_secret_post",
|
|
19
|
-
"private_key_jwt",
|
|
20
|
-
"client_secret_basic",
|
|
21
|
-
],
|
|
22
|
-
jwks_uri:
|
|
23
|
-
"https://login.microsoftonline.com/common/discovery/v2.0/keys",
|
|
24
|
-
response_modes_supported: ["query", "fragment", "form_post"],
|
|
25
|
-
subject_types_supported: ["pairwise"],
|
|
26
|
-
id_token_signing_alg_values_supported: ["RS256"],
|
|
27
|
-
response_types_supported: [
|
|
28
|
-
"code",
|
|
29
|
-
"id_token",
|
|
30
|
-
"code id_token",
|
|
31
|
-
"id_token token",
|
|
32
|
-
],
|
|
33
|
-
scopes_supported: ["openid", "profile", "email", "offline_access"],
|
|
34
|
-
issuer: "https://login.microsoftonline.com/{tenantid}/v2.0",
|
|
35
|
-
request_uri_parameter_supported: false,
|
|
36
|
-
userinfo_endpoint: "https://graph.microsoft.com/oidc/userinfo",
|
|
37
|
-
authorization_endpoint:
|
|
38
|
-
"https://login.microsoftonline.com/common/oauth2/v2.0/authorize",
|
|
39
|
-
device_authorization_endpoint:
|
|
40
|
-
"https://login.microsoftonline.com/common/oauth2/v2.0/devicecode",
|
|
41
|
-
http_logout_supported: true,
|
|
42
|
-
frontchannel_logout_supported: true,
|
|
43
|
-
end_session_endpoint:
|
|
44
|
-
"https://login.microsoftonline.com/common/oauth2/v2.0/logout",
|
|
45
|
-
claims_supported: [
|
|
46
|
-
"sub",
|
|
47
|
-
"iss",
|
|
48
|
-
"cloud_instance_name",
|
|
49
|
-
"cloud_instance_host_name",
|
|
50
|
-
"cloud_graph_host_name",
|
|
51
|
-
"msgraph_host",
|
|
52
|
-
"aud",
|
|
53
|
-
"exp",
|
|
54
|
-
"iat",
|
|
55
|
-
"auth_time",
|
|
56
|
-
"acr",
|
|
57
|
-
"nonce",
|
|
58
|
-
"preferred_username",
|
|
59
|
-
"name",
|
|
60
|
-
"tid",
|
|
61
|
-
"ver",
|
|
62
|
-
"at_hash",
|
|
63
|
-
"c_hash",
|
|
64
|
-
"email",
|
|
65
|
-
],
|
|
66
|
-
kerberos_endpoint:
|
|
67
|
-
"https://login.microsoftonline.com/common/kerberos",
|
|
68
|
-
tenant_region_scope: null,
|
|
69
|
-
cloud_instance_name: "microsoftonline.com",
|
|
70
|
-
cloud_graph_host_name: "graph.windows.net",
|
|
71
|
-
msgraph_host: "graph.microsoft.com",
|
|
72
|
-
rbac_url: "https://pas.windows.net",
|
|
73
|
-
},
|
|
74
|
-
"https://login.chinacloudapi.cn/common/": {
|
|
75
|
-
token_endpoint:
|
|
76
|
-
"https://login.chinacloudapi.cn/common/oauth2/v2.0/token",
|
|
77
|
-
token_endpoint_auth_methods_supported: [
|
|
78
|
-
"client_secret_post",
|
|
79
|
-
"private_key_jwt",
|
|
80
|
-
"client_secret_basic",
|
|
81
|
-
],
|
|
82
|
-
jwks_uri:
|
|
83
|
-
"https://login.chinacloudapi.cn/common/discovery/v2.0/keys",
|
|
84
|
-
response_modes_supported: ["query", "fragment", "form_post"],
|
|
85
|
-
subject_types_supported: ["pairwise"],
|
|
86
|
-
id_token_signing_alg_values_supported: ["RS256"],
|
|
87
|
-
response_types_supported: [
|
|
88
|
-
"code",
|
|
89
|
-
"id_token",
|
|
90
|
-
"code id_token",
|
|
91
|
-
"id_token token",
|
|
92
|
-
],
|
|
93
|
-
scopes_supported: ["openid", "profile", "email", "offline_access"],
|
|
94
|
-
issuer: "https://login.partner.microsoftonline.cn/{tenantid}/v2.0",
|
|
95
|
-
request_uri_parameter_supported: false,
|
|
96
|
-
userinfo_endpoint:
|
|
97
|
-
"https://microsoftgraph.chinacloudapi.cn/oidc/userinfo",
|
|
98
|
-
authorization_endpoint:
|
|
99
|
-
"https://login.chinacloudapi.cn/common/oauth2/v2.0/authorize",
|
|
100
|
-
device_authorization_endpoint:
|
|
101
|
-
"https://login.chinacloudapi.cn/common/oauth2/v2.0/devicecode",
|
|
102
|
-
http_logout_supported: true,
|
|
103
|
-
frontchannel_logout_supported: true,
|
|
104
|
-
end_session_endpoint:
|
|
105
|
-
"https://login.chinacloudapi.cn/common/oauth2/v2.0/logout",
|
|
106
|
-
claims_supported: [
|
|
107
|
-
"sub",
|
|
108
|
-
"iss",
|
|
109
|
-
"cloud_instance_name",
|
|
110
|
-
"cloud_instance_host_name",
|
|
111
|
-
"cloud_graph_host_name",
|
|
112
|
-
"msgraph_host",
|
|
113
|
-
"aud",
|
|
114
|
-
"exp",
|
|
115
|
-
"iat",
|
|
116
|
-
"auth_time",
|
|
117
|
-
"acr",
|
|
118
|
-
"nonce",
|
|
119
|
-
"preferred_username",
|
|
120
|
-
"name",
|
|
121
|
-
"tid",
|
|
122
|
-
"ver",
|
|
123
|
-
"at_hash",
|
|
124
|
-
"c_hash",
|
|
125
|
-
"email",
|
|
126
|
-
],
|
|
127
|
-
kerberos_endpoint: "https://login.chinacloudapi.cn/common/kerberos",
|
|
128
|
-
tenant_region_scope: null,
|
|
129
|
-
cloud_instance_name: "partner.microsoftonline.cn",
|
|
130
|
-
cloud_graph_host_name: "graph.chinacloudapi.cn",
|
|
131
|
-
msgraph_host: "microsoftgraph.chinacloudapi.cn",
|
|
132
|
-
rbac_url: "https://pas.chinacloudapi.cn",
|
|
133
|
-
},
|
|
134
|
-
"https://login.microsoftonline.us/common/": {
|
|
135
|
-
token_endpoint:
|
|
136
|
-
"https://login.microsoftonline.us/common/oauth2/v2.0/token",
|
|
137
|
-
token_endpoint_auth_methods_supported: [
|
|
138
|
-
"client_secret_post",
|
|
139
|
-
"private_key_jwt",
|
|
140
|
-
"client_secret_basic",
|
|
141
|
-
],
|
|
142
|
-
jwks_uri:
|
|
143
|
-
"https://login.microsoftonline.us/common/discovery/v2.0/keys",
|
|
144
|
-
response_modes_supported: ["query", "fragment", "form_post"],
|
|
145
|
-
subject_types_supported: ["pairwise"],
|
|
146
|
-
id_token_signing_alg_values_supported: ["RS256"],
|
|
147
|
-
response_types_supported: [
|
|
148
|
-
"code",
|
|
149
|
-
"id_token",
|
|
150
|
-
"code id_token",
|
|
151
|
-
"id_token token",
|
|
152
|
-
],
|
|
153
|
-
scopes_supported: ["openid", "profile", "email", "offline_access"],
|
|
154
|
-
issuer: "https://login.microsoftonline.us/{tenantid}/v2.0",
|
|
155
|
-
request_uri_parameter_supported: false,
|
|
156
|
-
userinfo_endpoint: "https://graph.microsoft.com/oidc/userinfo",
|
|
157
|
-
authorization_endpoint:
|
|
158
|
-
"https://login.microsoftonline.us/common/oauth2/v2.0/authorize",
|
|
159
|
-
device_authorization_endpoint:
|
|
160
|
-
"https://login.microsoftonline.us/common/oauth2/v2.0/devicecode",
|
|
161
|
-
http_logout_supported: true,
|
|
162
|
-
frontchannel_logout_supported: true,
|
|
163
|
-
end_session_endpoint:
|
|
164
|
-
"https://login.microsoftonline.us/common/oauth2/v2.0/logout",
|
|
165
|
-
claims_supported: [
|
|
166
|
-
"sub",
|
|
167
|
-
"iss",
|
|
168
|
-
"cloud_instance_name",
|
|
169
|
-
"cloud_instance_host_name",
|
|
170
|
-
"cloud_graph_host_name",
|
|
171
|
-
"msgraph_host",
|
|
172
|
-
"aud",
|
|
173
|
-
"exp",
|
|
174
|
-
"iat",
|
|
175
|
-
"auth_time",
|
|
176
|
-
"acr",
|
|
177
|
-
"nonce",
|
|
178
|
-
"preferred_username",
|
|
179
|
-
"name",
|
|
180
|
-
"tid",
|
|
181
|
-
"ver",
|
|
182
|
-
"at_hash",
|
|
183
|
-
"c_hash",
|
|
184
|
-
"email",
|
|
185
|
-
],
|
|
186
|
-
kerberos_endpoint:
|
|
187
|
-
"https://login.microsoftonline.us/common/kerberos",
|
|
188
|
-
tenant_region_scope: null,
|
|
189
|
-
cloud_instance_name: "microsoftonline.us",
|
|
190
|
-
cloud_graph_host_name: "graph.windows.net",
|
|
191
|
-
msgraph_host: "graph.microsoft.com",
|
|
192
|
-
rbac_url: "https://pasff.usgovcloudapi.net",
|
|
193
|
-
},
|
|
194
|
-
"https://login.microsoftonline.com/consumers/": {
|
|
195
|
-
token_endpoint:
|
|
196
|
-
"https://login.microsoftonline.com/consumers/oauth2/v2.0/token",
|
|
197
|
-
token_endpoint_auth_methods_supported: [
|
|
198
|
-
"client_secret_post",
|
|
199
|
-
"private_key_jwt",
|
|
200
|
-
"client_secret_basic",
|
|
201
|
-
],
|
|
202
|
-
jwks_uri:
|
|
203
|
-
"https://login.microsoftonline.com/consumers/discovery/v2.0/keys",
|
|
204
|
-
response_modes_supported: ["query", "fragment", "form_post"],
|
|
205
|
-
subject_types_supported: ["pairwise"],
|
|
206
|
-
id_token_signing_alg_values_supported: ["RS256"],
|
|
207
|
-
response_types_supported: [
|
|
208
|
-
"code",
|
|
209
|
-
"id_token",
|
|
210
|
-
"code id_token",
|
|
211
|
-
"id_token token",
|
|
212
|
-
],
|
|
213
|
-
scopes_supported: ["openid", "profile", "email", "offline_access"],
|
|
214
|
-
issuer: "https://login.microsoftonline.com/9188040d-6c67-4c5b-b112-36a304b66dad/v2.0",
|
|
215
|
-
request_uri_parameter_supported: false,
|
|
216
|
-
userinfo_endpoint: "https://graph.microsoft.com/oidc/userinfo",
|
|
217
|
-
authorization_endpoint:
|
|
218
|
-
"https://login.microsoftonline.com/consumers/oauth2/v2.0/authorize",
|
|
219
|
-
device_authorization_endpoint:
|
|
220
|
-
"https://login.microsoftonline.com/consumers/oauth2/v2.0/devicecode",
|
|
221
|
-
http_logout_supported: true,
|
|
222
|
-
frontchannel_logout_supported: true,
|
|
223
|
-
end_session_endpoint:
|
|
224
|
-
"https://login.microsoftonline.com/consumers/oauth2/v2.0/logout",
|
|
225
|
-
claims_supported: [
|
|
226
|
-
"sub",
|
|
227
|
-
"iss",
|
|
228
|
-
"cloud_instance_name",
|
|
229
|
-
"cloud_instance_host_name",
|
|
230
|
-
"cloud_graph_host_name",
|
|
231
|
-
"msgraph_host",
|
|
232
|
-
"aud",
|
|
233
|
-
"exp",
|
|
234
|
-
"iat",
|
|
235
|
-
"auth_time",
|
|
236
|
-
"acr",
|
|
237
|
-
"nonce",
|
|
238
|
-
"preferred_username",
|
|
239
|
-
"name",
|
|
240
|
-
"tid",
|
|
241
|
-
"ver",
|
|
242
|
-
"at_hash",
|
|
243
|
-
"c_hash",
|
|
244
|
-
"email",
|
|
245
|
-
],
|
|
246
|
-
kerberos_endpoint:
|
|
247
|
-
"https://login.microsoftonline.com/consumers/kerberos",
|
|
248
|
-
tenant_region_scope: null,
|
|
249
|
-
cloud_instance_name: "microsoftonline.com",
|
|
250
|
-
cloud_graph_host_name: "graph.windows.net",
|
|
251
|
-
msgraph_host: "graph.microsoft.com",
|
|
252
|
-
rbac_url: "https://pas.windows.net",
|
|
253
|
-
},
|
|
254
|
-
"https://login.chinacloudapi.cn/consumers/": {
|
|
255
|
-
token_endpoint:
|
|
256
|
-
"https://login.chinacloudapi.cn/consumers/oauth2/v2.0/token",
|
|
257
|
-
token_endpoint_auth_methods_supported: [
|
|
258
|
-
"client_secret_post",
|
|
259
|
-
"private_key_jwt",
|
|
260
|
-
"client_secret_basic",
|
|
261
|
-
],
|
|
262
|
-
jwks_uri:
|
|
263
|
-
"https://login.chinacloudapi.cn/consumers/discovery/v2.0/keys",
|
|
264
|
-
response_modes_supported: ["query", "fragment", "form_post"],
|
|
265
|
-
subject_types_supported: ["pairwise"],
|
|
266
|
-
id_token_signing_alg_values_supported: ["RS256"],
|
|
267
|
-
response_types_supported: [
|
|
268
|
-
"code",
|
|
269
|
-
"id_token",
|
|
270
|
-
"code id_token",
|
|
271
|
-
"id_token token",
|
|
272
|
-
],
|
|
273
|
-
scopes_supported: ["openid", "profile", "email", "offline_access"],
|
|
274
|
-
issuer: "https://login.partner.microsoftonline.cn/9188040d-6c67-4c5b-b112-36a304b66dad/v2.0",
|
|
275
|
-
request_uri_parameter_supported: false,
|
|
276
|
-
userinfo_endpoint:
|
|
277
|
-
"https://microsoftgraph.chinacloudapi.cn/oidc/userinfo",
|
|
278
|
-
authorization_endpoint:
|
|
279
|
-
"https://login.chinacloudapi.cn/consumers/oauth2/v2.0/authorize",
|
|
280
|
-
device_authorization_endpoint:
|
|
281
|
-
"https://login.chinacloudapi.cn/consumers/oauth2/v2.0/devicecode",
|
|
282
|
-
http_logout_supported: true,
|
|
283
|
-
frontchannel_logout_supported: true,
|
|
284
|
-
end_session_endpoint:
|
|
285
|
-
"https://login.chinacloudapi.cn/consumers/oauth2/v2.0/logout",
|
|
286
|
-
claims_supported: [
|
|
287
|
-
"sub",
|
|
288
|
-
"iss",
|
|
289
|
-
"cloud_instance_name",
|
|
290
|
-
"cloud_instance_host_name",
|
|
291
|
-
"cloud_graph_host_name",
|
|
292
|
-
"msgraph_host",
|
|
293
|
-
"aud",
|
|
294
|
-
"exp",
|
|
295
|
-
"iat",
|
|
296
|
-
"auth_time",
|
|
297
|
-
"acr",
|
|
298
|
-
"nonce",
|
|
299
|
-
"preferred_username",
|
|
300
|
-
"name",
|
|
301
|
-
"tid",
|
|
302
|
-
"ver",
|
|
303
|
-
"at_hash",
|
|
304
|
-
"c_hash",
|
|
305
|
-
"email",
|
|
306
|
-
],
|
|
307
|
-
kerberos_endpoint:
|
|
308
|
-
"https://login.chinacloudapi.cn/consumers/kerberos",
|
|
309
|
-
tenant_region_scope: null,
|
|
310
|
-
cloud_instance_name: "partner.microsoftonline.cn",
|
|
311
|
-
cloud_graph_host_name: "graph.chinacloudapi.cn",
|
|
312
|
-
msgraph_host: "microsoftgraph.chinacloudapi.cn",
|
|
313
|
-
rbac_url: "https://pas.chinacloudapi.cn",
|
|
314
|
-
},
|
|
315
|
-
"https://login.microsoftonline.us/consumers/": {
|
|
316
|
-
token_endpoint:
|
|
317
|
-
"https://login.microsoftonline.us/consumers/oauth2/v2.0/token",
|
|
318
|
-
token_endpoint_auth_methods_supported: [
|
|
319
|
-
"client_secret_post",
|
|
320
|
-
"private_key_jwt",
|
|
321
|
-
"client_secret_basic",
|
|
322
|
-
],
|
|
323
|
-
jwks_uri:
|
|
324
|
-
"https://login.microsoftonline.us/consumers/discovery/v2.0/keys",
|
|
325
|
-
response_modes_supported: ["query", "fragment", "form_post"],
|
|
326
|
-
subject_types_supported: ["pairwise"],
|
|
327
|
-
id_token_signing_alg_values_supported: ["RS256"],
|
|
328
|
-
response_types_supported: [
|
|
329
|
-
"code",
|
|
330
|
-
"id_token",
|
|
331
|
-
"code id_token",
|
|
332
|
-
"id_token token",
|
|
333
|
-
],
|
|
334
|
-
scopes_supported: ["openid", "profile", "email", "offline_access"],
|
|
335
|
-
issuer: "https://login.microsoftonline.us/9188040d-6c67-4c5b-b112-36a304b66dad/v2.0",
|
|
336
|
-
request_uri_parameter_supported: false,
|
|
337
|
-
userinfo_endpoint: "https://graph.microsoft.com/oidc/userinfo",
|
|
338
|
-
authorization_endpoint:
|
|
339
|
-
"https://login.microsoftonline.us/consumers/oauth2/v2.0/authorize",
|
|
340
|
-
device_authorization_endpoint:
|
|
341
|
-
"https://login.microsoftonline.us/consumers/oauth2/v2.0/devicecode",
|
|
342
|
-
http_logout_supported: true,
|
|
343
|
-
frontchannel_logout_supported: true,
|
|
344
|
-
end_session_endpoint:
|
|
345
|
-
"https://login.microsoftonline.us/consumers/oauth2/v2.0/logout",
|
|
346
|
-
claims_supported: [
|
|
347
|
-
"sub",
|
|
348
|
-
"iss",
|
|
349
|
-
"cloud_instance_name",
|
|
350
|
-
"cloud_instance_host_name",
|
|
351
|
-
"cloud_graph_host_name",
|
|
352
|
-
"msgraph_host",
|
|
353
|
-
"aud",
|
|
354
|
-
"exp",
|
|
355
|
-
"iat",
|
|
356
|
-
"auth_time",
|
|
357
|
-
"acr",
|
|
358
|
-
"nonce",
|
|
359
|
-
"preferred_username",
|
|
360
|
-
"name",
|
|
361
|
-
"tid",
|
|
362
|
-
"ver",
|
|
363
|
-
"at_hash",
|
|
364
|
-
"c_hash",
|
|
365
|
-
"email",
|
|
366
|
-
],
|
|
367
|
-
kerberos_endpoint:
|
|
368
|
-
"https://login.microsoftonline.us/consumers/kerberos",
|
|
369
|
-
tenant_region_scope: null,
|
|
370
|
-
cloud_instance_name: "microsoftonline.us",
|
|
371
|
-
cloud_graph_host_name: "graph.windows.net",
|
|
372
|
-
msgraph_host: "graph.microsoft.com",
|
|
373
|
-
rbac_url: "https://pasff.usgovcloudapi.net",
|
|
374
|
-
},
|
|
375
|
-
"https://login.microsoftonline.com/organizations/": {
|
|
21
|
+
"login.microsoftonline.com": {
|
|
376
22
|
token_endpoint:
|
|
377
|
-
"https://login.microsoftonline.com/
|
|
378
|
-
token_endpoint_auth_methods_supported: [
|
|
379
|
-
"client_secret_post",
|
|
380
|
-
"private_key_jwt",
|
|
381
|
-
"client_secret_basic",
|
|
382
|
-
],
|
|
23
|
+
"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/token",
|
|
383
24
|
jwks_uri:
|
|
384
|
-
"https://login.microsoftonline.com/
|
|
385
|
-
response_modes_supported: ["query", "fragment", "form_post"],
|
|
386
|
-
subject_types_supported: ["pairwise"],
|
|
387
|
-
id_token_signing_alg_values_supported: ["RS256"],
|
|
388
|
-
response_types_supported: [
|
|
389
|
-
"code",
|
|
390
|
-
"id_token",
|
|
391
|
-
"code id_token",
|
|
392
|
-
"id_token token",
|
|
393
|
-
],
|
|
394
|
-
scopes_supported: ["openid", "profile", "email", "offline_access"],
|
|
25
|
+
"https://login.microsoftonline.com/{tenantid}/discovery/v2.0/keys",
|
|
395
26
|
issuer: "https://login.microsoftonline.com/{tenantid}/v2.0",
|
|
396
|
-
request_uri_parameter_supported: false,
|
|
397
|
-
userinfo_endpoint: "https://graph.microsoft.com/oidc/userinfo",
|
|
398
27
|
authorization_endpoint:
|
|
399
|
-
"https://login.microsoftonline.com/
|
|
400
|
-
device_authorization_endpoint:
|
|
401
|
-
"https://login.microsoftonline.com/organizations/oauth2/v2.0/devicecode",
|
|
402
|
-
http_logout_supported: true,
|
|
403
|
-
frontchannel_logout_supported: true,
|
|
28
|
+
"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/authorize",
|
|
404
29
|
end_session_endpoint:
|
|
405
|
-
"https://login.microsoftonline.com/
|
|
406
|
-
claims_supported: [
|
|
407
|
-
"sub",
|
|
408
|
-
"iss",
|
|
409
|
-
"cloud_instance_name",
|
|
410
|
-
"cloud_instance_host_name",
|
|
411
|
-
"cloud_graph_host_name",
|
|
412
|
-
"msgraph_host",
|
|
413
|
-
"aud",
|
|
414
|
-
"exp",
|
|
415
|
-
"iat",
|
|
416
|
-
"auth_time",
|
|
417
|
-
"acr",
|
|
418
|
-
"nonce",
|
|
419
|
-
"preferred_username",
|
|
420
|
-
"name",
|
|
421
|
-
"tid",
|
|
422
|
-
"ver",
|
|
423
|
-
"at_hash",
|
|
424
|
-
"c_hash",
|
|
425
|
-
"email",
|
|
426
|
-
],
|
|
427
|
-
kerberos_endpoint:
|
|
428
|
-
"https://login.microsoftonline.com/organizations/kerberos",
|
|
429
|
-
tenant_region_scope: null,
|
|
430
|
-
cloud_instance_name: "microsoftonline.com",
|
|
431
|
-
cloud_graph_host_name: "graph.windows.net",
|
|
432
|
-
msgraph_host: "graph.microsoft.com",
|
|
433
|
-
rbac_url: "https://pas.windows.net",
|
|
30
|
+
"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/logout",
|
|
434
31
|
},
|
|
435
|
-
"
|
|
32
|
+
"login.chinacloudapi.cn": {
|
|
436
33
|
token_endpoint:
|
|
437
|
-
"https://login.chinacloudapi.cn/
|
|
438
|
-
token_endpoint_auth_methods_supported: [
|
|
439
|
-
"client_secret_post",
|
|
440
|
-
"private_key_jwt",
|
|
441
|
-
"client_secret_basic",
|
|
442
|
-
],
|
|
34
|
+
"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/token",
|
|
443
35
|
jwks_uri:
|
|
444
|
-
"https://login.chinacloudapi.cn/
|
|
445
|
-
response_modes_supported: ["query", "fragment", "form_post"],
|
|
446
|
-
subject_types_supported: ["pairwise"],
|
|
447
|
-
id_token_signing_alg_values_supported: ["RS256"],
|
|
448
|
-
response_types_supported: [
|
|
449
|
-
"code",
|
|
450
|
-
"id_token",
|
|
451
|
-
"code id_token",
|
|
452
|
-
"id_token token",
|
|
453
|
-
],
|
|
454
|
-
scopes_supported: ["openid", "profile", "email", "offline_access"],
|
|
36
|
+
"https://login.chinacloudapi.cn/{tenantid}/discovery/v2.0/keys",
|
|
455
37
|
issuer: "https://login.partner.microsoftonline.cn/{tenantid}/v2.0",
|
|
456
|
-
request_uri_parameter_supported: false,
|
|
457
|
-
userinfo_endpoint:
|
|
458
|
-
"https://microsoftgraph.chinacloudapi.cn/oidc/userinfo",
|
|
459
38
|
authorization_endpoint:
|
|
460
|
-
"https://login.chinacloudapi.cn/
|
|
461
|
-
device_authorization_endpoint:
|
|
462
|
-
"https://login.chinacloudapi.cn/organizations/oauth2/v2.0/devicecode",
|
|
463
|
-
http_logout_supported: true,
|
|
464
|
-
frontchannel_logout_supported: true,
|
|
39
|
+
"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/authorize",
|
|
465
40
|
end_session_endpoint:
|
|
466
|
-
"https://login.chinacloudapi.cn/
|
|
467
|
-
claims_supported: [
|
|
468
|
-
"sub",
|
|
469
|
-
"iss",
|
|
470
|
-
"cloud_instance_name",
|
|
471
|
-
"cloud_instance_host_name",
|
|
472
|
-
"cloud_graph_host_name",
|
|
473
|
-
"msgraph_host",
|
|
474
|
-
"aud",
|
|
475
|
-
"exp",
|
|
476
|
-
"iat",
|
|
477
|
-
"auth_time",
|
|
478
|
-
"acr",
|
|
479
|
-
"nonce",
|
|
480
|
-
"preferred_username",
|
|
481
|
-
"name",
|
|
482
|
-
"tid",
|
|
483
|
-
"ver",
|
|
484
|
-
"at_hash",
|
|
485
|
-
"c_hash",
|
|
486
|
-
"email",
|
|
487
|
-
],
|
|
488
|
-
kerberos_endpoint:
|
|
489
|
-
"https://login.chinacloudapi.cn/organizations/kerberos",
|
|
490
|
-
tenant_region_scope: null,
|
|
491
|
-
cloud_instance_name: "partner.microsoftonline.cn",
|
|
492
|
-
cloud_graph_host_name: "graph.chinacloudapi.cn",
|
|
493
|
-
msgraph_host: "microsoftgraph.chinacloudapi.cn",
|
|
494
|
-
rbac_url: "https://pas.chinacloudapi.cn",
|
|
41
|
+
"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/logout",
|
|
495
42
|
},
|
|
496
|
-
"
|
|
43
|
+
"login.microsoftonline.us": {
|
|
497
44
|
token_endpoint:
|
|
498
|
-
"https://login.microsoftonline.us/
|
|
499
|
-
token_endpoint_auth_methods_supported: [
|
|
500
|
-
"client_secret_post",
|
|
501
|
-
"private_key_jwt",
|
|
502
|
-
"client_secret_basic",
|
|
503
|
-
],
|
|
45
|
+
"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/token",
|
|
504
46
|
jwks_uri:
|
|
505
|
-
"https://login.microsoftonline.us/
|
|
506
|
-
response_modes_supported: ["query", "fragment", "form_post"],
|
|
507
|
-
subject_types_supported: ["pairwise"],
|
|
508
|
-
id_token_signing_alg_values_supported: ["RS256"],
|
|
509
|
-
response_types_supported: [
|
|
510
|
-
"code",
|
|
511
|
-
"id_token",
|
|
512
|
-
"code id_token",
|
|
513
|
-
"id_token token",
|
|
514
|
-
],
|
|
515
|
-
scopes_supported: ["openid", "profile", "email", "offline_access"],
|
|
47
|
+
"https://login.microsoftonline.us/{tenantid}/discovery/v2.0/keys",
|
|
516
48
|
issuer: "https://login.microsoftonline.us/{tenantid}/v2.0",
|
|
517
|
-
request_uri_parameter_supported: false,
|
|
518
|
-
userinfo_endpoint: "https://graph.microsoft.com/oidc/userinfo",
|
|
519
49
|
authorization_endpoint:
|
|
520
|
-
"https://login.microsoftonline.us/
|
|
521
|
-
device_authorization_endpoint:
|
|
522
|
-
"https://login.microsoftonline.us/organizations/oauth2/v2.0/devicecode",
|
|
523
|
-
http_logout_supported: true,
|
|
524
|
-
frontchannel_logout_supported: true,
|
|
50
|
+
"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/authorize",
|
|
525
51
|
end_session_endpoint:
|
|
526
|
-
"https://login.microsoftonline.us/
|
|
527
|
-
claims_supported: [
|
|
528
|
-
"sub",
|
|
529
|
-
"iss",
|
|
530
|
-
"cloud_instance_name",
|
|
531
|
-
"cloud_instance_host_name",
|
|
532
|
-
"cloud_graph_host_name",
|
|
533
|
-
"msgraph_host",
|
|
534
|
-
"aud",
|
|
535
|
-
"exp",
|
|
536
|
-
"iat",
|
|
537
|
-
"auth_time",
|
|
538
|
-
"acr",
|
|
539
|
-
"nonce",
|
|
540
|
-
"preferred_username",
|
|
541
|
-
"name",
|
|
542
|
-
"tid",
|
|
543
|
-
"ver",
|
|
544
|
-
"at_hash",
|
|
545
|
-
"c_hash",
|
|
546
|
-
"email",
|
|
547
|
-
],
|
|
548
|
-
kerberos_endpoint:
|
|
549
|
-
"https://login.microsoftonline.us/organizations/kerberos",
|
|
550
|
-
tenant_region_scope: null,
|
|
551
|
-
cloud_instance_name: "microsoftonline.us",
|
|
552
|
-
cloud_graph_host_name: "graph.windows.net",
|
|
553
|
-
msgraph_host: "graph.microsoft.com",
|
|
554
|
-
rbac_url: "https://pasff.usgovcloudapi.net",
|
|
52
|
+
"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/logout",
|
|
555
53
|
},
|
|
556
54
|
},
|
|
557
55
|
instanceDiscoveryMetadata: {
|
|
558
56
|
tenant_discovery_endpoint:
|
|
559
57
|
"https://{canonicalAuthority}/v2.0/.well-known/openid-configuration",
|
|
560
|
-
"api-version": "1.1",
|
|
561
58
|
metadata: [
|
|
562
59
|
{
|
|
563
60
|
preferred_network: "login.microsoftonline.com",
|
|
@@ -3,89 +3,14 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { APP_METADATA, Separators } from "../../utils/Constants";
|
|
7
|
-
|
|
8
6
|
/**
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* Key:Value Schema:
|
|
12
|
-
*
|
|
13
|
-
* Key: appmetadata-<environment>-<client_id>
|
|
14
|
-
*
|
|
15
|
-
* Value:
|
|
16
|
-
* {
|
|
17
|
-
* clientId: client ID of the application
|
|
18
|
-
* environment: entity that issued the token, represented as a full host
|
|
19
|
-
* familyId: Family ID identifier, '1' represents Microsoft Family
|
|
20
|
-
* }
|
|
7
|
+
* App Metadata Cache Type
|
|
21
8
|
*/
|
|
22
|
-
export
|
|
9
|
+
export type AppMetadataEntity = {
|
|
10
|
+
/** clientId of the application */
|
|
23
11
|
clientId: string;
|
|
12
|
+
/** entity that issued the token, represented as a full host */
|
|
24
13
|
environment: string;
|
|
14
|
+
/** Family identifier, '1' represents Microsoft Family */
|
|
25
15
|
familyId?: string;
|
|
26
|
-
|
|
27
|
-
/**
|
|
28
|
-
* Generate AppMetadata Cache Key as per the schema: appmetadata-<environment>-<client_id>
|
|
29
|
-
*/
|
|
30
|
-
generateAppMetadataKey(): string {
|
|
31
|
-
return AppMetadataEntity.generateAppMetadataCacheKey(
|
|
32
|
-
this.environment,
|
|
33
|
-
this.clientId
|
|
34
|
-
);
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
/**
|
|
38
|
-
* Generate AppMetadata Cache Key
|
|
39
|
-
*/
|
|
40
|
-
static generateAppMetadataCacheKey(
|
|
41
|
-
environment: string,
|
|
42
|
-
clientId: string
|
|
43
|
-
): string {
|
|
44
|
-
const appMetaDataKeyArray: Array<string> = [
|
|
45
|
-
APP_METADATA,
|
|
46
|
-
environment,
|
|
47
|
-
clientId,
|
|
48
|
-
];
|
|
49
|
-
return appMetaDataKeyArray
|
|
50
|
-
.join(Separators.CACHE_KEY_SEPARATOR)
|
|
51
|
-
.toLowerCase();
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
/**
|
|
55
|
-
* Creates AppMetadataEntity
|
|
56
|
-
* @param clientId
|
|
57
|
-
* @param environment
|
|
58
|
-
* @param familyId
|
|
59
|
-
*/
|
|
60
|
-
static createAppMetadataEntity(
|
|
61
|
-
clientId: string,
|
|
62
|
-
environment: string,
|
|
63
|
-
familyId?: string
|
|
64
|
-
): AppMetadataEntity {
|
|
65
|
-
const appMetadata = new AppMetadataEntity();
|
|
66
|
-
|
|
67
|
-
appMetadata.clientId = clientId;
|
|
68
|
-
appMetadata.environment = environment;
|
|
69
|
-
if (familyId) {
|
|
70
|
-
appMetadata.familyId = familyId;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
return appMetadata;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
/**
|
|
77
|
-
* Validates an entity: checks for all expected params
|
|
78
|
-
* @param entity
|
|
79
|
-
*/
|
|
80
|
-
static isAppMetadataEntity(key: string, entity: object): boolean {
|
|
81
|
-
if (!entity) {
|
|
82
|
-
return false;
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
return (
|
|
86
|
-
key.indexOf(APP_METADATA) === 0 &&
|
|
87
|
-
entity.hasOwnProperty("clientId") &&
|
|
88
|
-
entity.hasOwnProperty("environment")
|
|
89
|
-
);
|
|
90
|
-
}
|
|
91
|
-
}
|
|
16
|
+
};
|