@aws-sdk/credential-provider-sso 3.947.0 → 3.952.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/dist-cjs/index.js +5 -3
- package/dist-es/fromSSO.js +2 -0
- package/dist-es/resolveSSOCredentials.js +3 -3
- package/dist-types/fromSSO.d.ts +2 -1
- package/dist-types/resolveSSOCredentials.d.ts +1 -1
- package/dist-types/ts3.4/fromSSO.d.ts +2 -0
- package/dist-types/ts3.4/resolveSSOCredentials.d.ts +1 -0
- package/package.json +3 -3
package/dist-cjs/index.js
CHANGED
|
@@ -13,7 +13,7 @@ const isSsoProfile = (arg) => arg &&
|
|
|
13
13
|
typeof arg.sso_role_name === "string");
|
|
14
14
|
|
|
15
15
|
const SHOULD_FAIL_CREDENTIAL_CHAIN = false;
|
|
16
|
-
const resolveSSOCredentials = async ({ ssoStartUrl, ssoSession, ssoAccountId, ssoRegion, ssoRoleName, ssoClient, clientConfig, parentClientConfig, profile, filepath, configFilepath, ignoreCache, logger, }) => {
|
|
16
|
+
const resolveSSOCredentials = async ({ ssoStartUrl, ssoSession, ssoAccountId, ssoRegion, ssoRoleName, ssoClient, clientConfig, parentClientConfig, callerClientConfig, profile, filepath, configFilepath, ignoreCache, logger, }) => {
|
|
17
17
|
let token;
|
|
18
18
|
const refreshMessage = `To refresh this SSO session run aws sso login with the corresponding profile.`;
|
|
19
19
|
if (ssoSession) {
|
|
@@ -57,9 +57,9 @@ const resolveSSOCredentials = async ({ ssoStartUrl, ssoSession, ssoAccountId, ss
|
|
|
57
57
|
const { SSOClient, GetRoleCredentialsCommand } = await Promise.resolve().then(function () { return require('./loadSso-CVy8iqsZ.js'); });
|
|
58
58
|
const sso = ssoClient ||
|
|
59
59
|
new SSOClient(Object.assign({}, clientConfig ?? {}, {
|
|
60
|
-
logger: clientConfig?.logger ?? parentClientConfig?.logger,
|
|
60
|
+
logger: clientConfig?.logger ?? callerClientConfig?.logger ?? parentClientConfig?.logger,
|
|
61
61
|
region: clientConfig?.region ?? ssoRegion,
|
|
62
|
-
userAgentAppId: clientConfig?.userAgentAppId ?? parentClientConfig?.userAgentAppId,
|
|
62
|
+
userAgentAppId: clientConfig?.userAgentAppId ?? callerClientConfig?.userAgentAppId ?? parentClientConfig?.userAgentAppId,
|
|
63
63
|
}));
|
|
64
64
|
let ssoResp;
|
|
65
65
|
try {
|
|
@@ -155,6 +155,7 @@ const fromSSO = (init = {}) => async ({ callerClientConfig } = {}) => {
|
|
|
155
155
|
ssoClient: ssoClient,
|
|
156
156
|
clientConfig: init.clientConfig,
|
|
157
157
|
parentClientConfig: init.parentClientConfig,
|
|
158
|
+
callerClientConfig: init.callerClientConfig,
|
|
158
159
|
profile: profileName,
|
|
159
160
|
filepath: init.filepath,
|
|
160
161
|
configFilepath: init.configFilepath,
|
|
@@ -176,6 +177,7 @@ const fromSSO = (init = {}) => async ({ callerClientConfig } = {}) => {
|
|
|
176
177
|
ssoClient,
|
|
177
178
|
clientConfig: init.clientConfig,
|
|
178
179
|
parentClientConfig: init.parentClientConfig,
|
|
180
|
+
callerClientConfig: init.callerClientConfig,
|
|
179
181
|
profile: profileName,
|
|
180
182
|
filepath: init.filepath,
|
|
181
183
|
configFilepath: init.configFilepath,
|
package/dist-es/fromSSO.js
CHANGED
|
@@ -50,6 +50,7 @@ export const fromSSO = (init = {}) => async ({ callerClientConfig } = {}) => {
|
|
|
50
50
|
ssoClient: ssoClient,
|
|
51
51
|
clientConfig: init.clientConfig,
|
|
52
52
|
parentClientConfig: init.parentClientConfig,
|
|
53
|
+
callerClientConfig: init.callerClientConfig,
|
|
53
54
|
profile: profileName,
|
|
54
55
|
filepath: init.filepath,
|
|
55
56
|
configFilepath: init.configFilepath,
|
|
@@ -71,6 +72,7 @@ export const fromSSO = (init = {}) => async ({ callerClientConfig } = {}) => {
|
|
|
71
72
|
ssoClient,
|
|
72
73
|
clientConfig: init.clientConfig,
|
|
73
74
|
parentClientConfig: init.parentClientConfig,
|
|
75
|
+
callerClientConfig: init.callerClientConfig,
|
|
74
76
|
profile: profileName,
|
|
75
77
|
filepath: init.filepath,
|
|
76
78
|
configFilepath: init.configFilepath,
|
|
@@ -3,7 +3,7 @@ import { fromSso as getSsoTokenProvider } from "@aws-sdk/token-providers";
|
|
|
3
3
|
import { CredentialsProviderError } from "@smithy/property-provider";
|
|
4
4
|
import { getSSOTokenFromFile } from "@smithy/shared-ini-file-loader";
|
|
5
5
|
const SHOULD_FAIL_CREDENTIAL_CHAIN = false;
|
|
6
|
-
export const resolveSSOCredentials = async ({ ssoStartUrl, ssoSession, ssoAccountId, ssoRegion, ssoRoleName, ssoClient, clientConfig, parentClientConfig, profile, filepath, configFilepath, ignoreCache, logger, }) => {
|
|
6
|
+
export const resolveSSOCredentials = async ({ ssoStartUrl, ssoSession, ssoAccountId, ssoRegion, ssoRoleName, ssoClient, clientConfig, parentClientConfig, callerClientConfig, profile, filepath, configFilepath, ignoreCache, logger, }) => {
|
|
7
7
|
let token;
|
|
8
8
|
const refreshMessage = `To refresh this SSO session run aws sso login with the corresponding profile.`;
|
|
9
9
|
if (ssoSession) {
|
|
@@ -47,9 +47,9 @@ export const resolveSSOCredentials = async ({ ssoStartUrl, ssoSession, ssoAccoun
|
|
|
47
47
|
const { SSOClient, GetRoleCredentialsCommand } = await import("./loadSso");
|
|
48
48
|
const sso = ssoClient ||
|
|
49
49
|
new SSOClient(Object.assign({}, clientConfig ?? {}, {
|
|
50
|
-
logger: clientConfig?.logger ?? parentClientConfig?.logger,
|
|
50
|
+
logger: clientConfig?.logger ?? callerClientConfig?.logger ?? parentClientConfig?.logger,
|
|
51
51
|
region: clientConfig?.region ?? ssoRegion,
|
|
52
|
-
userAgentAppId: clientConfig?.userAgentAppId ?? parentClientConfig?.userAgentAppId,
|
|
52
|
+
userAgentAppId: clientConfig?.userAgentAppId ?? callerClientConfig?.userAgentAppId ?? parentClientConfig?.userAgentAppId,
|
|
53
53
|
}));
|
|
54
54
|
let ssoResp;
|
|
55
55
|
try {
|
package/dist-types/fromSSO.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { CredentialProviderOptions, RuntimeConfigAwsCredentialIdentityProvider } from "@aws-sdk/types";
|
|
1
|
+
import type { AwsIdentityProperties, CredentialProviderOptions, RuntimeConfigAwsCredentialIdentityProvider } from "@aws-sdk/types";
|
|
2
2
|
import { SourceProfileInit } from "@smithy/shared-ini-file-loader";
|
|
3
3
|
import type { SSOClient, SSOClientConfig } from "./loadSso";
|
|
4
4
|
/**
|
|
@@ -33,6 +33,7 @@ export interface SsoCredentialsParameters {
|
|
|
33
33
|
export interface FromSSOInit extends SourceProfileInit, CredentialProviderOptions {
|
|
34
34
|
ssoClient?: SSOClient;
|
|
35
35
|
clientConfig?: SSOClientConfig;
|
|
36
|
+
callerClientConfig?: AwsIdentityProperties["callerClientConfig"];
|
|
36
37
|
}
|
|
37
38
|
/**
|
|
38
39
|
* @internal
|
|
@@ -3,4 +3,4 @@ import { FromSSOInit, SsoCredentialsParameters } from "./fromSSO";
|
|
|
3
3
|
/**
|
|
4
4
|
* @internal
|
|
5
5
|
*/
|
|
6
|
-
export declare const resolveSSOCredentials: ({ ssoStartUrl, ssoSession, ssoAccountId, ssoRegion, ssoRoleName, ssoClient, clientConfig, parentClientConfig, profile, filepath, configFilepath, ignoreCache, logger, }: FromSSOInit & SsoCredentialsParameters) => Promise<AwsCredentialIdentity>;
|
|
6
|
+
export declare const resolveSSOCredentials: ({ ssoStartUrl, ssoSession, ssoAccountId, ssoRegion, ssoRoleName, ssoClient, clientConfig, parentClientConfig, callerClientConfig, profile, filepath, configFilepath, ignoreCache, logger, }: FromSSOInit & SsoCredentialsParameters) => Promise<AwsCredentialIdentity>;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import {
|
|
2
|
+
AwsIdentityProperties,
|
|
2
3
|
CredentialProviderOptions,
|
|
3
4
|
RuntimeConfigAwsCredentialIdentityProvider,
|
|
4
5
|
} from "@aws-sdk/types";
|
|
@@ -16,6 +17,7 @@ export interface FromSSOInit
|
|
|
16
17
|
CredentialProviderOptions {
|
|
17
18
|
ssoClient?: SSOClient;
|
|
18
19
|
clientConfig?: SSOClientConfig;
|
|
20
|
+
callerClientConfig?: AwsIdentityProperties["callerClientConfig"];
|
|
19
21
|
}
|
|
20
22
|
export declare const fromSSO: (
|
|
21
23
|
init?: FromSSOInit & Partial<SsoCredentialsParameters>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/credential-provider-sso",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.952.0",
|
|
4
4
|
"description": "AWS credential provider that exchanges a resolved SSO login token file for temporary AWS credentials",
|
|
5
5
|
"main": "./dist-cjs/index.js",
|
|
6
6
|
"module": "./dist-es/index.js",
|
|
@@ -26,9 +26,9 @@
|
|
|
26
26
|
},
|
|
27
27
|
"license": "Apache-2.0",
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@aws-sdk/client-sso": "3.
|
|
29
|
+
"@aws-sdk/client-sso": "3.948.0",
|
|
30
30
|
"@aws-sdk/core": "3.947.0",
|
|
31
|
-
"@aws-sdk/token-providers": "3.
|
|
31
|
+
"@aws-sdk/token-providers": "3.952.0",
|
|
32
32
|
"@aws-sdk/types": "3.936.0",
|
|
33
33
|
"@smithy/property-provider": "^4.2.5",
|
|
34
34
|
"@smithy/shared-ini-file-loader": "^4.4.0",
|