@thunderclient/cli 1.16.5 → 1.17.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/237.index.js +3 -0
- package/dist/290.index.js +3 -0
- package/dist/648.index.js +3 -0
- package/dist/678.index.js +3 -0
- package/dist/774.index.js +3 -0
- package/dist/869.index.js +2 -0
- package/dist/925.index.js +3 -0
- package/dist/958.index.js +3 -0
- package/dist/988.index.js +3 -0
- package/dist/997.index.js +3 -0
- package/dist/index.js +9 -9
- package/package.json +1 -1
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";exports.id=237,exports.ids=[237],exports.modules={789:(e,r,t)=>{t.d(r,{fromIni:()=>E});var n=t(24),o=t(25),i=t(54),s=t(28);const a=e=>(0,i.P)(e,"CREDENTIALS_PROFILE_NAMED_PROVIDER","p"),c=(e,{profile:r,logger:t})=>{const n="string"==typeof e.source_profile&&void 0===e.credential_source;return n&&t?.debug?.(` ${r} isAssumeRoleWithSourceProfile source_profile=${e.source_profile}`),n},l=(e,{profile:r,logger:t})=>{const n="string"==typeof e.credential_source&&void 0===e.source_profile;return n&&t?.debug?.(` ${r} isCredentialSourceProfile credential_source=${e.credential_source}`),n},f=async(e,r,c,l={})=>{c.logger?.debug("@aws-sdk/credential-provider-ini - resolveAssumeRoleCredentials (STS)");const f=r[e];if(!c.roleAssumer){const{getDefaultRoleAssumer:e}=await t.e(648).then(t.bind(t,796));c.roleAssumer=e({...c.clientConfig,credentialProviderLogger:c.logger,parentClientConfig:c?.parentClientConfig},c.clientPlugins)}const{source_profile:p}=f;if(p&&p in l)throw new o.m(`Detected a cycle attempting to resolve credentials for profile ${(0,n.Jl)(c)}. Profiles visited: `+Object.keys(l).join(", "),{logger:c.logger});c.logger?.debug("@aws-sdk/credential-provider-ini - finding credential resolver using "+(p?`source_profile=[${p}]`:`profile=[${e}]`));const g=p?u(p,r,c,{...l,[p]:!0},d(r[p]??{})):(await((e,r,n)=>{const i={EcsContainer:async e=>{const{fromHttp:r}=await t.e(925).then(t.bind(t,793)),{fromContainerMetadata:o}=await t.e(678).then(t.bind(t,792));return n?.debug("@aws-sdk/credential-provider-ini - credential_source is EcsContainer"),async()=>(0,s.t)(r(e??{}),o(e))().then(a)},Ec2InstanceMetadata:async e=>{n?.debug("@aws-sdk/credential-provider-ini - credential_source is Ec2InstanceMetadata");const{fromInstanceMetadata:r}=await t.e(678).then(t.bind(t,792));return async()=>r(e)().then(a)},Environment:async e=>{n?.debug("@aws-sdk/credential-provider-ini - credential_source is Environment");const{fromEnv:r}=await t.e(869).then(t.bind(t,809));return async()=>r(e)().then(a)}};if(e in i)return i[e];throw new o.m(`Unsupported credential source in profile ${r}. Got ${e}, expected EcsContainer or Ec2InstanceMetadata or Environment.`,{logger:n})})(f.credential_source,e,c.logger)(c))();if(d(f))return g.then((e=>(0,i.P)(e,"CREDENTIALS_PROFILE_SOURCE_PROFILE","o")));{const r={RoleArn:f.role_arn,RoleSessionName:f.role_session_name||`aws-sdk-js-${Date.now()}`,ExternalId:f.external_id,DurationSeconds:parseInt(f.duration_seconds||"3600",10)},{mfa_serial:t}=f;if(t){if(!c.mfaCodeProvider)throw new o.m(`Profile ${e} requires multi-factor authentication, but no MFA code callback was provided.`,{logger:c.logger,tryNextLink:!1});r.SerialNumber=t,r.TokenCode=await c.mfaCodeProvider(t)}const n=await g;return c.roleAssumer(n,r).then((e=>(0,i.P)(e,"CREDENTIALS_PROFILE_SOURCE_PROFILE","o")))}},d=e=>!e.role_arn&&!!e.credential_source,p=e=>Boolean(e)&&"object"==typeof e&&"string"==typeof e.aws_access_key_id&&"string"==typeof e.aws_secret_access_key&&["undefined","string"].indexOf(typeof e.aws_session_token)>-1&&["undefined","string"].indexOf(typeof e.aws_account_id)>-1,g=async(e,r)=>{r?.logger?.debug("@aws-sdk/credential-provider-ini - resolveStaticCredentials");const t={accessKeyId:e.aws_access_key_id,secretAccessKey:e.aws_secret_access_key,sessionToken:e.aws_session_token,...e.aws_credential_scope&&{credentialScope:e.aws_credential_scope},...e.aws_account_id&&{accountId:e.aws_account_id}};return(0,i.P)(t,"CREDENTIALS_PROFILE","n")},u=async(e,r,n,s={},a=!1)=>{const d=r[e];if(Object.keys(s).length>0&&p(d))return g(d,n);if(a||((e,{profile:r="default",logger:t}={})=>Boolean(e)&&"object"==typeof e&&"string"==typeof e.role_arn&&["undefined","string"].indexOf(typeof e.role_session_name)>-1&&["undefined","string"].indexOf(typeof e.external_id)>-1&&["undefined","string"].indexOf(typeof e.mfa_serial)>-1&&(c(e,{profile:r,logger:t})||l(e,{profile:r,logger:t})))(d,{profile:e,logger:n.logger}))return f(e,r,n,s);if(p(d))return g(d,n);if(u=d,Boolean(u)&&"object"==typeof u&&"string"==typeof u.web_identity_token_file&&"string"==typeof u.role_arn&&["undefined","string"].indexOf(typeof u.role_session_name)>-1)return(async(e,r)=>t.e(958).then(t.bind(t,791)).then((({fromTokenFile:t})=>t({webIdentityTokenFile:e.web_identity_token_file,roleArn:e.role_arn,roleSessionName:e.role_session_name,roleAssumerWithWebIdentity:r.roleAssumerWithWebIdentity,logger:r.logger,parentClientConfig:r.parentClientConfig})().then((e=>(0,i.P)(e,"CREDENTIALS_PROFILE_STS_WEB_ID_TOKEN","q"))))))(d,n);var u;if((e=>Boolean(e)&&"object"==typeof e&&"string"==typeof e.credential_process)(d))return(async(e,r)=>t.e(997).then(t.bind(t,790)).then((({fromProcess:t})=>t({...e,profile:r})().then((e=>(0,i.P)(e,"CREDENTIALS_PROFILE_PROCESS","v"))))))(n,e);if((e=>e&&("string"==typeof e.sso_start_url||"string"==typeof e.sso_account_id||"string"==typeof e.sso_session||"string"==typeof e.sso_region||"string"==typeof e.sso_role_name))(d))return await(async(e,r,n={})=>{const{fromSSO:o}=await t.e(774).then(t.bind(t,788));return o({profile:e,logger:n.logger})().then((e=>r.sso_session?(0,i.P)(e,"CREDENTIALS_PROFILE_SSO","r"):(0,i.P)(e,"CREDENTIALS_PROFILE_SSO_LEGACY","t")))})(e,d,n);throw new o.m(`Could not resolve credentials using profile: [${e}] in configuration/credentials file(s).`,{logger:n.logger})},E=(e={})=>async()=>{e.logger?.debug("@aws-sdk/credential-provider-ini - fromIni");const r=await(0,n.MX)(e);return u((0,n.Jl)(e),r,e)}}};
|
|
3
|
+
//# sourceMappingURL=237.index.js.map
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";exports.id=290,exports.ids=[290],exports.modules={794:(e,t,s)=>{s.d(t,{GetRoleCredentialsCommand:()=>q,SSOClient:()=>ze});var n=s(22),o=s(30),r=s(34);const i={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}};class a extends r.sI{constructor(e){super(e),Object.setPrototypeOf(this,a.prototype)}}class c extends a{constructor(e){super({name:"InvalidRequestException",$fault:"client",...e}),this.name="InvalidRequestException",this.$fault="client",Object.setPrototypeOf(this,c.prototype)}}class u extends a{constructor(e){super({name:"ResourceNotFoundException",$fault:"client",...e}),this.name="ResourceNotFoundException",this.$fault="client",Object.setPrototypeOf(this,u.prototype)}}class d extends a{constructor(e){super({name:"TooManyRequestsException",$fault:"client",...e}),this.name="TooManyRequestsException",this.$fault="client",Object.setPrototypeOf(this,d.prototype)}}class p extends a{constructor(e){super({name:"UnauthorizedException",$fault:"client",...e}),this.name="UnauthorizedException",this.$fault="client",Object.setPrototypeOf(this,p.prototype)}}const l=e=>({...e,...e.accessToken&&{accessToken:r.oc}}),h=e=>({...e,...e.secretAccessKey&&{secretAccessKey:r.oc},...e.sessionToken&&{sessionToken:r.oc}}),m=e=>({...e,...e.roleCredentials&&{roleCredentials:h(e.roleCredentials)}});var y=s(64),g=s(20);const S=async(e,t)=>{const s=(0,g.cu)(e,t),n=(0,r.UI)({},r.gj,{[F]:e[k]});s.bp("/federation/credentials");const o=(0,r.UI)({[D]:[,(0,r.CE)(e[C],"roleName")],[A]:[,(0,r.CE)(e[b],"accountId")]});return s.m("GET").h(n).q(o).b(undefined),s.build()},f=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return w(e,t);const s=(0,r.UI)({$metadata:I(e)}),n=(0,r.CE)((0,r.Wh)(await(0,y.e1)(e.body,t)),"body"),o=(0,r.qn)(n,{roleCredentials:r.F3});return Object.assign(s,o),s},w=async(e,t)=>{const s={...e,body:await(0,y.fk)(e.body,t)},n=(0,y.mJ)(e,s.body);switch(n){case"InvalidRequestException":case"com.amazonaws.sso#InvalidRequestException":throw await x(s,t);case"ResourceNotFoundException":case"com.amazonaws.sso#ResourceNotFoundException":throw await P(s,t);case"TooManyRequestsException":case"com.amazonaws.sso#TooManyRequestsException":throw await E(s,t);case"UnauthorizedException":case"com.amazonaws.sso#UnauthorizedException":throw await R(s,t);default:const o=s.body;return v({output:e,parsedBody:o,errorCode:n})}},v=(0,r.PC)(a),x=async(e,t)=>{const s=(0,r.UI)({}),n=e.body,o=(0,r.qn)(n,{message:r.pY});Object.assign(s,o);const i=new c({$metadata:I(e),...s});return(0,r.to)(i,e.body)},P=async(e,t)=>{const s=(0,r.UI)({}),n=e.body,o=(0,r.qn)(n,{message:r.pY});Object.assign(s,o);const i=new u({$metadata:I(e),...s});return(0,r.to)(i,e.body)},E=async(e,t)=>{const s=(0,r.UI)({}),n=e.body,o=(0,r.qn)(n,{message:r.pY});Object.assign(s,o);const i=new d({$metadata:I(e),...s});return(0,r.to)(i,e.body)},R=async(e,t)=>{const s=(0,r.UI)({}),n=e.body,o=(0,r.qn)(n,{message:r.pY});Object.assign(s,o);const i=new p({$metadata:I(e),...s});return(0,r.to)(i,e.body)},I=e=>({httpStatusCode:e.statusCode,requestId:e.headers["x-amzn-requestid"]??e.headers["x-amzn-request-id"]??e.headers["x-amz-request-id"],extendedRequestId:e.headers["x-amz-id-2"],cfId:e.headers["x-amz-cf-id"]}),b="accountId",k="accessToken",A="account_id",C="roleName",D="role_name",F="x-amz-sso_bearer_token";class q extends(r.mY.classBuilder().ep(i).m((function(e,t,s,r){return[(0,o.p2)(s,this.serialize,this.deserialize),(0,n.a3)(s,e.getEndpointParameterInstructions())]})).s("SWBPortalService","GetRoleCredentials",{}).n("SSOClient","GetRoleCredentialsCommand").f(l,m).ser(S).de(f).build()){}var O=s(14),U=s(17),z=s(18),j=s(19),$=s(50),T=s(51),M=s(31),N=s(60),G=s(21);const H=async(e,t,s)=>({operation:(0,G.J)(t).operation,region:await(0,G.$)(e.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});const L=e=>{const t=[];switch(e.operation){case"GetRoleCredentials":case"ListAccountRoles":case"ListAccounts":case"Logout":t.push({schemeId:"smithy.api#noAuth"});break;default:t.push(function(e){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"awsssoportal",region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}(e))}return t},_="3.670.0";var B=s(62),V=s(55),K=s(57),W=s(23),J=s(41),Q=s(58),X=s(32),Y=s(61),Z=s(29),ee=s(36),te=s(40),se=s(48),ne=s(49);const oe="required",re="fn",ie="argv",ae="ref",ce="isSet",ue="booleanEquals",de="error",pe="endpoint",le="tree",he="PartitionResult",me="getAttr",ye={[oe]:!1,type:"String"},ge={[oe]:!0,default:!1,type:"Boolean"},Se={[ae]:"Endpoint"},fe={[re]:ue,[ie]:[{[ae]:"UseFIPS"},!0]},we={[re]:ue,[ie]:[{[ae]:"UseDualStack"},!0]},ve={},xe={[re]:me,[ie]:[{[ae]:he},"supportsFIPS"]},Pe={[ae]:he},Ee={[re]:ue,[ie]:[!0,{[re]:me,[ie]:[Pe,"supportsDualStack"]}]},Re=[fe],Ie=[we],be=[{[ae]:"Region"}],ke={version:"1.0",parameters:{Region:ye,UseDualStack:ge,UseFIPS:ge,Endpoint:ye},rules:[{conditions:[{[re]:ce,[ie]:[Se]}],rules:[{conditions:Re,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:de},{conditions:Ie,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:de},{endpoint:{url:Se,properties:ve,headers:ve},type:pe}],type:le},{conditions:[{[re]:ce,[ie]:be}],rules:[{conditions:[{[re]:"aws.partition",[ie]:be,assign:he}],rules:[{conditions:[fe,we],rules:[{conditions:[{[re]:ue,[ie]:[true,xe]},Ee],rules:[{endpoint:{url:"https://portal.sso-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:ve,headers:ve},type:pe}],type:le},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:de}],type:le},{conditions:Re,rules:[{conditions:[{[re]:ue,[ie]:[xe,true]}],rules:[{conditions:[{[re]:"stringEquals",[ie]:[{[re]:me,[ie]:[Pe,"name"]},"aws-us-gov"]}],endpoint:{url:"https://portal.sso.{Region}.amazonaws.com",properties:ve,headers:ve},type:pe},{endpoint:{url:"https://portal.sso-fips.{Region}.{PartitionResult#dnsSuffix}",properties:ve,headers:ve},type:pe}],type:le},{error:"FIPS is enabled but this partition does not support FIPS",type:de}],type:le},{conditions:Ie,rules:[{conditions:[Ee],rules:[{endpoint:{url:"https://portal.sso.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:ve,headers:ve},type:pe}],type:le},{error:"DualStack is enabled but this partition does not support DualStack",type:de}],type:le},{endpoint:{url:"https://portal.sso.{Region}.{PartitionResult#dnsSuffix}",properties:ve,headers:ve},type:pe}],type:le}],type:le},{error:"Invalid Configuration: Missing Region",type:de}]},Ae=new ne.$X({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),Ce=(e,t={})=>Ae.get(e,(()=>(0,ne.B1)(ke,{endpointParams:e,logger:t.logger})));ne.DY.aws=se.Iu;var De=s(59);const Fe=e=>{(0,r.H_)(process.version);const t=(0,De.j)(e),s=()=>t().then(r.jv),n=(e=>({apiVersion:"2019-06-10",base64Decoder:e?.base64Decoder??ee.G,base64Encoder:e?.base64Encoder??ee.s,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??Ce,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??L,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new Y.VR},{schemeId:"smithy.api#noAuth",identityProvider:e=>e.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new g.oH}],logger:e?.logger??new r.vk,serviceId:e?.serviceId??"SSO",urlParser:e?.urlParser??Z.e,utf8Decoder:e?.utf8Decoder??te.$x,utf8Encoder:e?.utf8Encoder??te.GZ}))(e);return(0,B.H)(process.version),{...n,...e,runtime:"node",defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??Q.W,defaultUserAgentProvider:e?.defaultUserAgentProvider??(0,V.kk)({serviceId:n.serviceId,clientVersion:_}),maxAttempts:e?.maxAttempts??(0,W.M)(M.Hs),region:e?.region??(0,W.M)($._c,$.zb),requestHandler:J.NA.create(e?.requestHandler??s),retryMode:e?.retryMode??(0,W.M)({...M.aK,default:async()=>(await s()).retryMode||X.CA}),sha256:e?.sha256??K.k.bind(null,"sha256"),streamCollector:e?.streamCollector??J.CF,useDualstackEndpoint:e?.useDualstackEndpoint??(0,W.M)($.G7),useFipsEndpoint:e?.useFipsEndpoint??(0,W.M)($.NL),userAgentAppId:e?.userAgentAppId??(0,W.M)(V.eX)}};var qe=s(63),Oe=s(15);const Ue=e=>{const t=e.httpAuthSchemes;let s=e.httpAuthSchemeProvider,n=e.credentials;return{setHttpAuthScheme(e){const s=t.findIndex((t=>t.schemeId===e.schemeId));-1===s?t.push(e):t.splice(s,1,e)},httpAuthSchemes:()=>t,setHttpAuthSchemeProvider(e){s=e},httpAuthSchemeProvider:()=>s,setCredentials(e){n=e},credentials:()=>n}};class ze extends r.KU{constructor(...[e]){const t=Fe(e||{}),s=(o=t,{...o,useDualstackEndpoint:o.useDualstackEndpoint??!1,useFipsEndpoint:o.useFipsEndpoint??!1,defaultSigningName:"awsssoportal"});var o;const i=(0,j.er)(s),a=(0,M.BC)(i),c=(0,$.Xb)(a),u=(0,O.S8)(c),d=(0,n.uW)(u);var p;const l=((e,t)=>{const s={...(0,qe.GW)(e),...(0,r.kE)(e),...(0,Oe.cA)(e),...Ue(e)};return t.forEach((e=>e.configure(s))),{...e,...(0,qe.A1)(s),...(0,r.SQ)(s),...(0,Oe.AO)(s),...(n=s,{httpAuthSchemes:n.httpAuthSchemes(),httpAuthSchemeProvider:n.httpAuthSchemeProvider(),credentials:n.credentials()})};var n})((p=d,{...(0,N.K)(p)}),e?.extensions||[]);super(l),this.config=l,this.middlewareStack.use((0,j.XJ)(this.config)),this.middlewareStack.use((0,M.NQ)(this.config)),this.middlewareStack.use((0,T.VG)(this.config)),this.middlewareStack.use((0,O.G2)(this.config)),this.middlewareStack.use((0,U.cV)(this.config)),this.middlewareStack.use((0,z.eV)(this.config)),this.middlewareStack.use((0,g.tZ)(this.config,{httpAuthSchemeParametersProvider:H,identityProviderConfigProvider:async e=>new g.K5({"aws.auth#sigv4":e.credentials})})),this.middlewareStack.use((0,g.aZ)(this.config))}destroy(){super.destroy()}}}};
|
|
3
|
+
//# sourceMappingURL=290.index.js.map
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
exports.id=648,exports.ids=[648],exports.modules={796:(t,e,n)=>{"use strict";n.d(e,{getDefaultRoleAssumer:()=>yn,getDefaultRoleAssumerWithWebIdentity:()=>En});var i=n(54),s=n(22),o=n(30),r=n(34);const a={UseGlobalEndpoint:{type:"builtInParams",name:"useGlobalEndpoint"},UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}};class c extends r.sI{constructor(t){super(t),Object.setPrototypeOf(this,c.prototype)}}class u extends c{constructor(t){super({name:"ExpiredTokenException",$fault:"client",...t}),this.name="ExpiredTokenException",this.$fault="client",Object.setPrototypeOf(this,u.prototype)}}class l extends c{constructor(t){super({name:"MalformedPolicyDocumentException",$fault:"client",...t}),this.name="MalformedPolicyDocumentException",this.$fault="client",Object.setPrototypeOf(this,l.prototype)}}class d extends c{constructor(t){super({name:"PackedPolicyTooLargeException",$fault:"client",...t}),this.name="PackedPolicyTooLargeException",this.$fault="client",Object.setPrototypeOf(this,d.prototype)}}class h extends c{constructor(t){super({name:"RegionDisabledException",$fault:"client",...t}),this.name="RegionDisabledException",this.$fault="client",Object.setPrototypeOf(this,h.prototype)}}class f extends c{constructor(t){super({name:"IDPRejectedClaimException",$fault:"client",...t}),this.name="IDPRejectedClaimException",this.$fault="client",Object.setPrototypeOf(this,f.prototype)}}class p extends c{constructor(t){super({name:"InvalidIdentityTokenException",$fault:"client",...t}),this.name="InvalidIdentityTokenException",this.$fault="client",Object.setPrototypeOf(this,p.prototype)}}class g extends c{constructor(t){super({name:"IDPCommunicationErrorException",$fault:"client",...t}),this.name="IDPCommunicationErrorException",this.$fault="client",Object.setPrototypeOf(this,g.prototype)}}class m extends c{constructor(t){super({name:"InvalidAuthorizationMessageException",$fault:"client",...t}),this.name="InvalidAuthorizationMessageException",this.$fault="client",Object.setPrototypeOf(this,m.prototype)}}const v=t=>({...t,...t.SecretAccessKey&&{SecretAccessKey:r.oc}}),x=t=>({...t,...t.Credentials&&{Credentials:v(t.Credentials)}}),w=t=>({...t,...t.WebIdentityToken&&{WebIdentityToken:r.oc}}),b=t=>({...t,...t.Credentials&&{Credentials:v(t.Credentials)}});var y=n(797),E=n(65);const I=(t,e)=>(0,E.J)(t,e).then((t=>{if(t.length){const e=new y.XMLParser({attributeNamePrefix:"",htmlEntities:!0,ignoreAttributes:!1,ignoreDeclaration:!0,parseTagValue:!1,trimValues:!1,tagValueProcessor:(t,e)=>""===e.trim()&&e.includes("\n")?"":void 0});let n;e.addEntity("#xD","\r"),e.addEntity("#10","\n");try{n=e.parse(t,!0)}catch(e){throw e&&"object"==typeof e&&Object.defineProperty(e,"$responseBodyText",{value:t}),e}const i="#text",s=Object.keys(n)[0],o=n[s];return o[i]&&(o[s]=o[i],delete o[i]),(0,r.sT)(o)}return{}})),P=async(t,e)=>{const n=await I(t,e);return n.Error&&(n.Error.message=n.Error.message??n.Error.Message),n};var A=n(15);const S=async(t,e)=>{const n=ut;let i;return i=Xt({...L(t,e),[dt]:ft,[Vt]:lt}),ct(e,n,"/",void 0,i)},T=async(t,e)=>{const n=ut;let i;return i=Xt({...M(t,e),[dt]:mt,[Vt]:lt}),ct(e,n,"/",void 0,i)},$=async(t,e)=>{if(t.statusCode>=300)return R(t,e);const n=await I(t.body,e);let i={};i=H(n.AssumeRoleResult,e);return{$metadata:rt(t),...i}},D=async(t,e)=>{if(t.statusCode>=300)return R(t,e);const n=await I(t.body,e);let i={};i=Y(n.AssumeRoleWithWebIdentityResult,e);return{$metadata:rt(t),...i}},R=async(t,e)=>{const n={...t,body:await P(t.body,e)},i=Gt(t,n.body);switch(i){case"ExpiredTokenException":case"com.amazonaws.sts#ExpiredTokenException":throw await C(n,e);case"MalformedPolicyDocument":case"com.amazonaws.sts#MalformedPolicyDocumentException":throw await F(n,e);case"PackedPolicyTooLarge":case"com.amazonaws.sts#PackedPolicyTooLargeException":throw await _(n,e);case"RegionDisabledException":case"com.amazonaws.sts#RegionDisabledException":throw await U(n,e);case"IDPRejectedClaim":case"com.amazonaws.sts#IDPRejectedClaimException":throw await N(n,e);case"InvalidIdentityToken":case"com.amazonaws.sts#InvalidIdentityTokenException":throw await j(n,e);case"IDPCommunicationError":case"com.amazonaws.sts#IDPCommunicationErrorException":throw await O(n,e);case"InvalidAuthorizationMessageException":case"com.amazonaws.sts#InvalidAuthorizationMessageException":throw await k(n,e);default:const s=n.body;return at({output:t,parsedBody:s.Error,errorCode:i})}},C=async(t,e)=>{const n=t.body,i=J(n.Error,e),s=new u({$metadata:rt(t),...i});return(0,r.to)(s,n)},O=async(t,e)=>{const n=t.body,i=Q(n.Error,e),s=new g({$metadata:rt(t),...i});return(0,r.to)(s,n)},N=async(t,e)=>{const n=t.body,i=tt(n.Error,e),s=new f({$metadata:rt(t),...i});return(0,r.to)(s,n)},k=async(t,e)=>{const n=t.body,i=et(n.Error,e),s=new m({$metadata:rt(t),...i});return(0,r.to)(s,n)},j=async(t,e)=>{const n=t.body,i=nt(n.Error,e),s=new p({$metadata:rt(t),...i});return(0,r.to)(s,n)},F=async(t,e)=>{const n=t.body,i=it(n.Error,e),s=new l({$metadata:rt(t),...i});return(0,r.to)(s,n)},_=async(t,e)=>{const n=t.body,i=st(n.Error,e),s=new d({$metadata:rt(t),...i});return(0,r.to)(s,n)},U=async(t,e)=>{const n=t.body,i=ot(n.Error,e),s=new h({$metadata:rt(t),...i});return(0,r.to)(s,n)},L=(t,e)=>{const n={};if(null!=t[Ot]&&(n[Ot]=t[Ot]),null!=t[Nt]&&(n[Nt]=t[Nt]),null!=t[St]){const i=W(t[St],e);0===t[St]?.length&&(n.PolicyArns=[]),Object.entries(i).forEach((([t,e])=>{n[`PolicyArns.${t}`]=e}))}if(null!=t[At]&&(n[At]=t[At]),null!=t[yt]&&(n[yt]=t[yt]),null!=t[Lt]){const i=X(t[Lt],e);0===t[Lt]?.length&&(n.Tags=[]),Object.entries(i).forEach((([t,e])=>{n[`Tags.${t}`]=e}))}if(null!=t[Wt]){const i=K(t[Wt],e);0===t[Wt]?.length&&(n.TransitiveTagKeys=[]),Object.entries(i).forEach((([t,e])=>{n[`TransitiveTagKeys.${t}`]=e}))}if(null!=t[It]&&(n[It]=t[It]),null!=t[_t]&&(n[_t]=t[_t]),null!=t[Mt]&&(n[Mt]=t[Mt]),null!=t[Ft]&&(n[Ft]=t[Ft]),null!=t[$t]){const i=q(t[$t],e);0===t[$t]?.length&&(n.ProvidedContexts=[]),Object.entries(i).forEach((([t,e])=>{n[`ProvidedContexts.${t}`]=e}))}return n},M=(t,e)=>{const n={};if(null!=t[Ot]&&(n[Ot]=t[Ot]),null!=t[Nt]&&(n[Nt]=t[Nt]),null!=t[qt]&&(n[qt]=t[qt]),null!=t[Dt]&&(n[Dt]=t[Dt]),null!=t[St]){const i=W(t[St],e);0===t[St]?.length&&(n.PolicyArns=[]),Object.entries(i).forEach((([t,e])=>{n[`PolicyArns.${t}`]=e}))}return null!=t[At]&&(n[At]=t[At]),null!=t[yt]&&(n[yt]=t[yt]),n},W=(t,e)=>{const n={};let i=1;for(const s of t){if(null===s)continue;const t=V(s,e);Object.entries(t).forEach((([t,e])=>{n[`member.${i}.${t}`]=e})),i++}return n},V=(t,e)=>{const n={};return null!=t[Bt]&&(n[Bt]=t[Bt]),n},z=(t,e)=>{const n={};return null!=t[Tt]&&(n[Tt]=t[Tt]),null!=t[bt]&&(n[bt]=t[bt]),n},q=(t,e)=>{const n={};let i=1;for(const e of t){if(null===e)continue;const t=z(e);Object.entries(t).forEach((([t,e])=>{n[`member.${i}.${t}`]=e})),i++}return n},B=(t,e)=>{const n={};return null!=t[Pt]&&(n[Pt]=t[Pt]),null!=t[zt]&&(n[zt]=t[zt]),n},K=(t,e)=>{const n={};let i=1;for(const e of t)null!==e&&(n[`member.${i}`]=e,i++);return n},X=(t,e)=>{const n={};let i=1;for(const e of t){if(null===e)continue;const t=B(e);Object.entries(t).forEach((([t,e])=>{n[`member.${i}.${t}`]=e})),i++}return n},G=(t,e)=>{const n={};return null!=t[pt]&&(n[pt]=(0,r.pY)(t[pt])),null!=t[vt]&&(n[vt]=(0,r.pY)(t[vt])),n},H=(t,e)=>{const n={};return null!=t[wt]&&(n[wt]=Z(t[wt],e)),null!=t[gt]&&(n[gt]=G(t[gt])),null!=t[Rt]&&(n[Rt]=(0,r.AF)(t[Rt])),null!=t[Ft]&&(n[Ft]=(0,r.pY)(t[Ft])),n},Y=(t,e)=>{const n={};return null!=t[wt]&&(n[wt]=Z(t[wt],e)),null!=t[jt]&&(n[jt]=(0,r.pY)(t[jt])),null!=t[gt]&&(n[gt]=G(t[gt])),null!=t[Rt]&&(n[Rt]=(0,r.AF)(t[Rt])),null!=t[Ct]&&(n[Ct]=(0,r.pY)(t[Ct])),null!=t[xt]&&(n[xt]=(0,r.pY)(t[xt])),null!=t[Ft]&&(n[Ft]=(0,r.pY)(t[Ft])),n},Z=(t,e)=>{const n={};return null!=t[ht]&&(n[ht]=(0,r.pY)(t[ht])),null!=t[kt]&&(n[kt]=(0,r.pY)(t[kt])),null!=t[Ut]&&(n[Ut]=(0,r.pY)(t[Ut])),null!=t[Et]&&(n[Et]=(0,r.CE)((0,r.aH)(t[Et]))),n},J=(t,e)=>{const n={};return null!=t[Kt]&&(n[Kt]=(0,r.pY)(t[Kt])),n},Q=(t,e)=>{const n={};return null!=t[Kt]&&(n[Kt]=(0,r.pY)(t[Kt])),n},tt=(t,e)=>{const n={};return null!=t[Kt]&&(n[Kt]=(0,r.pY)(t[Kt])),n},et=(t,e)=>{const n={};return null!=t[Kt]&&(n[Kt]=(0,r.pY)(t[Kt])),n},nt=(t,e)=>{const n={};return null!=t[Kt]&&(n[Kt]=(0,r.pY)(t[Kt])),n},it=(t,e)=>{const n={};return null!=t[Kt]&&(n[Kt]=(0,r.pY)(t[Kt])),n},st=(t,e)=>{const n={};return null!=t[Kt]&&(n[Kt]=(0,r.pY)(t[Kt])),n},ot=(t,e)=>{const n={};return null!=t[Kt]&&(n[Kt]=(0,r.pY)(t[Kt])),n},rt=t=>({httpStatusCode:t.statusCode,requestId:t.headers["x-amzn-requestid"]??t.headers["x-amzn-request-id"]??t.headers["x-amz-request-id"],extendedRequestId:t.headers["x-amz-id-2"],cfId:t.headers["x-amz-cf-id"]}),at=(0,r.PC)(c),ct=async(t,e,n,i,s)=>{const{hostname:o,protocol:r="https",port:a,path:c}=await t.endpoint(),u={protocol:r,hostname:o,port:a,method:"POST",path:c.endsWith("/")?c.slice(0,-1)+n:c+n,headers:e};return void 0!==i&&(u.hostname=i),void 0!==s&&(u.body=s),new A.aW(u)},ut={"content-type":"application/x-www-form-urlencoded"},lt="2011-06-15",dt="Action",ht="AccessKeyId",ft="AssumeRole",pt="AssumedRoleId",gt="AssumedRoleUser",mt="AssumeRoleWithWebIdentity",vt="Arn",xt="Audience",wt="Credentials",bt="ContextAssertion",yt="DurationSeconds",Et="Expiration",It="ExternalId",Pt="Key",At="Policy",St="PolicyArns",Tt="ProviderArn",$t="ProvidedContexts",Dt="ProviderId",Rt="PackedPolicySize",Ct="Provider",Ot="RoleArn",Nt="RoleSessionName",kt="SecretAccessKey",jt="SubjectFromWebIdentityToken",Ft="SourceIdentity",_t="SerialNumber",Ut="SessionToken",Lt="Tags",Mt="TokenCode",Wt="TransitiveTagKeys",Vt="Version",zt="Value",qt="WebIdentityToken",Bt="arn",Kt="message",Xt=t=>Object.entries(t).map((([t,e])=>(0,r.jc)(t)+"="+(0,r.jc)(e))).join("&"),Gt=(t,e)=>void 0!==e.Error?.Code?e.Error.Code:404==t.statusCode?"NotFound":void 0;class Ht extends(r.mY.classBuilder().ep(a).m((function(t,e,n,i){return[(0,o.p2)(n,this.serialize,this.deserialize),(0,s.a3)(n,t.getEndpointParameterInstructions())]})).s("AWSSecurityTokenServiceV20110615","AssumeRole",{}).n("STSClient","AssumeRoleCommand").f(void 0,x).ser(S).de($).build()){}class Yt extends(r.mY.classBuilder().ep(a).m((function(t,e,n,i){return[(0,o.p2)(n,this.serialize,this.deserialize),(0,s.a3)(n,t.getEndpointParameterInstructions())]})).s("AWSSecurityTokenServiceV20110615","AssumeRoleWithWebIdentity",{}).n("STSClient","AssumeRoleWithWebIdentityCommand").f(w,b).ser(T).de(D).build()){}const Zt="us-east-1",Jt=t=>{if("string"==typeof t?.Arn){const e=t.Arn.split(":");if(e.length>4&&""!==e[4])return e[4]}},Qt=async(t,e,n)=>{const i="function"==typeof t?await t():t,s="function"==typeof e?await e():e;return n?.debug?.("@aws-sdk/client-sts::resolveRegion","accepting first of:",`${i} (provider)`,`${s} (parent client)`,`${Zt} (STS default)`),i??s??Zt},te=(t,e)=>{let n,s;return async(o,r)=>{if(s=o,!n){const{logger:i=t?.parentClientConfig?.logger,region:o,requestHandler:r=t?.parentClientConfig?.requestHandler,credentialProviderLogger:a}=t,c=await Qt(o,t?.parentClientConfig?.region,a),u=!ne(r);n=new e({credentialDefaultProvider:()=>async()=>s,region:c,requestHandler:u?r:void 0,logger:i})}const{Credentials:a,AssumedRoleUser:c}=await n.send(new Ht(r));if(!a||!a.AccessKeyId||!a.SecretAccessKey)throw new Error(`Invalid response from STS.assumeRole call with role ${r.RoleArn}`);const u=Jt(c),l={accessKeyId:a.AccessKeyId,secretAccessKey:a.SecretAccessKey,sessionToken:a.SessionToken,expiration:a.Expiration,...a.CredentialScope&&{credentialScope:a.CredentialScope},...u&&{accountId:u}};return(0,i.P)(l,"CREDENTIALS_STS_ASSUME_ROLE","i"),l}},ee=(t,e)=>{let n;return async s=>{if(!n){const{logger:i=t?.parentClientConfig?.logger,region:s,requestHandler:o=t?.parentClientConfig?.requestHandler,credentialProviderLogger:r}=t,a=await Qt(s,t?.parentClientConfig?.region,r),c=!ne(o);n=new e({region:a,requestHandler:c?o:void 0,logger:i})}const{Credentials:o,AssumedRoleUser:r}=await n.send(new Yt(s));if(!o||!o.AccessKeyId||!o.SecretAccessKey)throw new Error(`Invalid response from STS.assumeRoleWithWebIdentity call with role ${s.RoleArn}`);const a=Jt(r),c={accessKeyId:o.AccessKeyId,secretAccessKey:o.SecretAccessKey,sessionToken:o.SessionToken,expiration:o.Expiration,...o.CredentialScope&&{credentialScope:o.CredentialScope},...a&&{accountId:a}};return a&&(0,i.P)(c,"RESOLVED_ACCOUNT_ID","T"),(0,i.P)(c,"CREDENTIALS_STS_ASSUME_ROLE_WEB_ID","k"),c}},ne=t=>"h2"===t?.metadata?.handlerProtocol;var ie=n(14),se=n(17),oe=n(18),re=n(19),ae=n(50),ce=n(20),ue=n(51),le=n(31),de=n(60),he=n(21);const fe=async(t,e,n)=>({operation:(0,he.J)(e).operation,region:await(0,he.$)(t.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});const pe=t=>{const e=[];switch(t.operation){case"AssumeRoleWithSAML":case"AssumeRoleWithWebIdentity":e.push({schemeId:"smithy.api#noAuth"});break;default:e.push(function(t){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"sts",region:t.region},propertiesExtractor:(t,e)=>({signingProperties:{config:t,context:e}})}}(t))}return e},ge=t=>{const e=(n=t,{...n,stsClientCtor:wn});var n;return{...(0,de.K)(e)}},me="3.670.0";var ve=n(62),xe=n(61),we=n(52),be=n(55),ye=n(57),Ee=n(23),Ie=n(41),Pe=n(58),Ae=n(32),Se=n(29),Te=n(36),$e=n(40),De=n(48),Re=n(49);const Ce="required",Oe="type",Ne="fn",ke="argv",je="ref",Fe=!0,_e="booleanEquals",Ue="stringEquals",Le="sigv4",Me="us-east-1",We="endpoint",Ve="https://sts.{Region}.{PartitionResult#dnsSuffix}",ze="tree",qe="error",Be="getAttr",Ke={[Ce]:!1,[Oe]:"String"},Xe={[Ce]:!0,default:!1,[Oe]:"Boolean"},Ge={[je]:"Endpoint"},He={[Ne]:"isSet",[ke]:[{[je]:"Region"}]},Ye={[je]:"Region"},Ze={[Ne]:"aws.partition",[ke]:[Ye],assign:"PartitionResult"},Je={[je]:"UseFIPS"},Qe={[je]:"UseDualStack"},tn={url:"https://sts.amazonaws.com",properties:{authSchemes:[{name:Le,signingName:"sts",signingRegion:Me}]},headers:{}},en={},nn={conditions:[{[Ne]:Ue,[ke]:[Ye,"aws-global"]}],[We]:tn,[Oe]:We},sn={[Ne]:_e,[ke]:[Je,!0]},on={[Ne]:_e,[ke]:[Qe,!0]},rn={[Ne]:Be,[ke]:[{[je]:"PartitionResult"},"supportsFIPS"]},an={[je]:"PartitionResult"},cn={[Ne]:_e,[ke]:[!0,{[Ne]:Be,[ke]:[an,"supportsDualStack"]}]},un=[{[Ne]:"isSet",[ke]:[Ge]}],ln=[sn],dn=[on],hn={version:"1.0",parameters:{Region:Ke,UseDualStack:Xe,UseFIPS:Xe,Endpoint:Ke,UseGlobalEndpoint:Xe},rules:[{conditions:[{[Ne]:_e,[ke]:[{[je]:"UseGlobalEndpoint"},Fe]},{[Ne]:"not",[ke]:un},He,Ze,{[Ne]:_e,[ke]:[Je,false]},{[Ne]:_e,[ke]:[Qe,false]}],rules:[{conditions:[{[Ne]:Ue,[ke]:[Ye,"ap-northeast-1"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"ap-south-1"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"ap-southeast-1"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"ap-southeast-2"]}],endpoint:tn,[Oe]:We},nn,{conditions:[{[Ne]:Ue,[ke]:[Ye,"ca-central-1"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"eu-central-1"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"eu-north-1"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"eu-west-1"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"eu-west-2"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"eu-west-3"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"sa-east-1"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,Me]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"us-east-2"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"us-west-1"]}],endpoint:tn,[Oe]:We},{conditions:[{[Ne]:Ue,[ke]:[Ye,"us-west-2"]}],endpoint:tn,[Oe]:We},{endpoint:{url:Ve,properties:{authSchemes:[{name:Le,signingName:"sts",signingRegion:"{Region}"}]},headers:en},[Oe]:We}],[Oe]:ze},{conditions:un,rules:[{conditions:ln,error:"Invalid Configuration: FIPS and custom endpoint are not supported",[Oe]:qe},{conditions:dn,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",[Oe]:qe},{endpoint:{url:Ge,properties:en,headers:en},[Oe]:We}],[Oe]:ze},{conditions:[He],rules:[{conditions:[Ze],rules:[{conditions:[sn,on],rules:[{conditions:[{[Ne]:_e,[ke]:[Fe,rn]},cn],rules:[{endpoint:{url:"https://sts-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:en,headers:en},[Oe]:We}],[Oe]:ze},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",[Oe]:qe}],[Oe]:ze},{conditions:ln,rules:[{conditions:[{[Ne]:_e,[ke]:[rn,Fe]}],rules:[{conditions:[{[Ne]:Ue,[ke]:[{[Ne]:Be,[ke]:[an,"name"]},"aws-us-gov"]}],endpoint:{url:"https://sts.{Region}.amazonaws.com",properties:en,headers:en},[Oe]:We},{endpoint:{url:"https://sts-fips.{Region}.{PartitionResult#dnsSuffix}",properties:en,headers:en},[Oe]:We}],[Oe]:ze},{error:"FIPS is enabled but this partition does not support FIPS",[Oe]:qe}],[Oe]:ze},{conditions:dn,rules:[{conditions:[cn],rules:[{endpoint:{url:"https://sts.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:en,headers:en},[Oe]:We}],[Oe]:ze},{error:"DualStack is enabled but this partition does not support DualStack",[Oe]:qe}],[Oe]:ze},nn,{endpoint:{url:Ve,properties:en,headers:en},[Oe]:We}],[Oe]:ze}],[Oe]:ze},{error:"Invalid Configuration: Missing Region",[Oe]:qe}]},fn=new Re.$X({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS","UseGlobalEndpoint"]}),pn=(t,e={})=>fn.get(t,(()=>(0,Re.B1)(hn,{endpointParams:t,logger:e.logger})));Re.DY.aws=De.Iu;var gn=n(59);const mn=t=>{(0,r.H_)(process.version);const e=(0,gn.j)(t),n=()=>e().then(r.jv),i=(t=>({apiVersion:"2011-06-15",base64Decoder:t?.base64Decoder??Te.G,base64Encoder:t?.base64Encoder??Te.s,disableHostPrefix:t?.disableHostPrefix??!1,endpointProvider:t?.endpointProvider??pn,extensions:t?.extensions??[],httpAuthSchemeProvider:t?.httpAuthSchemeProvider??pe,httpAuthSchemes:t?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:t=>t.getIdentityProvider("aws.auth#sigv4"),signer:new xe.VR},{schemeId:"smithy.api#noAuth",identityProvider:t=>t.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new ce.oH}],logger:t?.logger??new r.vk,serviceId:t?.serviceId??"STS",urlParser:t?.urlParser??Se.e,utf8Decoder:t?.utf8Decoder??$e.$x,utf8Encoder:t?.utf8Encoder??$e.GZ}))(t);return(0,ve.H)(process.version),{...i,...t,runtime:"node",defaultsMode:e,bodyLengthChecker:t?.bodyLengthChecker??Pe.W,credentialDefaultProvider:t?.credentialDefaultProvider??we.iw,defaultUserAgentProvider:t?.defaultUserAgentProvider??(0,be.kk)({serviceId:i.serviceId,clientVersion:me}),httpAuthSchemes:t?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:t=>t.getIdentityProvider("aws.auth#sigv4")||(async t=>await(0,we.iw)(t?.t||{})()),signer:new xe.VR},{schemeId:"smithy.api#noAuth",identityProvider:t=>t.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new ce.oH}],maxAttempts:t?.maxAttempts??(0,Ee.M)(le.Hs),region:t?.region??(0,Ee.M)(ae._c,ae.zb),requestHandler:Ie.NA.create(t?.requestHandler??n),retryMode:t?.retryMode??(0,Ee.M)({...le.aK,default:async()=>(await n()).retryMode||Ae.CA}),sha256:t?.sha256??ye.k.bind(null,"sha256"),streamCollector:t?.streamCollector??Ie.CF,useDualstackEndpoint:t?.useDualstackEndpoint??(0,Ee.M)(ae.G7),useFipsEndpoint:t?.useFipsEndpoint??(0,Ee.M)(ae.NL),userAgentAppId:t?.userAgentAppId??(0,Ee.M)(be.eX)}};var vn=n(63);const xn=t=>{const e=t.httpAuthSchemes;let n=t.httpAuthSchemeProvider,i=t.credentials;return{setHttpAuthScheme(t){const n=e.findIndex((e=>e.schemeId===t.schemeId));-1===n?e.push(t):e.splice(n,1,t)},httpAuthSchemes:()=>e,setHttpAuthSchemeProvider(t){n=t},httpAuthSchemeProvider:()=>n,setCredentials(t){i=t},credentials:()=>i}};class wn extends r.KU{constructor(...[t]){const e=mn(t||{}),n=(i=e,{...i,useDualstackEndpoint:i.useDualstackEndpoint??!1,useFipsEndpoint:i.useFipsEndpoint??!1,useGlobalEndpoint:i.useGlobalEndpoint??!1,defaultSigningName:"sts"});var i;const o=(0,re.er)(n),a=(0,le.BC)(o),c=(0,ae.Xb)(a),u=(0,ie.S8)(c),l=(0,s.uW)(u),d=((t,e)=>{const n={...(0,vn.GW)(t),...(0,r.kE)(t),...(0,A.cA)(t),...xn(t)};return e.forEach((t=>t.configure(n))),{...t,...(0,vn.A1)(n),...(0,r.SQ)(n),...(0,A.AO)(n),...(i=n,{httpAuthSchemes:i.httpAuthSchemes(),httpAuthSchemeProvider:i.httpAuthSchemeProvider(),credentials:i.credentials()})};var i})(ge(l),t?.extensions||[]);super(d),this.config=d,this.middlewareStack.use((0,re.XJ)(this.config)),this.middlewareStack.use((0,le.NQ)(this.config)),this.middlewareStack.use((0,ue.VG)(this.config)),this.middlewareStack.use((0,ie.G2)(this.config)),this.middlewareStack.use((0,se.cV)(this.config)),this.middlewareStack.use((0,oe.eV)(this.config)),this.middlewareStack.use((0,ce.tZ)(this.config,{httpAuthSchemeParametersProvider:fe,identityProviderConfigProvider:async t=>new ce.K5({"aws.auth#sigv4":t.credentials})})),this.middlewareStack.use((0,ce.aZ)(this.config))}destroy(){super.destroy()}}const bn=(t,e)=>e?class extends t{constructor(t){super(t);for(const t of e)this.middlewareStack.use(t)}}:t,yn=(t={},e)=>te(t,bn(wn,e)),En=(t={},e)=>ee(t,bn(wn,e))},797:(t,e,n)=>{"use strict";const i=n(798),s=n(800),o=n(807);t.exports={XMLParser:s,XMLValidator:i,XMLBuilder:o}},799:(t,e)=>{"use strict";const n=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",i="["+n+"]["+(n+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040")+"]*",s=new RegExp("^"+i+"$");e.isExist=function(t){return void 0!==t},e.isEmptyObject=function(t){return 0===Object.keys(t).length},e.merge=function(t,e,n){if(e){const i=Object.keys(e),s=i.length;for(let o=0;o<s;o++)t[i[o]]="strict"===n?[e[i[o]]]:e[i[o]]}},e.getValue=function(t){return e.isExist(t)?t:""},e.isName=function(t){const e=s.exec(t);return!(null==e)},e.getAllMatches=function(t,e){const n=[];let i=e.exec(t);for(;i;){const s=[];s.startIndex=e.lastIndex-i[0].length;const o=i.length;for(let t=0;t<o;t++)s.push(i[t]);n.push(s),i=e.exec(t)}return n},e.nameRegexp=i},798:(t,e,n)=>{"use strict";const i=n(799),s={allowBooleanAttributes:!1,unpairedTags:[]};function o(t){return" "===t||"\t"===t||"\n"===t||"\r"===t}function r(t,e){const n=e;for(;e<t.length;e++)if("?"!=t[e]&&" "!=t[e]);else{const i=t.substr(n,e-n);if(e>5&&"xml"===i)return p("InvalidXml","XML declaration allowed only at the start of the document.",m(t,e));if("?"==t[e]&&">"==t[e+1]){e++;break}}return e}function a(t,e){if(t.length>e+5&&"-"===t[e+1]&&"-"===t[e+2]){for(e+=3;e<t.length;e++)if("-"===t[e]&&"-"===t[e+1]&&">"===t[e+2]){e+=2;break}}else if(t.length>e+8&&"D"===t[e+1]&&"O"===t[e+2]&&"C"===t[e+3]&&"T"===t[e+4]&&"Y"===t[e+5]&&"P"===t[e+6]&&"E"===t[e+7]){let n=1;for(e+=8;e<t.length;e++)if("<"===t[e])n++;else if(">"===t[e]&&(n--,0===n))break}else if(t.length>e+9&&"["===t[e+1]&&"C"===t[e+2]&&"D"===t[e+3]&&"A"===t[e+4]&&"T"===t[e+5]&&"A"===t[e+6]&&"["===t[e+7])for(e+=8;e<t.length;e++)if("]"===t[e]&&"]"===t[e+1]&&">"===t[e+2]){e+=2;break}return e}e.validate=function(t,e){e=Object.assign({},s,e);const n=[];let c=!1,u=!1;"\ufeff"===t[0]&&(t=t.substr(1));for(let s=0;s<t.length;s++)if("<"===t[s]&&"?"===t[s+1]){if(s+=2,s=r(t,s),s.err)return s}else{if("<"!==t[s]){if(o(t[s]))continue;return p("InvalidChar","char '"+t[s]+"' is not expected.",m(t,s))}{let g=s;if(s++,"!"===t[s]){s=a(t,s);continue}{let v=!1;"/"===t[s]&&(v=!0,s++);let x="";for(;s<t.length&&">"!==t[s]&&" "!==t[s]&&"\t"!==t[s]&&"\n"!==t[s]&&"\r"!==t[s];s++)x+=t[s];if(x=x.trim(),"/"===x[x.length-1]&&(x=x.substring(0,x.length-1),s--),d=x,!i.isName(d)){let e;return e=0===x.trim().length?"Invalid space after '<'.":"Tag '"+x+"' is an invalid name.",p("InvalidTag",e,m(t,s))}const w=l(t,s);if(!1===w)return p("InvalidAttr","Attributes for '"+x+"' have open quote.",m(t,s));let b=w.value;if(s=w.index,"/"===b[b.length-1]){const n=s-b.length;b=b.substring(0,b.length-1);const i=h(b,e);if(!0!==i)return p(i.err.code,i.err.msg,m(t,n+i.err.line));c=!0}else if(v){if(!w.tagClosed)return p("InvalidTag","Closing tag '"+x+"' doesn't have proper closing.",m(t,s));if(b.trim().length>0)return p("InvalidTag","Closing tag '"+x+"' can't have attributes or invalid starting.",m(t,g));if(0===n.length)return p("InvalidTag","Closing tag '"+x+"' has not been opened.",m(t,g));{const e=n.pop();if(x!==e.tagName){let n=m(t,e.tagStartPos);return p("InvalidTag","Expected closing tag '"+e.tagName+"' (opened in line "+n.line+", col "+n.col+") instead of closing tag '"+x+"'.",m(t,g))}0==n.length&&(u=!0)}}else{const i=h(b,e);if(!0!==i)return p(i.err.code,i.err.msg,m(t,s-b.length+i.err.line));if(!0===u)return p("InvalidXml","Multiple possible root nodes found.",m(t,s));-1!==e.unpairedTags.indexOf(x)||n.push({tagName:x,tagStartPos:g}),c=!0}for(s++;s<t.length;s++)if("<"===t[s]){if("!"===t[s+1]){s++,s=a(t,s);continue}if("?"!==t[s+1])break;if(s=r(t,++s),s.err)return s}else if("&"===t[s]){const e=f(t,s);if(-1==e)return p("InvalidChar","char '&' is not expected.",m(t,s));s=e}else if(!0===u&&!o(t[s]))return p("InvalidXml","Extra text at the end",m(t,s));"<"===t[s]&&s--}}}var d;return c?1==n.length?p("InvalidTag","Unclosed tag '"+n[0].tagName+"'.",m(t,n[0].tagStartPos)):!(n.length>0)||p("InvalidXml","Invalid '"+JSON.stringify(n.map((t=>t.tagName)),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):p("InvalidXml","Start tag expected.",1)};const c='"',u="'";function l(t,e){let n="",i="",s=!1;for(;e<t.length;e++){if(t[e]===c||t[e]===u)""===i?i=t[e]:i!==t[e]||(i="");else if(">"===t[e]&&""===i){s=!0;break}n+=t[e]}return""===i&&{value:n,index:e,tagClosed:s}}const d=new RegExp("(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['\"])(([\\s\\S])*?)\\5)?","g");function h(t,e){const n=i.getAllMatches(t,d),s={};for(let t=0;t<n.length;t++){if(0===n[t][1].length)return p("InvalidAttr","Attribute '"+n[t][2]+"' has no space in starting.",v(n[t]));if(void 0!==n[t][3]&&void 0===n[t][4])return p("InvalidAttr","Attribute '"+n[t][2]+"' is without value.",v(n[t]));if(void 0===n[t][3]&&!e.allowBooleanAttributes)return p("InvalidAttr","boolean attribute '"+n[t][2]+"' is not allowed.",v(n[t]));const i=n[t][2];if(!g(i))return p("InvalidAttr","Attribute '"+i+"' is an invalid name.",v(n[t]));if(s.hasOwnProperty(i))return p("InvalidAttr","Attribute '"+i+"' is repeated.",v(n[t]));s[i]=1}return!0}function f(t,e){if(";"===t[++e])return-1;if("#"===t[e])return function(t,e){let n=/\d/;for("x"===t[e]&&(e++,n=/[\da-fA-F]/);e<t.length;e++){if(";"===t[e])return e;if(!t[e].match(n))break}return-1}(t,++e);let n=0;for(;e<t.length;e++,n++)if(!(t[e].match(/\w/)&&n<20)){if(";"===t[e])break;return-1}return e}function p(t,e,n){return{err:{code:t,msg:e,line:n.line||n,col:n.col}}}function g(t){return i.isName(t)}function m(t,e){const n=t.substring(0,e).split(/\r?\n/);return{line:n.length,col:n[n.length-1].length+1}}function v(t){return t.startIndex+t[1].length}},807:(t,e,n)=>{"use strict";const i=n(808),s={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1};function o(t){this.options=Object.assign({},s,t),this.options.ignoreAttributes||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=c),this.processTextOrObjNode=r,this.options.format?(this.indentate=a,this.tagEndChar=">\n",this.newLine="\n"):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function r(t,e,n){const i=this.j2x(t,n+1);return void 0!==t[this.options.textNodeName]&&1===Object.keys(t).length?this.buildTextValNode(t[this.options.textNodeName],e,i.attrStr,n):this.buildObjectNode(i.val,e,i.attrStr,n)}function a(t){return this.options.indentBy.repeat(t)}function c(t){return!(!t.startsWith(this.options.attributeNamePrefix)||t===this.options.textNodeName)&&t.substr(this.attrPrefixLen)}o.prototype.build=function(t){return this.options.preserveOrder?i(t,this.options):(Array.isArray(t)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(t={[this.options.arrayNodeName]:t}),this.j2x(t,0).val)},o.prototype.j2x=function(t,e){let n="",i="";for(let s in t)if(Object.prototype.hasOwnProperty.call(t,s))if(void 0===t[s])this.isAttribute(s)&&(i+="");else if(null===t[s])this.isAttribute(s)?i+="":"?"===s[0]?i+=this.indentate(e)+"<"+s+"?"+this.tagEndChar:i+=this.indentate(e)+"<"+s+"/"+this.tagEndChar;else if(t[s]instanceof Date)i+=this.buildTextValNode(t[s],s,"",e);else if("object"!=typeof t[s]){const o=this.isAttribute(s);if(o)n+=this.buildAttrPairStr(o,""+t[s]);else if(s===this.options.textNodeName){let e=this.options.tagValueProcessor(s,""+t[s]);i+=this.replaceEntitiesValue(e)}else i+=this.buildTextValNode(t[s],s,"",e)}else if(Array.isArray(t[s])){const n=t[s].length;let o="",r="";for(let a=0;a<n;a++){const n=t[s][a];if(void 0===n);else if(null===n)"?"===s[0]?i+=this.indentate(e)+"<"+s+"?"+this.tagEndChar:i+=this.indentate(e)+"<"+s+"/"+this.tagEndChar;else if("object"==typeof n)if(this.options.oneListGroup){const t=this.j2x(n,e+1);o+=t.val,this.options.attributesGroupName&&n.hasOwnProperty(this.options.attributesGroupName)&&(r+=t.attrStr)}else o+=this.processTextOrObjNode(n,s,e);else if(this.options.oneListGroup){let t=this.options.tagValueProcessor(s,n);t=this.replaceEntitiesValue(t),o+=t}else o+=this.buildTextValNode(n,s,"",e)}this.options.oneListGroup&&(o=this.buildObjectNode(o,s,r,e)),i+=o}else if(this.options.attributesGroupName&&s===this.options.attributesGroupName){const e=Object.keys(t[s]),i=e.length;for(let o=0;o<i;o++)n+=this.buildAttrPairStr(e[o],""+t[s][e[o]])}else i+=this.processTextOrObjNode(t[s],s,e);return{attrStr:n,val:i}},o.prototype.buildAttrPairStr=function(t,e){return e=this.options.attributeValueProcessor(t,""+e),e=this.replaceEntitiesValue(e),this.options.suppressBooleanAttributes&&"true"===e?" "+t:" "+t+'="'+e+'"'},o.prototype.buildObjectNode=function(t,e,n,i){if(""===t)return"?"===e[0]?this.indentate(i)+"<"+e+n+"?"+this.tagEndChar:this.indentate(i)+"<"+e+n+this.closeTag(e)+this.tagEndChar;{let s="</"+e+this.tagEndChar,o="";return"?"===e[0]&&(o="?",s=""),!n&&""!==n||-1!==t.indexOf("<")?!1!==this.options.commentPropName&&e===this.options.commentPropName&&0===o.length?this.indentate(i)+`\x3c!--${t}--\x3e`+this.newLine:this.indentate(i)+"<"+e+n+o+this.tagEndChar+t+this.indentate(i)+s:this.indentate(i)+"<"+e+n+o+">"+t+s}},o.prototype.closeTag=function(t){let e="";return-1!==this.options.unpairedTags.indexOf(t)?this.options.suppressUnpairedNode||(e="/"):e=this.options.suppressEmptyNode?"/":`></${t}`,e},o.prototype.buildTextValNode=function(t,e,n,i){if(!1!==this.options.cdataPropName&&e===this.options.cdataPropName)return this.indentate(i)+`<![CDATA[${t}]]>`+this.newLine;if(!1!==this.options.commentPropName&&e===this.options.commentPropName)return this.indentate(i)+`\x3c!--${t}--\x3e`+this.newLine;if("?"===e[0])return this.indentate(i)+"<"+e+n+"?"+this.tagEndChar;{let s=this.options.tagValueProcessor(e,t);return s=this.replaceEntitiesValue(s),""===s?this.indentate(i)+"<"+e+n+this.closeTag(e)+this.tagEndChar:this.indentate(i)+"<"+e+n+">"+s+"</"+e+this.tagEndChar}},o.prototype.replaceEntitiesValue=function(t){if(t&&t.length>0&&this.options.processEntities)for(let e=0;e<this.options.entities.length;e++){const n=this.options.entities[e];t=t.replace(n.regex,n.val)}return t},t.exports=o},808:t=>{function e(t,r,a,c){let u="",l=!1;for(let d=0;d<t.length;d++){const h=t[d],f=n(h);if(void 0===f)continue;let p="";if(p=0===a.length?f:`${a}.${f}`,f===r.textNodeName){let t=h[f];s(p,r)||(t=r.tagValueProcessor(f,t),t=o(t,r)),l&&(u+=c),u+=t,l=!1;continue}if(f===r.cdataPropName){l&&(u+=c),u+=`<![CDATA[${h[f][0][r.textNodeName]}]]>`,l=!1;continue}if(f===r.commentPropName){u+=c+`\x3c!--${h[f][0][r.textNodeName]}--\x3e`,l=!0;continue}if("?"===f[0]){const t=i(h[":@"],r),e="?xml"===f?"":c;let n=h[f][0][r.textNodeName];n=0!==n.length?" "+n:"",u+=e+`<${f}${n}${t}?>`,l=!0;continue}let g=c;""!==g&&(g+=r.indentBy);const m=c+`<${f}${i(h[":@"],r)}`,v=e(h[f],r,p,g);-1!==r.unpairedTags.indexOf(f)?r.suppressUnpairedNode?u+=m+">":u+=m+"/>":v&&0!==v.length||!r.suppressEmptyNode?v&&v.endsWith(">")?u+=m+`>${v}${c}</${f}>`:(u+=m+">",v&&""!==c&&(v.includes("/>")||v.includes("</"))?u+=c+r.indentBy+v+c:u+=v,u+=`</${f}>`):u+=m+"/>",l=!0}return u}function n(t){const e=Object.keys(t);for(let n=0;n<e.length;n++){const i=e[n];if(t.hasOwnProperty(i)&&":@"!==i)return i}}function i(t,e){let n="";if(t&&!e.ignoreAttributes)for(let i in t){if(!t.hasOwnProperty(i))continue;let s=e.attributeValueProcessor(i,t[i]);s=o(s,e),!0===s&&e.suppressBooleanAttributes?n+=` ${i.substr(e.attributeNamePrefix.length)}`:n+=` ${i.substr(e.attributeNamePrefix.length)}="${s}"`}return n}function s(t,e){let n=(t=t.substr(0,t.length-e.textNodeName.length-1)).substr(t.lastIndexOf(".")+1);for(let i in e.stopNodes)if(e.stopNodes[i]===t||e.stopNodes[i]==="*."+n)return!0;return!1}function o(t,e){if(t&&t.length>0&&e.processEntities)for(let n=0;n<e.entities.length;n++){const i=e.entities[n];t=t.replace(i.regex,i.val)}return t}t.exports=function(t,n){let i="";return n.format&&n.indentBy.length>0&&(i="\n"),e(t,n,"",i)}},804:(t,e,n)=>{const i=n(799);function s(t,e){let n="";for(;e<t.length&&"'"!==t[e]&&'"'!==t[e];e++)n+=t[e];if(n=n.trim(),-1!==n.indexOf(" "))throw new Error("External entites are not supported");const i=t[e++];let s="";for(;e<t.length&&t[e]!==i;e++)s+=t[e];return[n,s,e]}function o(t,e){return"!"===t[e+1]&&"-"===t[e+2]&&"-"===t[e+3]}function r(t,e){return"!"===t[e+1]&&"E"===t[e+2]&&"N"===t[e+3]&&"T"===t[e+4]&&"I"===t[e+5]&&"T"===t[e+6]&&"Y"===t[e+7]}function a(t,e){return"!"===t[e+1]&&"E"===t[e+2]&&"L"===t[e+3]&&"E"===t[e+4]&&"M"===t[e+5]&&"E"===t[e+6]&&"N"===t[e+7]&&"T"===t[e+8]}function c(t,e){return"!"===t[e+1]&&"A"===t[e+2]&&"T"===t[e+3]&&"T"===t[e+4]&&"L"===t[e+5]&&"I"===t[e+6]&&"S"===t[e+7]&&"T"===t[e+8]}function u(t,e){return"!"===t[e+1]&&"N"===t[e+2]&&"O"===t[e+3]&&"T"===t[e+4]&&"A"===t[e+5]&&"T"===t[e+6]&&"I"===t[e+7]&&"O"===t[e+8]&&"N"===t[e+9]}function l(t){if(i.isName(t))return t;throw new Error(`Invalid entity name ${t}`)}t.exports=function(t,e){const n={};if("O"!==t[e+3]||"C"!==t[e+4]||"T"!==t[e+5]||"Y"!==t[e+6]||"P"!==t[e+7]||"E"!==t[e+8])throw new Error("Invalid Tag instead of DOCTYPE");{e+=9;let i=1,d=!1,h=!1,f="";for(;e<t.length;e++)if("<"!==t[e]||h)if(">"===t[e]){if(h?"-"===t[e-1]&&"-"===t[e-2]&&(h=!1,i--):i--,0===i)break}else"["===t[e]?d=!0:f+=t[e];else{if(d&&r(t,e))e+=7,[entityName,val,e]=s(t,e+1),-1===val.indexOf("&")&&(n[l(entityName)]={regx:RegExp(`&${entityName};`,"g"),val});else if(d&&a(t,e))e+=8;else if(d&&c(t,e))e+=8;else if(d&&u(t,e))e+=9;else{if(!o)throw new Error("Invalid DOCTYPE");h=!0}i++,f=""}if(0!==i)throw new Error("Unclosed DOCTYPE")}return{entities:n,i:e}}},801:(t,e)=>{const n={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(t,e,n){return t}};e.buildOptions=function(t){return Object.assign({},n,t)},e.defaultOptions=n},802:(t,e,n)=>{"use strict";const i=n(799),s=n(803),o=n(804),r=n(805);function a(t){const e=Object.keys(t);for(let n=0;n<e.length;n++){const i=e[n];this.lastEntities[i]={regex:new RegExp("&"+i+";","g"),val:t[i]}}}function c(t,e,n,i,s,o,r){if(void 0!==t&&(this.options.trimValues&&!i&&(t=t.trim()),t.length>0)){r||(t=this.replaceEntitiesValue(t));const i=this.options.tagValueProcessor(e,t,n,s,o);if(null==i)return t;if(typeof i!=typeof t||i!==t)return i;if(this.options.trimValues)return b(t,this.options.parseTagValue,this.options.numberParseOptions);return t.trim()===t?b(t,this.options.parseTagValue,this.options.numberParseOptions):t}}function u(t){if(this.options.removeNSPrefix){const e=t.split(":"),n="/"===t.charAt(0)?"/":"";if("xmlns"===e[0])return"";2===e.length&&(t=n+e[1])}return t}const l=new RegExp("([^\\s=]+)\\s*(=\\s*(['\"])([\\s\\S]*?)\\3)?","gm");function d(t,e,n){if(!this.options.ignoreAttributes&&"string"==typeof t){const n=i.getAllMatches(t,l),s=n.length,o={};for(let t=0;t<s;t++){const i=this.resolveNameSpace(n[t][1]);let s=n[t][4],r=this.options.attributeNamePrefix+i;if(i.length)if(this.options.transformAttributeName&&(r=this.options.transformAttributeName(r)),"__proto__"===r&&(r="#__proto__"),void 0!==s){this.options.trimValues&&(s=s.trim()),s=this.replaceEntitiesValue(s);const t=this.options.attributeValueProcessor(i,s,e);o[r]=null==t?s:typeof t!=typeof s||t!==s?t:b(s,this.options.parseAttributeValue,this.options.numberParseOptions)}else this.options.allowBooleanAttributes&&(o[r]=!0)}if(!Object.keys(o).length)return;if(this.options.attributesGroupName){const t={};return t[this.options.attributesGroupName]=o,t}return o}}const h=function(t){t=t.replace(/\r\n?/g,"\n");const e=new s("!xml");let n=e,i="",r="";for(let a=0;a<t.length;a++){if("<"===t[a])if("/"===t[a+1]){const e=v(t,">",a,"Closing Tag is not closed.");let s=t.substring(a+2,e).trim();if(this.options.removeNSPrefix){const t=s.indexOf(":");-1!==t&&(s=s.substr(t+1))}this.options.transformTagName&&(s=this.options.transformTagName(s)),n&&(i=this.saveTextToParentTag(i,n,r));const o=r.substring(r.lastIndexOf(".")+1);if(s&&-1!==this.options.unpairedTags.indexOf(s))throw new Error(`Unpaired tag can not be used as closing tag: </${s}>`);let c=0;o&&-1!==this.options.unpairedTags.indexOf(o)?(c=r.lastIndexOf(".",r.lastIndexOf(".")-1),this.tagsNodeStack.pop()):c=r.lastIndexOf("."),r=r.substring(0,c),n=this.tagsNodeStack.pop(),i="",a=e}else if("?"===t[a+1]){let e=x(t,a,!1,"?>");if(!e)throw new Error("Pi Tag is not closed.");if(i=this.saveTextToParentTag(i,n,r),this.options.ignoreDeclaration&&"?xml"===e.tagName||this.options.ignorePiTags);else{const t=new s(e.tagName);t.add(this.options.textNodeName,""),e.tagName!==e.tagExp&&e.attrExpPresent&&(t[":@"]=this.buildAttributesMap(e.tagExp,r,e.tagName)),this.addChild(n,t,r)}a=e.closeIndex+1}else if("!--"===t.substr(a+1,3)){const e=v(t,"--\x3e",a+4,"Comment is not closed.");if(this.options.commentPropName){const s=t.substring(a+4,e-2);i=this.saveTextToParentTag(i,n,r),n.add(this.options.commentPropName,[{[this.options.textNodeName]:s}])}a=e}else if("!D"===t.substr(a+1,2)){const e=o(t,a);this.docTypeEntities=e.entities,a=e.i}else if("!["===t.substr(a+1,2)){const e=v(t,"]]>",a,"CDATA is not closed.")-2,s=t.substring(a+9,e);i=this.saveTextToParentTag(i,n,r);let o=this.parseTextData(s,n.tagname,r,!0,!1,!0,!0);null==o&&(o=""),this.options.cdataPropName?n.add(this.options.cdataPropName,[{[this.options.textNodeName]:s}]):n.add(this.options.textNodeName,o),a=e+2}else{let o=x(t,a,this.options.removeNSPrefix),c=o.tagName;const u=o.rawTagName;let l=o.tagExp,d=o.attrExpPresent,h=o.closeIndex;this.options.transformTagName&&(c=this.options.transformTagName(c)),n&&i&&"!xml"!==n.tagname&&(i=this.saveTextToParentTag(i,n,r,!1));const f=n;if(f&&-1!==this.options.unpairedTags.indexOf(f.tagname)&&(n=this.tagsNodeStack.pop(),r=r.substring(0,r.lastIndexOf("."))),c!==e.tagname&&(r+=r?"."+c:c),this.isItStopNode(this.options.stopNodes,r,c)){let e="";if(l.length>0&&l.lastIndexOf("/")===l.length-1)"/"===c[c.length-1]?(c=c.substr(0,c.length-1),r=r.substr(0,r.length-1),l=c):l=l.substr(0,l.length-1),a=o.closeIndex;else if(-1!==this.options.unpairedTags.indexOf(c))a=o.closeIndex;else{const n=this.readStopNodeData(t,u,h+1);if(!n)throw new Error(`Unexpected end of ${u}`);a=n.i,e=n.tagContent}const i=new s(c);c!==l&&d&&(i[":@"]=this.buildAttributesMap(l,r,c)),e&&(e=this.parseTextData(e,c,r,!0,d,!0,!0)),r=r.substr(0,r.lastIndexOf(".")),i.add(this.options.textNodeName,e),this.addChild(n,i,r)}else{if(l.length>0&&l.lastIndexOf("/")===l.length-1){"/"===c[c.length-1]?(c=c.substr(0,c.length-1),r=r.substr(0,r.length-1),l=c):l=l.substr(0,l.length-1),this.options.transformTagName&&(c=this.options.transformTagName(c));const t=new s(c);c!==l&&d&&(t[":@"]=this.buildAttributesMap(l,r,c)),this.addChild(n,t,r),r=r.substr(0,r.lastIndexOf("."))}else{const t=new s(c);this.tagsNodeStack.push(n),c!==l&&d&&(t[":@"]=this.buildAttributesMap(l,r,c)),this.addChild(n,t,r),n=t}i="",a=h}}else i+=t[a]}return e.child};function f(t,e,n){const i=this.options.updateTag(e.tagname,n,e[":@"]);!1===i||("string"==typeof i?(e.tagname=i,t.addChild(e)):t.addChild(e))}const p=function(t){if(this.options.processEntities){for(let e in this.docTypeEntities){const n=this.docTypeEntities[e];t=t.replace(n.regx,n.val)}for(let e in this.lastEntities){const n=this.lastEntities[e];t=t.replace(n.regex,n.val)}if(this.options.htmlEntities)for(let e in this.htmlEntities){const n=this.htmlEntities[e];t=t.replace(n.regex,n.val)}t=t.replace(this.ampEntity.regex,this.ampEntity.val)}return t};function g(t,e,n,i){return t&&(void 0===i&&(i=0===Object.keys(e.child).length),void 0!==(t=this.parseTextData(t,e.tagname,n,!1,!!e[":@"]&&0!==Object.keys(e[":@"]).length,i))&&""!==t&&e.add(this.options.textNodeName,t),t=""),t}function m(t,e,n){const i="*."+n;for(const n in t){const s=t[n];if(i===s||e===s)return!0}return!1}function v(t,e,n,i){const s=t.indexOf(e,n);if(-1===s)throw new Error(i);return s+e.length-1}function x(t,e,n,i=">"){const s=function(t,e,n=">"){let i,s="";for(let o=e;o<t.length;o++){let e=t[o];if(i)e===i&&(i="");else if('"'===e||"'"===e)i=e;else if(e===n[0]){if(!n[1])return{data:s,index:o};if(t[o+1]===n[1])return{data:s,index:o}}else"\t"===e&&(e=" ");s+=e}}(t,e+1,i);if(!s)return;let o=s.data;const r=s.index,a=o.search(/\s/);let c=o,u=!0;-1!==a&&(c=o.substring(0,a),o=o.substring(a+1).trimStart());const l=c;if(n){const t=c.indexOf(":");-1!==t&&(c=c.substr(t+1),u=c!==s.data.substr(t+1))}return{tagName:c,tagExp:o,closeIndex:r,attrExpPresent:u,rawTagName:l}}function w(t,e,n){const i=n;let s=1;for(;n<t.length;n++)if("<"===t[n])if("/"===t[n+1]){const o=v(t,">",n,`${e} is not closed`);if(t.substring(n+2,o).trim()===e&&(s--,0===s))return{tagContent:t.substring(i,n),i:o};n=o}else if("?"===t[n+1]){n=v(t,"?>",n+1,"StopNode is not closed.")}else if("!--"===t.substr(n+1,3)){n=v(t,"--\x3e",n+3,"StopNode is not closed.")}else if("!["===t.substr(n+1,2)){n=v(t,"]]>",n,"StopNode is not closed.")-2}else{const i=x(t,n,">");if(i){(i&&i.tagName)===e&&"/"!==i.tagExp[i.tagExp.length-1]&&s++,n=i.closeIndex}}}function b(t,e,n){if(e&&"string"==typeof t){const e=t.trim();return"true"===e||"false"!==e&&r(t,n)}return i.isExist(t)?t:""}t.exports=class{constructor(t){this.options=t,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"},num_dec:{regex:/&#([0-9]{1,7});/g,val:(t,e)=>String.fromCharCode(Number.parseInt(e,10))},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:(t,e)=>String.fromCharCode(Number.parseInt(e,16))}},this.addExternalEntities=a,this.parseXml=h,this.parseTextData=c,this.resolveNameSpace=u,this.buildAttributesMap=d,this.isItStopNode=m,this.replaceEntitiesValue=p,this.readStopNodeData=w,this.saveTextToParentTag=g,this.addChild=f}}},800:(t,e,n)=>{const{buildOptions:i}=n(801),s=n(802),{prettify:o}=n(806),r=n(798);t.exports=class{constructor(t){this.externalEntities={},this.options=i(t)}parse(t,e){if("string"==typeof t);else{if(!t.toString)throw new Error("XML data is accepted in String or Bytes[] form.");t=t.toString()}if(e){!0===e&&(e={});const n=r.validate(t,e);if(!0!==n)throw Error(`${n.err.msg}:${n.err.line}:${n.err.col}`)}const n=new s(this.options);n.addExternalEntities(this.externalEntities);const i=n.parseXml(t);return this.options.preserveOrder||void 0===i?i:o(i,this.options)}addEntity(t,e){if(-1!==e.indexOf("&"))throw new Error("Entity value can't have '&'");if(-1!==t.indexOf("&")||-1!==t.indexOf(";"))throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '
'");if("&"===e)throw new Error("An entity with value '&' is not permitted");this.externalEntities[t]=e}}},806:(t,e)=>{"use strict";function n(t,e,r){let a;const c={};for(let u=0;u<t.length;u++){const l=t[u],d=i(l);let h="";if(h=void 0===r?d:r+"."+d,d===e.textNodeName)void 0===a?a=l[d]:a+=""+l[d];else{if(void 0===d)continue;if(l[d]){let t=n(l[d],e,h);const i=o(t,e);l[":@"]?s(t,l[":@"],h,e):1!==Object.keys(t).length||void 0===t[e.textNodeName]||e.alwaysCreateTextNode?0===Object.keys(t).length&&(e.alwaysCreateTextNode?t[e.textNodeName]="":t=""):t=t[e.textNodeName],void 0!==c[d]&&c.hasOwnProperty(d)?(Array.isArray(c[d])||(c[d]=[c[d]]),c[d].push(t)):e.isArray(d,h,i)?c[d]=[t]:c[d]=t}}}return"string"==typeof a?a.length>0&&(c[e.textNodeName]=a):void 0!==a&&(c[e.textNodeName]=a),c}function i(t){const e=Object.keys(t);for(let t=0;t<e.length;t++){const n=e[t];if(":@"!==n)return n}}function s(t,e,n,i){if(e){const s=Object.keys(e),o=s.length;for(let r=0;r<o;r++){const o=s[r];i.isArray(o,n+"."+o,!0,!0)?t[o]=[e[o]]:t[o]=e[o]}}}function o(t,e){const{textNodeName:n}=e,i=Object.keys(t).length;return 0===i||!(1!==i||!t[n]&&"boolean"!=typeof t[n]&&0!==t[n])}e.prettify=function(t,e){return n(t,e)}},803:t=>{"use strict";t.exports=class{constructor(t){this.tagname=t,this.child=[],this[":@"]={}}add(t,e){"__proto__"===t&&(t="#__proto__"),this.child.push({[t]:e})}addChild(t){"__proto__"===t.tagname&&(t.tagname="#__proto__"),t[":@"]&&Object.keys(t[":@"]).length>0?this.child.push({[t.tagname]:t.child,":@":t[":@"]}):this.child.push({[t.tagname]:t.child})}}},805:t=>{const e=/^[-+]?0x[a-fA-F0-9]+$/,n=/^([\-\+])?(0*)(\.[0-9]+([eE]\-?[0-9]+)?|[0-9]+(\.[0-9]+([eE]\-?[0-9]+)?)?)$/;!Number.parseInt&&window.parseInt&&(Number.parseInt=window.parseInt),!Number.parseFloat&&window.parseFloat&&(Number.parseFloat=window.parseFloat);const i={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};t.exports=function(t,s={}){if(s=Object.assign({},i,s),!t||"string"!=typeof t)return t;let o=t.trim();if(void 0!==s.skipLike&&s.skipLike.test(o))return t;if(s.hex&&e.test(o))return Number.parseInt(o,16);{const e=n.exec(o);if(e){const n=e[1],i=e[2];let r=function(t){if(t&&-1!==t.indexOf("."))return"."===(t=t.replace(/0+$/,""))?t="0":"."===t[0]?t="0"+t:"."===t[t.length-1]&&(t=t.substr(0,t.length-1)),t;return t}(e[3]);const a=e[4]||e[6];if(!s.leadingZeros&&i.length>0&&n&&"."!==o[2])return t;if(!s.leadingZeros&&i.length>0&&!n&&"."!==o[1])return t;{const e=Number(o),c=""+e;return-1!==c.search(/[eE]/)||a?s.eNotation?e:t:-1!==o.indexOf(".")?"0"===c&&""===r||c===r||n&&c==="-"+r?e:t:i?r===c||n+r===c?e:t:o===c||o===n+c?e:t}}return t}}}};
|
|
3
|
+
//# sourceMappingURL=648.index.js.map
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";exports.id=678,exports.ids=[678],exports.modules={792:(e,t,a)=>{a.d(t,{ENV_CMDS_FULL_URI:()=>m,ENV_CMDS_RELATIVE_URI:()=>p,fromContainerMetadata:()=>w,fromInstanceMetadata:()=>L,getInstanceMetadataEndpoint:()=>N,httpRequest:()=>c});var n=a(25),r=a(4),o=a(26),i=a(38),s=a(42);function c(e){return new Promise(((t,a)=>{const n=(0,s.request)({method:"GET",...e,hostname:e.hostname?.replace(/^\[(.+)\]$/,"$1")});n.on("error",(e=>{a(Object.assign(new o.k("Unable to connect to instance metadata service"),e)),n.destroy()})),n.on("timeout",(()=>{a(new o.k("TimeoutError from instance metadata service")),n.destroy()})),n.on("response",(e=>{const{statusCode:r=400}=e;(r<200||300<=r)&&(a(Object.assign(new o.k("Error response received from instance metadata service"),{statusCode:r})),n.destroy());const s=[];e.on("data",(e=>{s.push(e)})),e.on("end",(()=>{t(i.Buffer.concat(s)),n.destroy()}))})),n.end()}))}const l=e=>Boolean(e)&&"object"==typeof e&&"string"==typeof e.AccessKeyId&&"string"==typeof e.SecretAccessKey&&"string"==typeof e.Token&&"string"==typeof e.Expiration,d=e=>({accessKeyId:e.AccessKeyId,secretAccessKey:e.SecretAccessKey,sessionToken:e.Token,expiration:new Date(e.Expiration),...e.AccountId&&{accountId:e.AccountId}}),u=({maxRetries:e=0,timeout:t=1e3})=>({maxRetries:e,timeout:t}),f=(e,t)=>{let a=e();for(let n=0;n<t;n++)a=a.catch(e);return a},m="AWS_CONTAINER_CREDENTIALS_FULL_URI",p="AWS_CONTAINER_CREDENTIALS_RELATIVE_URI",h="AWS_CONTAINER_AUTHORIZATION_TOKEN",w=(e={})=>{const{timeout:t,maxRetries:a}=u(e);return()=>f((async()=>{const a=await E({logger:e.logger}),r=JSON.parse(await v(t,a));if(!l(r))throw new n.m("Invalid response received from instance metadata service.",{logger:e.logger});return d(r)}),a)},v=async(e,t)=>{process.env[h]&&(t.headers={...t.headers,Authorization:process.env[h]});return(await c({...t,timeout:e})).toString()},g={localhost:!0,"127.0.0.1":!0},y={"http:":!0,"https:":!0},E=async({logger:e})=>{if(process.env[p])return{hostname:"169.254.170.2",path:process.env[p]};if(process.env[m]){const t=(0,r.parse)(process.env[m]);if(!t.hostname||!(t.hostname in g))throw new n.m(`${t.hostname} is not a valid container metadata service hostname`,{tryNextLink:!1,logger:e});if(!t.protocol||!(t.protocol in y))throw new n.m(`${t.protocol} is not a valid container metadata service protocol`,{tryNextLink:!1,logger:e});return{...t,port:t.port?parseInt(t.port,10):void 0}}throw new n.m(`The container metadata credential provider cannot be used unless the ${p} or ${m} environment variable is set`,{tryNextLink:!1,logger:e})};var I=a(23);class A extends n.m{constructor(e,t=!0){super(e,t),this.tryNextLink=t,this.name="InstanceMetadataV1FallbackError",Object.setPrototypeOf(this,A.prototype)}}var S,b=a(29);!function(e){e.IPv4="http://169.254.169.254",e.IPv6="http://[fd00:ec2::254]"}(S||(S={}));const _={environmentVariableSelector:e=>e.AWS_EC2_METADATA_SERVICE_ENDPOINT,configFileSelector:e=>e.ec2_metadata_service_endpoint,default:void 0};var x;!function(e){e.IPv4="IPv4",e.IPv6="IPv6"}(x||(x={}));const T={environmentVariableSelector:e=>e.AWS_EC2_METADATA_SERVICE_ENDPOINT_MODE,configFileSelector:e=>e.ec2_metadata_service_endpoint_mode,default:x.IPv4},N=async()=>(0,b.e)(await R()||await k()),R=async()=>(0,I.M)(_)(),k=async()=>{const e=await(0,I.M)(T)();switch(e){case x.IPv4:return S.IPv4;case x.IPv6:return S.IPv6;default:throw new Error(`Unsupported endpoint mode: ${e}. Select from ${Object.values(x)}`)}},D=(e,t)=>{const a=300+Math.floor(300*Math.random()),n=new Date(Date.now()+1e3*a);t.warn(`Attempting credential expiration extension due to a credential service availability issue. A refresh of these credentials will be attempted after ${new Date(n)}.\nFor more information, please visit: https://docs.aws.amazon.com/sdkref/latest/guide/feature-static-credentials.html`);const r=e.originalExpiration??e.expiration;return{...e,...r?{originalExpiration:r}:{},expiration:n}},C="/latest/meta-data/iam/security-credentials/",M="AWS_EC2_METADATA_V1_DISABLED",O="ec2_metadata_v1_disabled",$="x-aws-ec2-metadata-token",L=(e={})=>((e,t={})=>{const a=t?.logger||console;let n;return async()=>{let t;try{t=await e(),t.expiration&&t.expiration.getTime()<Date.now()&&(t=D(t,a))}catch(e){if(!n)throw e;a.warn("Credential renew failed: ",e),t=D(n,a)}return n=t,t}})(U(e),{logger:e.logger}),U=(e={})=>{let t=!1;const{logger:a,profile:r}=e,{timeout:o,maxRetries:i}=u(e),s=async(a,o)=>{if(t||null==o.headers?.[$]){let t=!1,a=!1;const o=await(0,I.M)({environmentVariableSelector:t=>{const r=t[M];if(a=!!r&&"false"!==r,void 0===r)throw new n.m(`${M} not set in env, checking config file next.`,{logger:e.logger});return a},configFileSelector:e=>{const a=e[O];return t=!!a&&"false"!==a,t},default:!1},{profile:r})();if(e.ec2MetadataV1Disabled||o){const n=[];throw e.ec2MetadataV1Disabled&&n.push("credential provider initialization (runtime option ec2MetadataV1Disabled)"),t&&n.push(`config file profile (${O})`),a&&n.push(`process environment variable (${M})`),new A(`AWS EC2 Metadata v1 fallback has been blocked by AWS SDK configuration in the following: [${n.join(", ")}].`)}}const i=(await f((async()=>{let e;try{e=await W(o)}catch(e){throw 401===e.statusCode&&(t=!1),e}return e}),a)).trim();return f((async()=>{let a;try{a=await F(i,o,e)}catch(e){throw 401===e.statusCode&&(t=!1),e}return a}),a)};return async()=>{const e=await N();if(t)return a?.debug("AWS SDK Instance Metadata","using v1 fallback (no token fetch)"),s(i,{...e,timeout:o});{let n;try{n=(await V({...e,timeout:o})).toString()}catch(n){if(400===n?.statusCode)throw Object.assign(n,{message:"EC2 Metadata token request returned error"});return("TimeoutError"===n.message||[403,404,405].includes(n.statusCode))&&(t=!0),a?.debug("AWS SDK Instance Metadata","using v1 fallback (initial)"),s(i,{...e,timeout:o})}return s(i,{...e,headers:{[$]:n},timeout:o})}}},V=async e=>c({...e,path:"/latest/api/token",method:"PUT",headers:{"x-aws-ec2-metadata-token-ttl-seconds":"21600"}}),W=async e=>(await c({...e,path:C})).toString(),F=async(e,t,a)=>{const r=JSON.parse((await c({...t,path:C+e})).toString());if(!l(r))throw new n.m("Invalid response received from instance metadata service.",{logger:a.logger});return d(r)}}};
|
|
3
|
+
//# sourceMappingURL=678.index.js.map
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";exports.id=774,exports.ids=[774],exports.modules={788:(e,s,o)=>{o.d(s,{fromSSO:()=>k});var t=o(25),n=o(24);var r=o(54),i=o(26);class a extends i.k{constructor(e,s=!0){super(e,s),this.name="TokenProviderError",Object.setPrototypeOf(this,a.prototype)}}const c="To refresh this SSO session run 'aws sso login' with the corresponding profile.",l={},w=async(e,s)=>{const{CreateTokenCommand:t}=await o.e(988).then(o.bind(o,795)),n=await(async e=>{const{SSOOIDCClient:s}=await o.e(988).then(o.bind(o,795));if(l[e])return l[e];const t=new s({region:e});return l[e]=t,t})(s);return n.send(new t({clientId:e.clientId,clientSecret:e.clientSecret,refreshToken:e.refreshToken,grantType:"refresh_token"}))},f=e=>{if(e.expiration&&e.expiration.getTime()<Date.now())throw new a(`Token is expired. ${c}`,!1)},d=(e,s,o=!1)=>{if(void 0===s)throw new a(`Value not present for '${e}' in SSO Token${o?". Cannot refresh":""}. ${c}`,!1)};var g=o(6);const{writeFile:h}=g.promises,u=new Date(0),S=(e={})=>async()=>{e.logger?.debug("@aws-sdk/token-providers - fromSso");const s=await(0,n.MX)(e),o=(0,n.Jl)(e),t=s[o];if(!t)throw new a(`Profile '${o}' could not be found in shared credentials file.`,!1);if(!t.sso_session)throw new a(`Profile '${o}' is missing required property 'sso_session'.`);const r=t.sso_session,i=(await(0,n.G)(e))[r];if(!i)throw new a(`Sso session '${r}' could not be found in shared credentials file.`,!1);for(const e of["sso_start_url","sso_region"])if(!i[e])throw new a(`Sso session '${r}' is missing required property '${e}'.`,!1);i.sso_start_url;const l=i.sso_region;let g;try{g=await(0,n.gH)(r)}catch(e){throw new a(`The SSO session token associated with profile=${o} was not found or is invalid. ${c}`,!1)}d("accessToken",g.accessToken),d("expiresAt",g.expiresAt);const{accessToken:S,expiresAt:p}=g,y={token:S,expiration:new Date(p)};if(y.expiration.getTime()-Date.now()>3e5)return y;if(Date.now()-u.getTime()<3e4)return f(y),y;d("clientId",g.clientId,!0),d("clientSecret",g.clientSecret,!0),d("refreshToken",g.refreshToken,!0);try{u.setTime(Date.now());const e=await w(g,l);d("accessToken",e.accessToken),d("expiresIn",e.expiresIn);const s=new Date(Date.now()+1e3*e.expiresIn);try{await((e,s)=>{const o=(0,n.Py)(e),t=JSON.stringify(s,null,2);return h(o,t)})(r,{...g,accessToken:e.accessToken,expiresAt:s.toISOString(),refreshToken:e.refreshToken})}catch(e){}return{token:e.accessToken,expiration:s}}catch(e){return f(y),y}},p=!1,y=async({ssoStartUrl:e,ssoSession:s,ssoAccountId:i,ssoRegion:a,ssoRoleName:c,ssoClient:l,clientConfig:w,profile:f,logger:d})=>{let g;const h="To refresh this SSO session run aws sso login with the corresponding profile.";if(s)try{const e=await S({profile:f})();g={accessToken:e.token,expiresAt:new Date(e.expiration).toISOString()}}catch(e){throw new t.m(e.message,{tryNextLink:p,logger:d})}else try{g=await(0,n.gH)(e)}catch(e){throw new t.m(`The SSO session associated with this profile is invalid. ${h}`,{tryNextLink:p,logger:d})}if(new Date(g.expiresAt).getTime()-Date.now()<=0)throw new t.m(`The SSO session associated with this profile has expired. ${h}`,{tryNextLink:p,logger:d});const{accessToken:u}=g,{SSOClient:y,GetRoleCredentialsCommand:k}=await o.e(290).then(o.bind(o,794)),_=l||new y(Object.assign({},w??{},{region:w?.region??a}));let m;try{m=await _.send(new k({accountId:i,roleName:c,accessToken:u}))}catch(e){throw new t.m(e,{tryNextLink:p,logger:d})}const{roleCredentials:{accessKeyId:T,secretAccessKey:x,sessionToken:O,expiration:C,credentialScope:N,accountId:$}={}}=m;if(!(T&&x&&O&&C))throw new t.m("SSO returns an invalid temporary credential.",{tryNextLink:p,logger:d});const I={accessKeyId:T,secretAccessKey:x,sessionToken:O,expiration:new Date(C),...N&&{credentialScope:N},...$&&{accountId:$}};return s?(0,r.P)(I,"CREDENTIALS_SSO","s"):(0,r.P)(I,"CREDENTIALS_SSO_LEGACY","u"),I},k=(e={})=>async()=>{e.logger?.debug("@aws-sdk/credential-provider-sso - fromSSO");const{ssoStartUrl:s,ssoAccountId:o,ssoRegion:r,ssoRoleName:i,ssoSession:a}=e,{ssoClient:c}=e,l=(0,n.Jl)(e);if(s||o||r||i||a){if(s&&o&&r&&i)return y({ssoStartUrl:s,ssoSession:a,ssoAccountId:o,ssoRegion:r,ssoRoleName:i,ssoClient:c,clientConfig:e.clientConfig,profile:l});throw new t.m('Incomplete configuration. The fromSSO() argument hash must include "ssoStartUrl", "ssoAccountId", "ssoRegion", "ssoRoleName"',{tryNextLink:!1,logger:e.logger})}{const o=(await(0,n.MX)(e))[l];if(!o)throw new t.m(`Profile ${l} was not found.`,{logger:e.logger});if(!(w=o)||"string"!=typeof w.sso_start_url&&"string"!=typeof w.sso_account_id&&"string"!=typeof w.sso_session&&"string"!=typeof w.sso_region&&"string"!=typeof w.sso_role_name)throw new t.m(`Profile ${l} is not configured with SSO credentials.`,{logger:e.logger});if(o?.sso_session){const i=(await(0,n.G)(e))[o.sso_session],a=` configurations in profile ${l} and sso-session ${o.sso_session}`;if(r&&r!==i.sso_region)throw new t.m("Conflicting SSO region"+a,{tryNextLink:!1,logger:e.logger});if(s&&s!==i.sso_start_url)throw new t.m("Conflicting SSO start_url"+a,{tryNextLink:!1,logger:e.logger});o.sso_region=i.sso_region,o.sso_start_url=i.sso_start_url}const{sso_start_url:i,sso_account_id:a,sso_region:f,sso_role_name:d,sso_session:g}=((e,s)=>{const{sso_start_url:o,sso_account_id:n,sso_region:r,sso_role_name:i}=e;if(!(o&&n&&r&&i))throw new t.m(`Profile is configured with invalid SSO credentials. Required parameters "sso_account_id", "sso_region", "sso_role_name", "sso_start_url". Got ${Object.keys(e).join(", ")}\nReference: https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-sso.html`,{tryNextLink:!1,logger:s});return e})(o,e.logger);return y({ssoStartUrl:i,ssoSession:g,ssoAccountId:a,ssoRegion:f,ssoRoleName:d,ssoClient:c,clientConfig:e.clientConfig,profile:l})}var w}}};
|
|
3
|
+
//# sourceMappingURL=774.index.js.map
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";exports.id=925,exports.ids=[925],exports.modules={793:(e,t,r)=>{r.d(t,{fromHttp:()=>w});var o=r(54),n=r(41),s=r(25),i=r(77),a=r.n(i);var c=r(15),p=r(34),l=r(35);const w=(e={})=>{let t;e.logger?.debug("@aws-sdk/credential-provider-http - fromHttp");const r=e.awsContainerCredentialsRelativeUri??process.env.AWS_CONTAINER_CREDENTIALS_RELATIVE_URI,i=e.awsContainerCredentialsFullUri??process.env.AWS_CONTAINER_CREDENTIALS_FULL_URI,w=e.awsContainerAuthorizationToken??process.env.AWS_CONTAINER_AUTHORIZATION_TOKEN,h=e.awsContainerAuthorizationTokenFile??process.env.AWS_CONTAINER_AUTHORIZATION_TOKEN_FILE,d="NoOpLogger"!==e.logger?.constructor?.name&&e.logger?e.logger.warn:console.warn;if(r&&i&&(d("@aws-sdk/credential-provider-http: you have set both awsContainerCredentialsRelativeUri and awsContainerCredentialsFullUri."),d("awsContainerCredentialsFullUri will take precedence.")),w&&h&&(d("@aws-sdk/credential-provider-http: you have set both awsContainerAuthorizationToken and awsContainerAuthorizationTokenFile."),d("awsContainerAuthorizationToken will take precedence.")),i)t=i;else{if(!r)throw new s.m("No HTTP credential provider host provided.\nSet AWS_CONTAINER_CREDENTIALS_FULL_URI or AWS_CONTAINER_CREDENTIALS_RELATIVE_URI.",{logger:e.logger});t=`http://169.254.170.2${r}`}const u=new URL(t);((e,t)=>{if("https:"!==e.protocol&&"169.254.170.2"!==e.hostname&&"169.254.170.23"!==e.hostname&&"[fd00:ec2::23]"!==e.hostname){if(e.hostname.includes("[")){if("[::1]"===e.hostname||"[0000:0000:0000:0000:0000:0000:0000:0001]"===e.hostname)return}else{if("localhost"===e.hostname)return;const t=e.hostname.split("."),r=e=>{const t=parseInt(e,10);return 0<=t&&t<=255};if("127"===t[0]&&r(t[1])&&r(t[2])&&r(t[3])&&4===t.length)return}throw new s.m("URL not accepted. It must either be HTTPS or match one of the following:\n - loopback CIDR 127.0.0.0/8 or [::1/128]\n - ECS container host 169.254.170.2\n - EKS container host 169.254.170.23 or [fd00:ec2::23]",{logger:t})}})(u,e.logger);const f=new n.NA({requestTimeout:e.timeout??1e3,connectionTimeout:e.timeout??1e3});return g=async()=>{const t=function(e){return new c.aW({protocol:e.protocol,hostname:e.hostname,port:Number(e.port),path:e.pathname,query:Array.from(e.searchParams.entries()).reduce(((e,[t,r])=>(e[t]=r,e)),{}),fragment:e.hash})}(u);w?t.headers.Authorization=w:h&&(t.headers.Authorization=(await a().readFile(h)).toString());try{return async function(e,t){const r=(0,l.Ou)(e.body),o=await r.transformToString();if(200===e.statusCode){const e=JSON.parse(o);if("string"!=typeof e.AccessKeyId||"string"!=typeof e.SecretAccessKey||"string"!=typeof e.Token||"string"!=typeof e.Expiration)throw new s.m("HTTP credential provider response not of the required format, an object matching: { AccessKeyId: string, SecretAccessKey: string, Token: string, Expiration: string(rfc3339) }",{logger:t});return{accessKeyId:e.AccessKeyId,secretAccessKey:e.SecretAccessKey,sessionToken:e.Token,expiration:(0,p.uj)(e.Expiration)}}if(e.statusCode>=400&&e.statusCode<500){let r={};try{r=JSON.parse(o)}catch(e){}throw Object.assign(new s.m(`Server responded with status: ${e.statusCode}`,{logger:t}),{Code:r.Code,Message:r.Message})}throw new s.m(`Server responded with status: ${e.statusCode}`,{logger:t})}((await f.handle(t)).response).then((e=>(0,o.P)(e,"CREDENTIALS_HTTP","z")))}catch(t){throw new s.m(String(t),{logger:e.logger})}},T=e.maxRetries??3,y=e.timeout??1e3,async()=>{for(let e=0;e<T;++e)try{return await g()}catch(e){await new Promise((e=>setTimeout(e,y)))}return await g()};var g,T,y}}};
|
|
3
|
+
//# sourceMappingURL=925.index.js.map
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";exports.id=958,exports.ids=[958],exports.modules={791:(e,o,n)=>{n.r(o),n.d(o,{fromTokenFile:()=>c,fromWebToken:()=>t});var r=n(54),i=n(25),s=n(6);const t=e=>async()=>{e.logger?.debug("@aws-sdk/credential-provider-web-identity - fromWebToken");const{roleArn:o,roleSessionName:r,webIdentityToken:i,providerId:s,policyArns:t,policy:d,durationSeconds:c}=e;let{roleAssumerWithWebIdentity:a}=e;if(!a){const{getDefaultRoleAssumerWithWebIdentity:o}=await n.e(648).then(n.bind(n,796));a=o({...e.clientConfig,credentialProviderLogger:e.logger,parentClientConfig:e.parentClientConfig},e.clientPlugins)}return a({RoleArn:o,RoleSessionName:r??`aws-sdk-js-session-${Date.now()}`,WebIdentityToken:i,ProviderId:s,PolicyArns:t,Policy:d,DurationSeconds:c})},d="AWS_WEB_IDENTITY_TOKEN_FILE",c=(e={})=>async()=>{e.logger?.debug("@aws-sdk/credential-provider-web-identity - fromTokenFile");const o=e?.webIdentityTokenFile??process.env[d],n=e?.roleArn??process.env.AWS_ROLE_ARN,c=e?.roleSessionName??process.env.AWS_ROLE_SESSION_NAME;if(!o||!n)throw new i.m("Web identity configuration not specified",{logger:e.logger});const a=await t({...e,webIdentityToken:(0,s.readFileSync)(o,{encoding:"ascii"}),roleArn:n,roleSessionName:c})();return o===process.env[d]&&(0,r.P)(a,"CREDENTIALS_ENV_VARS_STS_WEB_ID_TOKEN","h"),a}}};
|
|
3
|
+
//# sourceMappingURL=958.index.js.map
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";exports.id=988,exports.ids=[988],exports.modules={795:(e,t,n)=>{n.d(t,{CreateTokenCommand:()=>Ke,SSOOIDCClient:()=>pe});var s=n(14),i=n(17),o=n(18),r=n(19),a=n(50),c=n(20),d=n(51),p=n(22),u=n(31),l=n(34),h=n(60),m=n(21);const x=async(e,t,n)=>({operation:(0,m.J)(t).operation,region:await(0,m.$)(e.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});const w=e=>{const t=[];switch(e.operation){case"CreateToken":case"RegisterClient":case"StartDeviceAuthorization":t.push({schemeId:"smithy.api#noAuth"});break;default:t.push(function(e){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"sso-oauth",region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}(e))}return t},E={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}},v="3.670.0";var y=n(62),I=n(52),S=n(55),g=n(57),f=n(23),b=n(41),P=n(58),O=n(32),C=n(61),k=n(29),R=n(36),j=n(40),D=n(48),$=n(49);const A="required",z="fn",T="argv",U="ref",q="isSet",_="booleanEquals",F="error",G="endpoint",M="tree",H="PartitionResult",V="getAttr",B={[A]:!1,type:"String"},N={[A]:!0,default:!1,type:"Boolean"},J={[U]:"Endpoint"},L={[z]:_,[T]:[{[U]:"UseFIPS"},!0]},W={[z]:_,[T]:[{[U]:"UseDualStack"},!0]},K={},Q={[z]:V,[T]:[{[U]:H},"supportsFIPS"]},X={[U]:H},Y={[z]:_,[T]:[!0,{[z]:V,[T]:[X,"supportsDualStack"]}]},Z=[L],ee=[W],te=[{[U]:"Region"}],ne={version:"1.0",parameters:{Region:B,UseDualStack:N,UseFIPS:N,Endpoint:B},rules:[{conditions:[{[z]:q,[T]:[J]}],rules:[{conditions:Z,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:F},{conditions:ee,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:F},{endpoint:{url:J,properties:K,headers:K},type:G}],type:M},{conditions:[{[z]:q,[T]:te}],rules:[{conditions:[{[z]:"aws.partition",[T]:te,assign:H}],rules:[{conditions:[L,W],rules:[{conditions:[{[z]:_,[T]:[true,Q]},Y],rules:[{endpoint:{url:"https://oidc-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:K,headers:K},type:G}],type:M},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:F}],type:M},{conditions:Z,rules:[{conditions:[{[z]:_,[T]:[Q,true]}],rules:[{conditions:[{[z]:"stringEquals",[T]:[{[z]:V,[T]:[X,"name"]},"aws-us-gov"]}],endpoint:{url:"https://oidc.{Region}.amazonaws.com",properties:K,headers:K},type:G},{endpoint:{url:"https://oidc-fips.{Region}.{PartitionResult#dnsSuffix}",properties:K,headers:K},type:G}],type:M},{error:"FIPS is enabled but this partition does not support FIPS",type:F}],type:M},{conditions:ee,rules:[{conditions:[Y],rules:[{endpoint:{url:"https://oidc.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:K,headers:K},type:G}],type:M},{error:"DualStack is enabled but this partition does not support DualStack",type:F}],type:M},{endpoint:{url:"https://oidc.{Region}.{PartitionResult#dnsSuffix}",properties:K,headers:K},type:G}],type:M}],type:M},{error:"Invalid Configuration: Missing Region",type:F}]},se=new $.$X({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),ie=(e,t={})=>se.get(e,(()=>(0,$.B1)(ne,{endpointParams:e,logger:t.logger})));$.DY.aws=D.Iu;var oe=n(59);const re=e=>{(0,l.H_)(process.version);const t=(0,oe.j)(e),n=()=>t().then(l.jv),s=(e=>({apiVersion:"2019-06-10",base64Decoder:e?.base64Decoder??R.G,base64Encoder:e?.base64Encoder??R.s,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??ie,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??w,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new C.VR},{schemeId:"smithy.api#noAuth",identityProvider:e=>e.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new c.oH}],logger:e?.logger??new l.vk,serviceId:e?.serviceId??"SSO OIDC",urlParser:e?.urlParser??k.e,utf8Decoder:e?.utf8Decoder??j.$x,utf8Encoder:e?.utf8Encoder??j.GZ}))(e);return(0,y.H)(process.version),{...s,...e,runtime:"node",defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??P.W,credentialDefaultProvider:e?.credentialDefaultProvider??I.iw,defaultUserAgentProvider:e?.defaultUserAgentProvider??(0,S.kk)({serviceId:s.serviceId,clientVersion:v}),maxAttempts:e?.maxAttempts??(0,f.M)(u.Hs),region:e?.region??(0,f.M)(a._c,a.zb),requestHandler:b.NA.create(e?.requestHandler??n),retryMode:e?.retryMode??(0,f.M)({...u.aK,default:async()=>(await n()).retryMode||O.CA}),sha256:e?.sha256??g.k.bind(null,"sha256"),streamCollector:e?.streamCollector??b.CF,useDualstackEndpoint:e?.useDualstackEndpoint??(0,f.M)(a.G7),useFipsEndpoint:e?.useFipsEndpoint??(0,f.M)(a.NL),userAgentAppId:e?.userAgentAppId??(0,f.M)(S.eX)}};var ae=n(63),ce=n(15);const de=e=>{const t=e.httpAuthSchemes;let n=e.httpAuthSchemeProvider,s=e.credentials;return{setHttpAuthScheme(e){const n=t.findIndex((t=>t.schemeId===e.schemeId));-1===n?t.push(e):t.splice(n,1,e)},httpAuthSchemes:()=>t,setHttpAuthSchemeProvider(e){n=e},httpAuthSchemeProvider:()=>n,setCredentials(e){s=e},credentials:()=>s}};class pe extends l.KU{constructor(...[e]){const t=re(e||{}),n=(m=t,{...m,useDualstackEndpoint:m.useDualstackEndpoint??!1,useFipsEndpoint:m.useFipsEndpoint??!1,defaultSigningName:"sso-oauth"});var m;const w=(0,r.er)(n),E=(0,u.BC)(w),v=(0,a.Xb)(E),y=(0,s.S8)(v),I=(0,p.uW)(y);var S;const g=((e,t)=>{const n={...(0,ae.GW)(e),...(0,l.kE)(e),...(0,ce.cA)(e),...de(e)};return t.forEach((e=>e.configure(n))),{...e,...(0,ae.A1)(n),...(0,l.SQ)(n),...(0,ce.AO)(n),...(s=n,{httpAuthSchemes:s.httpAuthSchemes(),httpAuthSchemeProvider:s.httpAuthSchemeProvider(),credentials:s.credentials()})};var s})((S=I,{...(0,h.K)(S)}),e?.extensions||[]);super(g),this.config=g,this.middlewareStack.use((0,r.XJ)(this.config)),this.middlewareStack.use((0,u.NQ)(this.config)),this.middlewareStack.use((0,d.VG)(this.config)),this.middlewareStack.use((0,s.G2)(this.config)),this.middlewareStack.use((0,i.cV)(this.config)),this.middlewareStack.use((0,o.eV)(this.config)),this.middlewareStack.use((0,c.tZ)(this.config,{httpAuthSchemeParametersProvider:x,identityProviderConfigProvider:async e=>new c.K5({"aws.auth#sigv4":e.credentials})})),this.middlewareStack.use((0,c.aZ)(this.config))}destroy(){super.destroy()}}var ue=n(30);class le extends l.sI{constructor(e){super(e),Object.setPrototypeOf(this,le.prototype)}}class he extends le{constructor(e){super({name:"AccessDeniedException",$fault:"client",...e}),this.name="AccessDeniedException",this.$fault="client",Object.setPrototypeOf(this,he.prototype),this.error=e.error,this.error_description=e.error_description}}class me extends le{constructor(e){super({name:"AuthorizationPendingException",$fault:"client",...e}),this.name="AuthorizationPendingException",this.$fault="client",Object.setPrototypeOf(this,me.prototype),this.error=e.error,this.error_description=e.error_description}}class xe extends le{constructor(e){super({name:"ExpiredTokenException",$fault:"client",...e}),this.name="ExpiredTokenException",this.$fault="client",Object.setPrototypeOf(this,xe.prototype),this.error=e.error,this.error_description=e.error_description}}class we extends le{constructor(e){super({name:"InternalServerException",$fault:"server",...e}),this.name="InternalServerException",this.$fault="server",Object.setPrototypeOf(this,we.prototype),this.error=e.error,this.error_description=e.error_description}}class Ee extends le{constructor(e){super({name:"InvalidClientException",$fault:"client",...e}),this.name="InvalidClientException",this.$fault="client",Object.setPrototypeOf(this,Ee.prototype),this.error=e.error,this.error_description=e.error_description}}class ve extends le{constructor(e){super({name:"InvalidGrantException",$fault:"client",...e}),this.name="InvalidGrantException",this.$fault="client",Object.setPrototypeOf(this,ve.prototype),this.error=e.error,this.error_description=e.error_description}}class ye extends le{constructor(e){super({name:"InvalidRequestException",$fault:"client",...e}),this.name="InvalidRequestException",this.$fault="client",Object.setPrototypeOf(this,ye.prototype),this.error=e.error,this.error_description=e.error_description}}class Ie extends le{constructor(e){super({name:"InvalidScopeException",$fault:"client",...e}),this.name="InvalidScopeException",this.$fault="client",Object.setPrototypeOf(this,Ie.prototype),this.error=e.error,this.error_description=e.error_description}}class Se extends le{constructor(e){super({name:"SlowDownException",$fault:"client",...e}),this.name="SlowDownException",this.$fault="client",Object.setPrototypeOf(this,Se.prototype),this.error=e.error,this.error_description=e.error_description}}class ge extends le{constructor(e){super({name:"UnauthorizedClientException",$fault:"client",...e}),this.name="UnauthorizedClientException",this.$fault="client",Object.setPrototypeOf(this,ge.prototype),this.error=e.error,this.error_description=e.error_description}}class fe extends le{constructor(e){super({name:"UnsupportedGrantTypeException",$fault:"client",...e}),this.name="UnsupportedGrantTypeException",this.$fault="client",Object.setPrototypeOf(this,fe.prototype),this.error=e.error,this.error_description=e.error_description}}class be extends le{constructor(e){super({name:"InvalidRequestRegionException",$fault:"client",...e}),this.name="InvalidRequestRegionException",this.$fault="client",Object.setPrototypeOf(this,be.prototype),this.error=e.error,this.error_description=e.error_description,this.endpoint=e.endpoint,this.region=e.region}}class Pe extends le{constructor(e){super({name:"InvalidClientMetadataException",$fault:"client",...e}),this.name="InvalidClientMetadataException",this.$fault="client",Object.setPrototypeOf(this,Pe.prototype),this.error=e.error,this.error_description=e.error_description}}class Oe extends le{constructor(e){super({name:"InvalidRedirectUriException",$fault:"client",...e}),this.name="InvalidRedirectUriException",this.$fault="client",Object.setPrototypeOf(this,Oe.prototype),this.error=e.error,this.error_description=e.error_description}}const Ce=e=>({...e,...e.clientSecret&&{clientSecret:l.oc},...e.refreshToken&&{refreshToken:l.oc},...e.codeVerifier&&{codeVerifier:l.oc}}),ke=e=>({...e,...e.accessToken&&{accessToken:l.oc},...e.refreshToken&&{refreshToken:l.oc},...e.idToken&&{idToken:l.oc}});var Re=n(64);const je=async(e,t)=>{const n=(0,c.cu)(e,t);let s;return n.bp("/token"),s=JSON.stringify((0,l.qn)(e,{clientId:[],clientSecret:[],code:[],codeVerifier:[],deviceCode:[],grantType:[],redirectUri:[],refreshToken:[],scope:e=>(0,l.F3)(e)})),n.m("POST").h({"content-type":"application/json"}).b(s),n.build()},De=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return $e(e,t);const n=(0,l.UI)({$metadata:We(e)}),s=(0,l.CE)((0,l.Wh)(await(0,Re.e1)(e.body,t)),"body"),i=(0,l.qn)(s,{accessToken:l.pY,expiresIn:l.u$,idToken:l.pY,refreshToken:l.pY,tokenType:l.pY});return Object.assign(n,i),n},$e=async(e,t)=>{const n={...e,body:await(0,Re.fk)(e.body,t)},s=(0,Re.mJ)(e,n.body);switch(s){case"AccessDeniedException":case"com.amazonaws.ssooidc#AccessDeniedException":throw await ze(n,t);case"AuthorizationPendingException":case"com.amazonaws.ssooidc#AuthorizationPendingException":throw await Te(n,t);case"ExpiredTokenException":case"com.amazonaws.ssooidc#ExpiredTokenException":throw await Ue(n,t);case"InternalServerException":case"com.amazonaws.ssooidc#InternalServerException":throw await qe(n,t);case"InvalidClientException":case"com.amazonaws.ssooidc#InvalidClientException":throw await _e(n,t);case"InvalidGrantException":case"com.amazonaws.ssooidc#InvalidGrantException":throw await Ge(n,t);case"InvalidRequestException":case"com.amazonaws.ssooidc#InvalidRequestException":throw await He(n,t);case"InvalidScopeException":case"com.amazonaws.ssooidc#InvalidScopeException":throw await Be(n,t);case"SlowDownException":case"com.amazonaws.ssooidc#SlowDownException":throw await Ne(n,t);case"UnauthorizedClientException":case"com.amazonaws.ssooidc#UnauthorizedClientException":throw await Je(n,t);case"UnsupportedGrantTypeException":case"com.amazonaws.ssooidc#UnsupportedGrantTypeException":throw await Le(n,t);case"InvalidRequestRegionException":case"com.amazonaws.ssooidc#InvalidRequestRegionException":throw await Ve(n,t);case"InvalidClientMetadataException":case"com.amazonaws.ssooidc#InvalidClientMetadataException":throw await Fe(n,t);case"InvalidRedirectUriException":case"com.amazonaws.ssooidc#InvalidRedirectUriException":throw await Me(n,t);default:const i=n.body;return Ae({output:e,parsedBody:i,errorCode:s})}},Ae=(0,l.PC)(le),ze=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new he({$metadata:We(e),...n});return(0,l.to)(o,e.body)},Te=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new me({$metadata:We(e),...n});return(0,l.to)(o,e.body)},Ue=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new xe({$metadata:We(e),...n});return(0,l.to)(o,e.body)},qe=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new we({$metadata:We(e),...n});return(0,l.to)(o,e.body)},_e=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new Ee({$metadata:We(e),...n});return(0,l.to)(o,e.body)},Fe=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new Pe({$metadata:We(e),...n});return(0,l.to)(o,e.body)},Ge=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new ve({$metadata:We(e),...n});return(0,l.to)(o,e.body)},Me=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new Oe({$metadata:We(e),...n});return(0,l.to)(o,e.body)},He=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new ye({$metadata:We(e),...n});return(0,l.to)(o,e.body)},Ve=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{endpoint:l.pY,error:l.pY,error_description:l.pY,region:l.pY});Object.assign(n,i);const o=new be({$metadata:We(e),...n});return(0,l.to)(o,e.body)},Be=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new Ie({$metadata:We(e),...n});return(0,l.to)(o,e.body)},Ne=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new Se({$metadata:We(e),...n});return(0,l.to)(o,e.body)},Je=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new ge({$metadata:We(e),...n});return(0,l.to)(o,e.body)},Le=async(e,t)=>{const n=(0,l.UI)({}),s=e.body,i=(0,l.qn)(s,{error:l.pY,error_description:l.pY});Object.assign(n,i);const o=new fe({$metadata:We(e),...n});return(0,l.to)(o,e.body)},We=e=>({httpStatusCode:e.statusCode,requestId:e.headers["x-amzn-requestid"]??e.headers["x-amzn-request-id"]??e.headers["x-amz-request-id"],extendedRequestId:e.headers["x-amz-id-2"],cfId:e.headers["x-amz-cf-id"]});class Ke extends(l.mY.classBuilder().ep(E).m((function(e,t,n,s){return[(0,ue.p2)(n,this.serialize,this.deserialize),(0,p.a3)(n,e.getEndpointParameterInstructions())]})).s("AWSSSOOIDCService","CreateToken",{}).n("SSOOIDCClient","CreateTokenCommand").f(Ce,ke).ser(je).de(De).build()){}}};
|
|
3
|
+
//# sourceMappingURL=988.index.js.map
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";exports.id=997,exports.ids=[997],exports.modules={790:(e,r,o)=>{o.r(r),o.d(r,{fromProcess:()=>a});var t=o(24),n=o(25),s=o(80),c=o(9),i=o(54);const d=async(e,r,o)=>{const t=r[e];if(!r[e])throw new n.m(`Profile ${e} could not be found in shared credentials file.`,{logger:o});{const d=t.credential_process;if(void 0===d)throw new n.m(`Profile ${e} did not contain credential_process.`,{logger:o});{const t=(0,c.promisify)(s.exec);try{const{stdout:o}=await t(d);let n;try{n=JSON.parse(o.trim())}catch{throw Error(`Profile ${e} credential_process returned invalid JSON.`)}return((e,r,o)=>{if(1!==r.Version)throw Error(`Profile ${e} credential_process did not return Version 1.`);if(void 0===r.AccessKeyId||void 0===r.SecretAccessKey)throw Error(`Profile ${e} credential_process returned invalid credentials.`);if(r.Expiration){const o=new Date;if(new Date(r.Expiration)<o)throw Error(`Profile ${e} credential_process returned expired credentials.`)}let t=r.AccountId;!t&&o?.[e]?.aws_account_id&&(t=o[e].aws_account_id);const n={accessKeyId:r.AccessKeyId,secretAccessKey:r.SecretAccessKey,...r.SessionToken&&{sessionToken:r.SessionToken},...r.Expiration&&{expiration:new Date(r.Expiration)},...r.CredentialScope&&{credentialScope:r.CredentialScope},...t&&{accountId:t}};return(0,i.P)(n,"CREDENTIALS_PROCESS","w"),n})(e,n,r)}catch(e){throw new n.m(e.message,{logger:o})}}}},a=(e={})=>async()=>{e.logger?.debug("@aws-sdk/credential-provider-process - fromProcess");const r=await(0,t.MX)(e);return d((0,t.Jl)(e),r,e.logger)}}};
|
|
3
|
+
//# sourceMappingURL=997.index.js.map
|