@smithy/experimental-identity-and-auth 0.3.68 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-cjs/index.js +9 -9
- package/dist-es/middleware-http-auth-scheme/httpAuthSchemeMiddleware.js +0 -1
- package/dist-es/middleware-http-signing/httpSigningMiddleware.js +0 -1
- package/dist-types/HttpAuthScheme.d.ts +3 -3
- package/dist-types/HttpAuthSchemeProvider.d.ts +2 -2
- package/dist-types/HttpSigner.d.ts +1 -1
- package/dist-types/IdentityProviderConfig.d.ts +2 -2
- package/dist-types/SigV4Signer.d.ts +2 -2
- package/dist-types/apiKeyIdentity.d.ts +1 -1
- package/dist-types/endpointRuleSet.d.ts +3 -3
- package/dist-types/httpApiKeyAuth.d.ts +3 -3
- package/dist-types/httpBearerAuth.d.ts +3 -3
- package/dist-types/memoizeIdentityProvider.d.ts +1 -1
- package/dist-types/middleware-http-auth-scheme/getHttpAuthSchemeEndpointRuleSetPlugin.d.ts +4 -4
- package/dist-types/middleware-http-auth-scheme/getHttpAuthSchemePlugin.d.ts +4 -4
- package/dist-types/middleware-http-auth-scheme/httpAuthSchemeMiddleware.d.ts +4 -4
- package/dist-types/middleware-http-signing/getHttpSigningMiddleware.d.ts +1 -1
- package/dist-types/middleware-http-signing/httpSigningMiddleware.d.ts +1 -1
- package/dist-types/noAuth.d.ts +2 -2
- package/dist-types/tokenIdentity.d.ts +1 -1
- package/package.json +9 -8
package/dist-cjs/index.js
CHANGED
|
@@ -18,8 +18,8 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
18
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
19
|
|
|
20
20
|
// src/index.ts
|
|
21
|
-
var
|
|
22
|
-
__export(
|
|
21
|
+
var index_exports = {};
|
|
22
|
+
__export(index_exports, {
|
|
23
23
|
DefaultIdentityProviderConfig: () => DefaultIdentityProviderConfig,
|
|
24
24
|
EXPIRATION_MS: () => EXPIRATION_MS,
|
|
25
25
|
HttpApiKeyAuthLocation: () => HttpApiKeyAuthLocation,
|
|
@@ -42,7 +42,7 @@ __export(src_exports, {
|
|
|
42
42
|
isIdentityExpired: () => isIdentityExpired,
|
|
43
43
|
memoizeIdentityProvider: () => memoizeIdentityProvider
|
|
44
44
|
});
|
|
45
|
-
module.exports = __toCommonJS(
|
|
45
|
+
module.exports = __toCommonJS(index_exports);
|
|
46
46
|
|
|
47
47
|
// src/IdentityProviderConfig.ts
|
|
48
48
|
var DefaultIdentityProviderConfig = class {
|
|
@@ -316,7 +316,7 @@ var getHttpAuthSchemeEndpointRuleSetPlugin = /* @__PURE__ */ __name((config, {
|
|
|
316
316
|
httpAuthSchemeParametersProvider,
|
|
317
317
|
identityProviderConfigProvider
|
|
318
318
|
}) => ({
|
|
319
|
-
applyToStack: (clientStack) => {
|
|
319
|
+
applyToStack: /* @__PURE__ */ __name((clientStack) => {
|
|
320
320
|
clientStack.addRelativeTo(
|
|
321
321
|
httpAuthSchemeMiddleware(config, {
|
|
322
322
|
httpAuthSchemeParametersProvider,
|
|
@@ -324,7 +324,7 @@ var getHttpAuthSchemeEndpointRuleSetPlugin = /* @__PURE__ */ __name((config, {
|
|
|
324
324
|
}),
|
|
325
325
|
httpAuthSchemeEndpointRuleSetMiddlewareOptions
|
|
326
326
|
);
|
|
327
|
-
}
|
|
327
|
+
}, "applyToStack")
|
|
328
328
|
}), "getHttpAuthSchemeEndpointRuleSetPlugin");
|
|
329
329
|
|
|
330
330
|
// src/middleware-http-auth-scheme/getHttpAuthSchemePlugin.ts
|
|
@@ -341,7 +341,7 @@ var getHttpAuthSchemePlugin = /* @__PURE__ */ __name((config, {
|
|
|
341
341
|
httpAuthSchemeParametersProvider,
|
|
342
342
|
identityProviderConfigProvider
|
|
343
343
|
}) => ({
|
|
344
|
-
applyToStack: (clientStack) => {
|
|
344
|
+
applyToStack: /* @__PURE__ */ __name((clientStack) => {
|
|
345
345
|
clientStack.addRelativeTo(
|
|
346
346
|
httpAuthSchemeMiddleware(config, {
|
|
347
347
|
httpAuthSchemeParametersProvider,
|
|
@@ -349,7 +349,7 @@ var getHttpAuthSchemePlugin = /* @__PURE__ */ __name((config, {
|
|
|
349
349
|
}),
|
|
350
350
|
httpAuthSchemeMiddlewareOptions
|
|
351
351
|
);
|
|
352
|
-
}
|
|
352
|
+
}, "applyToStack")
|
|
353
353
|
}), "getHttpAuthSchemePlugin");
|
|
354
354
|
|
|
355
355
|
// src/middleware-http-signing/httpSigningMiddleware.ts
|
|
@@ -387,9 +387,9 @@ var httpSigningMiddlewareOptions = {
|
|
|
387
387
|
toMiddleware: import_middleware_retry.retryMiddlewareOptions.name
|
|
388
388
|
};
|
|
389
389
|
var getHttpSigningPlugin = /* @__PURE__ */ __name((config) => ({
|
|
390
|
-
applyToStack: (clientStack) => {
|
|
390
|
+
applyToStack: /* @__PURE__ */ __name((clientStack) => {
|
|
391
391
|
clientStack.addRelativeTo(httpSigningMiddleware(config), httpSigningMiddlewareOptions);
|
|
392
|
-
}
|
|
392
|
+
}, "applyToStack")
|
|
393
393
|
}), "getHttpSigningPlugin");
|
|
394
394
|
|
|
395
395
|
// src/noAuth.ts
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { HttpRequest } from "@smithy/protocol-http";
|
|
2
|
-
import { SMITHY_CONTEXT_KEY, } from "@smithy/types";
|
|
3
2
|
import { getSmithyContext } from "@smithy/util-middleware";
|
|
4
3
|
export const httpSigningMiddleware = (config) => (next, context) => async (args) => {
|
|
5
4
|
if (!HttpRequest.isInstance(args.request)) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { HandlerExecutionContext, Identity, IdentityProvider } from "@smithy/types";
|
|
2
|
-
import { HttpSigner } from "./HttpSigner";
|
|
3
|
-
import { IdentityProviderConfig } from "./IdentityProviderConfig";
|
|
1
|
+
import type { HandlerExecutionContext, Identity, IdentityProvider } from "@smithy/types";
|
|
2
|
+
import type { HttpSigner } from "./HttpSigner";
|
|
3
|
+
import type { IdentityProviderConfig } from "./IdentityProviderConfig";
|
|
4
4
|
/**
|
|
5
5
|
* ID for {@link HttpAuthScheme}
|
|
6
6
|
* @internal
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Identity, IdentityProvider } from "@smithy/types";
|
|
2
|
-
import { HttpAuthSchemeId } from "./HttpAuthScheme";
|
|
1
|
+
import type { Identity, IdentityProvider } from "@smithy/types";
|
|
2
|
+
import type { HttpAuthSchemeId } from "./HttpAuthScheme";
|
|
3
3
|
/**
|
|
4
4
|
* Interface to get an IdentityProvider for a specified HttpAuthScheme
|
|
5
5
|
* @internal
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { HttpRequest } from "@smithy/protocol-http";
|
|
2
|
-
import { AwsCredentialIdentity, HttpRequest as IHttpRequest } from "@smithy/types";
|
|
3
|
-
import { HttpSigner } from "./HttpSigner";
|
|
2
|
+
import type { AwsCredentialIdentity, HttpRequest as IHttpRequest } from "@smithy/types";
|
|
3
|
+
import type { HttpSigner } from "./HttpSigner";
|
|
4
4
|
/**
|
|
5
5
|
* @internal
|
|
6
6
|
*/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { EndpointParameterInstructions } from "@smithy/middleware-endpoint";
|
|
2
|
-
import { EndpointParameters, EndpointV2, HandlerExecutionContext, Logger } from "@smithy/types";
|
|
3
|
-
import { HttpAuthSchemeParameters, HttpAuthSchemeParametersProvider, HttpAuthSchemeProvider } from "./HttpAuthSchemeProvider";
|
|
1
|
+
import type { EndpointParameterInstructions } from "@smithy/middleware-endpoint";
|
|
2
|
+
import type { EndpointParameters, EndpointV2, HandlerExecutionContext, Logger } from "@smithy/types";
|
|
3
|
+
import type { HttpAuthSchemeParameters, HttpAuthSchemeParametersProvider, HttpAuthSchemeProvider } from "./HttpAuthSchemeProvider";
|
|
4
4
|
/**
|
|
5
5
|
* @internal
|
|
6
6
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { HttpRequest } from "@smithy/protocol-http";
|
|
2
|
-
import { HttpRequest as IHttpRequest } from "@smithy/types";
|
|
3
|
-
import { ApiKeyIdentity } from "./apiKeyIdentity";
|
|
4
|
-
import { HttpSigner } from "./HttpSigner";
|
|
2
|
+
import type { HttpRequest as IHttpRequest } from "@smithy/types";
|
|
3
|
+
import type { ApiKeyIdentity } from "./apiKeyIdentity";
|
|
4
|
+
import type { HttpSigner } from "./HttpSigner";
|
|
5
5
|
/**
|
|
6
6
|
* @internal
|
|
7
7
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { HttpRequest } from "@smithy/protocol-http";
|
|
2
|
-
import { HttpRequest as IHttpRequest } from "@smithy/types";
|
|
3
|
-
import { HttpSigner } from "./HttpSigner";
|
|
4
|
-
import { TokenIdentity } from "./tokenIdentity";
|
|
2
|
+
import type { HttpRequest as IHttpRequest } from "@smithy/types";
|
|
3
|
+
import type { HttpSigner } from "./HttpSigner";
|
|
4
|
+
import type { TokenIdentity } from "./tokenIdentity";
|
|
5
5
|
/**
|
|
6
6
|
* @internal
|
|
7
7
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { HandlerExecutionContext, Pluggable, RelativeMiddlewareOptions, SerializeHandlerOptions } from "@smithy/types";
|
|
2
|
-
import { HttpAuthSchemeParameters, HttpAuthSchemeParametersProvider } from "../HttpAuthSchemeProvider";
|
|
3
|
-
import { IdentityProviderConfig } from "../IdentityProviderConfig";
|
|
4
|
-
import { PreviouslyResolved } from "./httpAuthSchemeMiddleware";
|
|
1
|
+
import type { HandlerExecutionContext, Pluggable, RelativeMiddlewareOptions, SerializeHandlerOptions } from "@smithy/types";
|
|
2
|
+
import type { HttpAuthSchemeParameters, HttpAuthSchemeParametersProvider } from "../HttpAuthSchemeProvider";
|
|
3
|
+
import type { IdentityProviderConfig } from "../IdentityProviderConfig";
|
|
4
|
+
import type { PreviouslyResolved } from "./httpAuthSchemeMiddleware";
|
|
5
5
|
/**
|
|
6
6
|
* @internal
|
|
7
7
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { HandlerExecutionContext, Pluggable, RelativeMiddlewareOptions, SerializeHandlerOptions } from "@smithy/types";
|
|
2
|
-
import { HttpAuthSchemeParameters, HttpAuthSchemeParametersProvider } from "../HttpAuthSchemeProvider";
|
|
3
|
-
import { IdentityProviderConfig } from "../IdentityProviderConfig";
|
|
4
|
-
import { PreviouslyResolved } from "./httpAuthSchemeMiddleware";
|
|
1
|
+
import type { HandlerExecutionContext, Pluggable, RelativeMiddlewareOptions, SerializeHandlerOptions } from "@smithy/types";
|
|
2
|
+
import type { HttpAuthSchemeParameters, HttpAuthSchemeParametersProvider } from "../HttpAuthSchemeProvider";
|
|
3
|
+
import type { IdentityProviderConfig } from "../IdentityProviderConfig";
|
|
4
|
+
import type { PreviouslyResolved } from "./httpAuthSchemeMiddleware";
|
|
5
5
|
/**
|
|
6
6
|
* @internal
|
|
7
7
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { HandlerExecutionContext, SerializeMiddleware, SMITHY_CONTEXT_KEY } from "@smithy/types";
|
|
2
|
-
import { HttpAuthScheme, SelectedHttpAuthScheme } from "../HttpAuthScheme";
|
|
3
|
-
import { HttpAuthSchemeParameters, HttpAuthSchemeParametersProvider, HttpAuthSchemeProvider } from "../HttpAuthSchemeProvider";
|
|
4
|
-
import { IdentityProviderConfig } from "../IdentityProviderConfig";
|
|
1
|
+
import type { HandlerExecutionContext, SerializeMiddleware, SMITHY_CONTEXT_KEY } from "@smithy/types";
|
|
2
|
+
import type { HttpAuthScheme, SelectedHttpAuthScheme } from "../HttpAuthScheme";
|
|
3
|
+
import type { HttpAuthSchemeParameters, HttpAuthSchemeParametersProvider, HttpAuthSchemeProvider } from "../HttpAuthSchemeProvider";
|
|
4
|
+
import type { IdentityProviderConfig } from "../IdentityProviderConfig";
|
|
5
5
|
/**
|
|
6
6
|
* @internal
|
|
7
7
|
*/
|
package/dist-types/noAuth.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { HttpRequest, Identity } from "@smithy/types";
|
|
2
|
-
import { HttpSigner } from "./HttpSigner";
|
|
1
|
+
import type { HttpRequest, Identity } from "@smithy/types";
|
|
2
|
+
import type { HttpSigner } from "./HttpSigner";
|
|
3
3
|
/**
|
|
4
4
|
* Signer for the synthetic @smithy.api#noAuth auth scheme.
|
|
5
5
|
* @internal
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/experimental-identity-and-auth",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
|
|
6
6
|
"build:cjs": "node ../../scripts/inline experimental-identity-and-auth",
|
|
@@ -25,14 +25,15 @@
|
|
|
25
25
|
"url": "https://smithy.io"
|
|
26
26
|
},
|
|
27
27
|
"license": "Apache-2.0",
|
|
28
|
+
"sideEffects": false,
|
|
28
29
|
"dependencies": {
|
|
29
|
-
"@smithy/middleware-endpoint": "^4.
|
|
30
|
-
"@smithy/middleware-retry": "^4.
|
|
31
|
-
"@smithy/middleware-serde": "^4.0
|
|
32
|
-
"@smithy/protocol-http": "^5.
|
|
33
|
-
"@smithy/signature-v4": "^5.
|
|
34
|
-
"@smithy/types": "^4.
|
|
35
|
-
"@smithy/util-middleware": "^4.0
|
|
30
|
+
"@smithy/middleware-endpoint": "^4.2.0",
|
|
31
|
+
"@smithy/middleware-retry": "^4.2.0",
|
|
32
|
+
"@smithy/middleware-serde": "^4.1.0",
|
|
33
|
+
"@smithy/protocol-http": "^5.2.0",
|
|
34
|
+
"@smithy/signature-v4": "^5.2.0",
|
|
35
|
+
"@smithy/types": "^4.4.0",
|
|
36
|
+
"@smithy/util-middleware": "^4.1.0",
|
|
36
37
|
"tslib": "^2.6.2"
|
|
37
38
|
},
|
|
38
39
|
"engines": {
|