Crypto
Cryptographic support routines.
This object contains various cryptographic primitives and is a wrapper to a platform- specific crypto library.
Cryptographic support routines.
This object contains various cryptographic primitives and is a wrapper to a platform- specific crypto library.
Properties
Functions
Link copied to clipboard
expect fun checkSignature(publicKey: EcPublicKey, message: ByteArray, algorithm: Algorithm, signature: EcSignature)
Checks signature validity.
actual fun checkSignature(publicKey: <Error class: unknown class>, message: ByteArray, algorithm: <Error class: unknown class>, signature: <Error class: unknown class>)
actual fun checkSignature(publicKey: EcPublicKey, message: ByteArray, algorithm: Algorithm, signature: EcSignature)
Checks signature validity.
Link copied to clipboard
Creates an EC private key.
Creates an EC private key.
Link copied to clipboard
Link copied to clipboard
expect fun hpkeDecrypt(cipherSuite: Algorithm, receiverPrivateKey: EcPrivateKey, cipherText: ByteArray, aad: ByteArray, encapsulatedPublicKey: EcPublicKey): ByteArray
Decrypts data using HPKE according to RFC 9180.
actual fun hpkeDecrypt(cipherSuite: <Error class: unknown class>, receiverPrivateKey: <Error class: unknown class>, cipherText: ByteArray, aad: ByteArray, encapsulatedPublicKey: <Error class: unknown class>): ByteArray
actual fun hpkeDecrypt(cipherSuite: Algorithm, receiverPrivateKey: EcPrivateKey, cipherText: ByteArray, aad: ByteArray, encapsulatedPublicKey: EcPublicKey): ByteArray
Decrypts data using HPKE according to RFC 9180.
Link copied to clipboard
expect fun hpkeEncrypt(cipherSuite: Algorithm, receiverPublicKey: EcPublicKey, plainText: ByteArray, aad: ByteArray): Pair<ByteArray, EcPublicKey>
Encrypts data using HPKE according to RFC 9180.
actual fun hpkeEncrypt(cipherSuite: <Error class: unknown class>, receiverPublicKey: <Error class: unknown class>, plainText: ByteArray, aad: ByteArray): Pair<ByteArray, <Error class: unknown class>>
actual fun hpkeEncrypt(cipherSuite: Algorithm, receiverPublicKey: EcPublicKey, plainText: ByteArray, aad: ByteArray): Pair<ByteArray, EcPublicKey>
Encrypts data using HPKE according to RFC 9180.
Link copied to clipboard
Performs Key Agreement.
actual fun keyAgreement(key: <Error class: unknown class>, otherKey: <Error class: unknown class>): ByteArray
Performs Key Agreement.
Link copied to clipboard
Message authentication code function.
Link copied to clipboard
Signs data with a key.
Signs data with a key.