Skip to content

Commit 373fc4e

Browse files
committed
feat: crypto-ffi: add updateDatabaseKey to Kotlin bindings [WPB-18538]
1 parent f682a15 commit 373fc4e

File tree

1 file changed

+10
-0
lines changed
  • crypto-ffi/bindings/jvm/src/main/kotlin/com/wire/crypto

1 file changed

+10
-0
lines changed

crypto-ffi/bindings/jvm/src/main/kotlin/com/wire/crypto/CoreCrypto.kt

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,16 @@ suspend fun migrateDatabaseKeyTypeToBytes(name: String, oldKey: String, newKey:
2424
return com.wire.crypto.uniffi.migrateDbKeyTypeToBytes(name, oldKey, newKey.bytes)
2525
}
2626

27+
/**
28+
* Updates the key of the CoreCrypto database.
29+
* @param name path to the database file
30+
* @param oldKey the old key
31+
* @param newKey the new key
32+
*/
33+
suspend fun updateDatabaseKey(name: String, oldKey: DatabaseKey, newKey: DatabaseKey) {
34+
return com.wire.crypto.uniffi.updateDatabaseKey(name, oldKey.bytes, newKey.bytes)
35+
}
36+
2737
/**
2838
* An `EpochObserver` is notified whenever a conversation's epoch changes.
2939
*/

0 commit comments

Comments
 (0)