@adcp/sdk 15.9.0 → 16.0.0-beta.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/bin/adcp-identity.js +74 -0
- package/bin/adcp.js +2 -0
- package/dist/lib/adapters/keyed-account-backend.d.mts +37 -0
- package/dist/lib/adapters/keyed-account-backend.d.ts +37 -0
- package/dist/lib/adapters/keyed-account-backend.js +121 -0
- package/dist/lib/adapters/keyed-account-backend.mjs +94 -0
- package/dist/lib/adapters/keyed-account-store.d.mts +28 -0
- package/dist/lib/adapters/keyed-account-store.d.ts +28 -0
- package/dist/lib/adapters/keyed-account-store.js +227 -0
- package/dist/lib/adapters/keyed-account-store.mjs +203 -0
- package/dist/lib/core/SingleAgentClient.d.mts +16 -2
- package/dist/lib/core/SingleAgentClient.d.ts +16 -2
- package/dist/lib/core/SingleAgentClient.js +259 -62
- package/dist/lib/core/SingleAgentClient.mjs +261 -57
- package/dist/lib/core/TaskExecutor.d.mts +6 -0
- package/dist/lib/core/TaskExecutor.d.ts +6 -0
- package/dist/lib/core/TaskExecutor.js +66 -5
- package/dist/lib/core/TaskExecutor.mjs +71 -5
- package/dist/lib/core/postgres-webhook-registration-store.js +32 -5
- package/dist/lib/core/postgres-webhook-registration-store.mjs +32 -5
- package/dist/lib/core/redis-webhook-registration-store.js +23 -1
- package/dist/lib/core/redis-webhook-registration-store.mjs +23 -1
- package/dist/lib/core/webhook-registration.d.mts +7 -1
- package/dist/lib/core/webhook-registration.d.ts +7 -1
- package/dist/lib/core/webhook-registration.js +24 -2
- package/dist/lib/core/webhook-registration.mjs +23 -2
- package/dist/lib/identity-3.3/index.d.mts +10 -0
- package/dist/lib/identity-3.3/index.d.ts +10 -0
- package/dist/lib/identity-3.3/index.js +75 -0
- package/dist/lib/identity-3.3/index.mjs +46 -0
- package/dist/lib/identity-3.3/lifecycle.d.mts +113 -0
- package/dist/lib/identity-3.3/lifecycle.d.ts +113 -0
- package/dist/lib/identity-3.3/lifecycle.js +267 -0
- package/dist/lib/identity-3.3/lifecycle.mjs +240 -0
- package/dist/lib/identity-3.3/revocation.d.mts +50 -0
- package/dist/lib/identity-3.3/revocation.d.ts +50 -0
- package/dist/lib/identity-3.3/revocation.js +238 -0
- package/dist/lib/identity-3.3/revocation.mjs +216 -0
- package/dist/lib/identity-3.3/schemas.draft.d.mts +2472 -0
- package/dist/lib/identity-3.3/schemas.draft.d.ts +2472 -0
- package/dist/lib/identity-3.3/schemas.draft.js +1448 -0
- package/dist/lib/identity-3.3/schemas.draft.mjs +1428 -0
- package/dist/lib/identity-3.3/server.d.mts +34 -0
- package/dist/lib/identity-3.3/server.d.ts +34 -0
- package/dist/lib/identity-3.3/server.js +219 -0
- package/dist/lib/identity-3.3/server.mjs +194 -0
- package/dist/lib/identity-3.3/store.d.mts +24 -0
- package/dist/lib/identity-3.3/store.d.ts +24 -0
- package/dist/lib/identity-3.3/store.js +191 -0
- package/dist/lib/identity-3.3/store.mjs +169 -0
- package/dist/lib/identity-3.3/trust.d.mts +94 -0
- package/dist/lib/identity-3.3/trust.d.ts +94 -0
- package/dist/lib/identity-3.3/trust.js +278 -0
- package/dist/lib/identity-3.3/trust.mjs +239 -0
- package/dist/lib/identity-3.3/types.d.mts +127 -0
- package/dist/lib/identity-3.3/types.d.ts +127 -0
- package/dist/lib/identity-3.3/types.js +16 -0
- package/dist/lib/identity-3.3/types.mjs +0 -0
- package/dist/lib/identity-3.3/validation.d.mts +2 -0
- package/dist/lib/identity-3.3/validation.d.ts +2 -0
- package/dist/lib/identity-3.3/validation.js +125 -0
- package/dist/lib/identity-3.3/validation.mjs +91 -0
- package/dist/lib/index.d.mts +1 -1
- package/dist/lib/index.d.ts +1 -1
- package/dist/lib/reporting/azure/index.d.mts +5 -0
- package/dist/lib/reporting/azure/index.d.ts +5 -0
- package/dist/lib/reporting/azure/index.js +26 -7
- package/dist/lib/reporting/azure/index.mjs +26 -7
- package/dist/lib/reporting/bigquery/index.d.mts +80 -25
- package/dist/lib/reporting/bigquery/index.d.ts +80 -25
- package/dist/lib/reporting/bigquery/index.js +184 -81
- package/dist/lib/reporting/bigquery/index.mjs +182 -80
- package/dist/lib/reporting/gcs/adapter.d.mts +8 -1
- package/dist/lib/reporting/gcs/adapter.d.ts +8 -1
- package/dist/lib/reporting/gcs/errors.d.mts +6 -0
- package/dist/lib/reporting/gcs/errors.d.ts +6 -0
- package/dist/lib/reporting/gcs/fence.d.mts +5 -0
- package/dist/lib/reporting/gcs/fence.d.ts +5 -0
- package/dist/lib/reporting/gcs/index.d.mts +9 -0
- package/dist/lib/reporting/gcs/index.d.ts +9 -0
- package/dist/lib/reporting/gcs/reader.d.mts +27 -3
- package/dist/lib/reporting/gcs/reader.d.ts +27 -3
- package/dist/lib/reporting/gcs/row-provider.d.mts +7 -0
- package/dist/lib/reporting/gcs/row-provider.d.ts +7 -0
- package/dist/lib/reporting/gcs/row-provider.js +34 -14
- package/dist/lib/reporting/gcs/row-provider.mjs +34 -14
- package/dist/lib/reporting/ledger/change-feed.d.mts +22 -1
- package/dist/lib/reporting/ledger/change-feed.d.ts +22 -1
- package/dist/lib/reporting/ledger/index.d.mts +11 -0
- package/dist/lib/reporting/ledger/index.d.ts +11 -0
- package/dist/lib/reporting/ledger/managed-postgres.d.mts +8 -0
- package/dist/lib/reporting/ledger/managed-postgres.d.ts +8 -0
- package/dist/lib/reporting/ledger/managed-router.d.mts +27 -2
- package/dist/lib/reporting/ledger/managed-router.d.ts +27 -2
- package/dist/lib/reporting/ledger/managed.d.mts +86 -6
- package/dist/lib/reporting/ledger/managed.d.ts +86 -6
- package/dist/lib/reporting/ledger/notification-activity.d.mts +65 -3
- package/dist/lib/reporting/ledger/notification-activity.d.ts +65 -3
- package/dist/lib/reporting/ledger/object-writes.d.mts +64 -5
- package/dist/lib/reporting/ledger/object-writes.d.ts +64 -5
- package/dist/lib/reporting/ledger/postgres.d.mts +43 -9
- package/dist/lib/reporting/ledger/postgres.d.ts +43 -9
- package/dist/lib/reporting/ledger/postgres.js +43 -27
- package/dist/lib/reporting/ledger/postgres.mjs +43 -27
- package/dist/lib/reporting/ledger/row-encoding.d.mts +92 -6
- package/dist/lib/reporting/ledger/row-encoding.d.ts +92 -6
- package/dist/lib/reporting/ledger/row-encoding.js +8 -4
- package/dist/lib/reporting/ledger/row-encoding.mjs +6 -3
- package/dist/lib/reporting/ledger/row-storage-errors.d.mts +11 -1
- package/dist/lib/reporting/ledger/row-storage-errors.d.ts +11 -1
- package/dist/lib/reporting/ledger/row-storage-migration.d.mts +19 -1
- package/dist/lib/reporting/ledger/row-storage-migration.d.ts +19 -1
- package/dist/lib/reporting/ledger/row-storage-migration.js +133 -18
- package/dist/lib/reporting/ledger/row-storage-migration.mjs +133 -18
- package/dist/lib/reporting/ledger/row-storage-object.d.mts +103 -12
- package/dist/lib/reporting/ledger/row-storage-object.d.ts +103 -12
- package/dist/lib/reporting/ledger/row-storage-object.js +106 -31
- package/dist/lib/reporting/ledger/row-storage-object.mjs +104 -31
- package/dist/lib/reporting/ledger/row-storage.d.mts +87 -20
- package/dist/lib/reporting/ledger/row-storage.d.ts +87 -20
- package/dist/lib/reporting/ledger/row-storage.js +126 -66
- package/dist/lib/reporting/ledger/row-storage.mjs +129 -67
- package/dist/lib/reporting/ledger/schedule.d.mts +13 -0
- package/dist/lib/reporting/ledger/schedule.d.ts +13 -0
- package/dist/lib/reporting/ledger/schedule.js +24 -0
- package/dist/lib/reporting/ledger/schedule.mjs +23 -0
- package/dist/lib/reporting/ledger/types.d.mts +23 -1
- package/dist/lib/reporting/ledger/types.d.ts +23 -1
- package/dist/lib/reporting/s3/index.d.mts +5 -0
- package/dist/lib/reporting/s3/index.d.ts +5 -0
- package/dist/lib/reporting/s3/index.js +37 -14
- package/dist/lib/reporting/s3/index.mjs +37 -14
- package/dist/lib/reporting/service/index.d.mts +10 -0
- package/dist/lib/reporting/service/index.d.ts +10 -0
- package/dist/lib/reporting/service/maintenance.d.mts +28 -2
- package/dist/lib/reporting/service/maintenance.d.ts +28 -2
- package/dist/lib/schemas-data/v2.5/_provenance.json +1 -1
- package/dist/lib/server/account-sync-contract.d.mts +14 -0
- package/dist/lib/server/account-sync-contract.d.ts +14 -0
- package/dist/lib/server/account-sync-contract.js +225 -0
- package/dist/lib/server/account-sync-contract.mjs +197 -0
- package/dist/lib/server/adcp-server.js +5 -0
- package/dist/lib/server/adcp-server.mjs +10 -0
- package/dist/lib/server/auth-signature.d.mts +10 -0
- package/dist/lib/server/auth-signature.d.ts +10 -0
- package/dist/lib/server/auth-signature.js +61 -2
- package/dist/lib/server/auth-signature.mjs +65 -2
- package/dist/lib/server/auth.d.mts +6 -0
- package/dist/lib/server/auth.d.ts +6 -0
- package/dist/lib/server/auth.js +6 -0
- package/dist/lib/server/auth.mjs +6 -0
- package/dist/lib/server/create-adcp-server.d.mts +19 -5
- package/dist/lib/server/create-adcp-server.d.ts +19 -5
- package/dist/lib/server/create-adcp-server.js +238 -19
- package/dist/lib/server/create-adcp-server.mjs +240 -10
- package/dist/lib/server/decisioning/account.d.mts +24 -1
- package/dist/lib/server/decisioning/account.d.ts +24 -1
- package/dist/lib/server/decisioning/index.d.mts +1 -1
- package/dist/lib/server/decisioning/index.d.ts +1 -1
- package/dist/lib/server/decisioning/runtime/from-platform.d.mts +0 -50
- package/dist/lib/server/decisioning/runtime/from-platform.d.ts +0 -50
- package/dist/lib/server/decisioning/runtime/from-platform.js +61 -11
- package/dist/lib/server/decisioning/runtime/from-platform.mjs +65 -12
- package/dist/lib/server/index.d.mts +2 -0
- package/dist/lib/server/index.d.ts +2 -0
- package/dist/lib/server/index.js +12 -0
- package/dist/lib/server/index.mjs +12 -0
- package/dist/lib/server/notification-subscriptions/runtime.js +9 -1
- package/dist/lib/server/notification-subscriptions/runtime.mjs +9 -1
- package/dist/lib/server/notification-subscriptions/types.d.mts +5 -0
- package/dist/lib/server/notification-subscriptions/types.d.ts +5 -0
- package/dist/lib/server/principal/types.d.mts +1 -1
- package/dist/lib/server/principal/types.d.ts +1 -1
- package/dist/lib/server/serve.js +5 -0
- package/dist/lib/server/serve.mjs +5 -0
- package/dist/lib/server/webhook-delivery/recovery.d.mts +1 -0
- package/dist/lib/server/webhook-delivery/recovery.d.ts +1 -0
- package/dist/lib/server/webhook-delivery/recovery.js +4 -0
- package/dist/lib/server/webhook-delivery/recovery.mjs +4 -0
- package/dist/lib/server/webhook-emitter.d.mts +10 -0
- package/dist/lib/server/webhook-emitter.d.ts +10 -0
- package/dist/lib/server/webhook-emitter.js +22 -0
- package/dist/lib/server/webhook-emitter.mjs +22 -0
- package/dist/lib/signing/agent-context.d.mts +0 -5
- package/dist/lib/signing/agent-context.d.ts +0 -5
- package/dist/lib/signing/agent-context.js +9 -1
- package/dist/lib/signing/agent-context.mjs +9 -1
- package/dist/lib/signing/agent-fetch.js +27 -2
- package/dist/lib/signing/agent-fetch.mjs +32 -2
- package/dist/lib/signing/agent-resolver/canonicalize.d.mts +10 -15
- package/dist/lib/signing/agent-resolver/canonicalize.d.ts +10 -15
- package/dist/lib/signing/agent-resolver/canonicalize.js +17 -5
- package/dist/lib/signing/agent-resolver/canonicalize.mjs +16 -5
- package/dist/lib/signing/agent-resolver/index.d.mts +1 -0
- package/dist/lib/signing/agent-resolver/index.d.ts +1 -0
- package/dist/lib/signing/agent-resolver/index.js +5 -0
- package/dist/lib/signing/agent-resolver/index.mjs +3 -0
- package/dist/lib/signing/agent-resolver/resolved-agent-jwks.d.mts +3 -2
- package/dist/lib/signing/agent-resolver/resolved-agent-jwks.d.ts +3 -2
- package/dist/lib/signing/agent-resolver/resolved-agent-jwks.js +30 -3
- package/dist/lib/signing/agent-resolver/resolved-agent-jwks.mjs +30 -3
- package/dist/lib/signing/agent-resolver/strict-json.d.mts +2 -2
- package/dist/lib/signing/agent-resolver/strict-json.d.ts +2 -2
- package/dist/lib/signing/agent-resolver/strict-json.js +5 -3
- package/dist/lib/signing/agent-resolver/strict-json.mjs +5 -3
- package/dist/lib/signing/brand-jwks.d.mts +2 -2
- package/dist/lib/signing/brand-jwks.d.ts +2 -2
- package/dist/lib/signing/brand-jwks.js +4 -4
- package/dist/lib/signing/brand-jwks.mjs +4 -4
- package/dist/lib/signing/client.d.mts +1 -0
- package/dist/lib/signing/client.d.ts +1 -0
- package/dist/lib/signing/client.js +5 -0
- package/dist/lib/signing/client.mjs +3 -0
- package/dist/lib/signing/jwks-https.d.mts +1 -1
- package/dist/lib/signing/jwks-https.d.ts +1 -1
- package/dist/lib/signing/jwks-https.js +1 -1
- package/dist/lib/signing/jwks-https.mjs +1 -1
- package/dist/lib/signing/jwks.d.mts +11 -3
- package/dist/lib/signing/jwks.d.ts +11 -3
- package/dist/lib/signing/jwks.js +1 -1
- package/dist/lib/signing/jwks.mjs +1 -1
- package/dist/lib/signing/parser.d.mts +1 -1
- package/dist/lib/signing/parser.d.ts +1 -1
- package/dist/lib/signing/parser.js +5 -3
- package/dist/lib/signing/parser.mjs +6 -4
- package/dist/lib/signing/revocation.d.mts +4 -1
- package/dist/lib/signing/revocation.d.ts +4 -1
- package/dist/lib/signing/revocation.js +33 -3
- package/dist/lib/signing/revocation.mjs +31 -2
- package/dist/lib/signing/server.d.mts +1 -1
- package/dist/lib/signing/server.d.ts +1 -1
- package/dist/lib/signing/server.js +4 -0
- package/dist/lib/signing/server.mjs +4 -0
- package/dist/lib/signing/types.d.mts +3 -0
- package/dist/lib/signing/types.d.ts +3 -0
- package/dist/lib/signing/web-bot-auth.d.mts +117 -0
- package/dist/lib/signing/web-bot-auth.d.ts +117 -0
- package/dist/lib/signing/web-bot-auth.js +660 -0
- package/dist/lib/signing/web-bot-auth.mjs +624 -0
- package/dist/lib/testing/client.d.mts +1 -4
- package/dist/lib/testing/client.d.ts +1 -4
- package/dist/lib/testing/client.js +141 -20
- package/dist/lib/testing/client.mjs +137 -19
- package/dist/lib/testing/compliance/comply.js +29 -10
- package/dist/lib/testing/compliance/comply.mjs +37 -11
- package/dist/lib/testing/storyboard/account-sync-contract.d.mts +3 -0
- package/dist/lib/testing/storyboard/account-sync-contract.d.ts +3 -0
- package/dist/lib/testing/storyboard/account-sync-contract.js +79 -0
- package/dist/lib/testing/storyboard/account-sync-contract.mjs +55 -0
- package/dist/lib/testing/storyboard/default-invariants.js +2 -0
- package/dist/lib/testing/storyboard/default-invariants.mjs +2 -0
- package/dist/lib/testing/storyboard/runner.js +23 -8
- package/dist/lib/testing/storyboard/runner.mjs +24 -8
- package/dist/lib/testing/storyboard/validations.d.mts +1 -1
- package/dist/lib/testing/storyboard/validations.d.ts +1 -1
- package/dist/lib/types/adcp.d.mts +4 -0
- package/dist/lib/types/adcp.d.ts +4 -0
- package/dist/lib/types/schemas.generated.d.ts +6 -6
- package/dist/lib/utils/capabilities.d.mts +1 -0
- package/dist/lib/utils/capabilities.d.ts +1 -0
- package/dist/lib/utils/capabilities.js +5 -0
- package/dist/lib/utils/capabilities.mjs +5 -0
- package/dist/lib/v2/projection/creative-delivery.d.mts +3 -1
- package/dist/lib/v2/projection/creative-delivery.d.ts +3 -1
- package/dist/lib/v2/projection/creative-delivery.js +26 -10
- package/dist/lib/v2/projection/creative-delivery.mjs +26 -10
- package/dist/lib/v2/projection/index.d.mts +1 -1
- package/dist/lib/v2/projection/index.d.ts +1 -1
- package/dist/lib/v2/projection/legacy-routes.d.mts +24 -2
- package/dist/lib/v2/projection/legacy-routes.d.ts +24 -2
- package/dist/lib/v2/projection/legacy-routes.js +28 -2
- package/dist/lib/v2/projection/legacy-routes.mjs +26 -2
- package/dist/lib/validation/schema-loader.d.mts +2 -0
- package/dist/lib/validation/schema-loader.d.ts +2 -0
- package/dist/lib/validation/schema-loader.js +43 -4
- package/dist/lib/validation/schema-loader.mjs +39 -3
- package/dist/lib/version.d.mts +3 -3
- package/dist/lib/version.d.ts +3 -3
- package/dist/lib/version.js +3 -3
- package/dist/lib/version.mjs +3 -3
- package/docs/TYPE-SUMMARY.md +2 -2
- package/docs/guides/DISCOVERY-CACHE-AND-SESSION-REUSE.md +4 -0
- package/docs/guides/REPORTING-LEDGER-CUTOVER.md +1 -1
- package/docs/guides/REPORTING-LEDGER.md +132 -46
- package/docs/guides/REPORTING-OPERATIONS.md +25 -4
- package/docs/guides/REPORTING-STABILITY.md +76 -0
- package/docs/guides/account-resolution.md +101 -0
- package/docs/llms.txt +3 -2
- package/docs/migration-12-to-13.md +7 -0
- package/docs/migration-14.x-rc-worksheet.md +4 -4
- package/docs/migration-agent-identity-3.3.md +355 -0
- package/docs/migration-agent-resolution-3.3.md +5 -0
- package/docs/migration-reporting-row-storage-alignment.md +137 -0
- package/examples/storyboards/account-sync-contract.yaml +57 -0
- package/package.json +15 -1
|
@@ -88,11 +88,11 @@ class BrandJsonJwksResolver {
|
|
|
88
88
|
});
|
|
89
89
|
return this.onboarding;
|
|
90
90
|
}
|
|
91
|
-
async resolve(keyid) {
|
|
92
|
-
return (await this.confirmedResolver()).resolve(keyid);
|
|
91
|
+
async resolve(keyid, signerOrigin) {
|
|
92
|
+
return (await this.confirmedResolver()).resolve(keyid, signerOrigin);
|
|
93
93
|
}
|
|
94
|
-
async resolveWithMetadata(keyid) {
|
|
95
|
-
return (await this.confirmedResolver()).resolveWithMetadata(keyid);
|
|
94
|
+
async resolveWithMetadata(keyid, signerOrigin) {
|
|
95
|
+
return (await this.confirmedResolver()).resolveWithMetadata(keyid, signerOrigin);
|
|
96
96
|
}
|
|
97
97
|
get agentUrl() {
|
|
98
98
|
return this.resolver?.resolvedAgentUrl;
|
|
@@ -23,3 +23,4 @@ export { buildAgentSigningFetch, createAgentSignedFetch, extractAdcpOperation, i
|
|
|
23
23
|
export { buildAgentSigningContext, signingContextStorage, type AgentSigningContext, type AgentSigningIdentitySnapshot, } from './agent-context.mjs';
|
|
24
24
|
export { ensureCapabilityLoaded, CAPABILITY_OP } from './capability-priming.mjs';
|
|
25
25
|
export { pemToAdcpJwk, type AdcpUse, type PemToAdcpJwkOptions } from './jwks-helpers.mjs';
|
|
26
|
+
export { canonicalAgentOrigin, CanonicalizeError } from './agent-resolver/canonicalize.mjs';
|
|
@@ -23,3 +23,4 @@ export { buildAgentSigningFetch, createAgentSignedFetch, extractAdcpOperation, i
|
|
|
23
23
|
export { buildAgentSigningContext, signingContextStorage, type AgentSigningContext, type AgentSigningIdentitySnapshot, } from './agent-context';
|
|
24
24
|
export { ensureCapabilityLoaded, CAPABILITY_OP } from './capability-priming';
|
|
25
25
|
export { pemToAdcpJwk, type AdcpUse, type PemToAdcpJwkOptions } from './jwks-helpers';
|
|
26
|
+
export { canonicalAgentOrigin, CanonicalizeError } from './agent-resolver/canonicalize';
|
|
@@ -21,6 +21,7 @@ __export(client_exports, {
|
|
|
21
21
|
ALLOWED_ALGS: () => import_types.ALLOWED_ALGS,
|
|
22
22
|
CAPABILITY_OP: () => import_capability_priming.CAPABILITY_OP,
|
|
23
23
|
CLOCK_SKEW_TOLERANCE_SECONDS: () => import_types.CLOCK_SKEW_TOLERANCE_SECONDS,
|
|
24
|
+
CanonicalizeError: () => import_canonicalize2.CanonicalizeError,
|
|
24
25
|
CapabilityCache: () => import_capability_cache.CapabilityCache,
|
|
25
26
|
MANDATORY_COMPONENTS: () => import_types.MANDATORY_COMPONENTS,
|
|
26
27
|
MAX_SIGNATURE_WINDOW_SECONDS: () => import_types.MAX_SIGNATURE_WINDOW_SECONDS,
|
|
@@ -39,6 +40,7 @@ __export(client_exports, {
|
|
|
39
40
|
buildCapabilityCacheKey: () => import_capability_cache.buildCapabilityCacheKey,
|
|
40
41
|
buildResponseSignatureBase: () => import_canonicalize.buildResponseSignatureBase,
|
|
41
42
|
buildSignatureBase: () => import_canonicalize.buildSignatureBase,
|
|
43
|
+
canonicalAgentOrigin: () => import_canonicalize2.canonicalAgentOrigin,
|
|
42
44
|
canonicalAuthority: () => import_canonicalize.canonicalAuthority,
|
|
43
45
|
canonicalMethod: () => import_canonicalize.canonicalMethod,
|
|
44
46
|
canonicalTargetUri: () => import_canonicalize.canonicalTargetUri,
|
|
@@ -95,11 +97,13 @@ var import_agent_fetch = require('./agent-fetch.js');
|
|
|
95
97
|
var import_agent_context = require('./agent-context.js');
|
|
96
98
|
var import_capability_priming = require('./capability-priming.js');
|
|
97
99
|
var import_jwks_helpers = require('./jwks-helpers.js');
|
|
100
|
+
var import_canonicalize2 = require('./agent-resolver/canonicalize.js');
|
|
98
101
|
// Annotate the CommonJS export names for ESM import in node:
|
|
99
102
|
0 && (module.exports = {
|
|
100
103
|
ALLOWED_ALGS,
|
|
101
104
|
CAPABILITY_OP,
|
|
102
105
|
CLOCK_SKEW_TOLERANCE_SECONDS,
|
|
106
|
+
CanonicalizeError,
|
|
103
107
|
CapabilityCache,
|
|
104
108
|
MANDATORY_COMPONENTS,
|
|
105
109
|
MAX_SIGNATURE_WINDOW_SECONDS,
|
|
@@ -118,6 +122,7 @@ var import_jwks_helpers = require('./jwks-helpers.js');
|
|
|
118
122
|
buildCapabilityCacheKey,
|
|
119
123
|
buildResponseSignatureBase,
|
|
120
124
|
buildSignatureBase,
|
|
125
|
+
canonicalAgentOrigin,
|
|
121
126
|
canonicalAuthority,
|
|
122
127
|
canonicalMethod,
|
|
123
128
|
canonicalTargetUri,
|
|
@@ -71,10 +71,12 @@ import {
|
|
|
71
71
|
} from "./agent-context.mjs";
|
|
72
72
|
import { ensureCapabilityLoaded, CAPABILITY_OP } from "./capability-priming.mjs";
|
|
73
73
|
import { pemToAdcpJwk } from "./jwks-helpers.mjs";
|
|
74
|
+
import { canonicalAgentOrigin, CanonicalizeError } from "./agent-resolver/canonicalize.mjs";
|
|
74
75
|
export {
|
|
75
76
|
ALLOWED_ALGS,
|
|
76
77
|
CAPABILITY_OP,
|
|
77
78
|
CLOCK_SKEW_TOLERANCE_SECONDS,
|
|
79
|
+
CanonicalizeError,
|
|
78
80
|
CapabilityCache,
|
|
79
81
|
MANDATORY_COMPONENTS,
|
|
80
82
|
MAX_SIGNATURE_WINDOW_SECONDS,
|
|
@@ -93,6 +95,7 @@ export {
|
|
|
93
95
|
buildCapabilityCacheKey,
|
|
94
96
|
buildResponseSignatureBase,
|
|
95
97
|
buildSignatureBase,
|
|
98
|
+
canonicalAgentOrigin,
|
|
96
99
|
canonicalAuthority,
|
|
97
100
|
canonicalMethod,
|
|
98
101
|
canonicalTargetUri,
|
|
@@ -58,7 +58,7 @@ export declare class HttpsJwksResolver implements JwksResolver {
|
|
|
58
58
|
private inFlight;
|
|
59
59
|
private lastAttemptAt;
|
|
60
60
|
constructor(url: string, options?: HttpsJwksResolverOptions);
|
|
61
|
-
resolve(keyid: string): Promise<AdcpJsonWebKey | null>;
|
|
61
|
+
resolve(keyid: string, _signerOrigin?: string): Promise<AdcpJsonWebKey | null>;
|
|
62
62
|
/**
|
|
63
63
|
* Force a refetch, bypassing the cooldown. Primarily for tests and for
|
|
64
64
|
* operator-triggered rotation flushes; normal callers should rely on the
|
|
@@ -58,7 +58,7 @@ export declare class HttpsJwksResolver implements JwksResolver {
|
|
|
58
58
|
private inFlight;
|
|
59
59
|
private lastAttemptAt;
|
|
60
60
|
constructor(url: string, options?: HttpsJwksResolverOptions);
|
|
61
|
-
resolve(keyid: string): Promise<AdcpJsonWebKey | null>;
|
|
61
|
+
resolve(keyid: string, _signerOrigin?: string): Promise<AdcpJsonWebKey | null>;
|
|
62
62
|
/**
|
|
63
63
|
* Force a refetch, bypassing the cooldown. Primarily for tests and for
|
|
64
64
|
* operator-triggered rotation flushes; normal callers should rely on the
|
|
@@ -56,7 +56,7 @@ class HttpsJwksResolver {
|
|
|
56
56
|
this.lookup = options.lookup;
|
|
57
57
|
this.now = options.now ?? (() => Math.floor(Date.now() / 1e3));
|
|
58
58
|
}
|
|
59
|
-
async resolve(keyid) {
|
|
59
|
+
async resolve(keyid, _signerOrigin) {
|
|
60
60
|
if (!this.cache) {
|
|
61
61
|
if (!this.inFlight && this.now() - this.lastAttemptAt < this.minCooldown) {
|
|
62
62
|
throw new Error("JWKS lookup is in its retry cooldown");
|
|
@@ -33,7 +33,7 @@ class HttpsJwksResolver {
|
|
|
33
33
|
this.lookup = options.lookup;
|
|
34
34
|
this.now = options.now ?? (() => Math.floor(Date.now() / 1e3));
|
|
35
35
|
}
|
|
36
|
-
async resolve(keyid) {
|
|
36
|
+
async resolve(keyid, _signerOrigin) {
|
|
37
37
|
if (!this.cache) {
|
|
38
38
|
if (!this.inFlight && this.now() - this.lastAttemptAt < this.minCooldown) {
|
|
39
39
|
throw new Error("JWKS lookup is in its retry cooldown");
|
|
@@ -13,12 +13,20 @@ export interface JwksResolution {
|
|
|
13
13
|
operatorAuthorizationValidUntil?: number;
|
|
14
14
|
}
|
|
15
15
|
export interface JwksResolver {
|
|
16
|
-
|
|
16
|
+
/**
|
|
17
|
+
* Optional signer-origin locator for resolvers serving multiple signers.
|
|
18
|
+
* It is unverified request context, never proof of identity or authority.
|
|
19
|
+
* Origin-aware caches must scope entries by (canonical origin, keyid).
|
|
20
|
+
* Wrappers must forward it on both lookup methods. Existing one-argument
|
|
21
|
+
* implementations remain valid; static and HTTPS resolvers stay pinned to
|
|
22
|
+
* their configured key source and do not attribute identity from this value.
|
|
23
|
+
*/
|
|
24
|
+
resolve(keyid: string, signerOrigin?: string): Promise<AdcpJsonWebKey | null>;
|
|
17
25
|
/** Optional metadata-aware lookup used by verifiers that must enforce delegation expiry at acceptance time. */
|
|
18
|
-
resolveWithMetadata?(keyid: string): Promise<JwksResolution>;
|
|
26
|
+
resolveWithMetadata?(keyid: string, signerOrigin?: string): Promise<JwksResolution>;
|
|
19
27
|
}
|
|
20
28
|
export declare class StaticJwksResolver implements JwksResolver {
|
|
21
29
|
private readonly byKid;
|
|
22
30
|
constructor(keys: AdcpJsonWebKey[]);
|
|
23
|
-
resolve(keyid: string): Promise<AdcpJsonWebKey | null>;
|
|
31
|
+
resolve(keyid: string, _signerOrigin?: string): Promise<AdcpJsonWebKey | null>;
|
|
24
32
|
}
|
|
@@ -13,12 +13,20 @@ export interface JwksResolution {
|
|
|
13
13
|
operatorAuthorizationValidUntil?: number;
|
|
14
14
|
}
|
|
15
15
|
export interface JwksResolver {
|
|
16
|
-
|
|
16
|
+
/**
|
|
17
|
+
* Optional signer-origin locator for resolvers serving multiple signers.
|
|
18
|
+
* It is unverified request context, never proof of identity or authority.
|
|
19
|
+
* Origin-aware caches must scope entries by (canonical origin, keyid).
|
|
20
|
+
* Wrappers must forward it on both lookup methods. Existing one-argument
|
|
21
|
+
* implementations remain valid; static and HTTPS resolvers stay pinned to
|
|
22
|
+
* their configured key source and do not attribute identity from this value.
|
|
23
|
+
*/
|
|
24
|
+
resolve(keyid: string, signerOrigin?: string): Promise<AdcpJsonWebKey | null>;
|
|
17
25
|
/** Optional metadata-aware lookup used by verifiers that must enforce delegation expiry at acceptance time. */
|
|
18
|
-
resolveWithMetadata?(keyid: string): Promise<JwksResolution>;
|
|
26
|
+
resolveWithMetadata?(keyid: string, signerOrigin?: string): Promise<JwksResolution>;
|
|
19
27
|
}
|
|
20
28
|
export declare class StaticJwksResolver implements JwksResolver {
|
|
21
29
|
private readonly byKid;
|
|
22
30
|
constructor(keys: AdcpJsonWebKey[]);
|
|
23
|
-
resolve(keyid: string): Promise<AdcpJsonWebKey | null>;
|
|
31
|
+
resolve(keyid: string, _signerOrigin?: string): Promise<AdcpJsonWebKey | null>;
|
|
24
32
|
}
|
package/dist/lib/signing/jwks.js
CHANGED
|
@@ -23,7 +23,7 @@ export interface ParsedSignature {
|
|
|
23
23
|
label: string;
|
|
24
24
|
bytes: Uint8Array;
|
|
25
25
|
}
|
|
26
|
-
export declare function parseSignatureInput(headerValue: string): ParsedSignatureInput;
|
|
26
|
+
export declare function parseSignatureInput(headerValue: string, expectedLabel?: string): ParsedSignatureInput;
|
|
27
27
|
export declare function parseSignature(headerValue: string, expectedLabel: string, encoding?: SfBinaryEncoding): ParsedSignature;
|
|
28
28
|
/**
|
|
29
29
|
* RFC 8941 §3.2 parsers deduplicate by keeping the last value. The AdCP
|
|
@@ -23,7 +23,7 @@ export interface ParsedSignature {
|
|
|
23
23
|
label: string;
|
|
24
24
|
bytes: Uint8Array;
|
|
25
25
|
}
|
|
26
|
-
export declare function parseSignatureInput(headerValue: string): ParsedSignatureInput;
|
|
26
|
+
export declare function parseSignatureInput(headerValue: string, expectedLabel?: string): ParsedSignatureInput;
|
|
27
27
|
export declare function parseSignature(headerValue: string, expectedLabel: string, encoding?: SfBinaryEncoding): ParsedSignature;
|
|
28
28
|
/**
|
|
29
29
|
* RFC 8941 §3.2 parsers deduplicate by keeping the last value. The AdCP
|
|
@@ -31,7 +31,7 @@ const INTEGER_PARAMS = /* @__PURE__ */ new Set(["created", "expires"]);
|
|
|
31
31
|
function malformed(message) {
|
|
32
32
|
throw new import_errors.RequestSignatureError("request_signature_header_malformed", 1, message);
|
|
33
33
|
}
|
|
34
|
-
function parseSignatureInput(headerValue) {
|
|
34
|
+
function parseSignatureInput(headerValue, expectedLabel) {
|
|
35
35
|
rejectDuplicateDictionaryKeys(headerValue, "Signature-Input");
|
|
36
36
|
let dict;
|
|
37
37
|
try {
|
|
@@ -41,7 +41,8 @@ function parseSignatureInput(headerValue) {
|
|
|
41
41
|
throw e;
|
|
42
42
|
}
|
|
43
43
|
if (dict.size === 0) malformed("Signature-Input header is empty");
|
|
44
|
-
const label = dict.has("sig1") ? "sig1" : dict.keys().next().value;
|
|
44
|
+
const label = expectedLabel ?? (dict.has("sig1") ? "sig1" : dict.keys().next().value);
|
|
45
|
+
if (!dict.has(label)) malformed("Signature-Input label is missing");
|
|
45
46
|
const entry = dict.get(label);
|
|
46
47
|
if (!isInnerList(entry)) {
|
|
47
48
|
malformed("Signature-Input value must be a parenthesized component list");
|
|
@@ -49,7 +50,8 @@ function parseSignatureInput(headerValue) {
|
|
|
49
50
|
const components = [];
|
|
50
51
|
for (const [bare, itemParams] of entry[0]) {
|
|
51
52
|
if (typeof bare !== "string") malformed("Signature-Input components must all be strings");
|
|
52
|
-
|
|
53
|
+
const serialized = (0, import_structured_headers.serializeItem)([bare, itemParams]);
|
|
54
|
+
components.push(`${bare}${serialized.slice(serialized.indexOf('"', 1) + 1)}`);
|
|
53
55
|
}
|
|
54
56
|
const params = {};
|
|
55
57
|
for (const [key, value] of entry[1]) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ParseError, parseDictionary, serializeInnerList } from "structured-headers";
|
|
1
|
+
import { ParseError, parseDictionary, serializeInnerList, serializeItem } from "structured-headers";
|
|
2
2
|
import { RequestSignatureError } from "./errors.mjs";
|
|
3
3
|
import { isPaddedStandardBase64 } from "./content-digest.mjs";
|
|
4
4
|
const STRING_PARAMS = /* @__PURE__ */ new Set(["nonce", "keyid", "alg", "tag"]);
|
|
@@ -6,7 +6,7 @@ const INTEGER_PARAMS = /* @__PURE__ */ new Set(["created", "expires"]);
|
|
|
6
6
|
function malformed(message) {
|
|
7
7
|
throw new RequestSignatureError("request_signature_header_malformed", 1, message);
|
|
8
8
|
}
|
|
9
|
-
function parseSignatureInput(headerValue) {
|
|
9
|
+
function parseSignatureInput(headerValue, expectedLabel) {
|
|
10
10
|
rejectDuplicateDictionaryKeys(headerValue, "Signature-Input");
|
|
11
11
|
let dict;
|
|
12
12
|
try {
|
|
@@ -16,7 +16,8 @@ function parseSignatureInput(headerValue) {
|
|
|
16
16
|
throw e;
|
|
17
17
|
}
|
|
18
18
|
if (dict.size === 0) malformed("Signature-Input header is empty");
|
|
19
|
-
const label = dict.has("sig1") ? "sig1" : dict.keys().next().value;
|
|
19
|
+
const label = expectedLabel ?? (dict.has("sig1") ? "sig1" : dict.keys().next().value);
|
|
20
|
+
if (!dict.has(label)) malformed("Signature-Input label is missing");
|
|
20
21
|
const entry = dict.get(label);
|
|
21
22
|
if (!isInnerList(entry)) {
|
|
22
23
|
malformed("Signature-Input value must be a parenthesized component list");
|
|
@@ -24,7 +25,8 @@ function parseSignatureInput(headerValue) {
|
|
|
24
25
|
const components = [];
|
|
25
26
|
for (const [bare, itemParams] of entry[0]) {
|
|
26
27
|
if (typeof bare !== "string") malformed("Signature-Input components must all be strings");
|
|
27
|
-
|
|
28
|
+
const serialized = serializeItem([bare, itemParams]);
|
|
29
|
+
components.push(`${bare}${serialized.slice(serialized.indexOf('"', 1) + 1)}`);
|
|
28
30
|
}
|
|
29
31
|
const params = {};
|
|
30
32
|
for (const [key, value] of entry[1]) {
|
|
@@ -1,10 +1,13 @@
|
|
|
1
|
+
import type { RevocationDetail } from '../identity-3.3/types.mjs';
|
|
1
2
|
import type { RevocationSnapshot } from './types.mjs';
|
|
2
3
|
export interface RevocationStore {
|
|
3
4
|
isRevoked(keyid: string): Promise<boolean>;
|
|
4
5
|
}
|
|
5
6
|
export declare class InMemoryRevocationStore implements RevocationStore {
|
|
6
|
-
private revokedKids;
|
|
7
|
+
private readonly revokedKids;
|
|
8
|
+
private readonly details;
|
|
7
9
|
constructor(snapshot?: RevocationSnapshot);
|
|
8
10
|
load(snapshot: RevocationSnapshot): void;
|
|
11
|
+
getDetails(keyid: string): RevocationDetail | undefined;
|
|
9
12
|
isRevoked(keyid: string): Promise<boolean>;
|
|
10
13
|
}
|
|
@@ -1,10 +1,13 @@
|
|
|
1
|
+
import type { RevocationDetail } from '../identity-3.3/types';
|
|
1
2
|
import type { RevocationSnapshot } from './types';
|
|
2
3
|
export interface RevocationStore {
|
|
3
4
|
isRevoked(keyid: string): Promise<boolean>;
|
|
4
5
|
}
|
|
5
6
|
export declare class InMemoryRevocationStore implements RevocationStore {
|
|
6
|
-
private revokedKids;
|
|
7
|
+
private readonly revokedKids;
|
|
8
|
+
private readonly details;
|
|
7
9
|
constructor(snapshot?: RevocationSnapshot);
|
|
8
10
|
load(snapshot: RevocationSnapshot): void;
|
|
11
|
+
getDetails(keyid: string): RevocationDetail | undefined;
|
|
9
12
|
isRevoked(keyid: string): Promise<boolean>;
|
|
10
13
|
}
|
|
@@ -18,22 +18,52 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
18
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
19
|
var revocation_exports = {};
|
|
20
20
|
__export(revocation_exports, {
|
|
21
|
-
InMemoryRevocationStore: () => InMemoryRevocationStore
|
|
21
|
+
InMemoryRevocationStore: () => InMemoryRevocationStore,
|
|
22
|
+
mergeRevocationDetails: () => mergeRevocationDetails
|
|
22
23
|
});
|
|
23
24
|
module.exports = __toCommonJS(revocation_exports);
|
|
24
25
|
class InMemoryRevocationStore {
|
|
25
26
|
revokedKids = /* @__PURE__ */ new Set();
|
|
27
|
+
details = /* @__PURE__ */ new Map();
|
|
26
28
|
constructor(snapshot) {
|
|
27
29
|
if (snapshot) this.load(snapshot);
|
|
28
30
|
}
|
|
29
31
|
load(snapshot) {
|
|
30
|
-
|
|
32
|
+
if ((/* @__PURE__ */ new Set([...this.revokedKids, ...snapshot.revoked_kids])).size > 1e5)
|
|
33
|
+
throw new RangeError("Revocation store capacity exceeded");
|
|
34
|
+
for (const kid of snapshot.revoked_kids) {
|
|
35
|
+
this.revokedKids.add(kid);
|
|
36
|
+
const detail = snapshot.revocation_details?.[kid];
|
|
37
|
+
this.details.set(kid, mergeRevocationDetails(this.details.get(kid), detail ?? {}));
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
getDetails(keyid) {
|
|
41
|
+
const detail = this.details.get(keyid);
|
|
42
|
+
return detail && { ...detail };
|
|
31
43
|
}
|
|
32
44
|
async isRevoked(keyid) {
|
|
33
45
|
return this.revokedKids.has(keyid);
|
|
34
46
|
}
|
|
35
47
|
}
|
|
48
|
+
const REASONS = [
|
|
49
|
+
"removeFromCRL",
|
|
50
|
+
"unspecified",
|
|
51
|
+
"superseded",
|
|
52
|
+
"cessationOfOperation",
|
|
53
|
+
"affiliationChanged",
|
|
54
|
+
"certificateHold",
|
|
55
|
+
"privilegeWithdrawn",
|
|
56
|
+
"aACompromise",
|
|
57
|
+
"cACompromise",
|
|
58
|
+
"keyCompromise"
|
|
59
|
+
];
|
|
60
|
+
function mergeRevocationDetails(prior, detail) {
|
|
61
|
+
const reason = REASONS.indexOf(detail.reason ?? "unspecified") > REASONS.indexOf(prior?.reason ?? "unspecified") ? detail.reason : prior?.reason ?? detail.reason;
|
|
62
|
+
const dates = [prior?.invalidity_date, detail.invalidity_date].filter((s) => !!s && Number.isFinite(Date.parse(s))).sort((a, b) => Date.parse(a) - Date.parse(b));
|
|
63
|
+
return { ...reason ? { reason } : {}, ...dates[0] ? { invalidity_date: dates[0] } : {} };
|
|
64
|
+
}
|
|
36
65
|
// Annotate the CommonJS export names for ESM import in node:
|
|
37
66
|
0 && (module.exports = {
|
|
38
|
-
InMemoryRevocationStore
|
|
67
|
+
InMemoryRevocationStore,
|
|
68
|
+
mergeRevocationDetails
|
|
39
69
|
});
|
|
@@ -1,15 +1,44 @@
|
|
|
1
1
|
class InMemoryRevocationStore {
|
|
2
2
|
revokedKids = /* @__PURE__ */ new Set();
|
|
3
|
+
details = /* @__PURE__ */ new Map();
|
|
3
4
|
constructor(snapshot) {
|
|
4
5
|
if (snapshot) this.load(snapshot);
|
|
5
6
|
}
|
|
6
7
|
load(snapshot) {
|
|
7
|
-
|
|
8
|
+
if ((/* @__PURE__ */ new Set([...this.revokedKids, ...snapshot.revoked_kids])).size > 1e5)
|
|
9
|
+
throw new RangeError("Revocation store capacity exceeded");
|
|
10
|
+
for (const kid of snapshot.revoked_kids) {
|
|
11
|
+
this.revokedKids.add(kid);
|
|
12
|
+
const detail = snapshot.revocation_details?.[kid];
|
|
13
|
+
this.details.set(kid, mergeRevocationDetails(this.details.get(kid), detail ?? {}));
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
getDetails(keyid) {
|
|
17
|
+
const detail = this.details.get(keyid);
|
|
18
|
+
return detail && { ...detail };
|
|
8
19
|
}
|
|
9
20
|
async isRevoked(keyid) {
|
|
10
21
|
return this.revokedKids.has(keyid);
|
|
11
22
|
}
|
|
12
23
|
}
|
|
24
|
+
const REASONS = [
|
|
25
|
+
"removeFromCRL",
|
|
26
|
+
"unspecified",
|
|
27
|
+
"superseded",
|
|
28
|
+
"cessationOfOperation",
|
|
29
|
+
"affiliationChanged",
|
|
30
|
+
"certificateHold",
|
|
31
|
+
"privilegeWithdrawn",
|
|
32
|
+
"aACompromise",
|
|
33
|
+
"cACompromise",
|
|
34
|
+
"keyCompromise"
|
|
35
|
+
];
|
|
36
|
+
function mergeRevocationDetails(prior, detail) {
|
|
37
|
+
const reason = REASONS.indexOf(detail.reason ?? "unspecified") > REASONS.indexOf(prior?.reason ?? "unspecified") ? detail.reason : prior?.reason ?? detail.reason;
|
|
38
|
+
const dates = [prior?.invalidity_date, detail.invalidity_date].filter((s) => !!s && Number.isFinite(Date.parse(s))).sort((a, b) => Date.parse(a) - Date.parse(b));
|
|
39
|
+
return { ...reason ? { reason } : {}, ...dates[0] ? { invalidity_date: dates[0] } : {} };
|
|
40
|
+
}
|
|
13
41
|
export {
|
|
14
|
-
InMemoryRevocationStore
|
|
42
|
+
InMemoryRevocationStore,
|
|
43
|
+
mergeRevocationDetails
|
|
15
44
|
};
|
|
@@ -30,5 +30,5 @@ export { createWebhookVerifier, isWebhookLoopbackHost, verifyWebhookSignature, W
|
|
|
30
30
|
export { createExpressVerifier, type ExpressLike, type ExpressMiddlewareOptions } from './middleware.mjs';
|
|
31
31
|
export { finalizeResponseSignature, prepareResponseSignature, signResponse, type PreparedResponseSignature, type SignedResponse, type SignResponseOptions, } from './signer.mjs';
|
|
32
32
|
export { signResponseAsync } from './signer-async.mjs';
|
|
33
|
-
export { resolveAgent, ResolvedAgentJwksResolver, getAgentJwks, createAgentJwksSet, AgentResolverError, attackerInfluencedFields, ATTACKER_INFLUENCED, readBrandJsonUrl, readIdentityPosture, type AgentResolution, type AgentProtocol, type AuthorizedOperatorScope, type DelegatedOperatorAuthorizationContext, type AgentResolverErrorCode, type AgentResolverErrorDetail, type AgentEntry, type AgentJwksResult, type CapabilitiesWithBrandJsonUrl, type CreateAgentJwksSetOptions, type FetchCapabilitiesFn, type GetAgentJwksOptions, type IdentityKeyOriginPurpose, type IdentityKeyOrigins, type IdentityPosture, type ResolveAgentOptions, type ResolvedAgentJwksResolverOptions, type TraceStep, } from './agent-resolver/index.mjs';
|
|
33
|
+
export { resolveAgent, ResolvedAgentJwksResolver, canonicalAgentOrigin, CanonicalizeError, getAgentJwks, createAgentJwksSet, AgentResolverError, attackerInfluencedFields, ATTACKER_INFLUENCED, readBrandJsonUrl, readIdentityPosture, type AgentResolution, type AgentProtocol, type AuthorizedOperatorScope, type DelegatedOperatorAuthorizationContext, type AgentResolverErrorCode, type AgentResolverErrorDetail, type AgentEntry, type AgentJwksResult, type CapabilitiesWithBrandJsonUrl, type CreateAgentJwksSetOptions, type FetchCapabilitiesFn, type GetAgentJwksOptions, type IdentityKeyOriginPurpose, type IdentityKeyOrigins, type IdentityPosture, type ResolveAgentOptions, type ResolvedAgentJwksResolverOptions, type TraceStep, } from './agent-resolver/index.mjs';
|
|
34
34
|
export type { PublisherSigningKeyPin } from './publisher-pins.mjs';
|
|
@@ -30,5 +30,5 @@ export { createWebhookVerifier, isWebhookLoopbackHost, verifyWebhookSignature, W
|
|
|
30
30
|
export { createExpressVerifier, type ExpressLike, type ExpressMiddlewareOptions } from './middleware';
|
|
31
31
|
export { finalizeResponseSignature, prepareResponseSignature, signResponse, type PreparedResponseSignature, type SignedResponse, type SignResponseOptions, } from './signer';
|
|
32
32
|
export { signResponseAsync } from './signer-async';
|
|
33
|
-
export { resolveAgent, ResolvedAgentJwksResolver, getAgentJwks, createAgentJwksSet, AgentResolverError, attackerInfluencedFields, ATTACKER_INFLUENCED, readBrandJsonUrl, readIdentityPosture, type AgentResolution, type AgentProtocol, type AuthorizedOperatorScope, type DelegatedOperatorAuthorizationContext, type AgentResolverErrorCode, type AgentResolverErrorDetail, type AgentEntry, type AgentJwksResult, type CapabilitiesWithBrandJsonUrl, type CreateAgentJwksSetOptions, type FetchCapabilitiesFn, type GetAgentJwksOptions, type IdentityKeyOriginPurpose, type IdentityKeyOrigins, type IdentityPosture, type ResolveAgentOptions, type ResolvedAgentJwksResolverOptions, type TraceStep, } from './agent-resolver';
|
|
33
|
+
export { resolveAgent, ResolvedAgentJwksResolver, canonicalAgentOrigin, CanonicalizeError, getAgentJwks, createAgentJwksSet, AgentResolverError, attackerInfluencedFields, ATTACKER_INFLUENCED, readBrandJsonUrl, readIdentityPosture, type AgentResolution, type AgentProtocol, type AuthorizedOperatorScope, type DelegatedOperatorAuthorizationContext, type AgentResolverErrorCode, type AgentResolverErrorDetail, type AgentEntry, type AgentJwksResult, type CapabilitiesWithBrandJsonUrl, type CreateAgentJwksSetOptions, type FetchCapabilitiesFn, type GetAgentJwksOptions, type IdentityKeyOriginPurpose, type IdentityKeyOrigins, type IdentityPosture, type ResolveAgentOptions, type ResolvedAgentJwksResolverOptions, type TraceStep, } from './agent-resolver';
|
|
34
34
|
export type { PublisherSigningKeyPin } from './publisher-pins';
|
|
@@ -24,6 +24,7 @@ __export(server_exports, {
|
|
|
24
24
|
BrandJsonJwksResolver: () => import_brand_jwks.BrandJsonJwksResolver,
|
|
25
25
|
BrandJsonResolverError: () => import_brand_jwks.BrandJsonResolverError,
|
|
26
26
|
CLOCK_SKEW_TOLERANCE_SECONDS: () => import_types.CLOCK_SKEW_TOLERANCE_SECONDS,
|
|
27
|
+
CanonicalizeError: () => import_agent_resolver.CanonicalizeError,
|
|
27
28
|
HttpsJwksResolver: () => import_jwks_https.HttpsJwksResolver,
|
|
28
29
|
HttpsRevocationStore: () => import_revocation_https.HttpsRevocationStore,
|
|
29
30
|
InMemoryReplayStore: () => import_replay.InMemoryReplayStore,
|
|
@@ -48,6 +49,7 @@ __export(server_exports, {
|
|
|
48
49
|
attackerInfluencedFields: () => import_agent_resolver.attackerInfluencedFields,
|
|
49
50
|
buildResponseSignatureBase: () => import_canonicalize.buildResponseSignatureBase,
|
|
50
51
|
buildSignatureBase: () => import_canonicalize.buildSignatureBase,
|
|
52
|
+
canonicalAgentOrigin: () => import_agent_resolver.canonicalAgentOrigin,
|
|
51
53
|
canonicalAuthority: () => import_canonicalize.canonicalAuthority,
|
|
52
54
|
canonicalMethod: () => import_canonicalize.canonicalMethod,
|
|
53
55
|
canonicalTargetUri: () => import_canonicalize.canonicalTargetUri,
|
|
@@ -114,6 +116,7 @@ var import_agent_resolver = require('./agent-resolver/index.js');
|
|
|
114
116
|
BrandJsonJwksResolver,
|
|
115
117
|
BrandJsonResolverError,
|
|
116
118
|
CLOCK_SKEW_TOLERANCE_SECONDS,
|
|
119
|
+
CanonicalizeError,
|
|
117
120
|
HttpsJwksResolver,
|
|
118
121
|
HttpsRevocationStore,
|
|
119
122
|
InMemoryReplayStore,
|
|
@@ -138,6 +141,7 @@ var import_agent_resolver = require('./agent-resolver/index.js');
|
|
|
138
141
|
attackerInfluencedFields,
|
|
139
142
|
buildResponseSignatureBase,
|
|
140
143
|
buildSignatureBase,
|
|
144
|
+
canonicalAgentOrigin,
|
|
141
145
|
canonicalAuthority,
|
|
142
146
|
canonicalMethod,
|
|
143
147
|
canonicalTargetUri,
|
|
@@ -74,6 +74,8 @@ import { signResponseAsync } from "./signer-async.mjs";
|
|
|
74
74
|
import {
|
|
75
75
|
resolveAgent,
|
|
76
76
|
ResolvedAgentJwksResolver,
|
|
77
|
+
canonicalAgentOrigin,
|
|
78
|
+
CanonicalizeError,
|
|
77
79
|
getAgentJwks,
|
|
78
80
|
createAgentJwksSet,
|
|
79
81
|
AgentResolverError,
|
|
@@ -89,6 +91,7 @@ export {
|
|
|
89
91
|
BrandJsonJwksResolver,
|
|
90
92
|
BrandJsonResolverError,
|
|
91
93
|
CLOCK_SKEW_TOLERANCE_SECONDS,
|
|
94
|
+
CanonicalizeError,
|
|
92
95
|
HttpsJwksResolver,
|
|
93
96
|
HttpsRevocationStore,
|
|
94
97
|
InMemoryReplayStore,
|
|
@@ -113,6 +116,7 @@ export {
|
|
|
113
116
|
attackerInfluencedFields,
|
|
114
117
|
buildResponseSignatureBase,
|
|
115
118
|
buildSignatureBase,
|
|
119
|
+
canonicalAgentOrigin,
|
|
116
120
|
canonicalAuthority,
|
|
117
121
|
canonicalMethod,
|
|
118
122
|
canonicalTargetUri,
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
export type ContentDigestPolicy = 'required' | 'forbidden' | 'either';
|
|
2
2
|
export interface VerifierCapability {
|
|
3
|
+
profiles?: ('adcp/request-signing/v1' | 'web-bot-auth')[];
|
|
4
|
+
wba_draft_revision?: string;
|
|
3
5
|
supported: boolean;
|
|
4
6
|
covers_content_digest: ContentDigestPolicy;
|
|
5
7
|
required_for: string[];
|
|
@@ -46,6 +48,7 @@ export interface RevocationSnapshot {
|
|
|
46
48
|
next_update: string;
|
|
47
49
|
revoked_kids: string[];
|
|
48
50
|
revoked_jtis: string[];
|
|
51
|
+
revocation_details?: Record<string, import('../identity-3.3/types.mjs').RevocationDetail>;
|
|
49
52
|
}
|
|
50
53
|
/**
|
|
51
54
|
* Narrow "successfully verified" shape. Middleware sets `req.verifiedSigner`
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
export type ContentDigestPolicy = 'required' | 'forbidden' | 'either';
|
|
2
2
|
export interface VerifierCapability {
|
|
3
|
+
profiles?: ('adcp/request-signing/v1' | 'web-bot-auth')[];
|
|
4
|
+
wba_draft_revision?: string;
|
|
3
5
|
supported: boolean;
|
|
4
6
|
covers_content_digest: ContentDigestPolicy;
|
|
5
7
|
required_for: string[];
|
|
@@ -46,6 +48,7 @@ export interface RevocationSnapshot {
|
|
|
46
48
|
next_update: string;
|
|
47
49
|
revoked_kids: string[];
|
|
48
50
|
revoked_jtis: string[];
|
|
51
|
+
revocation_details?: Record<string, import('../identity-3.3/types').RevocationDetail>;
|
|
49
52
|
}
|
|
50
53
|
/**
|
|
51
54
|
* Narrow "successfully verified" shape. Middleware sets `req.verifiedSigner`
|