@tinycloud/sdk-core 3.12.0-beta.4 → 3.12.0-beta.5
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/delegations/index.d.cts +16 -16
- package/dist/delegations/index.d.ts +16 -16
- package/dist/delegations/issued.d.cts +1 -1
- package/dist/delegations/issued.d.ts +1 -1
- package/dist/index.cjs +52 -22
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +14 -5
- package/dist/index.d.ts +14 -5
- package/dist/index.js +52 -22
- package/dist/index.js.map +1 -1
- package/dist/{recipient-types.schema-BIJcihno.d.cts → recipient-types.schema--5j8kRNE.d.ts} +1 -1
- package/dist/{recipient-types.schema-Ebi5aliq.d.ts → recipient-types.schema-C-q64lEk.d.cts} +1 -1
- package/package.json +1 -1
- package/dist/{types.schema-BmN-OnCA.d.cts → types.schema-B0ZUx7Ss.d.cts} +24 -24
- package/dist/{types.schema-BmN-OnCA.d.ts → types.schema-B0ZUx7Ss.d.ts} +24 -24
package/dist/index.d.cts
CHANGED
|
@@ -5,10 +5,10 @@ export { canonicalEmailDomain, canonicalMailbox, isCanonicalEmailDomain, mailbox
|
|
|
5
5
|
import { InvokeFunction, InvokeAnyFunction, ParsedNetworkId, ServiceError, Result, FetchFunction, ServiceConstructor, RetryPolicy, TelemetryConfig, IServiceContext, IService, IKVService, ISQLService, IDuckDbService, IHooksService, IDataVaultService, IEncryptionService, ISecretsService, ServiceSession, IDatabaseHandle, SqlValue, QueryResponse } from '@tinycloud/sdk-services';
|
|
6
6
|
export { AuthorityRefusal, AuthorizationVerdict, BatchOptions, BatchResponse, BuildCanonicalDecryptRequestInput, BuildDecryptFactsInput, BuildDecryptInvocationInput, BuiltDecryptInvocation, CanonicalDecryptRequest, CanonicalJson, ColumnInfo, DECRYPT_ACTION, DECRYPT_FACT_TYPE, DECRYPT_RESULT_TYPE, DEFAULT_ENCRYPTION_ALG, DEFAULT_KEY_VERSION, DataVaultConfig, DataVaultService, DatabaseHandle, DecryptCapabilityProof, DecryptEnvelopeOptions, DecryptInvocationFact, DecryptInvocationSigner, DecryptRequestBody, DecryptResponseBody, DecryptTransport, DecryptTransportResponseError, DiscoverNetworkInput, DiscoveredNetwork, DiscoverySource, DuckDbAction, DuckDbActionType, DuckDbBatchOptions, DuckDbBatchResponse, DuckDbDatabaseHandle, DuckDbExecuteOptions, DuckDbExecuteResponse, DuckDbOptions, DuckDbQueryOptions, DuckDbQueryResponse, DuckDbService, DuckDbServiceConfig, DuckDbStatement, DuckDbValue, ENCRYPTION_NETWORK_URN_PREFIX, ENCRYPTION_SERVICE, ENCRYPTION_SERVICE_SHORT, ENVELOPE_VERSION, EncryptToNetworkInput, EncryptToNetworkOptions, EncryptToNetworkResult, EncryptionCrypto, EncryptionError, EncryptionErrorInput, EncryptionService, EncryptionServiceConfig, ErrorCode, ErrorCodes, ExecuteOptions, ExecuteResponse, FetchFunction, HookEvent, HookServiceName, HookStreamEvent, HookSubscription, HookWebhookListOptions, HookWebhookRecord, HookWebhookRegistration, HookWebhookScope, HookWebhookUnregisterOptions, HooksService, HooksServiceConfig, IDataVaultService, IDatabaseHandle, IDuckDbDatabaseHandle, IDuckDbService, IEncryptionService, IHooksService, IKVService, IPrefixedKVService, ISQLService, ISecretsService, IService, IServiceContext, IStorageService, InlineEncryptedEnvelope, InvokeAnyEntry, InvokeAnyFunction, InvokeFunction, KVBatchReadResponse, KVChange, KVChangesAuthority, KVChangesOptions, KVChangesResponse, KVCreateSignedReadUrlOptions, KVDeleteOptions, KVGetOptions, KVHeadOptions, KVListOptions, KVListPage, KVListResponse, KVPutOptions, KVReadThrough, KVReplicaHandle, KVReplicaSpec, KVReplicaStorage, KVReplicationController, KVReplicationDeps, KVResponse, KVResponseHeaders, KVService, KVServiceConfig, KVSignedReadUrlResponse, LocalGetResult, LocalListResult, LocalReadMeta, LocalReplicaStatus, LocalSyncResult, MAX_SECRET_SCOPE_LENGTH, NETWORK_NAME_PATTERN, NetworkDescriptor, NetworkIdError, NodeDescriptorFetcher, ParsedNetworkId, ParsedSecretCatalogKey, PendingWriteRecord, PendingWriteState, PendingWriteStore, PinnedKey, PrefixedKVService, PurgeTarget, QueryOptions, QueryResponse, RandomReceiverKeyInput, ReceiverKeyPair, ReceiverKeySigner, ReplicaAuthorityState, ReplicaCoverage, ReplicaDevice, ReplicaGatedHandle, ReplicaGrantInfo, ReplicaInspectedStatus, ReplicaLocalEraseOutcome, ReplicaPurgeError, ReplicaPurgeFailedEvent, ReplicaPurgeLocalCopyResult, ReplicaPurgeTrigger, ReplicaState, ReplicaStatusEntry, ReplicationAuthority, ReplicationControl, ReplicationEvent, ReplicationIdentity, ReplicationOptions, ReplicationPurgeReport, ReplicationReason, ReplicationScheduler, ResolvedReplicationOptions, ResolvedSecretPath, Result, RetryPolicy, SECRET_NAME_RE, SECRET_SCOPE_RE, SQLAction, SQLActionType, SQLService, SQLServiceConfig, STORAGE_FULL_MESSAGE, STORAGE_MANAGE_URL, STORAGE_NEARLY_FULL_RATIO, STORAGE_WRITE_TOO_LARGE_MESSAGE, SchemaInfo, SecretCatalogEntry, SecretPayload, SecretPutOptions, SecretScopeOptions, SecretsError, SecretsService, ServiceContext, ServiceContextConfig, ServiceError, ServiceSession, SignedReceiverKeyInput, SqlStatement, SqlValue, StorageAccountUsage, StorageFullEvent, StorageFullHandler, StorageFullMonitor, StorageRejectionDetails, StorageStatus, StorageStatusOptions, StorageUsage, StorageUsageState, SubscribeOptions, TC832_RESERVED_SCOPES, TableInfo, TelemetryConfig, TelemetryEventHandler, TinyCloudDebugEnableOptions, TinyCloudDebugEvent, TinyCloudDebugLevel, TinyCloudDebugLogger, TinyCloudDebugTimer, VaultCrypto, VaultEntry, VaultError, VaultGetOptions, VaultGrantOptions, VaultHeaders, VaultListOptions, VaultNetworkReadResult, VaultPublicSpaceKVActions, VaultPutOptions, VerifyDecryptResponseInput, ViewInfo, WasmVaultFunctions, WellKnownDescriptorFetcher, appSecretScope, authorizationVerdictOf, buildCanonicalDecryptRequest, buildDecryptAttenuation, buildDecryptFacts, buildDecryptInvocation, buildNetworkId, canonicalHashHex, canonicalSignedResponse, canonicalizeEncryptionJson, canonicalizeSecretScope, checkDecryptInvocationInput, clearTinyCloudDebugLogs, createVaultCrypto, decryptEnvelopeWithKey, defaultRetryPolicy, deriveSignedReceiverKey, disableTinyCloudDebug, discoverNetwork, enableTinyCloudDebug, encryptToNetwork, base64Decode as encryptionBase64Decode, base64Encode as encryptionBase64Encode, encryptionError, utf8Decode as encryptionUtf8Decode, utf8Encode as encryptionUtf8Encode, ensureNetworkUsableForDecrypt, err, generateRandomReceiverKey, getTinyCloudDebugLogs, hexDecode, hexEncode, installTinyCloudDebugGlobals, isNetworkId, isStorageFullError, networkDiscoveryKey, ok, openWrappedKey, parseCapabilityResource, parseNetworkId, parseSecretCatalogKey, parseStorageRejection, parseStorageStatus, resolveSecretListPrefix, resolveSecretPath, serviceError, storageUsageState, tinyCloudDebugLogger, validateEnvelope, validatedCapabilityOf, verifyDecryptResponse } from '@tinycloud/sdk-services';
|
|
7
7
|
export { HOLDER_KEY_BINDING_PRESENTATION_SCHEMA, HolderKeyBindingPresentation, LISTEN_SQL_STATEMENT_CATALOG, ListenSqlStatementName, POLICY_ENGINE_CHALLENGE_REQUEST_SCHEMA, POLICY_ENGINE_CHALLENGE_RESPONSE_SCHEMA, POLICY_ENGINE_DENIAL_SCHEMA, POLICY_ENGINE_GRANT_PRESENTATION_DENIAL_CODES, POLICY_ENGINE_RESOLVE_REQUEST_SCHEMA, PORTABLE_DELEGATION_SCHEMA, PolicyEngineGrantPresentationDenialCode, PortableDelegation, REQUESTER_ENGINE_RETRY_ATTEMPTS, REQUESTER_ENGINE_RETRY_MAX_DELAY_MS, REQUESTER_NEAR_EXPIRY_SECONDS, RequesterEndpointResolution, RequesterHttpRequest, RequesterHttpResponse, RequesterInvocationCapability, RequesterSigningCapability, RequesterTransport, TranscriptRequester, TranscriptRequesterError, TranscriptRequesterErrorCode, TranscriptRequesterErrorState, TranscriptRequesterOptions, TranscriptRequesterReadKvResult, TranscriptRequesterReadSqlResult, createTranscriptRequester, deriveDelegationCid, parseNodeNativePortableDelegation } from './requester/index.cjs';
|
|
8
|
-
import { h as Delegation, d as CreateDelegationParams, G as GenerateShareParams, v as ShareLink, y as SpaceInfo, a as AccountDelegationQueryOptions, A as AccountDelegationPage, r as DelegationRevocationReceipt } from './types.schema-
|
|
9
|
-
export { b as AccountDelegationRecord, c as AccountDelegationResource, C as CapabilityEntry, e as CreateDelegationWasmParams, f as CreateDelegationWasmResult, g as DelegatedResource, i as DelegationApiResponse, j as DelegationChain, k as DelegationChainV2, l as DelegationDirection, D as DelegationError, m as DelegationErrorCode, n as DelegationErrorCodes, o as DelegationFilters, p as DelegationManagerConfig, q as DelegationRecord, R as DelegationResult, s as DelegationStatus, I as IngestOptions, J as JWK, K as KeyInfo, t as KeyProvider, u as KeyType, S as SessionInvocationSigner, w as ShareLinkData, x as ShareSchema, z as SpaceOwnership } from './types.schema-
|
|
10
|
-
import { I as ICapabilityKeyRegistry, h as ISharingService, f as DelegationManager } from './recipient-types.schema-
|
|
11
|
-
export { C as CREDENTIAL_INVITATION_REQUEST_DOMAIN, bl as CapabilityKeyRegistry, bm as CapabilityKeyRegistryErrorCode, bn as CapabilityKeyRegistryErrorCodes, a as CreateOwnerDelegationParams, b as CredentialInvitationRequest, D as DELIVERY_ADMISSION_DOMAIN, c as DelegateReceivedShareParams, d as DelegatedShareAccess, e as DelegatedShareKey, g as DeliveryAdmission, E as EncodedShareData, M as MAX_CONTENT_BYTES, i as MAX_SEALED_SHARE_CONTENT_BYTES, j as MAX_SHARE_ARTIFACT_BYTES, k as MAX_SHARE_CONTENT_BYTES, l as MemorySenderShareKeyStorage, m as MemorySenderShareRecordStorage, n as MemoryShareCache, O as OwnerDelegationPermission, o as OwnerDelegationReceipt, p as OwnerShareAction, q as OwnerShareDecryption, r as OwnerShareMatcher, s as OwnerSharePolicyRegistration, t as OwnerSharePolicyRegistrationReceipt, u as OwnerSharePolicyV2, P as PortableDelegationImportReceipt, R as ReceiveOptions, v as RegisterOwnerSharePolicyParams, S as SenderShareKeyStorage, w as SenderShareRecord, x as SenderShareRecordStorage, y as SenderShareRevocationScope, z as SenderShareStore, A as ShareAccess, B as ShareAccessError, F as ShareAccessV2, G as ShareAction, J as ShareAddressedDelegationEnvelopeV2, K as ShareAddressedDelegationEnvelopeV2Schema, L as ShareAddressedDelegationRequestV2, N as ShareAddressedDelegationRequestV2Schema, Q as ShareAddressedDelegationResponseV2, T as ShareAddressedDelegationResponseV2Schema, U as ShareAddressedRecipientMatcher, V as ShareArtifactInput, W as ShareArtifactResult, X as ShareArtifactV2, Y as ShareCache, Z as ShareCacheEntry, _ as ShareCacheKey, $ as ShareCacheMetadata, a0 as ShareCapabilityLike, a1 as ShareConflict, a2 as ShareContentMetadata, a3 as ShareContentSource, a4 as ShareDelegationPreflight, a5 as ShareDeliveryAuthorizationV3Receipt, a6 as ShareDeliveryAuthorizationV3Request, a7 as ShareDeliveryRefusedError, a8 as ShareDetachedProof, a9 as ShareEnvelopeError, aa as ShareEnvelopeV2, ab as ShareExpiryBounds, ac as ShareKvContentSource, ad as ShareLinkLocation, ae as ShareListEntry, af as ShareListResult, ag as ShareNativeAction, ah as ShareNativeInvokeEnvelopeV1, ai as ShareNativeInvokeErrorResult, aj as ShareNativeInvokeInput, ak as ShareNativeInvokeResult, al as ShareNativeInvokeSuccessResult, am as ShareNativeResponse, an as ShareNativeResponseSchema, ao as SharePolicy, ap as SharePolicyBinding, aq as SharePolicySession, ar as SharePolicySessionV1, as as SharePolicySessionWireV1, at as SharePortableDelegation, au as ShareReadInvocationV1, av as ShareReadResult, aw as ShareRecipientClient, ax as ShareRecipientClientOptions, az as ShareRecipientPolicy, aB as ShareRecipientResult, aC as ShareRecipientTarget, aE as ShareResource, aG as ShareSaveOptions, aH as ShareSqlContentSource, aI as ShareWireAction, aJ as SharingService, aK as SharingServiceConfig, aL as SignedDelegation, bo as StoredDelegationChain, aM as VerifyShareEnvelopeOptions, aN as canonicalOwnerSharePolicy, aO as computeOwnerShareRegistrationCid, aP as computeShareCid, bp as createCapabilityKeyRegistry, aQ as createDelegatedShareKey, aR as createPolicyEnforcementDelegation, aS as createShareArtifact, aT as createShareArtifactAsync, aU as createSharePolicy, aV as createSharingService, aW as decryptShareBytesAsync, aX as delegatePortablePolicySession, aY as encodeInlineShareUrl, aZ as encodeShareArtifact, a_ as encodeShareUrl, a$ as encryptShareBytes, b0 as encryptShareBytesAsync, b1 as importPortableDelegation, b2 as intersectShareCapabilities, b3 as isV2ShareLink, b4 as normalizeShareActions, b5 as normalizeShareRecipientTarget, b6 as normalizeShareResource, b7 as parsePortableDelegation, b8 as parseShareArtifact, b9 as parseShareUrl, ba as restoreDelegatedShareKey, bb as serializePortableDelegation, bc as shareCapabilityAllows, bd as shortDeliveryLinkBodyCid, be as signShareEnvelope, bf as validateOwnerSharePolicyRegistration, bg as validateOwnerSharePolicyRegistrationBytes, bh as verifyShareCid, bi as verifyShareDeliveryAuthorizationV3Bytes, bj as verifyShareEnvelope, bk as withoutShareLink } from './recipient-types.schema-
|
|
8
|
+
import { h as Delegation, d as CreateDelegationParams, G as GenerateShareParams, v as ShareLink, y as SpaceInfo, a as AccountDelegationQueryOptions, A as AccountDelegationPage, r as DelegationRevocationReceipt } from './types.schema-B0ZUx7Ss.cjs';
|
|
9
|
+
export { b as AccountDelegationRecord, c as AccountDelegationResource, C as CapabilityEntry, e as CreateDelegationWasmParams, f as CreateDelegationWasmResult, g as DelegatedResource, i as DelegationApiResponse, j as DelegationChain, k as DelegationChainV2, l as DelegationDirection, D as DelegationError, m as DelegationErrorCode, n as DelegationErrorCodes, o as DelegationFilters, p as DelegationManagerConfig, q as DelegationRecord, R as DelegationResult, s as DelegationStatus, I as IngestOptions, J as JWK, K as KeyInfo, t as KeyProvider, u as KeyType, S as SessionInvocationSigner, w as ShareLinkData, x as ShareSchema, z as SpaceOwnership } from './types.schema-B0ZUx7Ss.cjs';
|
|
10
|
+
import { I as ICapabilityKeyRegistry, h as ISharingService, f as DelegationManager } from './recipient-types.schema-C-q64lEk.cjs';
|
|
11
|
+
export { C as CREDENTIAL_INVITATION_REQUEST_DOMAIN, bl as CapabilityKeyRegistry, bm as CapabilityKeyRegistryErrorCode, bn as CapabilityKeyRegistryErrorCodes, a as CreateOwnerDelegationParams, b as CredentialInvitationRequest, D as DELIVERY_ADMISSION_DOMAIN, c as DelegateReceivedShareParams, d as DelegatedShareAccess, e as DelegatedShareKey, g as DeliveryAdmission, E as EncodedShareData, M as MAX_CONTENT_BYTES, i as MAX_SEALED_SHARE_CONTENT_BYTES, j as MAX_SHARE_ARTIFACT_BYTES, k as MAX_SHARE_CONTENT_BYTES, l as MemorySenderShareKeyStorage, m as MemorySenderShareRecordStorage, n as MemoryShareCache, O as OwnerDelegationPermission, o as OwnerDelegationReceipt, p as OwnerShareAction, q as OwnerShareDecryption, r as OwnerShareMatcher, s as OwnerSharePolicyRegistration, t as OwnerSharePolicyRegistrationReceipt, u as OwnerSharePolicyV2, P as PortableDelegationImportReceipt, R as ReceiveOptions, v as RegisterOwnerSharePolicyParams, S as SenderShareKeyStorage, w as SenderShareRecord, x as SenderShareRecordStorage, y as SenderShareRevocationScope, z as SenderShareStore, A as ShareAccess, B as ShareAccessError, F as ShareAccessV2, G as ShareAction, J as ShareAddressedDelegationEnvelopeV2, K as ShareAddressedDelegationEnvelopeV2Schema, L as ShareAddressedDelegationRequestV2, N as ShareAddressedDelegationRequestV2Schema, Q as ShareAddressedDelegationResponseV2, T as ShareAddressedDelegationResponseV2Schema, U as ShareAddressedRecipientMatcher, V as ShareArtifactInput, W as ShareArtifactResult, X as ShareArtifactV2, Y as ShareCache, Z as ShareCacheEntry, _ as ShareCacheKey, $ as ShareCacheMetadata, a0 as ShareCapabilityLike, a1 as ShareConflict, a2 as ShareContentMetadata, a3 as ShareContentSource, a4 as ShareDelegationPreflight, a5 as ShareDeliveryAuthorizationV3Receipt, a6 as ShareDeliveryAuthorizationV3Request, a7 as ShareDeliveryRefusedError, a8 as ShareDetachedProof, a9 as ShareEnvelopeError, aa as ShareEnvelopeV2, ab as ShareExpiryBounds, ac as ShareKvContentSource, ad as ShareLinkLocation, ae as ShareListEntry, af as ShareListResult, ag as ShareNativeAction, ah as ShareNativeInvokeEnvelopeV1, ai as ShareNativeInvokeErrorResult, aj as ShareNativeInvokeInput, ak as ShareNativeInvokeResult, al as ShareNativeInvokeSuccessResult, am as ShareNativeResponse, an as ShareNativeResponseSchema, ao as SharePolicy, ap as SharePolicyBinding, aq as SharePolicySession, ar as SharePolicySessionV1, as as SharePolicySessionWireV1, at as SharePortableDelegation, au as ShareReadInvocationV1, av as ShareReadResult, aw as ShareRecipientClient, ax as ShareRecipientClientOptions, az as ShareRecipientPolicy, aB as ShareRecipientResult, aC as ShareRecipientTarget, aE as ShareResource, aG as ShareSaveOptions, aH as ShareSqlContentSource, aI as ShareWireAction, aJ as SharingService, aK as SharingServiceConfig, aL as SignedDelegation, bo as StoredDelegationChain, aM as VerifyShareEnvelopeOptions, aN as canonicalOwnerSharePolicy, aO as computeOwnerShareRegistrationCid, aP as computeShareCid, bp as createCapabilityKeyRegistry, aQ as createDelegatedShareKey, aR as createPolicyEnforcementDelegation, aS as createShareArtifact, aT as createShareArtifactAsync, aU as createSharePolicy, aV as createSharingService, aW as decryptShareBytesAsync, aX as delegatePortablePolicySession, aY as encodeInlineShareUrl, aZ as encodeShareArtifact, a_ as encodeShareUrl, a$ as encryptShareBytes, b0 as encryptShareBytesAsync, b1 as importPortableDelegation, b2 as intersectShareCapabilities, b3 as isV2ShareLink, b4 as normalizeShareActions, b5 as normalizeShareRecipientTarget, b6 as normalizeShareResource, b7 as parsePortableDelegation, b8 as parseShareArtifact, b9 as parseShareUrl, ba as restoreDelegatedShareKey, bb as serializePortableDelegation, bc as shareCapabilityAllows, bd as shortDeliveryLinkBodyCid, be as signShareEnvelope, bf as validateOwnerSharePolicyRegistration, bg as validateOwnerSharePolicyRegistrationBytes, bh as verifyShareCid, bi as verifyShareDeliveryAuthorizationV3Bytes, bj as verifyShareEnvelope, bk as withoutShareLink } from './recipient-types.schema-C-q64lEk.cjs';
|
|
12
12
|
export { ACCOUNT_INDEX_SCHEMA, ACCOUNT_MANIFEST_PERMISSIONS, AGENTS_SPACE, BOOTSTRAP_ALLOWLIST, BOOTSTRAP_DEFAULT_ONLY_SESSION_REQUEST, BOOTSTRAP_DEFAULT_SPACE, BOOTSTRAP_ENCRYPTION_NETWORK_NAME, BOOTSTRAP_ENCRYPTION_NETWORK_RESOURCE_TEMPLATE, BOOTSTRAP_MANIFEST, BOOTSTRAP_PERSISTED_APPLICATION_MANIFESTS, BOOTSTRAP_PUBLIC_SPACE, BOOTSTRAP_SESSION_REQUESTS, BOOTSTRAP_SPACE_MANIFESTS, BOOTSTRAP_SPACE_NAMES, BootstrapAllowlistEntry, BootstrapAllowlistKind, BootstrapEncryptionNetworkStep, BootstrapManifest, BootstrapRawAbilityAllowlistEntry, BootstrapSchemaStep, BootstrapSeedApplicationsStep, BootstrapSeedSpacesStep, BootstrapSpaceDescriptor, BootstrapSpaceName, BootstrapSpaceStep, BootstrapStep, BootstrapStepKind, CAPABILITIES, CAPABILITY_REGISTRY, CapabilityRegistryEntry, CapabilityStatus, DUCKDB, ENCRYPTION, HOOKS, KV, SECRET_RECORDS_SCHEMA, SPACE, SQL, TINYCLOUD_ACCOUNT_SPACE_MANIFEST, TINYCLOUD_AGENTS_SPACE_MANIFEST, TINYCLOUD_APPLICATIONS_SPACE_MANIFEST, TINYCLOUD_DEFAULT_SPACE_MANIFEST, TINYCLOUD_PUBLIC_SPACE_MANIFEST, TINYCLOUD_SECRETS_BOOTSTRAP_MANIFEST, bootstrapEncryptionNetworkId, bootstrapSpaceId, bootstrapSteps, composeBootstrapSpaceManifest } from '@tinycloud/bootstrap';
|
|
13
13
|
export { a as JsonValue, j as jcsCanonicalize, n as normalizeJson, s as serializeJcsJson } from './capability-BjzXwtNw.cjs';
|
|
14
14
|
export { SiweMessage } from 'siwe';
|
|
@@ -1073,6 +1073,15 @@ declare function principalDidEquals(a: string, b: string): boolean;
|
|
|
1073
1073
|
declare function didCacheKey(input: string, options?: DidCacheKeyOptions): string;
|
|
1074
1074
|
declare function makePkhSpaceId(address: string, chainId: number, name: string): string;
|
|
1075
1075
|
|
|
1076
|
+
/**
|
|
1077
|
+
* The public key of `jwk`: only the standard public members of its key type, plus `kid` when it is a string, are
|
|
1078
|
+
* copied, so private members and anything else (`alg`, `use`, unknown fields) are dropped. Use it for every JWK that
|
|
1079
|
+
* leaves the device.
|
|
1080
|
+
*
|
|
1081
|
+
* Throws for a key type without a public form (`oct`, unknown) or a missing public member.
|
|
1082
|
+
*/
|
|
1083
|
+
declare function publicJwk(jwk: unknown): Record<string, string>;
|
|
1084
|
+
|
|
1076
1085
|
type ReCapAttenuation = Readonly<Record<string, Readonly<Record<string, readonly unknown[]>>>>;
|
|
1077
1086
|
/** A wallet-signed SIWE CACAO whose encoding, signature and exact-bytes CID were verified. */
|
|
1078
1087
|
interface SignedSiweCacao {
|
|
@@ -4136,4 +4145,4 @@ declare function assertExpiryWithinTechnicalLimit(expiresAt: Date | number, kind
|
|
|
4136
4145
|
declare const DEFAULT_SIGNED_READ_URL_EXPIRY_MS: number;
|
|
4137
4146
|
type ExpiryTier = keyof typeof EXPIRY;
|
|
4138
4147
|
|
|
4139
|
-
export { ACCOUNT_REGISTRY_PATH, ACCOUNT_REGISTRY_SPACE, type AbilitiesMap, type AccountApplication, type AccountApplicationListOptions, type AccountApplicationRegisterOptions, type AccountDelegation, type AccountDelegationListOptions, AccountDelegationPage, AccountDelegationQueryOptions, type AccountDelegationRevokeOptions, type AccountIndexEnsureResult, type AccountIndexRebuildResult, type AccountIndexStatus, type AccountIndexedReadOptions, AccountService, type AccountServiceConfig, type AccountSpace, type AccountSpaceListOptions, type AccountStatus, AutoApproveSpaceCreationHandler, type AutoRejectStrategy, type AutoSignStrategy, type Bytes, CREDENTIAL_ERROR_CODES, type CallbackStrategy, type CanonicalAddress, type CanonicalParsedNetworkId, type CanonicalTinyCloudIdentity, type CapabilityPresentationEnvelopeV1, CaveatedDelegationUnsupportedError, type CheckChangedExpirationInput, type ClassifyRegistryLookupOptions, type ClientSession, ClientSessionSchema, CloudLocationResolutionError, type ComposeManifestOptions, type ComposedManifestRequest, type CreateDelegationFunction, CreateDelegationParams, CredentialError, type CredentialErrorCode, CredentialFlowDescriptor, CredentialHolderBinding, CredentialIssuerMetadata, CredentialRequirement, CredentialStorageReceipt, DEFAULT_DEFAULTS, DEFAULT_EXPIRY, DEFAULT_KNOWLEDGE_ROOT, DEFAULT_LOCAL_NODE_PIN_STORAGE_KEY, DEFAULT_LOCAL_NODE_URL, DEFAULT_MANIFEST_SPACE, DEFAULT_MANIFEST_VERSION, DEFAULT_NEW_USER_HOST, DEFAULT_REGISTRY_CACHE_STORAGE_KEY, DEFAULT_REGISTRY_LOOKUP_TIMEOUT_MS, DEFAULT_REGISTRY_OWNER_CHAIN_ID, DEFAULT_REGISTRY_SEQUENCE_STORAGE_KEY, DEFAULT_SIGNED_READ_URL_EXPIRY_MS, DEFAULT_TINYCLOUD_FALLBACK_HOST, DEFAULT_TINYCLOUD_LOCATION_REGISTRY_URL, Delegation, DelegationManager, DelegationRevocationReceipt, type DidCacheKeyOptions, type DidEqualsOptions, type DiscoverLocalTinyCloudNodeOptions, type DiscoveredLocalTinyCloudNode, EMAIL_CREDENTIAL_MAX_AGE_SECONDS, EMAIL_DOMAIN_CREDENTIAL_MAX_AGE_SECONDS, ENCRYPTION_MANIFEST_SPACE, ENCRYPTION_PERMISSION_SERVICE, EXPIRY, type EnsData, EnsDataSchema, type EventEmitterStrategy, type ExpiryTier, type Extension, type FailClosedHostOptions, type FailClosedHosts, GenerateShareParams, ICapabilityKeyRegistry, type IENSResolver, type INotificationHandler, type ISessionManager, type ISessionStorage, ISharingService, type ISigner, type ISpace, type ISpaceCreationHandler, type ISpaceScopedDelegations, type ISpaceScopedSharing, type ISpaceService, type IUserAuthorization, type IWasmBindings, IdentityParseError, type ImmutableSiweFields, IssuedCredentialEnvelope, LOCAL_LINK_HOST_SUFFIX, LOCAL_LINK_PROBE_TIMEOUT_MS, LOCAL_LOOPBACK_PROBE_TIMEOUT_MS, type LocalNodeIdentityStore, type LocationCandidate, type LocationCandidateInput, type LocationRecord, type LocationRecordPayload, type LocationRecordSigner, type LocationRecordV2, type LocationRecordV2Payload, LocationRecordValidationError, LocationRegistryHttpError, type LocationResolutionAttempt, type LocationSource, type LookupOwnerRegistryVerdictOptions, MAX_SIWE_EXPIRY_MS, MAX_UCAN_EXPIRY_MS, type Manifest, type ManifestDefaults, type ManifestKnowledge, type ManifestRegistryRecord, type ManifestSecretActions, ManifestValidationError, type NodeInfo, type NodeNotFoundContext, type NodeNotFoundDecision, NodeNotFoundError, NodeRegistryEntryExistsError, OPENKEY_ACTION_ID_SEPARATOR, OWNER_NODE_BINDING_TIMEOUT_MS, type OnNodeNotFound, type OpenKeyCallbackStrategy, type OpenKeyManageKeyCallbackStrategy, OpenKeyManageKeyError, type OpenKeyManageKeyErrorCode, type OpenKeyManageKeyFetch, type OpenKeyManageKeySigningRequestBody, type OpenKeyManageKeySigningResponseBody, type OpenKeyManageKeySigningStrategyOptions, type OpenKeySigningRequestBody, type OpenKeySigningResponseBody, type OpenKeySigningStrategyOptions, type ParseRecapFromSiwe, type PartialSiweMessage, type PermissionEntry, PermissionNotInManifestError, type PersistedSessionData, type PersistedSessionProof, type PersistedTinyCloudSession, type PkhDidParts, ProtocolMismatchError, type PublishLocationRecordOptions, REGISTRY_CACHE_MAX_AGE_MS, REGISTRY_LOOKUP_MAX_BODY_BYTES, REGISTRY_NOT_FOUND_BODY, type RecapAttenuation, type RegisterBatchSuccess, type RegisteredRegistryVerdict, type RegistryCacheEntry, type RegistryCacheRecord, type RegistryCacheStore, type RegistryCacheTombstone, type RegistryFallbackReason, type RegistryHost, type RegistryHostSource, RegistryLookupInputError, type RegistryLookupInputErrorCode, type RegistryLookupResponse, type RegistryPolicy, type RegistrySequenceStore, RegistryUnavailableError, type RegistryUnavailableReason, type RegistryVerdict, type RegistryVerdictSource, type RegistryVerdictStatus, type ResolveCloudLocationOptions, type ResolveOwnerHostsOptions, type ResolveTinyCloudHostsOptions, type ResolvedCapabilities, type ResolvedCloudLocation, type ResolvedDelegate, type ResolvedTinyCloudHosts, type ResourceCapability, SECRETS_SPACE, SERVICE_LONG_TO_SHORT, SERVICE_SHORT_TO_LONG, type ServerHost, SessionExpiredError, ShareLink, type SignCallback, type SignInOptions, type SignRequest, type SignResponse, type SignStrategy, type SignedSiweCacao, SilentNotificationHandler, type SiweConfig, SiweConfigSchema, Space, type SpaceAbilitiesMap, type SpaceConfig, type SpaceCreationContext, type SpaceDelegationParams, type SpaceErrorCode, SpaceErrorCodes, type SpaceHostResult, SpaceInfo, SpaceService, type SpaceServiceConfig, StoredCredentialRecord, type SubsetCheckResult, TERMINAL_DELEGATION_FACT, TINYCLOUD_CANONICAL_IDENTITY_CLAIM, TINYCLOUD_MANAGE_KEY_SCOPE, type TechnicalExpiryKind, type TerminalDelegationSigningKey, TicketHolderBinding, TinyCloud, type TinyCloudAuthorizationRequestV1, type TinyCloudAuthorizationResultV1, type TinyCloudConfig, type TinyCloudEffectiveGrantV1, type TinyCloudSession, type UnavailableRegistryVerdict, type UnregisteredRegistryVerdict, UnsupportedFeatureError, type UserAuthorizationConfig, VAULT_PERMISSION_SERVICE, type ValidatedPersistedSessionProof, type ValidationError, VerifiedCredential, type VerifiedOwnerNodeBinding, type VerifyOwnerNodeBindingOptions, VersionCheckError, type WasmRecapEntry, type WebStorageLike, actionContains, activateSessionWithHost, addressStorageKey, applyPrefix, assertExpiryWithinTechnicalLimit, assertSpaceCreationAllowed, buildSpaceUri, canonicalDigest, canonicalLocationPayload, canonicalLocationPayloadV2, canonicalizeAddress, canonicalizeDid, canonicalizeDidUrl, canonicalizeNetworkId, canonicalizeRecapCaveats, checkChangedExpiration, checkNodeInfo, classifyRegistryLookup, composeManifestRequest, createEmailCredentialRequirement, createEmailDomainCredentialRequirement, createHolderBinding, createInMemoryLocalNodeIdentityStore, createInMemoryRegistryCacheStore, createInMemoryRegistrySequenceStore, createLocalStorageLocalNodeIdentityStore, createLocalStorageRegistryCacheStore, createLocalStorageRegistrySequenceStore, createOpenKeyCallbackSigningStrategy, createOpenKeyManageKeySigningStrategy, createSpaceService, createStorageReceipt, createStoredCredentialRecord, credentialEndpointPath, credentialError, credentialIndexKey, credentialMatchesRequirement, credentialRecordKey, credentialRequirementDigest, decodeBase64Url, defaultSignStrategy, defaultSpaceCreationHandler, descriptorSatisfiesRequirement, didCacheKey, didEquals, diffImmutableSiweFields, discoverLocalTinyCloudNode, encodeBase64Url, exactHttpOrigin, expandActionShortNames, expandDelegationPermissionEntries, expandPermissionEntries, expandPermissionEntry, expandRuntimePermissionEntries, extractImmutableSiweFields, extractRecapAttenuations, fetchLocationRecord, fetchPeerId, hasTinyCloudManageKeyScope, holderBindingCanonicalBytes, holderBindingSigningBytes, httpResponseError, httpUrlToMultiaddr, isCapabilitySubset, isDigest, isEvmAddress, isExplicitOnlyAction, isPlausibleOpenKeyActionId, loadManifest, locationPayloadForRecord, lookupOwnerRegistryVerdict, makePkhSpaceId, makePublicSpaceId, manifestAbilitiesUnion, markDelegationTerminal, multiaddrToHttpUrl, normalizeDefaults, parseCanonicalNetworkId, parseCanonicalRecapResource, parseCanonicalTinyCloudIdentity, parseCanonicalTinyCloudIdentityClaims, parseExpiry, parsePkhDid, parseRecapCapabilities, parseSignedSiweCacao, parseSpaceUri, pkhDid, principalDid, principalDidEquals, publishLocationRecord, recapCaveatsEqual, refreshOwnerRegistry, registryOwnerKeyV2, registryOwnerSubjectV1, requestTinyCloudManageKeyScope, resolveCloudLocation, resolveFailClosedTinyCloudHosts, resolveManifest, resolveManifestKnowledgeRoot, resolveOwnerHosts, resolveRegistryResource, resolveTinyCloudHosts, resourceCapabilitiesToAbilitiesMap, resourceCapabilitiesToSpaceAbilitiesMap, sha256Base64Url, signLocationRecord, signLocationRecordV2, submitHostDelegation, technicalExpiryRefusal, unauthorizedRecapCapabilities, validateAuthorizationResultV1, validateClientSession, validateCredentialFlowDescriptor, validateCredentialHolderBinding, validateCredentialRequirement, validateLocationRecord, validateLocationRecordPayload, validateLocationRecordV2, validateLocationRecordV2Payload, validateManifest, validatePersistedSessionData, verifyDidKeyEd25519Signature, verifyEip191MessageSignature, verifyIssuedCredential, verifyLocationRecord, verifyLocationRecordV2, verifyOwnerNodeBinding, verifyRegistryCacheEntry, verifyStorageReceipt, warnRegistryDefaultNode };
|
|
4148
|
+
export { ACCOUNT_REGISTRY_PATH, ACCOUNT_REGISTRY_SPACE, type AbilitiesMap, type AccountApplication, type AccountApplicationListOptions, type AccountApplicationRegisterOptions, type AccountDelegation, type AccountDelegationListOptions, AccountDelegationPage, AccountDelegationQueryOptions, type AccountDelegationRevokeOptions, type AccountIndexEnsureResult, type AccountIndexRebuildResult, type AccountIndexStatus, type AccountIndexedReadOptions, AccountService, type AccountServiceConfig, type AccountSpace, type AccountSpaceListOptions, type AccountStatus, AutoApproveSpaceCreationHandler, type AutoRejectStrategy, type AutoSignStrategy, type Bytes, CREDENTIAL_ERROR_CODES, type CallbackStrategy, type CanonicalAddress, type CanonicalParsedNetworkId, type CanonicalTinyCloudIdentity, type CapabilityPresentationEnvelopeV1, CaveatedDelegationUnsupportedError, type CheckChangedExpirationInput, type ClassifyRegistryLookupOptions, type ClientSession, ClientSessionSchema, CloudLocationResolutionError, type ComposeManifestOptions, type ComposedManifestRequest, type CreateDelegationFunction, CreateDelegationParams, CredentialError, type CredentialErrorCode, CredentialFlowDescriptor, CredentialHolderBinding, CredentialIssuerMetadata, CredentialRequirement, CredentialStorageReceipt, DEFAULT_DEFAULTS, DEFAULT_EXPIRY, DEFAULT_KNOWLEDGE_ROOT, DEFAULT_LOCAL_NODE_PIN_STORAGE_KEY, DEFAULT_LOCAL_NODE_URL, DEFAULT_MANIFEST_SPACE, DEFAULT_MANIFEST_VERSION, DEFAULT_NEW_USER_HOST, DEFAULT_REGISTRY_CACHE_STORAGE_KEY, DEFAULT_REGISTRY_LOOKUP_TIMEOUT_MS, DEFAULT_REGISTRY_OWNER_CHAIN_ID, DEFAULT_REGISTRY_SEQUENCE_STORAGE_KEY, DEFAULT_SIGNED_READ_URL_EXPIRY_MS, DEFAULT_TINYCLOUD_FALLBACK_HOST, DEFAULT_TINYCLOUD_LOCATION_REGISTRY_URL, Delegation, DelegationManager, DelegationRevocationReceipt, type DidCacheKeyOptions, type DidEqualsOptions, type DiscoverLocalTinyCloudNodeOptions, type DiscoveredLocalTinyCloudNode, EMAIL_CREDENTIAL_MAX_AGE_SECONDS, EMAIL_DOMAIN_CREDENTIAL_MAX_AGE_SECONDS, ENCRYPTION_MANIFEST_SPACE, ENCRYPTION_PERMISSION_SERVICE, EXPIRY, type EnsData, EnsDataSchema, type EventEmitterStrategy, type ExpiryTier, type Extension, type FailClosedHostOptions, type FailClosedHosts, GenerateShareParams, ICapabilityKeyRegistry, type IENSResolver, type INotificationHandler, type ISessionManager, type ISessionStorage, ISharingService, type ISigner, type ISpace, type ISpaceCreationHandler, type ISpaceScopedDelegations, type ISpaceScopedSharing, type ISpaceService, type IUserAuthorization, type IWasmBindings, IdentityParseError, type ImmutableSiweFields, IssuedCredentialEnvelope, LOCAL_LINK_HOST_SUFFIX, LOCAL_LINK_PROBE_TIMEOUT_MS, LOCAL_LOOPBACK_PROBE_TIMEOUT_MS, type LocalNodeIdentityStore, type LocationCandidate, type LocationCandidateInput, type LocationRecord, type LocationRecordPayload, type LocationRecordSigner, type LocationRecordV2, type LocationRecordV2Payload, LocationRecordValidationError, LocationRegistryHttpError, type LocationResolutionAttempt, type LocationSource, type LookupOwnerRegistryVerdictOptions, MAX_SIWE_EXPIRY_MS, MAX_UCAN_EXPIRY_MS, type Manifest, type ManifestDefaults, type ManifestKnowledge, type ManifestRegistryRecord, type ManifestSecretActions, ManifestValidationError, type NodeInfo, type NodeNotFoundContext, type NodeNotFoundDecision, NodeNotFoundError, NodeRegistryEntryExistsError, OPENKEY_ACTION_ID_SEPARATOR, OWNER_NODE_BINDING_TIMEOUT_MS, type OnNodeNotFound, type OpenKeyCallbackStrategy, type OpenKeyManageKeyCallbackStrategy, OpenKeyManageKeyError, type OpenKeyManageKeyErrorCode, type OpenKeyManageKeyFetch, type OpenKeyManageKeySigningRequestBody, type OpenKeyManageKeySigningResponseBody, type OpenKeyManageKeySigningStrategyOptions, type OpenKeySigningRequestBody, type OpenKeySigningResponseBody, type OpenKeySigningStrategyOptions, type ParseRecapFromSiwe, type PartialSiweMessage, type PermissionEntry, PermissionNotInManifestError, type PersistedSessionData, type PersistedSessionProof, type PersistedTinyCloudSession, type PkhDidParts, ProtocolMismatchError, type PublishLocationRecordOptions, REGISTRY_CACHE_MAX_AGE_MS, REGISTRY_LOOKUP_MAX_BODY_BYTES, REGISTRY_NOT_FOUND_BODY, type RecapAttenuation, type RegisterBatchSuccess, type RegisteredRegistryVerdict, type RegistryCacheEntry, type RegistryCacheRecord, type RegistryCacheStore, type RegistryCacheTombstone, type RegistryFallbackReason, type RegistryHost, type RegistryHostSource, RegistryLookupInputError, type RegistryLookupInputErrorCode, type RegistryLookupResponse, type RegistryPolicy, type RegistrySequenceStore, RegistryUnavailableError, type RegistryUnavailableReason, type RegistryVerdict, type RegistryVerdictSource, type RegistryVerdictStatus, type ResolveCloudLocationOptions, type ResolveOwnerHostsOptions, type ResolveTinyCloudHostsOptions, type ResolvedCapabilities, type ResolvedCloudLocation, type ResolvedDelegate, type ResolvedTinyCloudHosts, type ResourceCapability, SECRETS_SPACE, SERVICE_LONG_TO_SHORT, SERVICE_SHORT_TO_LONG, type ServerHost, SessionExpiredError, ShareLink, type SignCallback, type SignInOptions, type SignRequest, type SignResponse, type SignStrategy, type SignedSiweCacao, SilentNotificationHandler, type SiweConfig, SiweConfigSchema, Space, type SpaceAbilitiesMap, type SpaceConfig, type SpaceCreationContext, type SpaceDelegationParams, type SpaceErrorCode, SpaceErrorCodes, type SpaceHostResult, SpaceInfo, SpaceService, type SpaceServiceConfig, StoredCredentialRecord, type SubsetCheckResult, TERMINAL_DELEGATION_FACT, TINYCLOUD_CANONICAL_IDENTITY_CLAIM, TINYCLOUD_MANAGE_KEY_SCOPE, type TechnicalExpiryKind, type TerminalDelegationSigningKey, TicketHolderBinding, TinyCloud, type TinyCloudAuthorizationRequestV1, type TinyCloudAuthorizationResultV1, type TinyCloudConfig, type TinyCloudEffectiveGrantV1, type TinyCloudSession, type UnavailableRegistryVerdict, type UnregisteredRegistryVerdict, UnsupportedFeatureError, type UserAuthorizationConfig, VAULT_PERMISSION_SERVICE, type ValidatedPersistedSessionProof, type ValidationError, VerifiedCredential, type VerifiedOwnerNodeBinding, type VerifyOwnerNodeBindingOptions, VersionCheckError, type WasmRecapEntry, type WebStorageLike, actionContains, activateSessionWithHost, addressStorageKey, applyPrefix, assertExpiryWithinTechnicalLimit, assertSpaceCreationAllowed, buildSpaceUri, canonicalDigest, canonicalLocationPayload, canonicalLocationPayloadV2, canonicalizeAddress, canonicalizeDid, canonicalizeDidUrl, canonicalizeNetworkId, canonicalizeRecapCaveats, checkChangedExpiration, checkNodeInfo, classifyRegistryLookup, composeManifestRequest, createEmailCredentialRequirement, createEmailDomainCredentialRequirement, createHolderBinding, createInMemoryLocalNodeIdentityStore, createInMemoryRegistryCacheStore, createInMemoryRegistrySequenceStore, createLocalStorageLocalNodeIdentityStore, createLocalStorageRegistryCacheStore, createLocalStorageRegistrySequenceStore, createOpenKeyCallbackSigningStrategy, createOpenKeyManageKeySigningStrategy, createSpaceService, createStorageReceipt, createStoredCredentialRecord, credentialEndpointPath, credentialError, credentialIndexKey, credentialMatchesRequirement, credentialRecordKey, credentialRequirementDigest, decodeBase64Url, defaultSignStrategy, defaultSpaceCreationHandler, descriptorSatisfiesRequirement, didCacheKey, didEquals, diffImmutableSiweFields, discoverLocalTinyCloudNode, encodeBase64Url, exactHttpOrigin, expandActionShortNames, expandDelegationPermissionEntries, expandPermissionEntries, expandPermissionEntry, expandRuntimePermissionEntries, extractImmutableSiweFields, extractRecapAttenuations, fetchLocationRecord, fetchPeerId, hasTinyCloudManageKeyScope, holderBindingCanonicalBytes, holderBindingSigningBytes, httpResponseError, httpUrlToMultiaddr, isCapabilitySubset, isDigest, isEvmAddress, isExplicitOnlyAction, isPlausibleOpenKeyActionId, loadManifest, locationPayloadForRecord, lookupOwnerRegistryVerdict, makePkhSpaceId, makePublicSpaceId, manifestAbilitiesUnion, markDelegationTerminal, multiaddrToHttpUrl, normalizeDefaults, parseCanonicalNetworkId, parseCanonicalRecapResource, parseCanonicalTinyCloudIdentity, parseCanonicalTinyCloudIdentityClaims, parseExpiry, parsePkhDid, parseRecapCapabilities, parseSignedSiweCacao, parseSpaceUri, pkhDid, principalDid, principalDidEquals, publicJwk, publishLocationRecord, recapCaveatsEqual, refreshOwnerRegistry, registryOwnerKeyV2, registryOwnerSubjectV1, requestTinyCloudManageKeyScope, resolveCloudLocation, resolveFailClosedTinyCloudHosts, resolveManifest, resolveManifestKnowledgeRoot, resolveOwnerHosts, resolveRegistryResource, resolveTinyCloudHosts, resourceCapabilitiesToAbilitiesMap, resourceCapabilitiesToSpaceAbilitiesMap, sha256Base64Url, signLocationRecord, signLocationRecordV2, submitHostDelegation, technicalExpiryRefusal, unauthorizedRecapCapabilities, validateAuthorizationResultV1, validateClientSession, validateCredentialFlowDescriptor, validateCredentialHolderBinding, validateCredentialRequirement, validateLocationRecord, validateLocationRecordPayload, validateLocationRecordV2, validateLocationRecordV2Payload, validateManifest, validatePersistedSessionData, verifyDidKeyEd25519Signature, verifyEip191MessageSignature, verifyIssuedCredential, verifyLocationRecord, verifyLocationRecordV2, verifyOwnerNodeBinding, verifyRegistryCacheEntry, verifyStorageReceipt, warnRegistryDefaultNode };
|
package/dist/index.d.ts
CHANGED
|
@@ -5,10 +5,10 @@ export { canonicalEmailDomain, canonicalMailbox, isCanonicalEmailDomain, mailbox
|
|
|
5
5
|
import { InvokeFunction, InvokeAnyFunction, ParsedNetworkId, ServiceError, Result, FetchFunction, ServiceConstructor, RetryPolicy, TelemetryConfig, IServiceContext, IService, IKVService, ISQLService, IDuckDbService, IHooksService, IDataVaultService, IEncryptionService, ISecretsService, ServiceSession, IDatabaseHandle, SqlValue, QueryResponse } from '@tinycloud/sdk-services';
|
|
6
6
|
export { AuthorityRefusal, AuthorizationVerdict, BatchOptions, BatchResponse, BuildCanonicalDecryptRequestInput, BuildDecryptFactsInput, BuildDecryptInvocationInput, BuiltDecryptInvocation, CanonicalDecryptRequest, CanonicalJson, ColumnInfo, DECRYPT_ACTION, DECRYPT_FACT_TYPE, DECRYPT_RESULT_TYPE, DEFAULT_ENCRYPTION_ALG, DEFAULT_KEY_VERSION, DataVaultConfig, DataVaultService, DatabaseHandle, DecryptCapabilityProof, DecryptEnvelopeOptions, DecryptInvocationFact, DecryptInvocationSigner, DecryptRequestBody, DecryptResponseBody, DecryptTransport, DecryptTransportResponseError, DiscoverNetworkInput, DiscoveredNetwork, DiscoverySource, DuckDbAction, DuckDbActionType, DuckDbBatchOptions, DuckDbBatchResponse, DuckDbDatabaseHandle, DuckDbExecuteOptions, DuckDbExecuteResponse, DuckDbOptions, DuckDbQueryOptions, DuckDbQueryResponse, DuckDbService, DuckDbServiceConfig, DuckDbStatement, DuckDbValue, ENCRYPTION_NETWORK_URN_PREFIX, ENCRYPTION_SERVICE, ENCRYPTION_SERVICE_SHORT, ENVELOPE_VERSION, EncryptToNetworkInput, EncryptToNetworkOptions, EncryptToNetworkResult, EncryptionCrypto, EncryptionError, EncryptionErrorInput, EncryptionService, EncryptionServiceConfig, ErrorCode, ErrorCodes, ExecuteOptions, ExecuteResponse, FetchFunction, HookEvent, HookServiceName, HookStreamEvent, HookSubscription, HookWebhookListOptions, HookWebhookRecord, HookWebhookRegistration, HookWebhookScope, HookWebhookUnregisterOptions, HooksService, HooksServiceConfig, IDataVaultService, IDatabaseHandle, IDuckDbDatabaseHandle, IDuckDbService, IEncryptionService, IHooksService, IKVService, IPrefixedKVService, ISQLService, ISecretsService, IService, IServiceContext, IStorageService, InlineEncryptedEnvelope, InvokeAnyEntry, InvokeAnyFunction, InvokeFunction, KVBatchReadResponse, KVChange, KVChangesAuthority, KVChangesOptions, KVChangesResponse, KVCreateSignedReadUrlOptions, KVDeleteOptions, KVGetOptions, KVHeadOptions, KVListOptions, KVListPage, KVListResponse, KVPutOptions, KVReadThrough, KVReplicaHandle, KVReplicaSpec, KVReplicaStorage, KVReplicationController, KVReplicationDeps, KVResponse, KVResponseHeaders, KVService, KVServiceConfig, KVSignedReadUrlResponse, LocalGetResult, LocalListResult, LocalReadMeta, LocalReplicaStatus, LocalSyncResult, MAX_SECRET_SCOPE_LENGTH, NETWORK_NAME_PATTERN, NetworkDescriptor, NetworkIdError, NodeDescriptorFetcher, ParsedNetworkId, ParsedSecretCatalogKey, PendingWriteRecord, PendingWriteState, PendingWriteStore, PinnedKey, PrefixedKVService, PurgeTarget, QueryOptions, QueryResponse, RandomReceiverKeyInput, ReceiverKeyPair, ReceiverKeySigner, ReplicaAuthorityState, ReplicaCoverage, ReplicaDevice, ReplicaGatedHandle, ReplicaGrantInfo, ReplicaInspectedStatus, ReplicaLocalEraseOutcome, ReplicaPurgeError, ReplicaPurgeFailedEvent, ReplicaPurgeLocalCopyResult, ReplicaPurgeTrigger, ReplicaState, ReplicaStatusEntry, ReplicationAuthority, ReplicationControl, ReplicationEvent, ReplicationIdentity, ReplicationOptions, ReplicationPurgeReport, ReplicationReason, ReplicationScheduler, ResolvedReplicationOptions, ResolvedSecretPath, Result, RetryPolicy, SECRET_NAME_RE, SECRET_SCOPE_RE, SQLAction, SQLActionType, SQLService, SQLServiceConfig, STORAGE_FULL_MESSAGE, STORAGE_MANAGE_URL, STORAGE_NEARLY_FULL_RATIO, STORAGE_WRITE_TOO_LARGE_MESSAGE, SchemaInfo, SecretCatalogEntry, SecretPayload, SecretPutOptions, SecretScopeOptions, SecretsError, SecretsService, ServiceContext, ServiceContextConfig, ServiceError, ServiceSession, SignedReceiverKeyInput, SqlStatement, SqlValue, StorageAccountUsage, StorageFullEvent, StorageFullHandler, StorageFullMonitor, StorageRejectionDetails, StorageStatus, StorageStatusOptions, StorageUsage, StorageUsageState, SubscribeOptions, TC832_RESERVED_SCOPES, TableInfo, TelemetryConfig, TelemetryEventHandler, TinyCloudDebugEnableOptions, TinyCloudDebugEvent, TinyCloudDebugLevel, TinyCloudDebugLogger, TinyCloudDebugTimer, VaultCrypto, VaultEntry, VaultError, VaultGetOptions, VaultGrantOptions, VaultHeaders, VaultListOptions, VaultNetworkReadResult, VaultPublicSpaceKVActions, VaultPutOptions, VerifyDecryptResponseInput, ViewInfo, WasmVaultFunctions, WellKnownDescriptorFetcher, appSecretScope, authorizationVerdictOf, buildCanonicalDecryptRequest, buildDecryptAttenuation, buildDecryptFacts, buildDecryptInvocation, buildNetworkId, canonicalHashHex, canonicalSignedResponse, canonicalizeEncryptionJson, canonicalizeSecretScope, checkDecryptInvocationInput, clearTinyCloudDebugLogs, createVaultCrypto, decryptEnvelopeWithKey, defaultRetryPolicy, deriveSignedReceiverKey, disableTinyCloudDebug, discoverNetwork, enableTinyCloudDebug, encryptToNetwork, base64Decode as encryptionBase64Decode, base64Encode as encryptionBase64Encode, encryptionError, utf8Decode as encryptionUtf8Decode, utf8Encode as encryptionUtf8Encode, ensureNetworkUsableForDecrypt, err, generateRandomReceiverKey, getTinyCloudDebugLogs, hexDecode, hexEncode, installTinyCloudDebugGlobals, isNetworkId, isStorageFullError, networkDiscoveryKey, ok, openWrappedKey, parseCapabilityResource, parseNetworkId, parseSecretCatalogKey, parseStorageRejection, parseStorageStatus, resolveSecretListPrefix, resolveSecretPath, serviceError, storageUsageState, tinyCloudDebugLogger, validateEnvelope, validatedCapabilityOf, verifyDecryptResponse } from '@tinycloud/sdk-services';
|
|
7
7
|
export { HOLDER_KEY_BINDING_PRESENTATION_SCHEMA, HolderKeyBindingPresentation, LISTEN_SQL_STATEMENT_CATALOG, ListenSqlStatementName, POLICY_ENGINE_CHALLENGE_REQUEST_SCHEMA, POLICY_ENGINE_CHALLENGE_RESPONSE_SCHEMA, POLICY_ENGINE_DENIAL_SCHEMA, POLICY_ENGINE_GRANT_PRESENTATION_DENIAL_CODES, POLICY_ENGINE_RESOLVE_REQUEST_SCHEMA, PORTABLE_DELEGATION_SCHEMA, PolicyEngineGrantPresentationDenialCode, PortableDelegation, REQUESTER_ENGINE_RETRY_ATTEMPTS, REQUESTER_ENGINE_RETRY_MAX_DELAY_MS, REQUESTER_NEAR_EXPIRY_SECONDS, RequesterEndpointResolution, RequesterHttpRequest, RequesterHttpResponse, RequesterInvocationCapability, RequesterSigningCapability, RequesterTransport, TranscriptRequester, TranscriptRequesterError, TranscriptRequesterErrorCode, TranscriptRequesterErrorState, TranscriptRequesterOptions, TranscriptRequesterReadKvResult, TranscriptRequesterReadSqlResult, createTranscriptRequester, deriveDelegationCid, parseNodeNativePortableDelegation } from './requester/index.js';
|
|
8
|
-
import { h as Delegation, d as CreateDelegationParams, G as GenerateShareParams, v as ShareLink, y as SpaceInfo, a as AccountDelegationQueryOptions, A as AccountDelegationPage, r as DelegationRevocationReceipt } from './types.schema-
|
|
9
|
-
export { b as AccountDelegationRecord, c as AccountDelegationResource, C as CapabilityEntry, e as CreateDelegationWasmParams, f as CreateDelegationWasmResult, g as DelegatedResource, i as DelegationApiResponse, j as DelegationChain, k as DelegationChainV2, l as DelegationDirection, D as DelegationError, m as DelegationErrorCode, n as DelegationErrorCodes, o as DelegationFilters, p as DelegationManagerConfig, q as DelegationRecord, R as DelegationResult, s as DelegationStatus, I as IngestOptions, J as JWK, K as KeyInfo, t as KeyProvider, u as KeyType, S as SessionInvocationSigner, w as ShareLinkData, x as ShareSchema, z as SpaceOwnership } from './types.schema-
|
|
10
|
-
import { I as ICapabilityKeyRegistry, h as ISharingService, f as DelegationManager } from './recipient-types.schema
|
|
11
|
-
export { C as CREDENTIAL_INVITATION_REQUEST_DOMAIN, bl as CapabilityKeyRegistry, bm as CapabilityKeyRegistryErrorCode, bn as CapabilityKeyRegistryErrorCodes, a as CreateOwnerDelegationParams, b as CredentialInvitationRequest, D as DELIVERY_ADMISSION_DOMAIN, c as DelegateReceivedShareParams, d as DelegatedShareAccess, e as DelegatedShareKey, g as DeliveryAdmission, E as EncodedShareData, M as MAX_CONTENT_BYTES, i as MAX_SEALED_SHARE_CONTENT_BYTES, j as MAX_SHARE_ARTIFACT_BYTES, k as MAX_SHARE_CONTENT_BYTES, l as MemorySenderShareKeyStorage, m as MemorySenderShareRecordStorage, n as MemoryShareCache, O as OwnerDelegationPermission, o as OwnerDelegationReceipt, p as OwnerShareAction, q as OwnerShareDecryption, r as OwnerShareMatcher, s as OwnerSharePolicyRegistration, t as OwnerSharePolicyRegistrationReceipt, u as OwnerSharePolicyV2, P as PortableDelegationImportReceipt, R as ReceiveOptions, v as RegisterOwnerSharePolicyParams, S as SenderShareKeyStorage, w as SenderShareRecord, x as SenderShareRecordStorage, y as SenderShareRevocationScope, z as SenderShareStore, A as ShareAccess, B as ShareAccessError, F as ShareAccessV2, G as ShareAction, J as ShareAddressedDelegationEnvelopeV2, K as ShareAddressedDelegationEnvelopeV2Schema, L as ShareAddressedDelegationRequestV2, N as ShareAddressedDelegationRequestV2Schema, Q as ShareAddressedDelegationResponseV2, T as ShareAddressedDelegationResponseV2Schema, U as ShareAddressedRecipientMatcher, V as ShareArtifactInput, W as ShareArtifactResult, X as ShareArtifactV2, Y as ShareCache, Z as ShareCacheEntry, _ as ShareCacheKey, $ as ShareCacheMetadata, a0 as ShareCapabilityLike, a1 as ShareConflict, a2 as ShareContentMetadata, a3 as ShareContentSource, a4 as ShareDelegationPreflight, a5 as ShareDeliveryAuthorizationV3Receipt, a6 as ShareDeliveryAuthorizationV3Request, a7 as ShareDeliveryRefusedError, a8 as ShareDetachedProof, a9 as ShareEnvelopeError, aa as ShareEnvelopeV2, ab as ShareExpiryBounds, ac as ShareKvContentSource, ad as ShareLinkLocation, ae as ShareListEntry, af as ShareListResult, ag as ShareNativeAction, ah as ShareNativeInvokeEnvelopeV1, ai as ShareNativeInvokeErrorResult, aj as ShareNativeInvokeInput, ak as ShareNativeInvokeResult, al as ShareNativeInvokeSuccessResult, am as ShareNativeResponse, an as ShareNativeResponseSchema, ao as SharePolicy, ap as SharePolicyBinding, aq as SharePolicySession, ar as SharePolicySessionV1, as as SharePolicySessionWireV1, at as SharePortableDelegation, au as ShareReadInvocationV1, av as ShareReadResult, aw as ShareRecipientClient, ax as ShareRecipientClientOptions, az as ShareRecipientPolicy, aB as ShareRecipientResult, aC as ShareRecipientTarget, aE as ShareResource, aG as ShareSaveOptions, aH as ShareSqlContentSource, aI as ShareWireAction, aJ as SharingService, aK as SharingServiceConfig, aL as SignedDelegation, bo as StoredDelegationChain, aM as VerifyShareEnvelopeOptions, aN as canonicalOwnerSharePolicy, aO as computeOwnerShareRegistrationCid, aP as computeShareCid, bp as createCapabilityKeyRegistry, aQ as createDelegatedShareKey, aR as createPolicyEnforcementDelegation, aS as createShareArtifact, aT as createShareArtifactAsync, aU as createSharePolicy, aV as createSharingService, aW as decryptShareBytesAsync, aX as delegatePortablePolicySession, aY as encodeInlineShareUrl, aZ as encodeShareArtifact, a_ as encodeShareUrl, a$ as encryptShareBytes, b0 as encryptShareBytesAsync, b1 as importPortableDelegation, b2 as intersectShareCapabilities, b3 as isV2ShareLink, b4 as normalizeShareActions, b5 as normalizeShareRecipientTarget, b6 as normalizeShareResource, b7 as parsePortableDelegation, b8 as parseShareArtifact, b9 as parseShareUrl, ba as restoreDelegatedShareKey, bb as serializePortableDelegation, bc as shareCapabilityAllows, bd as shortDeliveryLinkBodyCid, be as signShareEnvelope, bf as validateOwnerSharePolicyRegistration, bg as validateOwnerSharePolicyRegistrationBytes, bh as verifyShareCid, bi as verifyShareDeliveryAuthorizationV3Bytes, bj as verifyShareEnvelope, bk as withoutShareLink } from './recipient-types.schema
|
|
8
|
+
import { h as Delegation, d as CreateDelegationParams, G as GenerateShareParams, v as ShareLink, y as SpaceInfo, a as AccountDelegationQueryOptions, A as AccountDelegationPage, r as DelegationRevocationReceipt } from './types.schema-B0ZUx7Ss.js';
|
|
9
|
+
export { b as AccountDelegationRecord, c as AccountDelegationResource, C as CapabilityEntry, e as CreateDelegationWasmParams, f as CreateDelegationWasmResult, g as DelegatedResource, i as DelegationApiResponse, j as DelegationChain, k as DelegationChainV2, l as DelegationDirection, D as DelegationError, m as DelegationErrorCode, n as DelegationErrorCodes, o as DelegationFilters, p as DelegationManagerConfig, q as DelegationRecord, R as DelegationResult, s as DelegationStatus, I as IngestOptions, J as JWK, K as KeyInfo, t as KeyProvider, u as KeyType, S as SessionInvocationSigner, w as ShareLinkData, x as ShareSchema, z as SpaceOwnership } from './types.schema-B0ZUx7Ss.js';
|
|
10
|
+
import { I as ICapabilityKeyRegistry, h as ISharingService, f as DelegationManager } from './recipient-types.schema--5j8kRNE.js';
|
|
11
|
+
export { C as CREDENTIAL_INVITATION_REQUEST_DOMAIN, bl as CapabilityKeyRegistry, bm as CapabilityKeyRegistryErrorCode, bn as CapabilityKeyRegistryErrorCodes, a as CreateOwnerDelegationParams, b as CredentialInvitationRequest, D as DELIVERY_ADMISSION_DOMAIN, c as DelegateReceivedShareParams, d as DelegatedShareAccess, e as DelegatedShareKey, g as DeliveryAdmission, E as EncodedShareData, M as MAX_CONTENT_BYTES, i as MAX_SEALED_SHARE_CONTENT_BYTES, j as MAX_SHARE_ARTIFACT_BYTES, k as MAX_SHARE_CONTENT_BYTES, l as MemorySenderShareKeyStorage, m as MemorySenderShareRecordStorage, n as MemoryShareCache, O as OwnerDelegationPermission, o as OwnerDelegationReceipt, p as OwnerShareAction, q as OwnerShareDecryption, r as OwnerShareMatcher, s as OwnerSharePolicyRegistration, t as OwnerSharePolicyRegistrationReceipt, u as OwnerSharePolicyV2, P as PortableDelegationImportReceipt, R as ReceiveOptions, v as RegisterOwnerSharePolicyParams, S as SenderShareKeyStorage, w as SenderShareRecord, x as SenderShareRecordStorage, y as SenderShareRevocationScope, z as SenderShareStore, A as ShareAccess, B as ShareAccessError, F as ShareAccessV2, G as ShareAction, J as ShareAddressedDelegationEnvelopeV2, K as ShareAddressedDelegationEnvelopeV2Schema, L as ShareAddressedDelegationRequestV2, N as ShareAddressedDelegationRequestV2Schema, Q as ShareAddressedDelegationResponseV2, T as ShareAddressedDelegationResponseV2Schema, U as ShareAddressedRecipientMatcher, V as ShareArtifactInput, W as ShareArtifactResult, X as ShareArtifactV2, Y as ShareCache, Z as ShareCacheEntry, _ as ShareCacheKey, $ as ShareCacheMetadata, a0 as ShareCapabilityLike, a1 as ShareConflict, a2 as ShareContentMetadata, a3 as ShareContentSource, a4 as ShareDelegationPreflight, a5 as ShareDeliveryAuthorizationV3Receipt, a6 as ShareDeliveryAuthorizationV3Request, a7 as ShareDeliveryRefusedError, a8 as ShareDetachedProof, a9 as ShareEnvelopeError, aa as ShareEnvelopeV2, ab as ShareExpiryBounds, ac as ShareKvContentSource, ad as ShareLinkLocation, ae as ShareListEntry, af as ShareListResult, ag as ShareNativeAction, ah as ShareNativeInvokeEnvelopeV1, ai as ShareNativeInvokeErrorResult, aj as ShareNativeInvokeInput, ak as ShareNativeInvokeResult, al as ShareNativeInvokeSuccessResult, am as ShareNativeResponse, an as ShareNativeResponseSchema, ao as SharePolicy, ap as SharePolicyBinding, aq as SharePolicySession, ar as SharePolicySessionV1, as as SharePolicySessionWireV1, at as SharePortableDelegation, au as ShareReadInvocationV1, av as ShareReadResult, aw as ShareRecipientClient, ax as ShareRecipientClientOptions, az as ShareRecipientPolicy, aB as ShareRecipientResult, aC as ShareRecipientTarget, aE as ShareResource, aG as ShareSaveOptions, aH as ShareSqlContentSource, aI as ShareWireAction, aJ as SharingService, aK as SharingServiceConfig, aL as SignedDelegation, bo as StoredDelegationChain, aM as VerifyShareEnvelopeOptions, aN as canonicalOwnerSharePolicy, aO as computeOwnerShareRegistrationCid, aP as computeShareCid, bp as createCapabilityKeyRegistry, aQ as createDelegatedShareKey, aR as createPolicyEnforcementDelegation, aS as createShareArtifact, aT as createShareArtifactAsync, aU as createSharePolicy, aV as createSharingService, aW as decryptShareBytesAsync, aX as delegatePortablePolicySession, aY as encodeInlineShareUrl, aZ as encodeShareArtifact, a_ as encodeShareUrl, a$ as encryptShareBytes, b0 as encryptShareBytesAsync, b1 as importPortableDelegation, b2 as intersectShareCapabilities, b3 as isV2ShareLink, b4 as normalizeShareActions, b5 as normalizeShareRecipientTarget, b6 as normalizeShareResource, b7 as parsePortableDelegation, b8 as parseShareArtifact, b9 as parseShareUrl, ba as restoreDelegatedShareKey, bb as serializePortableDelegation, bc as shareCapabilityAllows, bd as shortDeliveryLinkBodyCid, be as signShareEnvelope, bf as validateOwnerSharePolicyRegistration, bg as validateOwnerSharePolicyRegistrationBytes, bh as verifyShareCid, bi as verifyShareDeliveryAuthorizationV3Bytes, bj as verifyShareEnvelope, bk as withoutShareLink } from './recipient-types.schema--5j8kRNE.js';
|
|
12
12
|
export { ACCOUNT_INDEX_SCHEMA, ACCOUNT_MANIFEST_PERMISSIONS, AGENTS_SPACE, BOOTSTRAP_ALLOWLIST, BOOTSTRAP_DEFAULT_ONLY_SESSION_REQUEST, BOOTSTRAP_DEFAULT_SPACE, BOOTSTRAP_ENCRYPTION_NETWORK_NAME, BOOTSTRAP_ENCRYPTION_NETWORK_RESOURCE_TEMPLATE, BOOTSTRAP_MANIFEST, BOOTSTRAP_PERSISTED_APPLICATION_MANIFESTS, BOOTSTRAP_PUBLIC_SPACE, BOOTSTRAP_SESSION_REQUESTS, BOOTSTRAP_SPACE_MANIFESTS, BOOTSTRAP_SPACE_NAMES, BootstrapAllowlistEntry, BootstrapAllowlistKind, BootstrapEncryptionNetworkStep, BootstrapManifest, BootstrapRawAbilityAllowlistEntry, BootstrapSchemaStep, BootstrapSeedApplicationsStep, BootstrapSeedSpacesStep, BootstrapSpaceDescriptor, BootstrapSpaceName, BootstrapSpaceStep, BootstrapStep, BootstrapStepKind, CAPABILITIES, CAPABILITY_REGISTRY, CapabilityRegistryEntry, CapabilityStatus, DUCKDB, ENCRYPTION, HOOKS, KV, SECRET_RECORDS_SCHEMA, SPACE, SQL, TINYCLOUD_ACCOUNT_SPACE_MANIFEST, TINYCLOUD_AGENTS_SPACE_MANIFEST, TINYCLOUD_APPLICATIONS_SPACE_MANIFEST, TINYCLOUD_DEFAULT_SPACE_MANIFEST, TINYCLOUD_PUBLIC_SPACE_MANIFEST, TINYCLOUD_SECRETS_BOOTSTRAP_MANIFEST, bootstrapEncryptionNetworkId, bootstrapSpaceId, bootstrapSteps, composeBootstrapSpaceManifest } from '@tinycloud/bootstrap';
|
|
13
13
|
export { a as JsonValue, j as jcsCanonicalize, n as normalizeJson, s as serializeJcsJson } from './capability-BjzXwtNw.js';
|
|
14
14
|
export { SiweMessage } from 'siwe';
|
|
@@ -1073,6 +1073,15 @@ declare function principalDidEquals(a: string, b: string): boolean;
|
|
|
1073
1073
|
declare function didCacheKey(input: string, options?: DidCacheKeyOptions): string;
|
|
1074
1074
|
declare function makePkhSpaceId(address: string, chainId: number, name: string): string;
|
|
1075
1075
|
|
|
1076
|
+
/**
|
|
1077
|
+
* The public key of `jwk`: only the standard public members of its key type, plus `kid` when it is a string, are
|
|
1078
|
+
* copied, so private members and anything else (`alg`, `use`, unknown fields) are dropped. Use it for every JWK that
|
|
1079
|
+
* leaves the device.
|
|
1080
|
+
*
|
|
1081
|
+
* Throws for a key type without a public form (`oct`, unknown) or a missing public member.
|
|
1082
|
+
*/
|
|
1083
|
+
declare function publicJwk(jwk: unknown): Record<string, string>;
|
|
1084
|
+
|
|
1076
1085
|
type ReCapAttenuation = Readonly<Record<string, Readonly<Record<string, readonly unknown[]>>>>;
|
|
1077
1086
|
/** A wallet-signed SIWE CACAO whose encoding, signature and exact-bytes CID were verified. */
|
|
1078
1087
|
interface SignedSiweCacao {
|
|
@@ -4136,4 +4145,4 @@ declare function assertExpiryWithinTechnicalLimit(expiresAt: Date | number, kind
|
|
|
4136
4145
|
declare const DEFAULT_SIGNED_READ_URL_EXPIRY_MS: number;
|
|
4137
4146
|
type ExpiryTier = keyof typeof EXPIRY;
|
|
4138
4147
|
|
|
4139
|
-
export { ACCOUNT_REGISTRY_PATH, ACCOUNT_REGISTRY_SPACE, type AbilitiesMap, type AccountApplication, type AccountApplicationListOptions, type AccountApplicationRegisterOptions, type AccountDelegation, type AccountDelegationListOptions, AccountDelegationPage, AccountDelegationQueryOptions, type AccountDelegationRevokeOptions, type AccountIndexEnsureResult, type AccountIndexRebuildResult, type AccountIndexStatus, type AccountIndexedReadOptions, AccountService, type AccountServiceConfig, type AccountSpace, type AccountSpaceListOptions, type AccountStatus, AutoApproveSpaceCreationHandler, type AutoRejectStrategy, type AutoSignStrategy, type Bytes, CREDENTIAL_ERROR_CODES, type CallbackStrategy, type CanonicalAddress, type CanonicalParsedNetworkId, type CanonicalTinyCloudIdentity, type CapabilityPresentationEnvelopeV1, CaveatedDelegationUnsupportedError, type CheckChangedExpirationInput, type ClassifyRegistryLookupOptions, type ClientSession, ClientSessionSchema, CloudLocationResolutionError, type ComposeManifestOptions, type ComposedManifestRequest, type CreateDelegationFunction, CreateDelegationParams, CredentialError, type CredentialErrorCode, CredentialFlowDescriptor, CredentialHolderBinding, CredentialIssuerMetadata, CredentialRequirement, CredentialStorageReceipt, DEFAULT_DEFAULTS, DEFAULT_EXPIRY, DEFAULT_KNOWLEDGE_ROOT, DEFAULT_LOCAL_NODE_PIN_STORAGE_KEY, DEFAULT_LOCAL_NODE_URL, DEFAULT_MANIFEST_SPACE, DEFAULT_MANIFEST_VERSION, DEFAULT_NEW_USER_HOST, DEFAULT_REGISTRY_CACHE_STORAGE_KEY, DEFAULT_REGISTRY_LOOKUP_TIMEOUT_MS, DEFAULT_REGISTRY_OWNER_CHAIN_ID, DEFAULT_REGISTRY_SEQUENCE_STORAGE_KEY, DEFAULT_SIGNED_READ_URL_EXPIRY_MS, DEFAULT_TINYCLOUD_FALLBACK_HOST, DEFAULT_TINYCLOUD_LOCATION_REGISTRY_URL, Delegation, DelegationManager, DelegationRevocationReceipt, type DidCacheKeyOptions, type DidEqualsOptions, type DiscoverLocalTinyCloudNodeOptions, type DiscoveredLocalTinyCloudNode, EMAIL_CREDENTIAL_MAX_AGE_SECONDS, EMAIL_DOMAIN_CREDENTIAL_MAX_AGE_SECONDS, ENCRYPTION_MANIFEST_SPACE, ENCRYPTION_PERMISSION_SERVICE, EXPIRY, type EnsData, EnsDataSchema, type EventEmitterStrategy, type ExpiryTier, type Extension, type FailClosedHostOptions, type FailClosedHosts, GenerateShareParams, ICapabilityKeyRegistry, type IENSResolver, type INotificationHandler, type ISessionManager, type ISessionStorage, ISharingService, type ISigner, type ISpace, type ISpaceCreationHandler, type ISpaceScopedDelegations, type ISpaceScopedSharing, type ISpaceService, type IUserAuthorization, type IWasmBindings, IdentityParseError, type ImmutableSiweFields, IssuedCredentialEnvelope, LOCAL_LINK_HOST_SUFFIX, LOCAL_LINK_PROBE_TIMEOUT_MS, LOCAL_LOOPBACK_PROBE_TIMEOUT_MS, type LocalNodeIdentityStore, type LocationCandidate, type LocationCandidateInput, type LocationRecord, type LocationRecordPayload, type LocationRecordSigner, type LocationRecordV2, type LocationRecordV2Payload, LocationRecordValidationError, LocationRegistryHttpError, type LocationResolutionAttempt, type LocationSource, type LookupOwnerRegistryVerdictOptions, MAX_SIWE_EXPIRY_MS, MAX_UCAN_EXPIRY_MS, type Manifest, type ManifestDefaults, type ManifestKnowledge, type ManifestRegistryRecord, type ManifestSecretActions, ManifestValidationError, type NodeInfo, type NodeNotFoundContext, type NodeNotFoundDecision, NodeNotFoundError, NodeRegistryEntryExistsError, OPENKEY_ACTION_ID_SEPARATOR, OWNER_NODE_BINDING_TIMEOUT_MS, type OnNodeNotFound, type OpenKeyCallbackStrategy, type OpenKeyManageKeyCallbackStrategy, OpenKeyManageKeyError, type OpenKeyManageKeyErrorCode, type OpenKeyManageKeyFetch, type OpenKeyManageKeySigningRequestBody, type OpenKeyManageKeySigningResponseBody, type OpenKeyManageKeySigningStrategyOptions, type OpenKeySigningRequestBody, type OpenKeySigningResponseBody, type OpenKeySigningStrategyOptions, type ParseRecapFromSiwe, type PartialSiweMessage, type PermissionEntry, PermissionNotInManifestError, type PersistedSessionData, type PersistedSessionProof, type PersistedTinyCloudSession, type PkhDidParts, ProtocolMismatchError, type PublishLocationRecordOptions, REGISTRY_CACHE_MAX_AGE_MS, REGISTRY_LOOKUP_MAX_BODY_BYTES, REGISTRY_NOT_FOUND_BODY, type RecapAttenuation, type RegisterBatchSuccess, type RegisteredRegistryVerdict, type RegistryCacheEntry, type RegistryCacheRecord, type RegistryCacheStore, type RegistryCacheTombstone, type RegistryFallbackReason, type RegistryHost, type RegistryHostSource, RegistryLookupInputError, type RegistryLookupInputErrorCode, type RegistryLookupResponse, type RegistryPolicy, type RegistrySequenceStore, RegistryUnavailableError, type RegistryUnavailableReason, type RegistryVerdict, type RegistryVerdictSource, type RegistryVerdictStatus, type ResolveCloudLocationOptions, type ResolveOwnerHostsOptions, type ResolveTinyCloudHostsOptions, type ResolvedCapabilities, type ResolvedCloudLocation, type ResolvedDelegate, type ResolvedTinyCloudHosts, type ResourceCapability, SECRETS_SPACE, SERVICE_LONG_TO_SHORT, SERVICE_SHORT_TO_LONG, type ServerHost, SessionExpiredError, ShareLink, type SignCallback, type SignInOptions, type SignRequest, type SignResponse, type SignStrategy, type SignedSiweCacao, SilentNotificationHandler, type SiweConfig, SiweConfigSchema, Space, type SpaceAbilitiesMap, type SpaceConfig, type SpaceCreationContext, type SpaceDelegationParams, type SpaceErrorCode, SpaceErrorCodes, type SpaceHostResult, SpaceInfo, SpaceService, type SpaceServiceConfig, StoredCredentialRecord, type SubsetCheckResult, TERMINAL_DELEGATION_FACT, TINYCLOUD_CANONICAL_IDENTITY_CLAIM, TINYCLOUD_MANAGE_KEY_SCOPE, type TechnicalExpiryKind, type TerminalDelegationSigningKey, TicketHolderBinding, TinyCloud, type TinyCloudAuthorizationRequestV1, type TinyCloudAuthorizationResultV1, type TinyCloudConfig, type TinyCloudEffectiveGrantV1, type TinyCloudSession, type UnavailableRegistryVerdict, type UnregisteredRegistryVerdict, UnsupportedFeatureError, type UserAuthorizationConfig, VAULT_PERMISSION_SERVICE, type ValidatedPersistedSessionProof, type ValidationError, VerifiedCredential, type VerifiedOwnerNodeBinding, type VerifyOwnerNodeBindingOptions, VersionCheckError, type WasmRecapEntry, type WebStorageLike, actionContains, activateSessionWithHost, addressStorageKey, applyPrefix, assertExpiryWithinTechnicalLimit, assertSpaceCreationAllowed, buildSpaceUri, canonicalDigest, canonicalLocationPayload, canonicalLocationPayloadV2, canonicalizeAddress, canonicalizeDid, canonicalizeDidUrl, canonicalizeNetworkId, canonicalizeRecapCaveats, checkChangedExpiration, checkNodeInfo, classifyRegistryLookup, composeManifestRequest, createEmailCredentialRequirement, createEmailDomainCredentialRequirement, createHolderBinding, createInMemoryLocalNodeIdentityStore, createInMemoryRegistryCacheStore, createInMemoryRegistrySequenceStore, createLocalStorageLocalNodeIdentityStore, createLocalStorageRegistryCacheStore, createLocalStorageRegistrySequenceStore, createOpenKeyCallbackSigningStrategy, createOpenKeyManageKeySigningStrategy, createSpaceService, createStorageReceipt, createStoredCredentialRecord, credentialEndpointPath, credentialError, credentialIndexKey, credentialMatchesRequirement, credentialRecordKey, credentialRequirementDigest, decodeBase64Url, defaultSignStrategy, defaultSpaceCreationHandler, descriptorSatisfiesRequirement, didCacheKey, didEquals, diffImmutableSiweFields, discoverLocalTinyCloudNode, encodeBase64Url, exactHttpOrigin, expandActionShortNames, expandDelegationPermissionEntries, expandPermissionEntries, expandPermissionEntry, expandRuntimePermissionEntries, extractImmutableSiweFields, extractRecapAttenuations, fetchLocationRecord, fetchPeerId, hasTinyCloudManageKeyScope, holderBindingCanonicalBytes, holderBindingSigningBytes, httpResponseError, httpUrlToMultiaddr, isCapabilitySubset, isDigest, isEvmAddress, isExplicitOnlyAction, isPlausibleOpenKeyActionId, loadManifest, locationPayloadForRecord, lookupOwnerRegistryVerdict, makePkhSpaceId, makePublicSpaceId, manifestAbilitiesUnion, markDelegationTerminal, multiaddrToHttpUrl, normalizeDefaults, parseCanonicalNetworkId, parseCanonicalRecapResource, parseCanonicalTinyCloudIdentity, parseCanonicalTinyCloudIdentityClaims, parseExpiry, parsePkhDid, parseRecapCapabilities, parseSignedSiweCacao, parseSpaceUri, pkhDid, principalDid, principalDidEquals, publishLocationRecord, recapCaveatsEqual, refreshOwnerRegistry, registryOwnerKeyV2, registryOwnerSubjectV1, requestTinyCloudManageKeyScope, resolveCloudLocation, resolveFailClosedTinyCloudHosts, resolveManifest, resolveManifestKnowledgeRoot, resolveOwnerHosts, resolveRegistryResource, resolveTinyCloudHosts, resourceCapabilitiesToAbilitiesMap, resourceCapabilitiesToSpaceAbilitiesMap, sha256Base64Url, signLocationRecord, signLocationRecordV2, submitHostDelegation, technicalExpiryRefusal, unauthorizedRecapCapabilities, validateAuthorizationResultV1, validateClientSession, validateCredentialFlowDescriptor, validateCredentialHolderBinding, validateCredentialRequirement, validateLocationRecord, validateLocationRecordPayload, validateLocationRecordV2, validateLocationRecordV2Payload, validateManifest, validatePersistedSessionData, verifyDidKeyEd25519Signature, verifyEip191MessageSignature, verifyIssuedCredential, verifyLocationRecord, verifyLocationRecordV2, verifyOwnerNodeBinding, verifyRegistryCacheEntry, verifyStorageReceipt, warnRegistryDefaultNode };
|
|
4148
|
+
export { ACCOUNT_REGISTRY_PATH, ACCOUNT_REGISTRY_SPACE, type AbilitiesMap, type AccountApplication, type AccountApplicationListOptions, type AccountApplicationRegisterOptions, type AccountDelegation, type AccountDelegationListOptions, AccountDelegationPage, AccountDelegationQueryOptions, type AccountDelegationRevokeOptions, type AccountIndexEnsureResult, type AccountIndexRebuildResult, type AccountIndexStatus, type AccountIndexedReadOptions, AccountService, type AccountServiceConfig, type AccountSpace, type AccountSpaceListOptions, type AccountStatus, AutoApproveSpaceCreationHandler, type AutoRejectStrategy, type AutoSignStrategy, type Bytes, CREDENTIAL_ERROR_CODES, type CallbackStrategy, type CanonicalAddress, type CanonicalParsedNetworkId, type CanonicalTinyCloudIdentity, type CapabilityPresentationEnvelopeV1, CaveatedDelegationUnsupportedError, type CheckChangedExpirationInput, type ClassifyRegistryLookupOptions, type ClientSession, ClientSessionSchema, CloudLocationResolutionError, type ComposeManifestOptions, type ComposedManifestRequest, type CreateDelegationFunction, CreateDelegationParams, CredentialError, type CredentialErrorCode, CredentialFlowDescriptor, CredentialHolderBinding, CredentialIssuerMetadata, CredentialRequirement, CredentialStorageReceipt, DEFAULT_DEFAULTS, DEFAULT_EXPIRY, DEFAULT_KNOWLEDGE_ROOT, DEFAULT_LOCAL_NODE_PIN_STORAGE_KEY, DEFAULT_LOCAL_NODE_URL, DEFAULT_MANIFEST_SPACE, DEFAULT_MANIFEST_VERSION, DEFAULT_NEW_USER_HOST, DEFAULT_REGISTRY_CACHE_STORAGE_KEY, DEFAULT_REGISTRY_LOOKUP_TIMEOUT_MS, DEFAULT_REGISTRY_OWNER_CHAIN_ID, DEFAULT_REGISTRY_SEQUENCE_STORAGE_KEY, DEFAULT_SIGNED_READ_URL_EXPIRY_MS, DEFAULT_TINYCLOUD_FALLBACK_HOST, DEFAULT_TINYCLOUD_LOCATION_REGISTRY_URL, Delegation, DelegationManager, DelegationRevocationReceipt, type DidCacheKeyOptions, type DidEqualsOptions, type DiscoverLocalTinyCloudNodeOptions, type DiscoveredLocalTinyCloudNode, EMAIL_CREDENTIAL_MAX_AGE_SECONDS, EMAIL_DOMAIN_CREDENTIAL_MAX_AGE_SECONDS, ENCRYPTION_MANIFEST_SPACE, ENCRYPTION_PERMISSION_SERVICE, EXPIRY, type EnsData, EnsDataSchema, type EventEmitterStrategy, type ExpiryTier, type Extension, type FailClosedHostOptions, type FailClosedHosts, GenerateShareParams, ICapabilityKeyRegistry, type IENSResolver, type INotificationHandler, type ISessionManager, type ISessionStorage, ISharingService, type ISigner, type ISpace, type ISpaceCreationHandler, type ISpaceScopedDelegations, type ISpaceScopedSharing, type ISpaceService, type IUserAuthorization, type IWasmBindings, IdentityParseError, type ImmutableSiweFields, IssuedCredentialEnvelope, LOCAL_LINK_HOST_SUFFIX, LOCAL_LINK_PROBE_TIMEOUT_MS, LOCAL_LOOPBACK_PROBE_TIMEOUT_MS, type LocalNodeIdentityStore, type LocationCandidate, type LocationCandidateInput, type LocationRecord, type LocationRecordPayload, type LocationRecordSigner, type LocationRecordV2, type LocationRecordV2Payload, LocationRecordValidationError, LocationRegistryHttpError, type LocationResolutionAttempt, type LocationSource, type LookupOwnerRegistryVerdictOptions, MAX_SIWE_EXPIRY_MS, MAX_UCAN_EXPIRY_MS, type Manifest, type ManifestDefaults, type ManifestKnowledge, type ManifestRegistryRecord, type ManifestSecretActions, ManifestValidationError, type NodeInfo, type NodeNotFoundContext, type NodeNotFoundDecision, NodeNotFoundError, NodeRegistryEntryExistsError, OPENKEY_ACTION_ID_SEPARATOR, OWNER_NODE_BINDING_TIMEOUT_MS, type OnNodeNotFound, type OpenKeyCallbackStrategy, type OpenKeyManageKeyCallbackStrategy, OpenKeyManageKeyError, type OpenKeyManageKeyErrorCode, type OpenKeyManageKeyFetch, type OpenKeyManageKeySigningRequestBody, type OpenKeyManageKeySigningResponseBody, type OpenKeyManageKeySigningStrategyOptions, type OpenKeySigningRequestBody, type OpenKeySigningResponseBody, type OpenKeySigningStrategyOptions, type ParseRecapFromSiwe, type PartialSiweMessage, type PermissionEntry, PermissionNotInManifestError, type PersistedSessionData, type PersistedSessionProof, type PersistedTinyCloudSession, type PkhDidParts, ProtocolMismatchError, type PublishLocationRecordOptions, REGISTRY_CACHE_MAX_AGE_MS, REGISTRY_LOOKUP_MAX_BODY_BYTES, REGISTRY_NOT_FOUND_BODY, type RecapAttenuation, type RegisterBatchSuccess, type RegisteredRegistryVerdict, type RegistryCacheEntry, type RegistryCacheRecord, type RegistryCacheStore, type RegistryCacheTombstone, type RegistryFallbackReason, type RegistryHost, type RegistryHostSource, RegistryLookupInputError, type RegistryLookupInputErrorCode, type RegistryLookupResponse, type RegistryPolicy, type RegistrySequenceStore, RegistryUnavailableError, type RegistryUnavailableReason, type RegistryVerdict, type RegistryVerdictSource, type RegistryVerdictStatus, type ResolveCloudLocationOptions, type ResolveOwnerHostsOptions, type ResolveTinyCloudHostsOptions, type ResolvedCapabilities, type ResolvedCloudLocation, type ResolvedDelegate, type ResolvedTinyCloudHosts, type ResourceCapability, SECRETS_SPACE, SERVICE_LONG_TO_SHORT, SERVICE_SHORT_TO_LONG, type ServerHost, SessionExpiredError, ShareLink, type SignCallback, type SignInOptions, type SignRequest, type SignResponse, type SignStrategy, type SignedSiweCacao, SilentNotificationHandler, type SiweConfig, SiweConfigSchema, Space, type SpaceAbilitiesMap, type SpaceConfig, type SpaceCreationContext, type SpaceDelegationParams, type SpaceErrorCode, SpaceErrorCodes, type SpaceHostResult, SpaceInfo, SpaceService, type SpaceServiceConfig, StoredCredentialRecord, type SubsetCheckResult, TERMINAL_DELEGATION_FACT, TINYCLOUD_CANONICAL_IDENTITY_CLAIM, TINYCLOUD_MANAGE_KEY_SCOPE, type TechnicalExpiryKind, type TerminalDelegationSigningKey, TicketHolderBinding, TinyCloud, type TinyCloudAuthorizationRequestV1, type TinyCloudAuthorizationResultV1, type TinyCloudConfig, type TinyCloudEffectiveGrantV1, type TinyCloudSession, type UnavailableRegistryVerdict, type UnregisteredRegistryVerdict, UnsupportedFeatureError, type UserAuthorizationConfig, VAULT_PERMISSION_SERVICE, type ValidatedPersistedSessionProof, type ValidationError, VerifiedCredential, type VerifiedOwnerNodeBinding, type VerifyOwnerNodeBindingOptions, VersionCheckError, type WasmRecapEntry, type WebStorageLike, actionContains, activateSessionWithHost, addressStorageKey, applyPrefix, assertExpiryWithinTechnicalLimit, assertSpaceCreationAllowed, buildSpaceUri, canonicalDigest, canonicalLocationPayload, canonicalLocationPayloadV2, canonicalizeAddress, canonicalizeDid, canonicalizeDidUrl, canonicalizeNetworkId, canonicalizeRecapCaveats, checkChangedExpiration, checkNodeInfo, classifyRegistryLookup, composeManifestRequest, createEmailCredentialRequirement, createEmailDomainCredentialRequirement, createHolderBinding, createInMemoryLocalNodeIdentityStore, createInMemoryRegistryCacheStore, createInMemoryRegistrySequenceStore, createLocalStorageLocalNodeIdentityStore, createLocalStorageRegistryCacheStore, createLocalStorageRegistrySequenceStore, createOpenKeyCallbackSigningStrategy, createOpenKeyManageKeySigningStrategy, createSpaceService, createStorageReceipt, createStoredCredentialRecord, credentialEndpointPath, credentialError, credentialIndexKey, credentialMatchesRequirement, credentialRecordKey, credentialRequirementDigest, decodeBase64Url, defaultSignStrategy, defaultSpaceCreationHandler, descriptorSatisfiesRequirement, didCacheKey, didEquals, diffImmutableSiweFields, discoverLocalTinyCloudNode, encodeBase64Url, exactHttpOrigin, expandActionShortNames, expandDelegationPermissionEntries, expandPermissionEntries, expandPermissionEntry, expandRuntimePermissionEntries, extractImmutableSiweFields, extractRecapAttenuations, fetchLocationRecord, fetchPeerId, hasTinyCloudManageKeyScope, holderBindingCanonicalBytes, holderBindingSigningBytes, httpResponseError, httpUrlToMultiaddr, isCapabilitySubset, isDigest, isEvmAddress, isExplicitOnlyAction, isPlausibleOpenKeyActionId, loadManifest, locationPayloadForRecord, lookupOwnerRegistryVerdict, makePkhSpaceId, makePublicSpaceId, manifestAbilitiesUnion, markDelegationTerminal, multiaddrToHttpUrl, normalizeDefaults, parseCanonicalNetworkId, parseCanonicalRecapResource, parseCanonicalTinyCloudIdentity, parseCanonicalTinyCloudIdentityClaims, parseExpiry, parsePkhDid, parseRecapCapabilities, parseSignedSiweCacao, parseSpaceUri, pkhDid, principalDid, principalDidEquals, publicJwk, publishLocationRecord, recapCaveatsEqual, refreshOwnerRegistry, registryOwnerKeyV2, registryOwnerSubjectV1, requestTinyCloudManageKeyScope, resolveCloudLocation, resolveFailClosedTinyCloudHosts, resolveManifest, resolveManifestKnowledgeRoot, resolveOwnerHosts, resolveRegistryResource, resolveTinyCloudHosts, resourceCapabilitiesToAbilitiesMap, resourceCapabilitiesToSpaceAbilitiesMap, sha256Base64Url, signLocationRecord, signLocationRecordV2, submitHostDelegation, technicalExpiryRefusal, unauthorizedRecapCapabilities, validateAuthorizationResultV1, validateClientSession, validateCredentialFlowDescriptor, validateCredentialHolderBinding, validateCredentialRequirement, validateLocationRecord, validateLocationRecordPayload, validateLocationRecordV2, validateLocationRecordV2Payload, validateManifest, validatePersistedSessionData, verifyDidKeyEd25519Signature, verifyEip191MessageSignature, verifyIssuedCredential, verifyLocationRecord, verifyLocationRecordV2, verifyOwnerNodeBinding, verifyRegistryCacheEntry, verifyStorageReceipt, warnRegistryDefaultNode };
|
package/dist/index.js
CHANGED
|
@@ -845,6 +845,35 @@ function makePkhSpaceId(address, chainId, name2) {
|
|
|
845
845
|
return `tinycloud:pkh:eip155:${chainId}:${canonicalizeAddress(address)}:${name2}`;
|
|
846
846
|
}
|
|
847
847
|
|
|
848
|
+
// src/jwk.ts
|
|
849
|
+
var PUBLIC_MEMBERS = {
|
|
850
|
+
OKP: ["kty", "crv", "x"],
|
|
851
|
+
EC: ["kty", "crv", "x", "y"],
|
|
852
|
+
RSA: ["kty", "n", "e"]
|
|
853
|
+
};
|
|
854
|
+
var hasOwn = (value, key) => Object.prototype.hasOwnProperty.call(value, key);
|
|
855
|
+
function publicJwk(jwk) {
|
|
856
|
+
if (!jwk || typeof jwk !== "object" || Array.isArray(jwk)) {
|
|
857
|
+
throw new TypeError("A JWK must be an object");
|
|
858
|
+
}
|
|
859
|
+
const source = jwk;
|
|
860
|
+
const kty = hasOwn(source, "kty") ? source.kty : void 0;
|
|
861
|
+
const members = typeof kty === "string" && hasOwn(PUBLIC_MEMBERS, kty) ? PUBLIC_MEMBERS[kty] : void 0;
|
|
862
|
+
if (!members) {
|
|
863
|
+
throw new TypeError(`JWK key type ${JSON.stringify(kty)} has no public form`);
|
|
864
|
+
}
|
|
865
|
+
const result = {};
|
|
866
|
+
for (const member of members) {
|
|
867
|
+
const value = hasOwn(source, member) ? source[member] : void 0;
|
|
868
|
+
if (typeof value !== "string" || value === "") {
|
|
869
|
+
throw new TypeError(`JWK is missing its public "${member}" member`);
|
|
870
|
+
}
|
|
871
|
+
result[member] = value;
|
|
872
|
+
}
|
|
873
|
+
if (hasOwn(source, "kid") && typeof source.kid === "string") result.kid = source.kid;
|
|
874
|
+
return result;
|
|
875
|
+
}
|
|
876
|
+
|
|
848
877
|
// src/requester/index.ts
|
|
849
878
|
import { bytesToHex as bytesToHex3, sha256 as sha2566 } from "viem";
|
|
850
879
|
import { blake3 as blake32 } from "@noble/hashes/blake3";
|
|
@@ -1855,7 +1884,7 @@ function normalizePolicyCapabilityWithOptions(input, options2) {
|
|
|
1855
1884
|
output.space = canonicalSpace;
|
|
1856
1885
|
output.path = path;
|
|
1857
1886
|
output.actions = actions;
|
|
1858
|
-
if (
|
|
1887
|
+
if (hasOwn2(object4, "caveats")) {
|
|
1859
1888
|
output.caveats = validateCaveats(
|
|
1860
1889
|
requiredValue(object4, "caveats", "$", "policy-capability-malformed-caveats"),
|
|
1861
1890
|
output.service
|
|
@@ -1892,7 +1921,7 @@ function assertExactKeys(object4, allowed, path) {
|
|
|
1892
1921
|
}
|
|
1893
1922
|
}
|
|
1894
1923
|
function requiredValue(object4, key, path, code3) {
|
|
1895
|
-
if (!
|
|
1924
|
+
if (!hasOwn2(object4, key)) {
|
|
1896
1925
|
throw new PolicyCapabilityError(code3, `${path}.${key} is required`);
|
|
1897
1926
|
}
|
|
1898
1927
|
return object4[key];
|
|
@@ -2092,7 +2121,7 @@ function assertCaveatKeys(object4, allowed, path) {
|
|
|
2092
2121
|
}
|
|
2093
2122
|
}
|
|
2094
2123
|
function requiredCaveat(object4, key, path) {
|
|
2095
|
-
if (!
|
|
2124
|
+
if (!hasOwn2(object4, key)) {
|
|
2096
2125
|
throw new PolicyCapabilityError(
|
|
2097
2126
|
"policy-capability-malformed-caveats",
|
|
2098
2127
|
`${path}.${key} is required`
|
|
@@ -2132,7 +2161,7 @@ function caveatsContain(authority, request) {
|
|
|
2132
2161
|
(statement) => authorityStatements.some((candidate) => jcsCanonicalize(candidate) === jcsCanonicalize(statement))
|
|
2133
2162
|
);
|
|
2134
2163
|
}
|
|
2135
|
-
function
|
|
2164
|
+
function hasOwn2(object4, key) {
|
|
2136
2165
|
return objectHasOwn2(object4, key);
|
|
2137
2166
|
}
|
|
2138
2167
|
|
|
@@ -2617,10 +2646,10 @@ function validatePolicyShape(input, signed) {
|
|
|
2617
2646
|
validatePolicyResource(requiredValue2(object4, "resource", "$"), "$.resource");
|
|
2618
2647
|
validateExpression(requiredValue2(object4, "when", "$"), "$.when");
|
|
2619
2648
|
validateGrant(requiredValue2(object4, "grant", "$"), "$.grant");
|
|
2620
|
-
if (
|
|
2649
|
+
if (hasOwn3(object4, "disclosure")) {
|
|
2621
2650
|
validateDisclosure(requiredValue2(object4, "disclosure", "$"), "$.disclosure");
|
|
2622
2651
|
}
|
|
2623
|
-
if (
|
|
2652
|
+
if (hasOwn3(object4, "audit")) {
|
|
2624
2653
|
validateAudit(requiredValue2(object4, "audit", "$"), "$.audit");
|
|
2625
2654
|
}
|
|
2626
2655
|
return object4;
|
|
@@ -2818,7 +2847,7 @@ function validateEvidenceRequirement(input, path) {
|
|
|
2818
2847
|
requiredString2(object4, "requirementId", path);
|
|
2819
2848
|
requiredString2(object4, "verifier", path);
|
|
2820
2849
|
requiredValue2(object4, "requirements", path);
|
|
2821
|
-
if (
|
|
2850
|
+
if (hasOwn3(object4, "authority")) {
|
|
2822
2851
|
const authority = expectJsonObject(requiredValue2(object4, "authority", path), `${path}.authority`);
|
|
2823
2852
|
assertExactKeys2(
|
|
2824
2853
|
authority,
|
|
@@ -2826,12 +2855,12 @@ function validateEvidenceRequirement(input, path) {
|
|
|
2826
2855
|
`${path}.authority`
|
|
2827
2856
|
);
|
|
2828
2857
|
optionalString(authority, "profile", `${path}.authority`);
|
|
2829
|
-
if (
|
|
2858
|
+
if (hasOwn3(authority, "acceptedIssuers")) {
|
|
2830
2859
|
requiredStringArray(authority, "acceptedIssuers", `${path}.authority`);
|
|
2831
2860
|
}
|
|
2832
2861
|
optionalBoolean(authority, "allowOwnerAuthorizedIssuer", `${path}.authority`);
|
|
2833
2862
|
}
|
|
2834
|
-
if (
|
|
2863
|
+
if (hasOwn3(object4, "freshness")) {
|
|
2835
2864
|
const freshness = expectJsonObject(requiredValue2(object4, "freshness", path), `${path}.freshness`);
|
|
2836
2865
|
assertExactKeys2(freshness, ["maxStatusAgeSeconds"], `${path}.freshness`);
|
|
2837
2866
|
requiredInteger(freshness, "maxStatusAgeSeconds", `${path}.freshness`, 0);
|
|
@@ -2891,7 +2920,7 @@ function assertIdMatches(signed, material, descriptor) {
|
|
|
2891
2920
|
throw new SignedObjectIdError(`${descriptor.idField} does not match ${descriptor.idPrefix}`);
|
|
2892
2921
|
}
|
|
2893
2922
|
function assertSigningKeyBindingForCreate(unsigned, signerDid) {
|
|
2894
|
-
if (!
|
|
2923
|
+
if (!hasOwn3(unsigned, "signingKeyDid")) {
|
|
2895
2924
|
return;
|
|
2896
2925
|
}
|
|
2897
2926
|
const signingKeyDid = requiredString2(unsigned, "signingKeyDid", "$");
|
|
@@ -2902,7 +2931,7 @@ function assertSigningKeyBindingForCreate(unsigned, signerDid) {
|
|
|
2902
2931
|
}
|
|
2903
2932
|
}
|
|
2904
2933
|
function assertSigningKeyBindingForVerify(signed, signature) {
|
|
2905
|
-
if (!
|
|
2934
|
+
if (!hasOwn3(signed, "signingKeyDid")) {
|
|
2906
2935
|
return;
|
|
2907
2936
|
}
|
|
2908
2937
|
const signingKeyDid = requiredString2(signed, "signingKeyDid", "$");
|
|
@@ -3043,7 +3072,7 @@ function assertExactKeys2(object4, allowed, path) {
|
|
|
3043
3072
|
}
|
|
3044
3073
|
}
|
|
3045
3074
|
function requiredValue2(object4, key, path) {
|
|
3046
|
-
if (!
|
|
3075
|
+
if (!hasOwn3(object4, key)) {
|
|
3047
3076
|
throw new SignedObjectSchemaError(`${path}.${key} is required`);
|
|
3048
3077
|
}
|
|
3049
3078
|
return object4[key];
|
|
@@ -3052,7 +3081,7 @@ function requiredString2(object4, key, path) {
|
|
|
3052
3081
|
return requireStringType(requiredValue2(object4, key, path), `${path}.${key}`);
|
|
3053
3082
|
}
|
|
3054
3083
|
function optionalString(object4, key, path) {
|
|
3055
|
-
if (!
|
|
3084
|
+
if (!hasOwn3(object4, key)) {
|
|
3056
3085
|
return;
|
|
3057
3086
|
}
|
|
3058
3087
|
requireStringType(requiredValue2(object4, key, path), `${path}.${key}`);
|
|
@@ -3064,7 +3093,7 @@ function requireStringType(value, path) {
|
|
|
3064
3093
|
return value;
|
|
3065
3094
|
}
|
|
3066
3095
|
function optionalBoolean(object4, key, path) {
|
|
3067
|
-
if (!
|
|
3096
|
+
if (!hasOwn3(object4, key)) {
|
|
3068
3097
|
return;
|
|
3069
3098
|
}
|
|
3070
3099
|
if (typeof requiredValue2(object4, key, path) !== "boolean") {
|
|
@@ -3101,7 +3130,7 @@ function requiredDateString(object4, key, path) {
|
|
|
3101
3130
|
assertRfc3339(requiredString2(object4, key, path), `${path}.${key}`);
|
|
3102
3131
|
}
|
|
3103
3132
|
function optionalDateString(object4, key, path) {
|
|
3104
|
-
if (!
|
|
3133
|
+
if (!hasOwn3(object4, key)) {
|
|
3105
3134
|
return;
|
|
3106
3135
|
}
|
|
3107
3136
|
assertRfc3339(requiredString2(object4, key, path), `${path}.${key}`);
|
|
@@ -3136,7 +3165,7 @@ function expectOneOf(actual, allowed, path) {
|
|
|
3136
3165
|
}
|
|
3137
3166
|
throw new SignedObjectSchemaError(`${path} has unsupported value ${actual}`);
|
|
3138
3167
|
}
|
|
3139
|
-
function
|
|
3168
|
+
function hasOwn3(object4, key) {
|
|
3140
3169
|
return objectHasOwn3(object4, key);
|
|
3141
3170
|
}
|
|
3142
3171
|
function assertSupportedSignatureSuite(suite) {
|
|
@@ -3254,7 +3283,7 @@ async function verifyPolicyEngineRecordForRequester(options2) {
|
|
|
3254
3283
|
],
|
|
3255
3284
|
"$"
|
|
3256
3285
|
);
|
|
3257
|
-
if (!
|
|
3286
|
+
if (!hasOwn4(normalized, "signedRecord")) {
|
|
3258
3287
|
throw new PolicyAuthoringError(
|
|
3259
3288
|
"policy-engine-record-absent",
|
|
3260
3289
|
"$.signedRecord must be present"
|
|
@@ -3328,14 +3357,14 @@ async function verifyPolicyEngineRecordForRequester(options2) {
|
|
|
3328
3357
|
"$.signedRecord.grantIssuerDid does not match"
|
|
3329
3358
|
);
|
|
3330
3359
|
}
|
|
3331
|
-
const requiredPolicyVersion =
|
|
3360
|
+
const requiredPolicyVersion = hasOwn4(normalized, "requiredPolicyVersion") ? requiredString3(normalized, "requiredPolicyVersion", "$") : POLICY_VERSION_V0;
|
|
3332
3361
|
if (!verified.supportedPolicyVersions.includes(requiredPolicyVersion)) {
|
|
3333
3362
|
throw new PolicyAuthoringError(
|
|
3334
3363
|
"policy-engine-record-policy-version-unsupported",
|
|
3335
3364
|
"$.signedRecord.supportedPolicyVersions does not include the required version"
|
|
3336
3365
|
);
|
|
3337
3366
|
}
|
|
3338
|
-
const requiredEvidenceVerifier =
|
|
3367
|
+
const requiredEvidenceVerifier = hasOwn4(
|
|
3339
3368
|
normalized,
|
|
3340
3369
|
"requiredEvidenceVerifier"
|
|
3341
3370
|
) ? requiredString3(normalized, "requiredEvidenceVerifier", "$") : W3C_VC_CREDENTIAL_VERIFIER;
|
|
@@ -3376,7 +3405,7 @@ function assertExactKeys3(object4, allowed, path) {
|
|
|
3376
3405
|
}
|
|
3377
3406
|
}
|
|
3378
3407
|
function requiredValue3(object4, key, path) {
|
|
3379
|
-
if (!
|
|
3408
|
+
if (!hasOwn4(object4, key)) {
|
|
3380
3409
|
throw new PolicyAuthoringError(
|
|
3381
3410
|
"policy-authoring-malformed",
|
|
3382
3411
|
`${path}.${key} is required`
|
|
@@ -3395,7 +3424,7 @@ function requiredString3(object4, key, path) {
|
|
|
3395
3424
|
return value;
|
|
3396
3425
|
}
|
|
3397
3426
|
function fieldString(object4, key, path, code3) {
|
|
3398
|
-
if (!
|
|
3427
|
+
if (!hasOwn4(object4, key)) {
|
|
3399
3428
|
throw new PolicyAuthoringError(code3, `${path}.${key} is required`);
|
|
3400
3429
|
}
|
|
3401
3430
|
const value = object4[key];
|
|
@@ -3436,7 +3465,7 @@ function parseStrictRfc3339(value, path) {
|
|
|
3436
3465
|
var objectHasOwn4 = Object.hasOwn ?? Object.prototype.hasOwnProperty.call.bind(
|
|
3437
3466
|
Object.prototype.hasOwnProperty
|
|
3438
3467
|
);
|
|
3439
|
-
function
|
|
3468
|
+
function hasOwn4(object4, key) {
|
|
3440
3469
|
return objectHasOwn4(object4, key);
|
|
3441
3470
|
}
|
|
3442
3471
|
|
|
@@ -20993,6 +21022,7 @@ export {
|
|
|
20993
21022
|
principalDidEquals,
|
|
20994
21023
|
projectUnifiedPolicyCapabilities,
|
|
20995
21024
|
projectUnifiedPolicyCapability,
|
|
21025
|
+
publicJwk,
|
|
20996
21026
|
publishLocationRecord,
|
|
20997
21027
|
recapCaveatsEqual,
|
|
20998
21028
|
refreshOwnerRegistry,
|