feat: experimental 005 operator (#1753)

This commit is contained in:
Mo
2022-10-06 11:03:43 -05:00
committed by GitHub
parent c13dd883a4
commit cbbe913cd6
21 changed files with 284 additions and 46 deletions

View File

@@ -1,6 +1,7 @@
import {
Base64String,
HexString,
PkcKeyPair,
PureCryptoInterface,
SodiumConstant,
StreamDecryptorResult,
@@ -129,6 +130,28 @@ export class SNReactNativeCrypto implements PureCryptoInterface {
}
}
public sodiumCryptoBoxEasyEncrypt(
_message: Utf8String,
_nonce: HexString,
_senderSecretKey: HexString,
_recipientPublicKey: HexString,
): Base64String {
throw new Error('Not implemented')
}
public sodiumCryptoBoxEasyDecrypt(
_ciphertext: Base64String,
_nonce: HexString,
_senderPublicKey: HexString,
_recipientSecretKey: HexString,
): Utf8String {
throw new Error('Not implemented')
}
public sodiumCryptoBoxGenerateKeypair(): PkcKeyPair {
throw new Error('Not implemented')
}
public generateUUID() {
const randomBuf = Sodium.randombytes_buf(16)
const tempBuf = new Uint8Array(randomBuf.length / 2)