ping-openmls-sdk-react-native-macos 0.7.11 → 0.7.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.
Binary file
@@ -2524,13 +2524,15 @@ public struct HistoryAppEvent {
2524
2524
  public var eventId: Data
2525
2525
  public var wallMs: UInt64
2526
2526
  public var payload: Data
2527
+ public var author: String
2527
2528
 
2528
2529
  /// Default memberwise initializers are never public by default, so we
2529
2530
  /// declare one manually.
2530
- public init(eventId: Data, wallMs: UInt64, payload: Data) {
2531
+ public init(eventId: Data, wallMs: UInt64, payload: Data, author: String) {
2531
2532
  self.eventId = eventId
2532
2533
  self.wallMs = wallMs
2533
2534
  self.payload = payload
2535
+ self.author = author
2534
2536
  }
2535
2537
  }
2536
2538
 
@@ -2545,6 +2547,9 @@ extension HistoryAppEvent: Equatable, Hashable {
2545
2547
  if lhs.payload != rhs.payload {
2546
2548
  return false
2547
2549
  }
2550
+ if lhs.author != rhs.author {
2551
+ return false
2552
+ }
2548
2553
  return true
2549
2554
  }
2550
2555
 
@@ -2552,6 +2557,7 @@ extension HistoryAppEvent: Equatable, Hashable {
2552
2557
  hasher.combine(eventId)
2553
2558
  hasher.combine(wallMs)
2554
2559
  hasher.combine(payload)
2560
+ hasher.combine(author)
2555
2561
  }
2556
2562
  }
2557
2563
 
@@ -2564,7 +2570,8 @@ public struct FfiConverterTypeHistoryAppEvent: FfiConverterRustBuffer {
2564
2570
  try HistoryAppEvent(
2565
2571
  eventId: FfiConverterData.read(from: &buf),
2566
2572
  wallMs: FfiConverterUInt64.read(from: &buf),
2567
- payload: FfiConverterData.read(from: &buf)
2573
+ payload: FfiConverterData.read(from: &buf),
2574
+ author: FfiConverterString.read(from: &buf)
2568
2575
  )
2569
2576
  }
2570
2577
 
@@ -2572,6 +2579,7 @@ public struct FfiConverterTypeHistoryAppEvent: FfiConverterRustBuffer {
2572
2579
  FfiConverterData.write(value.eventId, into: &buf)
2573
2580
  FfiConverterUInt64.write(value.wallMs, into: &buf)
2574
2581
  FfiConverterData.write(value.payload, into: &buf)
2582
+ FfiConverterString.write(value.author, into: &buf)
2575
2583
  }
2576
2584
  }
2577
2585
 
@@ -4144,6 +4152,26 @@ public func generateMnemonicPhrase() throws -> String {
4144
4152
  })
4145
4153
  }
4146
4154
 
4155
+ public func hpkeOpen(sealed: Data, recipientPriv: Data, info: Data) throws -> Data {
4156
+ return try FfiConverterData.lift(rustCallWithError(FfiConverterTypePingError.lift) {
4157
+ uniffi_ping_ffi_fn_func_hpke_open(
4158
+ FfiConverterData.lower(sealed),
4159
+ FfiConverterData.lower(recipientPriv),
4160
+ FfiConverterData.lower(info), $0
4161
+ )
4162
+ })
4163
+ }
4164
+
4165
+ public func hpkeSeal(plaintext: Data, recipientPub: Data, info: Data) throws -> Data {
4166
+ return try FfiConverterData.lift(rustCallWithError(FfiConverterTypePingError.lift) {
4167
+ uniffi_ping_ffi_fn_func_hpke_seal(
4168
+ FfiConverterData.lower(plaintext),
4169
+ FfiConverterData.lower(recipientPub),
4170
+ FfiConverterData.lower(info), $0
4171
+ )
4172
+ })
4173
+ }
4174
+
4147
4175
  public func normalizeMnemonicPhrase(phrase: String) throws -> String {
4148
4176
  return try FfiConverterString.lift(rustCallWithError(FfiConverterTypePingError.lift) {
4149
4177
  uniffi_ping_ffi_fn_func_normalize_mnemonic_phrase(
@@ -4221,6 +4249,12 @@ private var initializationResult: InitializationResult = {
4221
4249
  if uniffi_ping_ffi_checksum_func_generate_mnemonic_phrase() != 9754 {
4222
4250
  return InitializationResult.apiChecksumMismatch
4223
4251
  }
4252
+ if uniffi_ping_ffi_checksum_func_hpke_open() != 21701 {
4253
+ return InitializationResult.apiChecksumMismatch
4254
+ }
4255
+ if uniffi_ping_ffi_checksum_func_hpke_seal() != 7740 {
4256
+ return InitializationResult.apiChecksumMismatch
4257
+ }
4224
4258
  if uniffi_ping_ffi_checksum_func_normalize_mnemonic_phrase() != 55353 {
4225
4259
  return InitializationResult.apiChecksumMismatch
4226
4260
  }
package/ios/pingFFI.h CHANGED
@@ -572,6 +572,16 @@ RustBuffer uniffi_ping_ffi_fn_func_generate_identity_export(RustCallStatus *_Non
572
572
  #define UNIFFI_FFIDEF_UNIFFI_PING_FFI_FN_FUNC_GENERATE_MNEMONIC_PHRASE
573
573
  RustBuffer uniffi_ping_ffi_fn_func_generate_mnemonic_phrase(RustCallStatus *_Nonnull out_status
574
574
 
575
+ );
576
+ #endif
577
+ #ifndef UNIFFI_FFIDEF_UNIFFI_PING_FFI_FN_FUNC_HPKE_OPEN
578
+ #define UNIFFI_FFIDEF_UNIFFI_PING_FFI_FN_FUNC_HPKE_OPEN
579
+ RustBuffer uniffi_ping_ffi_fn_func_hpke_open(RustBuffer sealed, RustBuffer recipient_priv, RustBuffer info, RustCallStatus *_Nonnull out_status
580
+ );
581
+ #endif
582
+ #ifndef UNIFFI_FFIDEF_UNIFFI_PING_FFI_FN_FUNC_HPKE_SEAL
583
+ #define UNIFFI_FFIDEF_UNIFFI_PING_FFI_FN_FUNC_HPKE_SEAL
584
+ RustBuffer uniffi_ping_ffi_fn_func_hpke_seal(RustBuffer plaintext, RustBuffer recipient_pub, RustBuffer info, RustCallStatus *_Nonnull out_status
575
585
  );
576
586
  #endif
577
587
  #ifndef UNIFFI_FFIDEF_UNIFFI_PING_FFI_FN_FUNC_NORMALIZE_MNEMONIC_PHRASE
@@ -907,6 +917,18 @@ uint16_t uniffi_ping_ffi_checksum_func_generate_identity_export(void
907
917
  #define UNIFFI_FFIDEF_UNIFFI_PING_FFI_CHECKSUM_FUNC_GENERATE_MNEMONIC_PHRASE
908
918
  uint16_t uniffi_ping_ffi_checksum_func_generate_mnemonic_phrase(void
909
919
 
920
+ );
921
+ #endif
922
+ #ifndef UNIFFI_FFIDEF_UNIFFI_PING_FFI_CHECKSUM_FUNC_HPKE_OPEN
923
+ #define UNIFFI_FFIDEF_UNIFFI_PING_FFI_CHECKSUM_FUNC_HPKE_OPEN
924
+ uint16_t uniffi_ping_ffi_checksum_func_hpke_open(void
925
+
926
+ );
927
+ #endif
928
+ #ifndef UNIFFI_FFIDEF_UNIFFI_PING_FFI_CHECKSUM_FUNC_HPKE_SEAL
929
+ #define UNIFFI_FFIDEF_UNIFFI_PING_FFI_CHECKSUM_FUNC_HPKE_SEAL
930
+ uint16_t uniffi_ping_ffi_checksum_func_hpke_seal(void
931
+
910
932
  );
911
933
  #endif
912
934
  #ifndef UNIFFI_FFIDEF_UNIFFI_PING_FFI_CHECKSUM_FUNC_NORMALIZE_MNEMONIC_PHRASE
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ping-openmls-sdk-react-native-macos",
3
- "version": "0.7.11",
3
+ "version": "0.7.13",
4
4
  "description": "Real MLS for React Native macOS apps — wraps the ping-openmls-sdk Rust core via UniFFI.",
5
5
  "homepage": "https://github.com/AMP-Media-Development/ping-openmls-sdk",
6
6
  "license": "Apache-2.0",