@trylimbo/sdk-issuer 0.2.10 → 0.2.11-canary.13

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.
@@ -181,7 +181,7 @@ declare const pointerLiteralSymbol: unique symbol;
181
181
  */
182
182
  declare const uniffiTypeNameSymbol: unique symbol;
183
183
  declare namespace trylimbo_issuer_d_exports {
184
- export { Action, ActionDetail, ActionKind, Action_Tags, Assertion, AssetIssuer, AssetIssuerInterface, AssetIssuerLike, AssetMarker, AssetMarkerInterface, AssetMarkerLike, Binder, BinderInterface, BinderLike, Code, Component, ComponentEvent, ConnectOptions, CreatedOrigin, CustomAction, DeriveOptions, EmbedOptions, FieldViolation, FileSink, FileSinkInterface, FileSinkLike, FileSource, FileSourceInterface, FileSourceLike, IdentityOptions, Ingredient, InitOutcome, ManifestMode, ManifestMode_Tags, ManifestSpec, Mark, MarkOptions, Mark_Tags, Marked, MemorySink, MemorySinkInterface, MemorySinkLike, MemorySource, MemorySourceInterface, MemorySourceLike, OpenedOrigin, Origin, Origin_Tags, PluginAuthor, PluginRegistry, PluginRegistryInterface, PluginRegistryLike, RangeSink, RangeSinkImpl, RangeSource, RangeSourceImpl, Region, RotationPolicy, SdkError, SdkError_Tags, SegmentKind, SignOptions, SignOutcome, SignedSegmentOutcome, SignerClient, SignerClientInterface, SignerClientLike, SigningVault, SoftBinding, StandardAction, StreamIssuer, StreamIssuerInterface, StreamIssuerLike, StreamSession, StreamSessionInterface, StreamSessionLike, StreamStart, Thumbnail, Value, VaultPublicKey, classifySegment, _default$1 as default, embed };
184
+ export { Action, ActionDetail, ActionKind, Action_Tags, Assertion, AssetIssuer, AssetIssuerInterface, AssetIssuerLike, AssetMarker, AssetMarkerInterface, AssetMarkerLike, Binder, BinderInterface, BinderLike, BinderPlugin, Code, Component, ComponentEvent, ConnectOptions, CreatedOrigin, CustomAction, DeriveOptions, EmbedOptions, FieldViolation, FileSink, FileSinkInterface, FileSinkLike, FileSource, FileSourceInterface, FileSourceLike, IdentityOptions, Ingredient, InitOutcome, ManifestMode, ManifestMode_Tags, ManifestSpec, Mark, MarkOptions, Mark_Tags, Marked, MemorySink, MemorySinkInterface, MemorySinkLike, MemorySource, MemorySourceInterface, MemorySourceLike, OpenedOrigin, Origin, Origin_Tags, PluginAuthor, PluginRegistry, PluginRegistryInterface, PluginRegistryLike, RangeSink, RangeSinkImpl, RangeSource, RangeSourceImpl, Region, RotationPolicy, SdkError, SdkError_Tags, SegmentKind, SignOptions, SignOutcome, SignedSegmentOutcome, SignerClient, SignerClientInterface, SignerClientLike, SigningVault, SoftBinding, StandardAction, StreamIssuer, StreamIssuerInterface, StreamIssuerLike, StreamSession, StreamSessionInterface, StreamSessionLike, StreamStart, Thumbnail, Value, VaultPublicKey, classifySegment, _default$1 as default, embed };
185
185
  }
186
186
  /**
187
187
  * Classify a fragmented-MP4 segment from a [`RangeSource`] as init/media/unknown: the
@@ -1543,6 +1543,10 @@ export declare class Binder extends UniffiAbstractObject implements BinderLike {
1543
1543
  readonly [destructorGuardSymbol]: UniffiGcObject;
1544
1544
  readonly [pointerLiteralSymbol]: UniffiHandle;
1545
1545
  private constructor();
1546
+ /**
1547
+ * A caller-supplied binder for a soft-binding algorithm not built into the SDK.
1548
+ */
1549
+ static custom(plugin: BinderPlugin): BinderLike;
1546
1550
  /**
1547
1551
  * A binding you already hold, such as an out-of-band video ISCC. Reads nothing.
1548
1552
  */
@@ -2476,6 +2480,19 @@ export declare class StreamIssuer extends UniffiAbstractObject implements Stream
2476
2480
  uniffiDestroy(): void;
2477
2481
  static instanceOf(obj_: any): obj_ is StreamIssuer;
2478
2482
  }
2483
+ /**
2484
+ * A caller-supplied soft-binding implementation.
2485
+ *
2486
+ * This is the extension point for algorithms the SDK does not ship. The callback receives the
2487
+ * same ranged asset source and resolved media type as the built-in binders and may return no
2488
+ * binding when the algorithm does not apply. The returned `alg` identifies the C2PA algorithm
2489
+ * used by the caller's recovery plan and registry index.
2490
+ */
2491
+ export interface BinderPlugin {
2492
+ derive(source: RangeSource, format: string, asyncOpts_?: {
2493
+ signal: AbortSignal;
2494
+ }): Promise<SoftBinding | undefined>;
2495
+ }
2479
2496
  /**
2480
2497
  * A per-session ECDSA key store, implemented by the host. `mint` returns a fresh public key
2481
2498
  * that will be signed under for `validity_period_secs`, so give it that lifetime and let the
package/gen/ffi/index.js CHANGED
@@ -1737,6 +1737,11 @@ const DEFINITIONS = {
1737
1737
  ret: FfiType.Void,
1738
1738
  hasRustCallStatus: false
1739
1739
  },
1740
+ "uniffi_trylimbo_sdk_issuer_fn_init_callback_vtable_binderplugin": {
1741
+ args: [FfiType.Reference(FfiType.Struct("VTableCallbackInterfaceTrylimboIssuerBinderPlugin"))],
1742
+ ret: FfiType.Void,
1743
+ hasRustCallStatus: false
1744
+ },
1740
1745
  "uniffi_trylimbo_sdk_issuer_fn_init_callback_vtable_pluginauthor": {
1741
1746
  args: [FfiType.Reference(FfiType.Struct("VTableCallbackInterfaceTrylimboIssuerPluginAuthor"))],
1742
1747
  ret: FfiType.Void,
@@ -1791,6 +1796,11 @@ const DEFINITIONS = {
1791
1796
  ret: FfiType.Handle,
1792
1797
  hasRustCallStatus: false
1793
1798
  },
1799
+ "uniffi_trylimbo_sdk_issuer_fn_constructor_binder_custom": {
1800
+ args: [FfiType.Handle],
1801
+ ret: FfiType.Handle,
1802
+ hasRustCallStatus: true
1803
+ },
1794
1804
  "uniffi_trylimbo_sdk_issuer_fn_constructor_binder_held": {
1795
1805
  args: [FfiType.RustBuffer],
1796
1806
  ret: FfiType.Handle,
@@ -2065,6 +2075,11 @@ const DEFINITIONS = {
2065
2075
  ret: FfiType.UInt16,
2066
2076
  hasRustCallStatus: false
2067
2077
  },
2078
+ "uniffi_trylimbo_sdk_issuer_checksum_constructor_binder_custom": {
2079
+ args: [],
2080
+ ret: FfiType.UInt16,
2081
+ hasRustCallStatus: false
2082
+ },
2068
2083
  "uniffi_trylimbo_sdk_issuer_checksum_constructor_binder_held": {
2069
2084
  args: [],
2070
2085
  ret: FfiType.UInt16,
@@ -2364,6 +2379,28 @@ const DEFINITIONS = {
2364
2379
  ret: FfiType.Void,
2365
2380
  hasRustCallStatus: false
2366
2381
  },
2382
+ "CallbackInterfaceTrylimboIssuerBinderPluginMethod0": {
2383
+ args: [
2384
+ FfiType.Handle,
2385
+ FfiType.Handle,
2386
+ FfiType.RustBuffer,
2387
+ FfiType.Callback("ForeignFutureCompleterust_buffer"),
2388
+ FfiType.Handle
2389
+ ],
2390
+ ret: FfiType.Struct("ForeignFutureDroppedCallbackStruct"),
2391
+ hasRustCallStatus: false,
2392
+ outReturn: true
2393
+ },
2394
+ "CallbackInterfaceCloneTrylimboIssuer_BinderPlugin": {
2395
+ args: [FfiType.Handle],
2396
+ ret: FfiType.Handle,
2397
+ hasRustCallStatus: false
2398
+ },
2399
+ "CallbackInterfaceFreeTrylimboIssuer_BinderPlugin": {
2400
+ args: [FfiType.Handle],
2401
+ ret: FfiType.Void,
2402
+ hasRustCallStatus: false
2403
+ },
2367
2404
  "CallbackInterfaceTrylimboIssuerPluginAuthorMethod0": {
2368
2405
  args: [FfiType.Handle],
2369
2406
  ret: FfiType.RustBuffer,
@@ -2529,6 +2566,20 @@ const DEFINITIONS = {
2529
2566
  type: FfiType.Callback("CallbackInterfaceTrylimboIssuerRangeSourceMethod1")
2530
2567
  }
2531
2568
  ],
2569
+ "VTableCallbackInterfaceTrylimboIssuerBinderPlugin": [
2570
+ {
2571
+ name: "uniffi_free",
2572
+ type: FfiType.Callback("CallbackInterfaceFreeTrylimboIssuer_BinderPlugin")
2573
+ },
2574
+ {
2575
+ name: "uniffi_clone",
2576
+ type: FfiType.Callback("CallbackInterfaceCloneTrylimboIssuer_BinderPlugin")
2577
+ },
2578
+ {
2579
+ name: "derive",
2580
+ type: FfiType.Callback("CallbackInterfaceTrylimboIssuerBinderPluginMethod0")
2581
+ }
2582
+ ],
2532
2583
  "VTableCallbackInterfaceTrylimboIssuerPluginAuthor": [
2533
2584
  {
2534
2585
  name: "uniffi_free",
@@ -4711,6 +4762,14 @@ var Binder = class extends UniffiAbstractObject {
4711
4762
  this[destructorGuardSymbol] = uniffiTypeBinderObjectFactory.bless(pointer);
4712
4763
  }
4713
4764
  /**
4765
+ * A caller-supplied binder for a soft-binding algorithm not built into the SDK.
4766
+ */
4767
+ static custom(plugin) {
4768
+ return FfiConverterTypeBinder.lift(uniffiCaller.rustCall((callStatus) => {
4769
+ return getter().uniffi_trylimbo_sdk_issuer_fn_constructor_binder_custom(FfiConverterTypeBinderPlugin.lower(plugin, getter().rustbuffer_alloc), callStatus);
4770
+ }, FfiConverterString.lift.bind(FfiConverterString)));
4771
+ }
4772
+ /**
4714
4773
  * A binding you already hold, such as an out-of-band video ISCC. Reads nothing.
4715
4774
  */
4716
4775
  static held(binding) {
@@ -6257,6 +6316,38 @@ const uniffiTypeStreamIssuerObjectFactory = (() => {
6257
6316
  };
6258
6317
  })();
6259
6318
  const FfiConverterTypeStreamIssuer = new FfiConverterObject(uniffiTypeStreamIssuerObjectFactory);
6319
+ const uniffiCallbackInterfaceBinderPlugin = {
6320
+ vtable: {
6321
+ derive: (uniffiHandle, source, format, uniffiFutureCallback, uniffiCallbackData) => {
6322
+ const uniffiMakeCall = async (signal) => {
6323
+ return await FfiConverterTypeBinderPlugin.lift(uniffiHandle).derive(FfiConverterTypeRangeSource.lift(source), FfiConverterString.lift(format), { signal });
6324
+ };
6325
+ const uniffiHandleSuccess = (returnValue) => {
6326
+ uniffiFutureCallback.call(uniffiFutureCallback, uniffiCallbackData, {
6327
+ return_value: FfiConverterOptionalTypeSoftBinding.lower(returnValue, getter().rustbuffer_alloc),
6328
+ call_status: uniffiCaller.createCallStatus()
6329
+ });
6330
+ };
6331
+ const uniffiHandleError = (code, errorBuf) => {
6332
+ uniffiFutureCallback.call(uniffiFutureCallback, uniffiCallbackData, {
6333
+ return_value: /* @__PURE__ */ new Uint8Array(0),
6334
+ call_status: uniffiCaller.createErrorStatus(code, errorBuf)
6335
+ });
6336
+ };
6337
+ return uniffiTraitInterfaceCallAsyncWithError(uniffiMakeCall, uniffiHandleSuccess, uniffiHandleError, SdkError.instanceOf, FfiConverterTypeSdkError.lower.bind(FfiConverterTypeSdkError), FfiConverterString.lower.bind(FfiConverterString), getter().rustbuffer_alloc);
6338
+ },
6339
+ uniffi_free: (uniffiHandle) => {
6340
+ FfiConverterTypeBinderPlugin.drop(uniffiHandle);
6341
+ },
6342
+ uniffi_clone: (uniffiHandle) => {
6343
+ return FfiConverterTypeBinderPlugin.clone(uniffiHandle);
6344
+ }
6345
+ },
6346
+ register: () => {
6347
+ getter().uniffi_trylimbo_sdk_issuer_fn_init_callback_vtable_binderplugin(uniffiCallbackInterfaceBinderPlugin.vtable);
6348
+ }
6349
+ };
6350
+ const FfiConverterTypeBinderPlugin = new FfiConverterCallback();
6260
6351
  const uniffiCallbackInterfaceSigningVault = {
6261
6352
  vtable: {
6262
6353
  mint: (uniffiHandle, validityPeriodSecs, uniffiFutureCallback, uniffiCallbackData) => {
@@ -6361,6 +6452,7 @@ function uniffiEnsureInitialized() {
6361
6452
  if (getter().uniffi_trylimbo_sdk_issuer_checksum_method_assetissuer_sign() !== 52777) throw new UniffiInternalError.ApiChecksumMismatch("uniffi_trylimbo_sdk_issuer_checksum_method_assetissuer_sign");
6362
6453
  if (getter().uniffi_trylimbo_sdk_issuer_checksum_constructor_assetmarker_create() !== 41968) throw new UniffiInternalError.ApiChecksumMismatch("uniffi_trylimbo_sdk_issuer_checksum_constructor_assetmarker_create");
6363
6454
  if (getter().uniffi_trylimbo_sdk_issuer_checksum_method_assetmarker_mark() !== 33916) throw new UniffiInternalError.ApiChecksumMismatch("uniffi_trylimbo_sdk_issuer_checksum_method_assetmarker_mark");
6455
+ if (getter().uniffi_trylimbo_sdk_issuer_checksum_constructor_binder_custom() !== 41200) throw new UniffiInternalError.ApiChecksumMismatch("uniffi_trylimbo_sdk_issuer_checksum_constructor_binder_custom");
6364
6456
  if (getter().uniffi_trylimbo_sdk_issuer_checksum_constructor_binder_held() !== 60668) throw new UniffiInternalError.ApiChecksumMismatch("uniffi_trylimbo_sdk_issuer_checksum_constructor_binder_held");
6365
6457
  if (getter().uniffi_trylimbo_sdk_issuer_checksum_constructor_binder_iscc() !== 9916) throw new UniffiInternalError.ApiChecksumMismatch("uniffi_trylimbo_sdk_issuer_checksum_constructor_binder_iscc");
6366
6458
  if (getter().uniffi_trylimbo_sdk_issuer_checksum_method_binder_derive() !== 18292) throw new UniffiInternalError.ApiChecksumMismatch("uniffi_trylimbo_sdk_issuer_checksum_method_binder_derive");
@@ -6401,6 +6493,7 @@ function uniffiEnsureInitialized() {
6401
6493
  uniffiCallbackInterfaceRangeSource.register();
6402
6494
  uniffiCallbackInterfaceRangeSink.register();
6403
6495
  uniffiCallbackInterfacePluginAuthor.register();
6496
+ uniffiCallbackInterfaceBinderPlugin.register();
6404
6497
  uniffiCallbackInterfaceSigningVault.register();
6405
6498
  }
6406
6499
  var trylimbo_issuer_default = Object.freeze({
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "optionalDependencies": {
3
- "@trylimbo/sdk-issuer-linux-arm64-gnu": "0.2.10",
4
- "@trylimbo/sdk-issuer-linux-x64-gnu": "0.2.10",
3
+ "@trylimbo/sdk-issuer-linux-arm64-gnu": "0.2.11-canary.13",
4
+ "@trylimbo/sdk-issuer-linux-x64-gnu": "0.2.11-canary.13",
5
5
  "@ubjs/node-linux-arm64-gnu": "0.31.0-5",
6
6
  "@ubjs/node-linux-x64-gnu": "0.31.0-5"
7
7
  },
8
8
  "name": "@trylimbo/sdk-issuer",
9
- "version": "0.2.10",
9
+ "version": "0.2.11-canary.13",
10
10
  "license": "UNLICENSED",
11
11
  "repository": {
12
12
  "type": "git",
@@ -50,5 +50,6 @@
50
50
  "@bufbuild/protoc-gen-es": "^2.12.1",
51
51
  "typescript": "^7.0.2",
52
52
  "uniffi-bindgen-react-native": "0.31.0-5"
53
- }
53
+ },
54
+ "stableVersion": "0.2.10"
54
55
  }