@azure/identity 4.0.0-alpha.20230210.3 → 4.0.0-alpha.20231026.4
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.
Potentially problematic release.
This version of @azure/identity might be problematic. Click here for more details.
- package/README.md +39 -65
- package/dist/index.js +846 -577
- package/dist/index.js.map +1 -1
- package/dist-esm/src/client/identityClient.js +11 -2
- package/dist-esm/src/client/identityClient.js.map +1 -1
- package/dist-esm/src/constants.js +2 -0
- package/dist-esm/src/constants.js.map +1 -1
- package/dist-esm/src/credentials/authorityValidationOptions.js.map +1 -1
- package/dist-esm/src/credentials/authorizationCodeCredential.js +6 -6
- package/dist-esm/src/credentials/authorizationCodeCredential.js.map +1 -1
- package/dist-esm/src/credentials/azureCliCredential.js +17 -10
- package/dist-esm/src/credentials/azureCliCredential.js.map +1 -1
- package/dist-esm/src/credentials/azureCliCredentialOptions.js.map +1 -1
- package/dist-esm/src/credentials/azureDeveloperCliCredential.js +52 -18
- package/dist-esm/src/credentials/azureDeveloperCliCredential.js.map +1 -1
- package/dist-esm/src/credentials/azureDeveloperCliCredentialOptions.js.map +1 -1
- package/dist-esm/src/credentials/azurePowerShellCredential.js +27 -13
- package/dist-esm/src/credentials/azurePowerShellCredential.js.map +1 -1
- package/dist-esm/src/credentials/azurePowerShellCredentialOptions.js.map +1 -1
- package/dist-esm/src/credentials/brokerAuthOptions.js +2 -0
- package/dist-esm/src/credentials/brokerAuthOptions.js.map +1 -0
- package/dist-esm/src/credentials/browserCustomizationOptions.js +4 -0
- package/dist-esm/src/credentials/browserCustomizationOptions.js.map +1 -0
- package/dist-esm/src/credentials/chainedTokenCredential.js +8 -4
- package/dist-esm/src/credentials/chainedTokenCredential.js.map +1 -1
- package/dist-esm/src/credentials/clientAssertionCredential.js +6 -6
- package/dist-esm/src/credentials/clientAssertionCredential.js.map +1 -1
- package/dist-esm/src/credentials/clientCertificateCredential.browser.js +1 -1
- package/dist-esm/src/credentials/clientCertificateCredential.browser.js.map +1 -1
- package/dist-esm/src/credentials/clientCertificateCredential.js +6 -6
- package/dist-esm/src/credentials/clientCertificateCredential.js.map +1 -1
- package/dist-esm/src/credentials/clientSecretCredential.browser.js +7 -7
- package/dist-esm/src/credentials/clientSecretCredential.browser.js.map +1 -1
- package/dist-esm/src/credentials/clientSecretCredential.js +8 -8
- package/dist-esm/src/credentials/clientSecretCredential.js.map +1 -1
- package/dist-esm/src/credentials/defaultAzureCredential.js +56 -4
- package/dist-esm/src/credentials/defaultAzureCredential.js.map +1 -1
- package/dist-esm/src/credentials/defaultAzureCredentialOptions.js.map +1 -1
- package/dist-esm/src/credentials/deviceCodeCredential.browser.js +1 -1
- package/dist-esm/src/credentials/deviceCodeCredential.browser.js.map +1 -1
- package/dist-esm/src/credentials/deviceCodeCredential.js +7 -7
- package/dist-esm/src/credentials/deviceCodeCredential.js.map +1 -1
- package/dist-esm/src/credentials/deviceCodeCredentialOptions.js.map +1 -1
- package/dist-esm/src/credentials/environmentCredential.browser.js +1 -1
- package/dist-esm/src/credentials/environmentCredential.browser.js.map +1 -1
- package/dist-esm/src/credentials/environmentCredential.js +3 -3
- package/dist-esm/src/credentials/environmentCredential.js.map +1 -1
- package/dist-esm/src/credentials/environmentCredentialOptions.js.map +1 -1
- package/dist-esm/src/credentials/interactiveBrowserCredential.browser.js +9 -9
- package/dist-esm/src/credentials/interactiveBrowserCredential.browser.js.map +1 -1
- package/dist-esm/src/credentials/interactiveBrowserCredential.js +29 -12
- package/dist-esm/src/credentials/interactiveBrowserCredential.js.map +1 -1
- package/dist-esm/src/credentials/interactiveBrowserCredentialOptions.js.map +1 -1
- package/dist-esm/src/credentials/managedIdentityCredential/appServiceMsi2017.js +1 -0
- package/dist-esm/src/credentials/managedIdentityCredential/appServiceMsi2017.js.map +1 -1
- package/dist-esm/src/credentials/managedIdentityCredential/appServiceMsi2019.js +1 -0
- package/dist-esm/src/credentials/managedIdentityCredential/appServiceMsi2019.js.map +1 -1
- package/dist-esm/src/credentials/managedIdentityCredential/arcMsi.js +1 -0
- package/dist-esm/src/credentials/managedIdentityCredential/arcMsi.js.map +1 -1
- package/dist-esm/src/credentials/managedIdentityCredential/cloudShellMsi.js +1 -0
- package/dist-esm/src/credentials/managedIdentityCredential/cloudShellMsi.js.map +1 -1
- package/dist-esm/src/credentials/managedIdentityCredential/fabricMsi.js +1 -0
- package/dist-esm/src/credentials/managedIdentityCredential/fabricMsi.js.map +1 -1
- package/dist-esm/src/credentials/managedIdentityCredential/imdsMsi.js +15 -4
- package/dist-esm/src/credentials/managedIdentityCredential/imdsMsi.js.map +1 -1
- package/dist-esm/src/credentials/managedIdentityCredential/index.js +65 -31
- package/dist-esm/src/credentials/managedIdentityCredential/index.js.map +1 -1
- package/dist-esm/src/credentials/managedIdentityCredential/models.js.map +1 -1
- package/dist-esm/src/credentials/managedIdentityCredential/tokenExchangeMsi.js +10 -65
- package/dist-esm/src/credentials/managedIdentityCredential/tokenExchangeMsi.js.map +1 -1
- package/dist-esm/src/credentials/managedIdentityCredential/utils.js +1 -1
- package/dist-esm/src/credentials/managedIdentityCredential/utils.js.map +1 -1
- package/dist-esm/src/credentials/onBehalfOfCredential.browser.js +1 -1
- package/dist-esm/src/credentials/onBehalfOfCredential.browser.js.map +1 -1
- package/dist-esm/src/credentials/onBehalfOfCredential.js +5 -5
- package/dist-esm/src/credentials/onBehalfOfCredential.js.map +1 -1
- package/dist-esm/src/credentials/onBehalfOfCredentialOptions.js.map +1 -1
- package/dist-esm/src/credentials/usernamePasswordCredential.browser.js +6 -6
- package/dist-esm/src/credentials/usernamePasswordCredential.browser.js.map +1 -1
- package/dist-esm/src/credentials/usernamePasswordCredential.js +7 -7
- package/dist-esm/src/credentials/usernamePasswordCredential.js.map +1 -1
- package/dist-esm/src/credentials/usernamePasswordCredentialOptions.js.map +1 -1
- package/dist-esm/src/credentials/visualStudioCodeCredential.js +3 -4
- package/dist-esm/src/credentials/visualStudioCodeCredential.js.map +1 -1
- package/dist-esm/src/credentials/workloadIdentityCredential.browser.js +27 -0
- package/dist-esm/src/credentials/workloadIdentityCredential.browser.js.map +1 -0
- package/dist-esm/src/credentials/workloadIdentityCredential.js +104 -0
- package/dist-esm/src/credentials/workloadIdentityCredential.js.map +1 -0
- package/dist-esm/src/credentials/workloadIdentityCredentialOptions.js +4 -0
- package/dist-esm/src/credentials/workloadIdentityCredentialOptions.js.map +1 -0
- package/dist-esm/src/errors.js.map +1 -1
- package/dist-esm/src/index.js +2 -0
- package/dist-esm/src/index.js.map +1 -1
- package/dist-esm/src/msal/browserFlows/msalAuthCode.js +3 -1
- package/dist-esm/src/msal/browserFlows/msalAuthCode.js.map +1 -1
- package/dist-esm/src/msal/browserFlows/msalBrowserCommon.js +2 -2
- package/dist-esm/src/msal/browserFlows/msalBrowserCommon.js.map +1 -1
- package/dist-esm/src/msal/credentials.js.map +1 -1
- package/dist-esm/src/msal/flows.js.map +1 -1
- package/dist-esm/src/msal/nodeFlows/brokerOptions.js +2 -0
- package/dist-esm/src/msal/nodeFlows/brokerOptions.js.map +1 -0
- package/dist-esm/src/msal/nodeFlows/msalAuthorizationCode.js +6 -4
- package/dist-esm/src/msal/nodeFlows/msalAuthorizationCode.js.map +1 -1
- package/dist-esm/src/msal/nodeFlows/msalClientAssertion.js +1 -1
- package/dist-esm/src/msal/nodeFlows/msalClientAssertion.js.map +1 -1
- package/dist-esm/src/msal/nodeFlows/msalClientCertificate.js +1 -1
- package/dist-esm/src/msal/nodeFlows/msalClientCertificate.js.map +1 -1
- package/dist-esm/src/msal/nodeFlows/msalClientSecret.js +1 -1
- package/dist-esm/src/msal/nodeFlows/msalClientSecret.js.map +1 -1
- package/dist-esm/src/msal/nodeFlows/msalDeviceCode.js +1 -1
- package/dist-esm/src/msal/nodeFlows/msalDeviceCode.js.map +1 -1
- package/dist-esm/src/msal/nodeFlows/msalNodeCommon.js +117 -21
- package/dist-esm/src/msal/nodeFlows/msalNodeCommon.js.map +1 -1
- package/dist-esm/src/msal/nodeFlows/msalOnBehalfOf.js +1 -1
- package/dist-esm/src/msal/nodeFlows/msalOnBehalfOf.js.map +1 -1
- package/dist-esm/src/msal/nodeFlows/msalOpenBrowser.js +40 -139
- package/dist-esm/src/msal/nodeFlows/msalOpenBrowser.js.map +1 -1
- package/dist-esm/src/msal/nodeFlows/msalUsernamePassword.js +1 -1
- package/dist-esm/src/msal/nodeFlows/msalUsernamePassword.js.map +1 -1
- package/dist-esm/src/msal/types.js.map +1 -1
- package/dist-esm/src/msal/utils.browser.js +236 -0
- package/dist-esm/src/msal/utils.browser.js.map +1 -0
- package/dist-esm/src/msal/utils.js +8 -5
- package/dist-esm/src/msal/utils.js.map +1 -1
- package/dist-esm/src/plugins/consumer.js +2 -1
- package/dist-esm/src/plugins/consumer.js.map +1 -1
- package/dist-esm/src/plugins/provider.js.map +1 -1
- package/dist-esm/src/tokenCredentialOptions.js.map +1 -1
- package/dist-esm/src/util/processMultiTenantRequest.js +5 -2
- package/dist-esm/src/util/processMultiTenantRequest.js.map +1 -1
- package/dist-esm/src/util/scopeUtils.js +2 -2
- package/dist-esm/src/util/scopeUtils.js.map +1 -1
- package/dist-esm/src/util/tenantIdUtils.js +3 -3
- package/dist-esm/src/util/tenantIdUtils.js.map +1 -1
- package/package.json +21 -19
- package/types/identity.d.ts +297 -67
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tenantIdUtils.js","sourceRoot":"","sources":["../../../src/util/tenantIdUtils.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,WAAW,EAAE,uBAAuB,EAAE,MAAM,cAAc,CAAC;AACpE,OAAO,EAAoB,WAAW,EAAE,MAAM,WAAW,CAAC;AAC1D,OAAO,EAAE,yBAAyB,EAAE,MAAM,6BAA6B,CAAC;AAExE;;GAEG;AACH,MAAM,UAAU,aAAa,CAAC,MAAwB,EAAE,QAAgB;IACtE,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,
|
|
1
|
+
{"version":3,"file":"tenantIdUtils.js","sourceRoot":"","sources":["../../../src/util/tenantIdUtils.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,OAAO,EAAE,WAAW,EAAE,uBAAuB,EAAE,MAAM,cAAc,CAAC;AACpE,OAAO,EAAoB,WAAW,EAAE,MAAM,WAAW,CAAC;AAC1D,OAAO,EAAE,yBAAyB,EAAE,MAAM,6BAA6B,CAAC;AAExE;;GAEG;AACH,MAAM,UAAU,aAAa,CAAC,MAAwB,EAAE,QAAgB;IACtE,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,kBAAkB,CAAC,EAAE;QACvC,MAAM,KAAK,GAAG,IAAI,KAAK,CACrB,4KAA4K,CAC7K,CAAC;QACF,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC,CAAC;QACpC,MAAM,KAAK,CAAC;KACb;AACH,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,eAAe,CAC7B,MAAwB,EACxB,QAAiB,EACjB,QAAiB;IAEjB,IAAI,QAAQ,EAAE;QACZ,aAAa,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;QAChC,OAAO,QAAQ,CAAC;KACjB;IACD,IAAI,CAAC,QAAQ,EAAE;QACb,QAAQ,GAAG,uBAAuB,CAAC;KACpC;IACD,IAAI,QAAQ,KAAK,uBAAuB,EAAE;QACxC,OAAO,QAAQ,CAAC;KACjB;IACD,OAAO,eAAe,CAAC;AACzB,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,mCAAmC,CACjD,0BAAqC;IAErC,IAAI,CAAC,0BAA0B,IAAI,0BAA0B,CAAC,MAAM,KAAK,CAAC,EAAE;QAC1E,OAAO,EAAE,CAAC;KACX;IAED,IAAI,0BAA0B,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE;QAC5C,OAAO,WAAW,CAAC;KACpB;IAED,OAAO,0BAA0B,CAAC;AACpC,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT license.\n\nimport { ALL_TENANTS, DeveloperSignOnClientId } from \"../constants\";\nimport { CredentialLogger, formatError } from \"./logging\";\nexport { processMultiTenantRequest } from \"./processMultiTenantRequest\";\n\n/**\n * @internal\n */\nexport function checkTenantId(logger: CredentialLogger, tenantId: string): void {\n if (!tenantId.match(/^[0-9a-zA-Z-.]+$/)) {\n const error = new Error(\n \"Invalid tenant id provided. You can locate your tenant id by following the instructions listed here: https://learn.microsoft.com/partner-center/find-ids-and-domain-names.\"\n );\n logger.info(formatError(\"\", error));\n throw error;\n }\n}\n\n/**\n * @internal\n */\nexport function resolveTenantId(\n logger: CredentialLogger,\n tenantId?: string,\n clientId?: string\n): string {\n if (tenantId) {\n checkTenantId(logger, tenantId);\n return tenantId;\n }\n if (!clientId) {\n clientId = DeveloperSignOnClientId;\n }\n if (clientId !== DeveloperSignOnClientId) {\n return \"common\";\n }\n return \"organizations\";\n}\n\n/**\n * @internal\n */\nexport function resolveAdditionallyAllowedTenantIds(\n additionallyAllowedTenants?: string[]\n): string[] {\n if (!additionallyAllowedTenants || additionallyAllowedTenants.length === 0) {\n return [];\n }\n\n if (additionallyAllowedTenants.includes(\"*\")) {\n return ALL_TENANTS;\n }\n\n return additionallyAllowedTenants;\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@azure/identity",
|
|
3
3
|
"sdk-type": "client",
|
|
4
|
-
"version": "4.0.0-alpha.
|
|
5
|
-
"description": "Provides credential implementations for Azure SDK libraries that can authenticate with
|
|
4
|
+
"version": "4.0.0-alpha.20231026.4",
|
|
5
|
+
"description": "Provides credential implementations for Azure SDK libraries that can authenticate with Microsoft Entra ID",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"module": "dist-esm/src/index.js",
|
|
8
8
|
"types": "./types/identity.d.ts",
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
"os": false,
|
|
11
11
|
"process": false,
|
|
12
12
|
"./dist-esm/src/credentials/azureCliCredential.js": "./dist-esm/src/credentials/azureCliCredential.browser.js",
|
|
13
|
+
"./dist-esm/src/credentials/azureDeveloperCliCredential.js": "./dist-esm/src/credentials/azureDeveloperCliCredential.browser.js",
|
|
13
14
|
"./dist-esm/src/credentials/environmentCredential.js": "./dist-esm/src/credentials/environmentCredential.browser.js",
|
|
14
15
|
"./dist-esm/src/credentials/managedIdentityCredential/index.js": "./dist-esm/src/credentials/managedIdentityCredential/index.browser.js",
|
|
15
16
|
"./dist-esm/src/credentials/clientCertificateCredential.js": "./dist-esm/src/credentials/clientCertificateCredential.browser.js",
|
|
@@ -24,6 +25,8 @@
|
|
|
24
25
|
"./dist-esm/src/credentials/azurePowerShellCredential.js": "./dist-esm/src/credentials/azurePowerShellCredential.browser.js",
|
|
25
26
|
"./dist-esm/src/credentials/azureApplicationCredential.js": "./dist-esm/src/credentials/azureApplicationCredential.browser.js",
|
|
26
27
|
"./dist-esm/src/credentials/onBehalfOfCredential.js": "./dist-esm/src/credentials/onBehalfOfCredential.browser.js",
|
|
28
|
+
"./dist-esm/src/credentials/workloadIdentityCredential.js": "./dist-esm/src/credentials/workloadIdentityCredential.browser.js",
|
|
29
|
+
"./dist-esm/src/msal/utils.js": "./dist-esm/src/msal/utils.browser.js",
|
|
27
30
|
"./dist-esm/src/util/authHostEnv.js": "./dist-esm/src/util/authHostEnv.browser.js",
|
|
28
31
|
"./dist-esm/src/util/processMultiTenantRequest.js": "./dist-esm/src/util/processMultiTenantRequest.browser.js",
|
|
29
32
|
"./dist-esm/src/tokenCache/TokenCachePersistence.js": "./dist-esm/src/tokenCache/TokenCachePersistence.browser.js",
|
|
@@ -81,7 +84,7 @@
|
|
|
81
84
|
]
|
|
82
85
|
},
|
|
83
86
|
"engines": {
|
|
84
|
-
"node": ">=
|
|
87
|
+
"node": ">=16.0.0"
|
|
85
88
|
},
|
|
86
89
|
"repository": "github:Azure/azure-sdk-for-js",
|
|
87
90
|
"keywords": [
|
|
@@ -104,24 +107,22 @@
|
|
|
104
107
|
"sideEffects": false,
|
|
105
108
|
"dependencies": {
|
|
106
109
|
"@azure/abort-controller": "^1.0.0",
|
|
107
|
-
"@azure/core-auth": "^1.
|
|
110
|
+
"@azure/core-auth": "^1.5.0",
|
|
108
111
|
"@azure/core-client": "^1.4.0",
|
|
109
112
|
"@azure/core-rest-pipeline": "^1.1.0",
|
|
110
113
|
"@azure/core-tracing": "^1.0.0",
|
|
111
114
|
"@azure/core-util": "^1.0.0",
|
|
112
115
|
"@azure/logger": "^1.0.0",
|
|
113
|
-
"@azure/msal-browser": "^
|
|
114
|
-
"@azure/msal-
|
|
115
|
-
"@azure/msal-node": "^1.14.6",
|
|
116
|
+
"@azure/msal-browser": "^3.1.0",
|
|
117
|
+
"@azure/msal-node": "^2.3.0",
|
|
116
118
|
"events": "^3.0.0",
|
|
117
119
|
"jws": "^4.0.0",
|
|
118
120
|
"open": "^8.0.0",
|
|
119
121
|
"stoppable": "^1.1.0",
|
|
120
|
-
"tslib": "^2.2.0"
|
|
121
|
-
"uuid": "^8.3.0"
|
|
122
|
+
"tslib": "^2.2.0"
|
|
122
123
|
},
|
|
123
124
|
"devDependencies": {
|
|
124
|
-
"@azure-tools/test-recorder": "^
|
|
125
|
+
"@azure-tools/test-recorder": "^3.0.0",
|
|
125
126
|
"@azure/dev-tool": ">=1.0.0-alpha <1.0.0-alphb",
|
|
126
127
|
"@azure/eslint-plugin-azure-sdk": ">=3.0.0-alpha <3.0.0-alphb",
|
|
127
128
|
"@azure/keyvault-keys": "^4.2.0",
|
|
@@ -130,14 +131,14 @@
|
|
|
130
131
|
"@types/chai": "^4.1.6",
|
|
131
132
|
"@types/jsonwebtoken": "^9.0.0",
|
|
132
133
|
"@types/jws": "^3.2.2",
|
|
133
|
-
"@types/mocha": "^
|
|
134
|
+
"@types/mocha": "^10.0.0",
|
|
134
135
|
"@types/ms": "^0.7.31",
|
|
135
|
-
"@types/node": "^
|
|
136
|
-
"@types/sinon": "^
|
|
136
|
+
"@types/node": "^16.0.0",
|
|
137
|
+
"@types/sinon": "^10.0.0",
|
|
137
138
|
"@types/stoppable": "^1.1.0",
|
|
138
139
|
"@types/uuid": "^8.0.0",
|
|
139
140
|
"chai": "^4.2.0",
|
|
140
|
-
"cross-env": "^7.0.
|
|
141
|
+
"cross-env": "^7.0.3",
|
|
141
142
|
"dotenv": "^16.0.0",
|
|
142
143
|
"eslint": "^8.0.0",
|
|
143
144
|
"inherits": "^2.0.3",
|
|
@@ -150,16 +151,17 @@
|
|
|
150
151
|
"karma-mocha": "^2.0.1",
|
|
151
152
|
"karma-mocha-reporter": "^2.2.5",
|
|
152
153
|
"karma-sourcemap-loader": "^0.3.8",
|
|
153
|
-
"mocha": "^
|
|
154
|
+
"mocha": "^10.0.0",
|
|
154
155
|
"mocha-junit-reporter": "^2.0.0",
|
|
155
156
|
"ms": "^2.1.3",
|
|
156
|
-
"
|
|
157
|
+
"c8": "^8.0.0",
|
|
157
158
|
"prettier": "^2.5.1",
|
|
158
159
|
"puppeteer": "^19.2.2",
|
|
159
160
|
"rimraf": "^3.0.0",
|
|
160
|
-
"sinon": "^
|
|
161
|
-
"
|
|
161
|
+
"sinon": "^15.0.0",
|
|
162
|
+
"ts-node": "^10.0.0",
|
|
163
|
+
"typescript": "~5.2.0",
|
|
162
164
|
"util": "^0.12.1",
|
|
163
|
-
"
|
|
165
|
+
"esm": "^3.2.18"
|
|
164
166
|
}
|
|
165
167
|
}
|