mirror of
https://github.com/aws-actions/configure-aws-credentials.git
synced 2026-11-30 19:54:26 +01:00
chore: Update dist
This commit is contained in:
1 parent
596a3d4911
commit
d099dbac22
2 files changed
+51
-34
No files matched your search
+10
-10
@@ -432,7 +432,7 @@ Apache License
|
|||||||
|
|
||||||
The following npm packages may be included in this product:
|
The following npm packages may be included in this product:
|
||||||
|
|
||||||
- @aws-sdk/signature-v4-multi-region@3.996.48
|
- @aws-sdk/signature-v4-multi-region@3.996.49
|
||||||
- @smithy/core@3.36.2
|
- @smithy/core@3.36.2
|
||||||
- @smithy/types@4.19.0
|
- @smithy/types@4.19.0
|
||||||
|
|
||||||
@@ -1043,9 +1043,9 @@ Apache License
|
|||||||
The following npm packages may be included in this product:
|
The following npm packages may be included in this product:
|
||||||
|
|
||||||
- @aws-sdk/credential-provider-env@3.972.76
|
- @aws-sdk/credential-provider-env@3.972.76
|
||||||
- @aws-sdk/credential-provider-ini@3.973.19
|
- @aws-sdk/credential-provider-ini@3.973.21
|
||||||
- @aws-sdk/credential-provider-node@3.972.86
|
- @aws-sdk/credential-provider-node@3.972.88
|
||||||
- @aws-sdk/token-providers@3.1150.0
|
- @aws-sdk/token-providers@3.1155.0
|
||||||
- @aws-sdk/types@3.975.0
|
- @aws-sdk/types@3.975.0
|
||||||
- @aws-sdk/xml-builder@3.972.41
|
- @aws-sdk/xml-builder@3.972.41
|
||||||
- @smithy/credential-provider-imds@4.5.2
|
- @smithy/credential-provider-imds@4.5.2
|
||||||
@@ -1261,9 +1261,9 @@ Apache License
|
|||||||
|
|
||||||
The following npm packages may be included in this product:
|
The following npm packages may be included in this product:
|
||||||
|
|
||||||
- @aws-sdk/credential-provider-process@3.972.74
|
- @aws-sdk/credential-provider-process@3.972.76
|
||||||
- @aws-sdk/credential-provider-sso@3.973.18
|
- @aws-sdk/credential-provider-sso@3.973.20
|
||||||
- @aws-sdk/credential-provider-web-identity@3.972.80
|
- @aws-sdk/credential-provider-web-identity@3.972.82
|
||||||
|
|
||||||
These packages each contain the following license:
|
These packages each contain the following license:
|
||||||
|
|
||||||
@@ -1473,9 +1473,9 @@ Apache License
|
|||||||
|
|
||||||
The following npm packages may be included in this product:
|
The following npm packages may be included in this product:
|
||||||
|
|
||||||
- @aws-sdk/credential-provider-http@3.972.76
|
- @aws-sdk/credential-provider-http@3.972.78
|
||||||
- @aws-sdk/credential-provider-login@3.972.81
|
- @aws-sdk/credential-provider-login@3.972.83
|
||||||
- @aws-sdk/nested-clients@3.997.48
|
- @aws-sdk/nested-clients@3.997.50
|
||||||
|
|
||||||
These packages each contain the following license:
|
These packages each contain the following license:
|
||||||
|
|
||||||
|
|||||||
+41
-24
@@ -37191,7 +37191,7 @@ var init_package = __esm({
|
|||||||
"node_modules/@aws-sdk/nested-clients/package.json"() {
|
"node_modules/@aws-sdk/nested-clients/package.json"() {
|
||||||
package_default = {
|
package_default = {
|
||||||
name: "@aws-sdk/nested-clients",
|
name: "@aws-sdk/nested-clients",
|
||||||
version: "3.997.48",
|
version: "3.997.50",
|
||||||
description: "Nested clients for AWS SDK packages.",
|
description: "Nested clients for AWS SDK packages.",
|
||||||
homepage: "https://github.com/aws/aws-sdk-js-v3/tree/main/packages/nested-clients",
|
homepage: "https://github.com/aws/aws-sdk-js-v3/tree/main/packages/nested-clients",
|
||||||
license: "Apache-2.0",
|
license: "Apache-2.0",
|
||||||
@@ -37291,10 +37291,10 @@ var init_package = __esm({
|
|||||||
"test:watch": "yarn g:vitest watch"
|
"test:watch": "yarn g:vitest watch"
|
||||||
},
|
},
|
||||||
dependencies: {
|
dependencies: {
|
||||||
"@aws-sdk/core": "^3.978.3",
|
"@aws-sdk/core": "^3.978.5",
|
||||||
"@aws-sdk/signature-v4-multi-region": "^3.996.48",
|
"@aws-sdk/signature-v4-multi-region": "^3.996.49",
|
||||||
"@aws-sdk/types": "^3.974.6",
|
"@aws-sdk/types": "^3.975.0",
|
||||||
"@smithy/core": "^3.35.2",
|
"@smithy/core": "^3.36.1",
|
||||||
"@smithy/fetch-http-handler": "^5.8.0",
|
"@smithy/fetch-http-handler": "^5.8.0",
|
||||||
"@smithy/node-http-handler": "^4.12.1",
|
"@smithy/node-http-handler": "^4.12.1",
|
||||||
"@smithy/types": "^4.19.0",
|
"@smithy/types": "^4.19.0",
|
||||||
@@ -41583,6 +41583,7 @@ var require_dist_cjs9 = __commonJS({
|
|||||||
return writeFile2(tokenFilepath, tokenString);
|
return writeFile2(tokenFilepath, tokenString);
|
||||||
};
|
};
|
||||||
var lastRefreshAttemptTimes = /* @__PURE__ */ new Map();
|
var lastRefreshAttemptTimes = /* @__PURE__ */ new Map();
|
||||||
|
var inFlightRefreshes = /* @__PURE__ */ new Map();
|
||||||
var fromSso = (init = {}) => async ({ callerClientConfig } = {}) => {
|
var fromSso = (init = {}) => async ({ callerClientConfig } = {}) => {
|
||||||
init.logger?.debug("@aws-sdk/token-providers - fromSso");
|
init.logger?.debug("@aws-sdk/token-providers - fromSso");
|
||||||
const profiles = await parseKnownFiles2(init);
|
const profiles = await parseKnownFiles2(init);
|
||||||
@@ -41596,6 +41597,10 @@ var require_dist_cjs9 = __commonJS({
|
|||||||
throw new TokenProviderError2(`Profile '${profileName}' is missing required property 'sso_session'.`);
|
throw new TokenProviderError2(`Profile '${profileName}' is missing required property 'sso_session'.`);
|
||||||
}
|
}
|
||||||
const ssoSessionName = profile["sso_session"];
|
const ssoSessionName = profile["sso_session"];
|
||||||
|
const inFlightRefresh = inFlightRefreshes.get(ssoSessionName);
|
||||||
|
if (inFlightRefresh) {
|
||||||
|
return await inFlightRefresh;
|
||||||
|
}
|
||||||
const ssoSessions = await loadSsoSessionData2(init);
|
const ssoSessions = await loadSsoSessionData2(init);
|
||||||
const ssoSession = ssoSessions[ssoSessionName];
|
const ssoSession = ssoSessions[ssoSessionName];
|
||||||
if (!ssoSession) {
|
if (!ssoSession) {
|
||||||
@@ -41624,6 +41629,10 @@ var require_dist_cjs9 = __commonJS({
|
|||||||
if (existingToken.expiration.getTime() - Date.now() > EXPIRE_WINDOW_MS) {
|
if (existingToken.expiration.getTime() - Date.now() > EXPIRE_WINDOW_MS) {
|
||||||
return existingToken;
|
return existingToken;
|
||||||
}
|
}
|
||||||
|
const inFlightRefreshAfterReadingToken = inFlightRefreshes.get(ssoSessionName);
|
||||||
|
if (inFlightRefreshAfterReadingToken) {
|
||||||
|
return await inFlightRefreshAfterReadingToken;
|
||||||
|
}
|
||||||
const lastRefreshAttemptTime = lastRefreshAttemptTimes.get(ssoSessionName) ?? 0;
|
const lastRefreshAttemptTime = lastRefreshAttemptTimes.get(ssoSessionName) ?? 0;
|
||||||
if (Date.now() - lastRefreshAttemptTime < 30 * 1e3) {
|
if (Date.now() - lastRefreshAttemptTime < 30 * 1e3) {
|
||||||
validateTokenExpiry(existingToken);
|
validateTokenExpiry(existingToken);
|
||||||
@@ -41632,28 +41641,36 @@ var require_dist_cjs9 = __commonJS({
|
|||||||
validateTokenKey("clientId", ssoToken.clientId, true);
|
validateTokenKey("clientId", ssoToken.clientId, true);
|
||||||
validateTokenKey("clientSecret", ssoToken.clientSecret, true);
|
validateTokenKey("clientSecret", ssoToken.clientSecret, true);
|
||||||
validateTokenKey("refreshToken", ssoToken.refreshToken, true);
|
validateTokenKey("refreshToken", ssoToken.refreshToken, true);
|
||||||
try {
|
const refresh = (async () => {
|
||||||
lastRefreshAttemptTimes.set(ssoSessionName, Date.now());
|
|
||||||
const newSsoOidcToken = await getNewSsoOidcToken(ssoToken, ssoRegion, init, callerClientConfig);
|
|
||||||
validateTokenKey("accessToken", newSsoOidcToken.accessToken);
|
|
||||||
validateTokenKey("expiresIn", newSsoOidcToken.expiresIn);
|
|
||||||
const newTokenExpiration = new Date(Date.now() + newSsoOidcToken.expiresIn * 1e3);
|
|
||||||
try {
|
try {
|
||||||
await writeSSOTokenToFile(ssoSessionName, {
|
lastRefreshAttemptTimes.set(ssoSessionName, Date.now());
|
||||||
...ssoToken,
|
const newSsoOidcToken = await getNewSsoOidcToken(ssoToken, ssoRegion, init, callerClientConfig);
|
||||||
accessToken: newSsoOidcToken.accessToken,
|
validateTokenKey("accessToken", newSsoOidcToken.accessToken);
|
||||||
expiresAt: newTokenExpiration.toISOString(),
|
validateTokenKey("expiresIn", newSsoOidcToken.expiresIn);
|
||||||
refreshToken: newSsoOidcToken.refreshToken
|
const newTokenExpiration = new Date(Date.now() + newSsoOidcToken.expiresIn * 1e3);
|
||||||
});
|
try {
|
||||||
|
await writeSSOTokenToFile(ssoSessionName, {
|
||||||
|
...ssoToken,
|
||||||
|
accessToken: newSsoOidcToken.accessToken,
|
||||||
|
expiresAt: newTokenExpiration.toISOString(),
|
||||||
|
refreshToken: newSsoOidcToken.refreshToken
|
||||||
|
});
|
||||||
|
} catch (error3) {
|
||||||
|
}
|
||||||
|
return {
|
||||||
|
token: newSsoOidcToken.accessToken,
|
||||||
|
expiration: newTokenExpiration
|
||||||
|
};
|
||||||
} catch (error3) {
|
} catch (error3) {
|
||||||
|
validateTokenExpiry(existingToken);
|
||||||
|
return existingToken;
|
||||||
}
|
}
|
||||||
return {
|
})();
|
||||||
token: newSsoOidcToken.accessToken,
|
inFlightRefreshes.set(ssoSessionName, refresh);
|
||||||
expiration: newTokenExpiration
|
try {
|
||||||
};
|
return await refresh;
|
||||||
} catch (error3) {
|
} finally {
|
||||||
validateTokenExpiry(existingToken);
|
inFlightRefreshes.delete(ssoSessionName);
|
||||||
return existingToken;
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
var fromStatic2 = ({ token, logger: logger2 }) => async () => {
|
var fromStatic2 = ({ token, logger: logger2 }) => async () => {
|
||||||
|
|||||||
Reference in new issue
Block a user