Socket
Socket
Sign inDemoInstall

@mongosh/node-runtime-worker-thread

Package Overview
Dependencies
Maintainers
0
Versions
86
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mongosh/node-runtime-worker-thread - npm Package Compare versions

Comparing version 2.2.15 to 2.3.0

dist/354.js

2

dist/528.js

@@ -1,1 +0,1 @@

"use strict";exports.id=528,exports.ids=[528],exports.modules={79779:(e,t,o)=>{o.d(t,{e1:()=>i,fk:()=>r,mJ:()=>s});var n=o(1742);const i=(e,t)=>(0,n.J)(e,t).then((e=>{if(e.length)try{return JSON.parse(e)}catch(t){throw"SyntaxError"===t?.name&&Object.defineProperty(t,"$responseBodyText",{value:e}),t}return{}})),r=async(e,t)=>{const o=await i(e,t);return o.message=o.message??o.Message,o},s=(e,t)=>{const o=e=>{let t=e;return"number"==typeof t&&(t=t.toString()),t.indexOf(",")>=0&&(t=t.split(",")[0]),t.indexOf(":")>=0&&(t=t.split(":")[0]),t.indexOf("#")>=0&&(t=t.split("#")[1]),t},n=(i=e.headers,r="x-amzn-errortype",Object.keys(i).find((e=>e.toLowerCase()===r.toLowerCase())));var i,r;return void 0!==n?o(e.headers[n]):void 0!==t.code?o(t.code):void 0!==t.__type?o(t.__type):void 0}},58528:(e,t,o)=>{o.d(t,{CognitoIdentityClient:()=>CognitoIdentityClient,GetCredentialsForIdentityCommand:()=>GetCredentialsForIdentityCommand,GetIdCommand:()=>GetIdCommand});var n=o(37493),i=o(70183),r=o(23703),s=o(48435),a=o(22144),c=o(68424),d=o(89362),p=o(75795),u=o(94726),l=o(51630),y=o(16301),h=o(95773);const m=async(e,t,o)=>({operation:(0,h.J)(t).operation,region:await(0,h.$)(e.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});const x=e=>{const t=[];switch(e.operation){case"GetCredentialsForIdentity":case"GetId":case"GetOpenIdToken":case"UnlinkIdentity":t.push({schemeId:"smithy.api#noAuth"});break;default:t.push(function(e){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"cognito-identity",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"}},g="3.529.1";var f=o(84629),v=o(66495),I=o(95640),C=o(87954),S=o(46807),P=o(11728),w=o(91743),b=o(88383),A=o(95071),F=o(53918),R=o(76954),$=o(7242),k=o(92718);const O="required",z="fn",D="argv",M="ref",G="isSet",N="booleanEquals",q="error",j="endpoint",U="tree",H="PartitionResult",L={[O]:!1,type:"String"},T={[O]:!0,default:!1,type:"Boolean"},J={[M]:"Endpoint"},W={[z]:N,[D]:[{[M]:"UseFIPS"},!0]},B={[z]:N,[D]:[{[M]:"UseDualStack"},!0]},K={},V={[z]:"getAttr",[D]:[{[M]:H},"supportsFIPS"]},Y={[z]:N,[D]:[!0,{[z]:"getAttr",[D]:[{[M]:H},"supportsDualStack"]}]},_=[W],X=[B],Z=[{[M]:"Region"}],Q={version:"1.0",parameters:{Region:L,UseDualStack:T,UseFIPS:T,Endpoint:L},rules:[{conditions:[{[z]:G,[D]:[J]}],rules:[{conditions:_,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:q},{conditions:X,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:q},{endpoint:{url:J,properties:K,headers:K},type:j}],type:U},{conditions:[{[z]:G,[D]:Z}],rules:[{conditions:[{[z]:"aws.partition",[D]:Z,assign:H}],rules:[{conditions:[W,B],rules:[{conditions:[{[z]:N,[D]:[true,V]},Y],rules:[{endpoint:{url:"https://cognito-identity-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:K,headers:K},type:j}],type:U},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:q}],type:U},{conditions:_,rules:[{conditions:[{[z]:N,[D]:[V,true]}],rules:[{endpoint:{url:"https://cognito-identity-fips.{Region}.{PartitionResult#dnsSuffix}",properties:K,headers:K},type:j}],type:U},{error:"FIPS is enabled but this partition does not support FIPS",type:q}],type:U},{conditions:X,rules:[{conditions:[Y],rules:[{endpoint:{url:"https://cognito-identity.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:K,headers:K},type:j}],type:U},{error:"DualStack is enabled but this partition does not support DualStack",type:q}],type:U},{endpoint:{url:"https://cognito-identity.{Region}.{PartitionResult#dnsSuffix}",properties:K,headers:K},type:j}],type:U}],type:U},{error:"Invalid Configuration: Missing Region",type:q}]},ee=(e,t={})=>(0,k.B1)(Q,{endpointParams:e,logger:t.logger});var te=o(66918);const oe=e=>{(0,l.H_)(process.version);const t=(0,te.j)(e),o=()=>t().then(l.jv),n=(e=>({apiVersion:"2014-06-30",base64Decoder:e?.base64Decoder??R.G,base64Encoder:e?.base64Encoder??R.s,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??ee,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??x,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new A.V},{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??"Cognito Identity",urlParser:e?.urlParser??F.e,utf8Decoder:e?.utf8Decoder??$.$x,utf8Encoder:e?.utf8Encoder??$.GZ}))(e);return(0,f.H)(process.version),{...n,...e,runtime:"node",defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??w.W,credentialDefaultProvider:e?.credentialDefaultProvider??v.defaultProvider,defaultUserAgentProvider:e?.defaultUserAgentProvider??(0,I.fV)({serviceId:n.serviceId,clientVersion:g}),maxAttempts:e?.maxAttempts??(0,S.M)(u.Hs),region:e?.region??(0,S.M)(a._c,a.zb),requestHandler:P.NA.create(e?.requestHandler??o),retryMode:e?.retryMode??(0,S.M)({...u.aK,default:async()=>(await o()).retryMode||b.CA}),sha256:e?.sha256??C.k.bind(null,"sha256"),streamCollector:e?.streamCollector??P.CF,useDualstackEndpoint:e?.useDualstackEndpoint??(0,S.M)(a.G7),useFipsEndpoint:e?.useFipsEndpoint??(0,S.M)(a.NL)}};var ne=o(31716),ie=o(25640);const re=e=>{const t=e.httpAuthSchemes;let o=e.httpAuthSchemeProvider,n=e.credentials;return{setHttpAuthScheme(e){const o=t.findIndex((t=>t.schemeId===e.schemeId));-1===o?t.push(e):t.splice(o,1,e)},httpAuthSchemes:()=>t,setHttpAuthSchemeProvider(e){o=e},httpAuthSchemeProvider:()=>o,setCredentials(e){n=e},credentials:()=>n}};class CognitoIdentityClient extends l.KU{constructor(...[e]){const t=oe(e||{}),o=(h=t,{...h,useDualstackEndpoint:h.useDualstackEndpoint??!1,useFipsEndpoint:h.useFipsEndpoint??!1,defaultSigningName:"cognito-identity"});var h;const m=(0,a.Xb)(o),x=(0,p.uW)(m),E=(0,u.BC)(x),g=(0,n.S8)(E),f=(0,s.er)(g);var v;const I=((e,t)=>{const o={...(0,ne.GW)(e),...(0,l.kE)(e),...(0,ie.cA)(e),...re(e)};return t.forEach((e=>e.configure(o))),{...e,...(0,ne.A1)(o),...(0,l.SQ)(o),...(0,ie.AO)(o),...(n=o,{httpAuthSchemes:n.httpAuthSchemes(),httpAuthSchemeProvider:n.httpAuthSchemeProvider(),credentials:n.credentials()})};var n})((v=f,{...(0,y.K)(v)}),e?.extensions||[]);super(I),this.config=I,this.middlewareStack.use((0,u.NQ)(this.config)),this.middlewareStack.use((0,d.VG)(this.config)),this.middlewareStack.use((0,n.G2)(this.config)),this.middlewareStack.use((0,i.cV)(this.config)),this.middlewareStack.use((0,r.eV)(this.config)),this.middlewareStack.use((0,s.XJ)(this.config)),this.middlewareStack.use((0,c.tZ)(this.config,{httpAuthSchemeParametersProvider:this.getDefaultHttpAuthSchemeParametersProvider(),identityProviderConfigProvider:this.getIdentityProviderConfigProvider()})),this.middlewareStack.use((0,c.aZ)(this.config))}destroy(){super.destroy()}getDefaultHttpAuthSchemeParametersProvider(){return m}getIdentityProviderConfigProvider(){return async e=>new c.K5({"aws.auth#sigv4":e.credentials})}}var se=o(43080),ae=o(79779);class CognitoIdentityServiceException extends l.sI{constructor(e){super(e),Object.setPrototypeOf(this,CognitoIdentityServiceException.prototype)}}class InternalErrorException extends CognitoIdentityServiceException{constructor(e){super({name:"InternalErrorException",$fault:"server",...e}),this.name="InternalErrorException",this.$fault="server",Object.setPrototypeOf(this,InternalErrorException.prototype)}}class InvalidParameterException extends CognitoIdentityServiceException{constructor(e){super({name:"InvalidParameterException",$fault:"client",...e}),this.name="InvalidParameterException",this.$fault="client",Object.setPrototypeOf(this,InvalidParameterException.prototype)}}class LimitExceededException extends CognitoIdentityServiceException{constructor(e){super({name:"LimitExceededException",$fault:"client",...e}),this.name="LimitExceededException",this.$fault="client",Object.setPrototypeOf(this,LimitExceededException.prototype)}}class NotAuthorizedException extends CognitoIdentityServiceException{constructor(e){super({name:"NotAuthorizedException",$fault:"client",...e}),this.name="NotAuthorizedException",this.$fault="client",Object.setPrototypeOf(this,NotAuthorizedException.prototype)}}class ResourceConflictException extends CognitoIdentityServiceException{constructor(e){super({name:"ResourceConflictException",$fault:"client",...e}),this.name="ResourceConflictException",this.$fault="client",Object.setPrototypeOf(this,ResourceConflictException.prototype)}}class TooManyRequestsException extends CognitoIdentityServiceException{constructor(e){super({name:"TooManyRequestsException",$fault:"client",...e}),this.name="TooManyRequestsException",this.$fault="client",Object.setPrototypeOf(this,TooManyRequestsException.prototype)}}class ResourceNotFoundException extends CognitoIdentityServiceException{constructor(e){super({name:"ResourceNotFoundException",$fault:"client",...e}),this.name="ResourceNotFoundException",this.$fault="client",Object.setPrototypeOf(this,ResourceNotFoundException.prototype)}}class ExternalServiceException extends CognitoIdentityServiceException{constructor(e){super({name:"ExternalServiceException",$fault:"client",...e}),this.name="ExternalServiceException",this.$fault="client",Object.setPrototypeOf(this,ExternalServiceException.prototype)}}class InvalidIdentityPoolConfigurationException extends CognitoIdentityServiceException{constructor(e){super({name:"InvalidIdentityPoolConfigurationException",$fault:"client",...e}),this.name="InvalidIdentityPoolConfigurationException",this.$fault="client",Object.setPrototypeOf(this,InvalidIdentityPoolConfigurationException.prototype)}}class DeveloperUserAlreadyRegisteredException extends CognitoIdentityServiceException{constructor(e){super({name:"DeveloperUserAlreadyRegisteredException",$fault:"client",...e}),this.name="DeveloperUserAlreadyRegisteredException",this.$fault="client",Object.setPrototypeOf(this,DeveloperUserAlreadyRegisteredException.prototype)}}class ConcurrentModificationException extends CognitoIdentityServiceException{constructor(e){super({name:"ConcurrentModificationException",$fault:"client",...e}),this.name="ConcurrentModificationException",this.$fault="client",Object.setPrototypeOf(this,ConcurrentModificationException.prototype)}}const ce=async(e,t)=>{const o=Fe("GetCredentialsForIdentity");let n;return n=JSON.stringify((0,l.F3)(e)),Ae(t,o,"/",void 0,n)},de=async(e,t)=>{const o=Fe("GetId");let n;return n=JSON.stringify((0,l.F3)(e)),Ae(t,o,"/",void 0,n)},pe=async(e,t)=>{if(e.statusCode>=300)return le(e,t);const o=await(0,ae.e1)(e.body,t);let n={};n=Pe(o,t);return{$metadata:we(e),...n}},ue=async(e,t)=>{if(e.statusCode>=300)return le(e,t);const o=await(0,ae.e1)(e.body,t);let n={};n=(0,l.F3)(o);return{$metadata:we(e),...n}},le=async(e,t)=>{const o={...e,body:await(0,ae.fk)(e.body,t)},n=(0,ae.mJ)(e,o.body);switch(n){case"InternalErrorException":case"com.amazonaws.cognitoidentity#InternalErrorException":throw await xe(o,t);case"InvalidParameterException":case"com.amazonaws.cognitoidentity#InvalidParameterException":throw await ge(o,t);case"LimitExceededException":case"com.amazonaws.cognitoidentity#LimitExceededException":throw await fe(o,t);case"NotAuthorizedException":case"com.amazonaws.cognitoidentity#NotAuthorizedException":throw await ve(o,t);case"ResourceConflictException":case"com.amazonaws.cognitoidentity#ResourceConflictException":throw await Ie(o,t);case"TooManyRequestsException":case"com.amazonaws.cognitoidentity#TooManyRequestsException":throw await Se(o,t);case"ResourceNotFoundException":case"com.amazonaws.cognitoidentity#ResourceNotFoundException":throw await Ce(o,t);case"ExternalServiceException":case"com.amazonaws.cognitoidentity#ExternalServiceException":throw await me(o,t);case"InvalidIdentityPoolConfigurationException":case"com.amazonaws.cognitoidentity#InvalidIdentityPoolConfigurationException":throw await Ee(o,t);case"DeveloperUserAlreadyRegisteredException":case"com.amazonaws.cognitoidentity#DeveloperUserAlreadyRegisteredException":throw await he(o,t);case"ConcurrentModificationException":case"com.amazonaws.cognitoidentity#ConcurrentModificationException":throw await ye(o,t);default:const i=o.body;return be({output:e,parsedBody:i,errorCode:n})}},ye=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new ConcurrentModificationException({$metadata:we(e),...n});return(0,l.to)(i,o)},he=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new DeveloperUserAlreadyRegisteredException({$metadata:we(e),...n});return(0,l.to)(i,o)},me=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new ExternalServiceException({$metadata:we(e),...n});return(0,l.to)(i,o)},xe=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new InternalErrorException({$metadata:we(e),...n});return(0,l.to)(i,o)},Ee=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new InvalidIdentityPoolConfigurationException({$metadata:we(e),...n});return(0,l.to)(i,o)},ge=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new InvalidParameterException({$metadata:we(e),...n});return(0,l.to)(i,o)},fe=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new LimitExceededException({$metadata:we(e),...n});return(0,l.to)(i,o)},ve=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new NotAuthorizedException({$metadata:we(e),...n});return(0,l.to)(i,o)},Ie=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new ResourceConflictException({$metadata:we(e),...n});return(0,l.to)(i,o)},Ce=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new ResourceNotFoundException({$metadata:we(e),...n});return(0,l.to)(i,o)},Se=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new TooManyRequestsException({$metadata:we(e),...n});return(0,l.to)(i,o)},Pe=(e,t)=>(0,l.qn)(e,{Credentials:e=>((e,t)=>(0,l.qn)(e,{AccessKeyId:l.pY,Expiration:e=>(0,l.CE)((0,l.KX)((0,l.Fx)(e))),SecretKey:l.pY,SessionToken:l.pY}))(e),IdentityId:l.pY}),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"]}),be=(0,l.PC)(CognitoIdentityServiceException),Ae=async(e,t,o,n,i)=>{const{hostname:r,protocol:s="https",port:a,path:c}=await e.endpoint(),d={protocol:s,hostname:r,port:a,method:"POST",path:c.endsWith("/")?c.slice(0,-1)+o:c+o,headers:t};return void 0!==n&&(d.hostname=n),void 0!==i&&(d.body=i),new ie.aW(d)};function Fe(e){return{"content-type":"application/x-amz-json-1.1","x-amz-target":`AWSCognitoIdentityService.${e}`}}class GetCredentialsForIdentityCommand extends(l.mY.classBuilder().ep({...E}).m((function(e,t,o,n){return[(0,se.p2)(o,this.serialize,this.deserialize),(0,p.a3)(o,e.getEndpointParameterInstructions())]})).s("AWSCognitoIdentityService","GetCredentialsForIdentity",{}).n("CognitoIdentityClient","GetCredentialsForIdentityCommand").f(void 0,void 0).ser(ce).de(pe).build()){}class GetIdCommand extends(l.mY.classBuilder().ep({...E}).m((function(e,t,o,n){return[(0,se.p2)(o,this.serialize,this.deserialize),(0,p.a3)(o,e.getEndpointParameterInstructions())]})).s("AWSCognitoIdentityService","GetId",{}).n("CognitoIdentityClient","GetIdCommand").f(void 0,void 0).ser(de).de(ue).build()){}}};
"use strict";exports.id=528,exports.ids=[528],exports.modules={10247:(e,t,o)=>{o.d(t,{e1:()=>i,fk:()=>r,mJ:()=>s});var n=o(29311);const i=(e,t)=>(0,n.J)(e,t).then((e=>{if(e.length)try{return JSON.parse(e)}catch(t){throw"SyntaxError"===t?.name&&Object.defineProperty(t,"$responseBodyText",{value:e}),t}return{}})),r=async(e,t)=>{const o=await i(e,t);return o.message=o.message??o.Message,o},s=(e,t)=>{const o=e=>{let t=e;return"number"==typeof t&&(t=t.toString()),t.indexOf(",")>=0&&(t=t.split(",")[0]),t.indexOf(":")>=0&&(t=t.split(":")[0]),t.indexOf("#")>=0&&(t=t.split("#")[1]),t},n=(i=e.headers,r="x-amzn-errortype",Object.keys(i).find((e=>e.toLowerCase()===r.toLowerCase())));var i,r;return void 0!==n?o(e.headers[n]):void 0!==t.code?o(t.code):void 0!==t.__type?o(t.__type):void 0}},58528:(e,t,o)=>{o.d(t,{CognitoIdentityClient:()=>CognitoIdentityClient,GetCredentialsForIdentityCommand:()=>GetCredentialsForIdentityCommand,GetIdCommand:()=>GetIdCommand});var n=o(37493),i=o(70183),r=o(23703),s=o(88610),a=o(22144),c=o(71818),d=o(89362),p=o(75795),u=o(48643),l=o(51630),y=o(35413),h=o(95773);const m=async(e,t,o)=>({operation:(0,h.J)(t).operation,region:await(0,h.$)(e.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});const x=e=>{const t=[];switch(e.operation){case"GetCredentialsForIdentity":case"GetId":case"GetOpenIdToken":case"UnlinkIdentity":t.push({schemeId:"smithy.api#noAuth"});break;default:t.push(function(e){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"cognito-identity",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"}},g="3.621.0";var f=o(74658),v=o(66495),I=o(95640),C=o(87954),S=o(88320),P=o(11728),w=o(91743),b=o(88383),A=o(234),F=o(53918),R=o(76954),$=o(7242),k=o(99558),O=o(92718);const z="required",D="fn",M="argv",G="ref",N="isSet",q="booleanEquals",j="error",U="endpoint",H="tree",L="PartitionResult",T={[z]:!1,type:"String"},J={[z]:!0,default:!1,type:"Boolean"},W={[G]:"Endpoint"},B={[D]:q,[M]:[{[G]:"UseFIPS"},!0]},K={[D]:q,[M]:[{[G]:"UseDualStack"},!0]},V={},Y={[D]:"getAttr",[M]:[{[G]:L},"supportsFIPS"]},_={[D]:q,[M]:[!0,{[D]:"getAttr",[M]:[{[G]:L},"supportsDualStack"]}]},X=[B],Z=[K],Q=[{[G]:"Region"}],ee={version:"1.0",parameters:{Region:T,UseDualStack:J,UseFIPS:J,Endpoint:T},rules:[{conditions:[{[D]:N,[M]:[W]}],rules:[{conditions:X,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:j},{conditions:Z,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:j},{endpoint:{url:W,properties:V,headers:V},type:U}],type:H},{conditions:[{[D]:N,[M]:Q}],rules:[{conditions:[{[D]:"aws.partition",[M]:Q,assign:L}],rules:[{conditions:[B,K],rules:[{conditions:[{[D]:q,[M]:[true,Y]},_],rules:[{endpoint:{url:"https://cognito-identity-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:V,headers:V},type:U}],type:H},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:j}],type:H},{conditions:X,rules:[{conditions:[{[D]:q,[M]:[Y,true]}],rules:[{endpoint:{url:"https://cognito-identity-fips.{Region}.{PartitionResult#dnsSuffix}",properties:V,headers:V},type:U}],type:H},{error:"FIPS is enabled but this partition does not support FIPS",type:j}],type:H},{conditions:Z,rules:[{conditions:[_],rules:[{endpoint:{url:"https://cognito-identity.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:V,headers:V},type:U}],type:H},{error:"DualStack is enabled but this partition does not support DualStack",type:j}],type:H},{endpoint:{url:"https://cognito-identity.{Region}.{PartitionResult#dnsSuffix}",properties:V,headers:V},type:U}],type:H}],type:H},{error:"Invalid Configuration: Missing Region",type:j}]},te=(e,t={})=>(0,O.B1)(ee,{endpointParams:e,logger:t.logger});O.DY.aws=k.Iu;var oe=o(66918);const ne=e=>{(0,l.H_)(process.version);const t=(0,oe.j)(e),o=()=>t().then(l.jv),n=(e=>({apiVersion:"2014-06-30",base64Decoder:e?.base64Decoder??R.G,base64Encoder:e?.base64Encoder??R.s,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??te,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??x,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new A.V},{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??"Cognito Identity",urlParser:e?.urlParser??F.e,utf8Decoder:e?.utf8Decoder??$.$x,utf8Encoder:e?.utf8Encoder??$.GZ}))(e);return(0,f.H)(process.version),{...n,...e,runtime:"node",defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??w.W,credentialDefaultProvider:e?.credentialDefaultProvider??v.iw,defaultUserAgentProvider:e?.defaultUserAgentProvider??(0,I.fV)({serviceId:n.serviceId,clientVersion:g}),maxAttempts:e?.maxAttempts??(0,S.M)(u.Hs),region:e?.region??(0,S.M)(a._c,a.zb),requestHandler:P.NA.create(e?.requestHandler??o),retryMode:e?.retryMode??(0,S.M)({...u.aK,default:async()=>(await o()).retryMode||b.CA}),sha256:e?.sha256??C.k.bind(null,"sha256"),streamCollector:e?.streamCollector??P.CF,useDualstackEndpoint:e?.useDualstackEndpoint??(0,S.M)(a.G7),useFipsEndpoint:e?.useFipsEndpoint??(0,S.M)(a.NL)}};var ie=o(31716),re=o(25640);const se=e=>{const t=e.httpAuthSchemes;let o=e.httpAuthSchemeProvider,n=e.credentials;return{setHttpAuthScheme(e){const o=t.findIndex((t=>t.schemeId===e.schemeId));-1===o?t.push(e):t.splice(o,1,e)},httpAuthSchemes:()=>t,setHttpAuthSchemeProvider(e){o=e},httpAuthSchemeProvider:()=>o,setCredentials(e){n=e},credentials:()=>n}};class CognitoIdentityClient extends l.KU{constructor(...[e]){const t=ne(e||{}),o=(h=t,{...h,useDualstackEndpoint:h.useDualstackEndpoint??!1,useFipsEndpoint:h.useFipsEndpoint??!1,defaultSigningName:"cognito-identity"});var h;const m=(0,a.Xb)(o),x=(0,p.uW)(m),E=(0,n.S8)(x),g=(0,s.er)(E),f=(0,u.BC)(g);var v;const I=((e,t)=>{const o={...(0,ie.GW)(e),...(0,l.kE)(e),...(0,re.cA)(e),...se(e)};return t.forEach((e=>e.configure(o))),{...e,...(0,ie.A1)(o),...(0,l.SQ)(o),...(0,re.AO)(o),...(n=o,{httpAuthSchemes:n.httpAuthSchemes(),httpAuthSchemeProvider:n.httpAuthSchemeProvider(),credentials:n.credentials()})};var n})((v=f,{...(0,y.K)(v)}),e?.extensions||[]);super(I),this.config=I,this.middlewareStack.use((0,n.G2)(this.config)),this.middlewareStack.use((0,i.cV)(this.config)),this.middlewareStack.use((0,r.eV)(this.config)),this.middlewareStack.use((0,s.XJ)(this.config)),this.middlewareStack.use((0,u.NQ)(this.config)),this.middlewareStack.use((0,d.VG)(this.config)),this.middlewareStack.use((0,c.tZ)(this.config,{httpAuthSchemeParametersProvider:this.getDefaultHttpAuthSchemeParametersProvider(),identityProviderConfigProvider:this.getIdentityProviderConfigProvider()})),this.middlewareStack.use((0,c.aZ)(this.config))}destroy(){super.destroy()}getDefaultHttpAuthSchemeParametersProvider(){return m}getIdentityProviderConfigProvider(){return async e=>new c.K5({"aws.auth#sigv4":e.credentials})}}var ae=o(43080),ce=o(10247);class CognitoIdentityServiceException extends l.sI{constructor(e){super(e),Object.setPrototypeOf(this,CognitoIdentityServiceException.prototype)}}class InternalErrorException extends CognitoIdentityServiceException{constructor(e){super({name:"InternalErrorException",$fault:"server",...e}),this.name="InternalErrorException",this.$fault="server",Object.setPrototypeOf(this,InternalErrorException.prototype)}}class InvalidParameterException extends CognitoIdentityServiceException{constructor(e){super({name:"InvalidParameterException",$fault:"client",...e}),this.name="InvalidParameterException",this.$fault="client",Object.setPrototypeOf(this,InvalidParameterException.prototype)}}class LimitExceededException extends CognitoIdentityServiceException{constructor(e){super({name:"LimitExceededException",$fault:"client",...e}),this.name="LimitExceededException",this.$fault="client",Object.setPrototypeOf(this,LimitExceededException.prototype)}}class NotAuthorizedException extends CognitoIdentityServiceException{constructor(e){super({name:"NotAuthorizedException",$fault:"client",...e}),this.name="NotAuthorizedException",this.$fault="client",Object.setPrototypeOf(this,NotAuthorizedException.prototype)}}class ResourceConflictException extends CognitoIdentityServiceException{constructor(e){super({name:"ResourceConflictException",$fault:"client",...e}),this.name="ResourceConflictException",this.$fault="client",Object.setPrototypeOf(this,ResourceConflictException.prototype)}}class TooManyRequestsException extends CognitoIdentityServiceException{constructor(e){super({name:"TooManyRequestsException",$fault:"client",...e}),this.name="TooManyRequestsException",this.$fault="client",Object.setPrototypeOf(this,TooManyRequestsException.prototype)}}class ResourceNotFoundException extends CognitoIdentityServiceException{constructor(e){super({name:"ResourceNotFoundException",$fault:"client",...e}),this.name="ResourceNotFoundException",this.$fault="client",Object.setPrototypeOf(this,ResourceNotFoundException.prototype)}}class ExternalServiceException extends CognitoIdentityServiceException{constructor(e){super({name:"ExternalServiceException",$fault:"client",...e}),this.name="ExternalServiceException",this.$fault="client",Object.setPrototypeOf(this,ExternalServiceException.prototype)}}class InvalidIdentityPoolConfigurationException extends CognitoIdentityServiceException{constructor(e){super({name:"InvalidIdentityPoolConfigurationException",$fault:"client",...e}),this.name="InvalidIdentityPoolConfigurationException",this.$fault="client",Object.setPrototypeOf(this,InvalidIdentityPoolConfigurationException.prototype)}}class DeveloperUserAlreadyRegisteredException extends CognitoIdentityServiceException{constructor(e){super({name:"DeveloperUserAlreadyRegisteredException",$fault:"client",...e}),this.name="DeveloperUserAlreadyRegisteredException",this.$fault="client",Object.setPrototypeOf(this,DeveloperUserAlreadyRegisteredException.prototype)}}class ConcurrentModificationException extends CognitoIdentityServiceException{constructor(e){super({name:"ConcurrentModificationException",$fault:"client",...e}),this.name="ConcurrentModificationException",this.$fault="client",Object.setPrototypeOf(this,ConcurrentModificationException.prototype)}}const de=async(e,t)=>{const o=Re("GetCredentialsForIdentity");let n;return n=JSON.stringify((0,l.F3)(e)),Fe(t,o,"/",void 0,n)},pe=async(e,t)=>{const o=Re("GetId");let n;return n=JSON.stringify((0,l.F3)(e)),Fe(t,o,"/",void 0,n)},ue=async(e,t)=>{if(e.statusCode>=300)return ye(e,t);const o=await(0,ce.e1)(e.body,t);let n={};n=we(o,t);return{$metadata:be(e),...n}},le=async(e,t)=>{if(e.statusCode>=300)return ye(e,t);const o=await(0,ce.e1)(e.body,t);let n={};n=(0,l.F3)(o);return{$metadata:be(e),...n}},ye=async(e,t)=>{const o={...e,body:await(0,ce.fk)(e.body,t)},n=(0,ce.mJ)(e,o.body);switch(n){case"InternalErrorException":case"com.amazonaws.cognitoidentity#InternalErrorException":throw await Ee(o,t);case"InvalidParameterException":case"com.amazonaws.cognitoidentity#InvalidParameterException":throw await fe(o,t);case"LimitExceededException":case"com.amazonaws.cognitoidentity#LimitExceededException":throw await ve(o,t);case"NotAuthorizedException":case"com.amazonaws.cognitoidentity#NotAuthorizedException":throw await Ie(o,t);case"ResourceConflictException":case"com.amazonaws.cognitoidentity#ResourceConflictException":throw await Ce(o,t);case"TooManyRequestsException":case"com.amazonaws.cognitoidentity#TooManyRequestsException":throw await Pe(o,t);case"ResourceNotFoundException":case"com.amazonaws.cognitoidentity#ResourceNotFoundException":throw await Se(o,t);case"ExternalServiceException":case"com.amazonaws.cognitoidentity#ExternalServiceException":throw await xe(o,t);case"InvalidIdentityPoolConfigurationException":case"com.amazonaws.cognitoidentity#InvalidIdentityPoolConfigurationException":throw await ge(o,t);case"DeveloperUserAlreadyRegisteredException":case"com.amazonaws.cognitoidentity#DeveloperUserAlreadyRegisteredException":throw await me(o,t);case"ConcurrentModificationException":case"com.amazonaws.cognitoidentity#ConcurrentModificationException":throw await he(o,t);default:const i=o.body;return Ae({output:e,parsedBody:i,errorCode:n})}},he=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new ConcurrentModificationException({$metadata:be(e),...n});return(0,l.to)(i,o)},me=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new DeveloperUserAlreadyRegisteredException({$metadata:be(e),...n});return(0,l.to)(i,o)},xe=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new ExternalServiceException({$metadata:be(e),...n});return(0,l.to)(i,o)},Ee=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new InternalErrorException({$metadata:be(e),...n});return(0,l.to)(i,o)},ge=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new InvalidIdentityPoolConfigurationException({$metadata:be(e),...n});return(0,l.to)(i,o)},fe=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new InvalidParameterException({$metadata:be(e),...n});return(0,l.to)(i,o)},ve=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new LimitExceededException({$metadata:be(e),...n});return(0,l.to)(i,o)},Ie=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new NotAuthorizedException({$metadata:be(e),...n});return(0,l.to)(i,o)},Ce=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new ResourceConflictException({$metadata:be(e),...n});return(0,l.to)(i,o)},Se=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new ResourceNotFoundException({$metadata:be(e),...n});return(0,l.to)(i,o)},Pe=async(e,t)=>{const o=e.body,n=(0,l.F3)(o),i=new TooManyRequestsException({$metadata:be(e),...n});return(0,l.to)(i,o)},we=(e,t)=>(0,l.qn)(e,{Credentials:e=>((e,t)=>(0,l.qn)(e,{AccessKeyId:l.pY,Expiration:e=>(0,l.CE)((0,l.KX)((0,l.Fx)(e))),SecretKey:l.pY,SessionToken:l.pY}))(e),IdentityId:l.pY}),be=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"]}),Ae=(0,l.PC)(CognitoIdentityServiceException),Fe=async(e,t,o,n,i)=>{const{hostname:r,protocol:s="https",port:a,path:c}=await e.endpoint(),d={protocol:s,hostname:r,port:a,method:"POST",path:c.endsWith("/")?c.slice(0,-1)+o:c+o,headers:t};return void 0!==n&&(d.hostname=n),void 0!==i&&(d.body=i),new re.aW(d)};function Re(e){return{"content-type":"application/x-amz-json-1.1","x-amz-target":`AWSCognitoIdentityService.${e}`}}class GetCredentialsForIdentityCommand extends(l.mY.classBuilder().ep({...E}).m((function(e,t,o,n){return[(0,ae.p2)(o,this.serialize,this.deserialize),(0,p.a3)(o,e.getEndpointParameterInstructions())]})).s("AWSCognitoIdentityService","GetCredentialsForIdentity",{}).n("CognitoIdentityClient","GetCredentialsForIdentityCommand").f(void 0,void 0).ser(de).de(ue).build()){}class GetIdCommand extends(l.mY.classBuilder().ep({...E}).m((function(e,t,o,n){return[(0,ae.p2)(o,this.serialize,this.deserialize),(0,p.a3)(o,e.getEndpointParameterInstructions())]})).s("AWSCognitoIdentityService","GetId",{}).n("CognitoIdentityClient","GetIdCommand").f(void 0,void 0).ser(pe).de(le).build()){}}};

@@ -1,1 +0,1 @@

"use strict";exports.id=650,exports.ids=[650],exports.modules={79779:(e,t,s)=>{s.d(t,{e1:()=>n,fk:()=>r,mJ:()=>i});var o=s(1742);const n=(e,t)=>(0,o.J)(e,t).then((e=>{if(e.length)try{return JSON.parse(e)}catch(t){throw"SyntaxError"===t?.name&&Object.defineProperty(t,"$responseBodyText",{value:e}),t}return{}})),r=async(e,t)=>{const s=await n(e,t);return s.message=s.message??s.Message,s},i=(e,t)=>{const s=e=>{let t=e;return"number"==typeof t&&(t=t.toString()),t.indexOf(",")>=0&&(t=t.split(",")[0]),t.indexOf(":")>=0&&(t=t.split(":")[0]),t.indexOf("#")>=0&&(t=t.split("#")[1]),t},o=(n=e.headers,r="x-amzn-errortype",Object.keys(n).find((e=>e.toLowerCase()===r.toLowerCase())));var n,r;return void 0!==o?s(e.headers[o]):void 0!==t.code?s(t.code):void 0!==t.__type?s(t.__type):void 0}},72650:(e,t,s)=>{s.d(t,{GetRoleCredentialsCommand:()=>GetRoleCredentialsCommand,SSOClient:()=>SSOClient});var o=s(75795),n=s(43080),r=s(51630);const i={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}};class SSOServiceException extends r.sI{constructor(e){super(e),Object.setPrototypeOf(this,SSOServiceException.prototype)}}class InvalidRequestException extends SSOServiceException{constructor(e){super({name:"InvalidRequestException",$fault:"client",...e}),this.name="InvalidRequestException",this.$fault="client",Object.setPrototypeOf(this,InvalidRequestException.prototype)}}class ResourceNotFoundException extends SSOServiceException{constructor(e){super({name:"ResourceNotFoundException",$fault:"client",...e}),this.name="ResourceNotFoundException",this.$fault="client",Object.setPrototypeOf(this,ResourceNotFoundException.prototype)}}class TooManyRequestsException extends SSOServiceException{constructor(e){super({name:"TooManyRequestsException",$fault:"client",...e}),this.name="TooManyRequestsException",this.$fault="client",Object.setPrototypeOf(this,TooManyRequestsException.prototype)}}class UnauthorizedException extends SSOServiceException{constructor(e){super({name:"UnauthorizedException",$fault:"client",...e}),this.name="UnauthorizedException",this.$fault="client",Object.setPrototypeOf(this,UnauthorizedException.prototype)}}const a=e=>({...e,...e.accessToken&&{accessToken:r.oc}}),c=e=>({...e,...e.secretAccessKey&&{secretAccessKey:r.oc},...e.sessionToken&&{sessionToken:r.oc}}),d=e=>({...e,...e.roleCredentials&&{roleCredentials:c(e.roleCredentials)}});var u=s(79779),p=s(68424);const l=async(e,t)=>{const s=(0,p.cu)(e,t),o=(0,r.UI)({},E,{[R]:e[b]});s.bp("/federation/credentials");const n=(0,r.UI)({[C]:[,(0,r.CE)(e[I],"roleName")],[w]:[,(0,r.CE)(e[P],"accountId")]});return s.m("GET").h(o).q(n).b(undefined),s.build()},h=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return m(e,t);const s=(0,r.UI)({$metadata:x(e)}),o=(0,r.CE)((0,r.Wh)(await(0,u.e1)(e.body,t)),"body"),n=(0,r.qn)(o,{roleCredentials:r.F3});return Object.assign(s,n),s},m=async(e,t)=>{const s={...e,body:await(0,u.fk)(e.body,t)},o=(0,u.mJ)(e,s.body);switch(o){case"InvalidRequestException":case"com.amazonaws.sso#InvalidRequestException":throw await g(s,t);case"ResourceNotFoundException":case"com.amazonaws.sso#ResourceNotFoundException":throw await S(s,t);case"TooManyRequestsException":case"com.amazonaws.sso#TooManyRequestsException":throw await f(s,t);case"UnauthorizedException":case"com.amazonaws.sso#UnauthorizedException":throw await v(s,t);default:const n=s.body;return y({output:e,parsedBody:n,errorCode:o})}},y=(0,r.PC)(SSOServiceException),g=async(e,t)=>{const s=(0,r.UI)({}),o=e.body,n=(0,r.qn)(o,{message:r.pY});Object.assign(s,n);const i=new InvalidRequestException({$metadata:x(e),...s});return(0,r.to)(i,e.body)},S=async(e,t)=>{const s=(0,r.UI)({}),o=e.body,n=(0,r.qn)(o,{message:r.pY});Object.assign(s,n);const i=new ResourceNotFoundException({$metadata:x(e),...s});return(0,r.to)(i,e.body)},f=async(e,t)=>{const s=(0,r.UI)({}),o=e.body,n=(0,r.qn)(o,{message:r.pY});Object.assign(s,n);const i=new TooManyRequestsException({$metadata:x(e),...s});return(0,r.to)(i,e.body)},v=async(e,t)=>{const s=(0,r.UI)({}),o=e.body,n=(0,r.qn)(o,{message:r.pY});Object.assign(s,n);const i=new UnauthorizedException({$metadata:x(e),...s});return(0,r.to)(i,e.body)},x=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"]}),E=e=>!(null==e||""===e||Object.getOwnPropertyNames(e).includes("length")&&0==e.length||Object.getOwnPropertyNames(e).includes("size")&&0==e.size),P="accountId",b="accessToken",w="account_id",I="roleName",C="role_name",R="x-amz-sso_bearer_token";class GetRoleCredentialsCommand extends(r.mY.classBuilder().ep({...i}).m((function(e,t,s,r){return[(0,n.p2)(s,this.serialize,this.deserialize),(0,o.a3)(s,e.getEndpointParameterInstructions())]})).s("SWBPortalService","GetRoleCredentials",{}).n("SSOClient","GetRoleCredentialsCommand").f(a,d).ser(l).de(h).build()){}var k=s(37493),O=s(70183),A=s(23703),q=s(48435),z=s(22144),U=s(89362),F=s(94726),D=s(16301),M=s(95773);const j=async(e,t,s)=>({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 N=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.529.1";var T=s(84629),G=s(95640),H=s(87954),_=s(46807),L=s(11728),B=s(91743),V=s(88383),J=s(95071),K=s(53918),W=s(76954),Y=s(7242),Z=s(92718);const Q="required",X="fn",ee="argv",te="ref",se="isSet",oe="booleanEquals",ne="error",re="endpoint",ie="tree",ae="PartitionResult",ce="getAttr",de={[Q]:!1,type:"String"},ue={[Q]:!0,default:!1,type:"Boolean"},pe={[te]:"Endpoint"},le={[X]:oe,[ee]:[{[te]:"UseFIPS"},!0]},he={[X]:oe,[ee]:[{[te]:"UseDualStack"},!0]},me={},ye={[X]:ce,[ee]:[{[te]:ae},"supportsFIPS"]},ge={[te]:ae},Se={[X]:oe,[ee]:[!0,{[X]:ce,[ee]:[ge,"supportsDualStack"]}]},fe=[le],ve=[he],xe=[{[te]:"Region"}],Ee={version:"1.0",parameters:{Region:de,UseDualStack:ue,UseFIPS:ue,Endpoint:de},rules:[{conditions:[{[X]:se,[ee]:[pe]}],rules:[{conditions:fe,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:ne},{conditions:ve,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:ne},{endpoint:{url:pe,properties:me,headers:me},type:re}],type:ie},{conditions:[{[X]:se,[ee]:xe}],rules:[{conditions:[{[X]:"aws.partition",[ee]:xe,assign:ae}],rules:[{conditions:[le,he],rules:[{conditions:[{[X]:oe,[ee]:[true,ye]},Se],rules:[{endpoint:{url:"https://portal.sso-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:me,headers:me},type:re}],type:ie},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:ne}],type:ie},{conditions:fe,rules:[{conditions:[{[X]:oe,[ee]:[ye,true]}],rules:[{conditions:[{[X]:"stringEquals",[ee]:[{[X]:ce,[ee]:[ge,"name"]},"aws-us-gov"]}],endpoint:{url:"https://portal.sso.{Region}.amazonaws.com",properties:me,headers:me},type:re},{endpoint:{url:"https://portal.sso-fips.{Region}.{PartitionResult#dnsSuffix}",properties:me,headers:me},type:re}],type:ie},{error:"FIPS is enabled but this partition does not support FIPS",type:ne}],type:ie},{conditions:ve,rules:[{conditions:[Se],rules:[{endpoint:{url:"https://portal.sso.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:me,headers:me},type:re}],type:ie},{error:"DualStack is enabled but this partition does not support DualStack",type:ne}],type:ie},{endpoint:{url:"https://portal.sso.{Region}.{PartitionResult#dnsSuffix}",properties:me,headers:me},type:re}],type:ie}],type:ie},{error:"Invalid Configuration: Missing Region",type:ne}]},Pe=(e,t={})=>(0,Z.B1)(Ee,{endpointParams:e,logger:t.logger});var be=s(66918);const we=e=>{(0,r.H_)(process.version);const t=(0,be.j)(e),s=()=>t().then(r.jv),o=(e=>({apiVersion:"2019-06-10",base64Decoder:e?.base64Decoder??W.G,base64Encoder:e?.base64Encoder??W.s,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??Pe,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??N,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new J.V},{schemeId:"smithy.api#noAuth",identityProvider:e=>e.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new p.oH}],logger:e?.logger??new r.vk,serviceId:e?.serviceId??"SSO",urlParser:e?.urlParser??K.e,utf8Decoder:e?.utf8Decoder??Y.$x,utf8Encoder:e?.utf8Encoder??Y.GZ}))(e);return(0,T.H)(process.version),{...o,...e,runtime:"node",defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??B.W,defaultUserAgentProvider:e?.defaultUserAgentProvider??(0,G.fV)({serviceId:o.serviceId,clientVersion:$}),maxAttempts:e?.maxAttempts??(0,_.M)(F.Hs),region:e?.region??(0,_.M)(z._c,z.zb),requestHandler:L.NA.create(e?.requestHandler??s),retryMode:e?.retryMode??(0,_.M)({...F.aK,default:async()=>(await s()).retryMode||V.CA}),sha256:e?.sha256??H.k.bind(null,"sha256"),streamCollector:e?.streamCollector??L.CF,useDualstackEndpoint:e?.useDualstackEndpoint??(0,_.M)(z.G7),useFipsEndpoint:e?.useFipsEndpoint??(0,_.M)(z.NL)}};var Ie=s(31716),Ce=s(25640);const Re=e=>{const t=e.httpAuthSchemes;let s=e.httpAuthSchemeProvider,o=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){o=e},credentials:()=>o}};class SSOClient extends r.KU{constructor(...[e]){const t=we(e||{}),s=(n=t,{...n,useDualstackEndpoint:n.useDualstackEndpoint??!1,useFipsEndpoint:n.useFipsEndpoint??!1,defaultSigningName:"awsssoportal"});var n;const i=(0,z.Xb)(s),a=(0,o.uW)(i),c=(0,F.BC)(a),d=(0,k.S8)(c),u=(0,q.er)(d);var l;const h=((e,t)=>{const s={...(0,Ie.GW)(e),...(0,r.kE)(e),...(0,Ce.cA)(e),...Re(e)};return t.forEach((e=>e.configure(s))),{...e,...(0,Ie.A1)(s),...(0,r.SQ)(s),...(0,Ce.AO)(s),...(o=s,{httpAuthSchemes:o.httpAuthSchemes(),httpAuthSchemeProvider:o.httpAuthSchemeProvider(),credentials:o.credentials()})};var o})((l=u,{...(0,D.K)(l)}),e?.extensions||[]);super(h),this.config=h,this.middlewareStack.use((0,F.NQ)(this.config)),this.middlewareStack.use((0,U.VG)(this.config)),this.middlewareStack.use((0,k.G2)(this.config)),this.middlewareStack.use((0,O.cV)(this.config)),this.middlewareStack.use((0,A.eV)(this.config)),this.middlewareStack.use((0,q.XJ)(this.config)),this.middlewareStack.use((0,p.tZ)(this.config,{httpAuthSchemeParametersProvider:this.getDefaultHttpAuthSchemeParametersProvider(),identityProviderConfigProvider:this.getIdentityProviderConfigProvider()})),this.middlewareStack.use((0,p.aZ)(this.config))}destroy(){super.destroy()}getDefaultHttpAuthSchemeParametersProvider(){return j}getIdentityProviderConfigProvider(){return async e=>new p.K5({"aws.auth#sigv4":e.credentials})}}}};
"use strict";exports.id=650,exports.ids=[650],exports.modules={10247:(e,t,s)=>{s.d(t,{e1:()=>n,fk:()=>r,mJ:()=>i});var o=s(29311);const n=(e,t)=>(0,o.J)(e,t).then((e=>{if(e.length)try{return JSON.parse(e)}catch(t){throw"SyntaxError"===t?.name&&Object.defineProperty(t,"$responseBodyText",{value:e}),t}return{}})),r=async(e,t)=>{const s=await n(e,t);return s.message=s.message??s.Message,s},i=(e,t)=>{const s=e=>{let t=e;return"number"==typeof t&&(t=t.toString()),t.indexOf(",")>=0&&(t=t.split(",")[0]),t.indexOf(":")>=0&&(t=t.split(":")[0]),t.indexOf("#")>=0&&(t=t.split("#")[1]),t},o=(n=e.headers,r="x-amzn-errortype",Object.keys(n).find((e=>e.toLowerCase()===r.toLowerCase())));var n,r;return void 0!==o?s(e.headers[o]):void 0!==t.code?s(t.code):void 0!==t.__type?s(t.__type):void 0}},72650:(e,t,s)=>{s.d(t,{GetRoleCredentialsCommand:()=>GetRoleCredentialsCommand,SSOClient:()=>SSOClient});var o=s(75795),n=s(43080),r=s(51630);const i={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}};class SSOServiceException extends r.sI{constructor(e){super(e),Object.setPrototypeOf(this,SSOServiceException.prototype)}}class InvalidRequestException extends SSOServiceException{constructor(e){super({name:"InvalidRequestException",$fault:"client",...e}),this.name="InvalidRequestException",this.$fault="client",Object.setPrototypeOf(this,InvalidRequestException.prototype)}}class ResourceNotFoundException extends SSOServiceException{constructor(e){super({name:"ResourceNotFoundException",$fault:"client",...e}),this.name="ResourceNotFoundException",this.$fault="client",Object.setPrototypeOf(this,ResourceNotFoundException.prototype)}}class TooManyRequestsException extends SSOServiceException{constructor(e){super({name:"TooManyRequestsException",$fault:"client",...e}),this.name="TooManyRequestsException",this.$fault="client",Object.setPrototypeOf(this,TooManyRequestsException.prototype)}}class UnauthorizedException extends SSOServiceException{constructor(e){super({name:"UnauthorizedException",$fault:"client",...e}),this.name="UnauthorizedException",this.$fault="client",Object.setPrototypeOf(this,UnauthorizedException.prototype)}}const a=e=>({...e,...e.accessToken&&{accessToken:r.oc}}),c=e=>({...e,...e.secretAccessKey&&{secretAccessKey:r.oc},...e.sessionToken&&{sessionToken:r.oc}}),d=e=>({...e,...e.roleCredentials&&{roleCredentials:c(e.roleCredentials)}});var u=s(10247),p=s(71818);const l=async(e,t)=>{const s=(0,p.cu)(e,t),o=(0,r.UI)({},E,{[R]:e[b]});s.bp("/federation/credentials");const n=(0,r.UI)({[C]:[,(0,r.CE)(e[I],"roleName")],[w]:[,(0,r.CE)(e[P],"accountId")]});return s.m("GET").h(o).q(n).b(undefined),s.build()},h=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return m(e,t);const s=(0,r.UI)({$metadata:x(e)}),o=(0,r.CE)((0,r.Wh)(await(0,u.e1)(e.body,t)),"body"),n=(0,r.qn)(o,{roleCredentials:r.F3});return Object.assign(s,n),s},m=async(e,t)=>{const s={...e,body:await(0,u.fk)(e.body,t)},o=(0,u.mJ)(e,s.body);switch(o){case"InvalidRequestException":case"com.amazonaws.sso#InvalidRequestException":throw await g(s,t);case"ResourceNotFoundException":case"com.amazonaws.sso#ResourceNotFoundException":throw await S(s,t);case"TooManyRequestsException":case"com.amazonaws.sso#TooManyRequestsException":throw await f(s,t);case"UnauthorizedException":case"com.amazonaws.sso#UnauthorizedException":throw await v(s,t);default:const n=s.body;return y({output:e,parsedBody:n,errorCode:o})}},y=(0,r.PC)(SSOServiceException),g=async(e,t)=>{const s=(0,r.UI)({}),o=e.body,n=(0,r.qn)(o,{message:r.pY});Object.assign(s,n);const i=new InvalidRequestException({$metadata:x(e),...s});return(0,r.to)(i,e.body)},S=async(e,t)=>{const s=(0,r.UI)({}),o=e.body,n=(0,r.qn)(o,{message:r.pY});Object.assign(s,n);const i=new ResourceNotFoundException({$metadata:x(e),...s});return(0,r.to)(i,e.body)},f=async(e,t)=>{const s=(0,r.UI)({}),o=e.body,n=(0,r.qn)(o,{message:r.pY});Object.assign(s,n);const i=new TooManyRequestsException({$metadata:x(e),...s});return(0,r.to)(i,e.body)},v=async(e,t)=>{const s=(0,r.UI)({}),o=e.body,n=(0,r.qn)(o,{message:r.pY});Object.assign(s,n);const i=new UnauthorizedException({$metadata:x(e),...s});return(0,r.to)(i,e.body)},x=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"]}),E=e=>!(null==e||""===e||Object.getOwnPropertyNames(e).includes("length")&&0==e.length||Object.getOwnPropertyNames(e).includes("size")&&0==e.size),P="accountId",b="accessToken",w="account_id",I="roleName",C="role_name",R="x-amz-sso_bearer_token";class GetRoleCredentialsCommand extends(r.mY.classBuilder().ep({...i}).m((function(e,t,s,r){return[(0,n.p2)(s,this.serialize,this.deserialize),(0,o.a3)(s,e.getEndpointParameterInstructions())]})).s("SWBPortalService","GetRoleCredentials",{}).n("SSOClient","GetRoleCredentialsCommand").f(a,d).ser(l).de(h).build()){}var k=s(37493),O=s(70183),A=s(23703),q=s(88610),z=s(22144),U=s(89362),D=s(48643),F=s(35413),M=s(95773);const j=async(e,t,s)=>({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 N=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.621.0";var T=s(74658),G=s(95640),H=s(87954),_=s(88320),L=s(11728),B=s(91743),V=s(88383),J=s(234),K=s(53918),Y=s(76954),W=s(7242),Z=s(99558),Q=s(92718);const X="required",ee="fn",te="argv",se="ref",oe="isSet",ne="booleanEquals",re="error",ie="endpoint",ae="tree",ce="PartitionResult",de="getAttr",ue={[X]:!1,type:"String"},pe={[X]:!0,default:!1,type:"Boolean"},le={[se]:"Endpoint"},he={[ee]:ne,[te]:[{[se]:"UseFIPS"},!0]},me={[ee]:ne,[te]:[{[se]:"UseDualStack"},!0]},ye={},ge={[ee]:de,[te]:[{[se]:ce},"supportsFIPS"]},Se={[se]:ce},fe={[ee]:ne,[te]:[!0,{[ee]:de,[te]:[Se,"supportsDualStack"]}]},ve=[he],xe=[me],Ee=[{[se]:"Region"}],Pe={version:"1.0",parameters:{Region:ue,UseDualStack:pe,UseFIPS:pe,Endpoint:ue},rules:[{conditions:[{[ee]:oe,[te]:[le]}],rules:[{conditions:ve,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:re},{conditions:xe,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:re},{endpoint:{url:le,properties:ye,headers:ye},type:ie}],type:ae},{conditions:[{[ee]:oe,[te]:Ee}],rules:[{conditions:[{[ee]:"aws.partition",[te]:Ee,assign:ce}],rules:[{conditions:[he,me],rules:[{conditions:[{[ee]:ne,[te]:[true,ge]},fe],rules:[{endpoint:{url:"https://portal.sso-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:ye,headers:ye},type:ie}],type:ae},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:re}],type:ae},{conditions:ve,rules:[{conditions:[{[ee]:ne,[te]:[ge,true]}],rules:[{conditions:[{[ee]:"stringEquals",[te]:[{[ee]:de,[te]:[Se,"name"]},"aws-us-gov"]}],endpoint:{url:"https://portal.sso.{Region}.amazonaws.com",properties:ye,headers:ye},type:ie},{endpoint:{url:"https://portal.sso-fips.{Region}.{PartitionResult#dnsSuffix}",properties:ye,headers:ye},type:ie}],type:ae},{error:"FIPS is enabled but this partition does not support FIPS",type:re}],type:ae},{conditions:xe,rules:[{conditions:[fe],rules:[{endpoint:{url:"https://portal.sso.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:ye,headers:ye},type:ie}],type:ae},{error:"DualStack is enabled but this partition does not support DualStack",type:re}],type:ae},{endpoint:{url:"https://portal.sso.{Region}.{PartitionResult#dnsSuffix}",properties:ye,headers:ye},type:ie}],type:ae}],type:ae},{error:"Invalid Configuration: Missing Region",type:re}]},be=(e,t={})=>(0,Q.B1)(Pe,{endpointParams:e,logger:t.logger});Q.DY.aws=Z.Iu;var we=s(66918);const Ie=e=>{(0,r.H_)(process.version);const t=(0,we.j)(e),s=()=>t().then(r.jv),o=(e=>({apiVersion:"2019-06-10",base64Decoder:e?.base64Decoder??Y.G,base64Encoder:e?.base64Encoder??Y.s,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??be,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??N,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new J.V},{schemeId:"smithy.api#noAuth",identityProvider:e=>e.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new p.oH}],logger:e?.logger??new r.vk,serviceId:e?.serviceId??"SSO",urlParser:e?.urlParser??K.e,utf8Decoder:e?.utf8Decoder??W.$x,utf8Encoder:e?.utf8Encoder??W.GZ}))(e);return(0,T.H)(process.version),{...o,...e,runtime:"node",defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??B.W,defaultUserAgentProvider:e?.defaultUserAgentProvider??(0,G.fV)({serviceId:o.serviceId,clientVersion:$}),maxAttempts:e?.maxAttempts??(0,_.M)(D.Hs),region:e?.region??(0,_.M)(z._c,z.zb),requestHandler:L.NA.create(e?.requestHandler??s),retryMode:e?.retryMode??(0,_.M)({...D.aK,default:async()=>(await s()).retryMode||V.CA}),sha256:e?.sha256??H.k.bind(null,"sha256"),streamCollector:e?.streamCollector??L.CF,useDualstackEndpoint:e?.useDualstackEndpoint??(0,_.M)(z.G7),useFipsEndpoint:e?.useFipsEndpoint??(0,_.M)(z.NL)}};var Ce=s(31716),Re=s(25640);const ke=e=>{const t=e.httpAuthSchemes;let s=e.httpAuthSchemeProvider,o=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){o=e},credentials:()=>o}};class SSOClient extends r.KU{constructor(...[e]){const t=Ie(e||{}),s=(n=t,{...n,useDualstackEndpoint:n.useDualstackEndpoint??!1,useFipsEndpoint:n.useFipsEndpoint??!1,defaultSigningName:"awsssoportal"});var n;const i=(0,z.Xb)(s),a=(0,o.uW)(i),c=(0,k.S8)(a),d=(0,q.er)(c),u=(0,D.BC)(d);var l;const h=((e,t)=>{const s={...(0,Ce.GW)(e),...(0,r.kE)(e),...(0,Re.cA)(e),...ke(e)};return t.forEach((e=>e.configure(s))),{...e,...(0,Ce.A1)(s),...(0,r.SQ)(s),...(0,Re.AO)(s),...(o=s,{httpAuthSchemes:o.httpAuthSchemes(),httpAuthSchemeProvider:o.httpAuthSchemeProvider(),credentials:o.credentials()})};var o})((l=u,{...(0,F.K)(l)}),e?.extensions||[]);super(h),this.config=h,this.middlewareStack.use((0,k.G2)(this.config)),this.middlewareStack.use((0,O.cV)(this.config)),this.middlewareStack.use((0,A.eV)(this.config)),this.middlewareStack.use((0,q.XJ)(this.config)),this.middlewareStack.use((0,D.NQ)(this.config)),this.middlewareStack.use((0,U.VG)(this.config)),this.middlewareStack.use((0,p.tZ)(this.config,{httpAuthSchemeParametersProvider:this.getDefaultHttpAuthSchemeParametersProvider(),identityProviderConfigProvider:this.getIdentityProviderConfigProvider()})),this.middlewareStack.use((0,p.aZ)(this.config))}destroy(){super.destroy()}getDefaultHttpAuthSchemeParametersProvider(){return j}getIdentityProviderConfigProvider(){return async e=>new p.K5({"aws.auth#sigv4":e.credentials})}}}};

@@ -1,1 +0,1 @@

"use strict";exports.id=942,exports.ids=[942],exports.modules={64942:(s,e,o)=>{o.d(e,{AssumeRoleCommand:()=>t.x,STSClient:()=>d.X});var t=o(31388),d=o(66792)}};
"use strict";exports.id=942,exports.ids=[942],exports.modules={64942:(s,e,o)=>{o.d(e,{AssumeRoleCommand:()=>t.x,STSClient:()=>d.X});var t=o(31388),d=o(58292)}};

@@ -250,2 +250,6 @@ /*!

/*! fetch-blob. MIT License. Jimmy Wärting <https://jimmy.warting.se/opensource> */
/*! node-domexception. MIT License. Jimmy Wärting <https://jimmy.warting.se/opensource> */
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */

@@ -261,1 +265,9 @@

*/
/**
* @license
* web-streams-polyfill v3.3.3
* Copyright 2024 Mattias Buelens, Diwank Singh Tomer and other contributors.
* This code is released under the MIT license.
* SPDX-License-Identifier: MIT
*/
{
"name": "@mongosh/node-runtime-worker-thread",
"version": "2.2.15",
"version": "2.3.0",
"description": "MongoDB shell runtime that lives in a worker thread",

@@ -37,10 +37,10 @@ "homepage": "https://github.com/mongodb-js/mongosh",

"devDependencies": {
"@mongodb-js/eslint-config-mongosh": "2.2.15",
"@mongodb-js/eslint-config-mongosh": "2.3.0",
"@mongodb-js/prettier-config-devtools": "^1.0.1",
"@mongodb-js/tsconfig-mongosh": "2.2.15",
"@mongosh/browser-runtime-core": "2.2.15",
"@mongosh/browser-runtime-electron": "2.2.15",
"@mongosh/service-provider-core": "2.2.15",
"@mongosh/service-provider-server": "2.2.15",
"@mongosh/types": "2.2.15",
"@mongodb-js/tsconfig-mongosh": "2.3.0",
"@mongosh/browser-runtime-core": "2.3.0",
"@mongosh/browser-runtime-electron": "2.3.0",
"@mongosh/service-provider-core": "2.3.0",
"@mongosh/service-provider-server": "2.3.0",
"@mongosh/types": "2.3.0",
"bson": "^6.7.0",

@@ -56,5 +56,5 @@ "depcheck": "^1.4.3",

"interruptor": "^1.0.1",
"system-ca": "^2.0.0"
"system-ca": "^2.0.1"
},
"gitHead": "1570f12d8dcdbf4668e2323edc124fd9c467e9f5"
"gitHead": "2013159f06f902b4e9a2060df411c6b5646d49d4"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc