syn.crypt.seal
Functions
keygen
(string, string) syn.crypt.seal.keygen()
Generates a new public & secret keypair, and returns it in that order.
derive
(string, string) syn.crypt.seal.derive(key: string)
TODO
encrypt
string syn.crypt.seal.encrypt(plaintext: string, public_key: string)
Encrypts data
with the public_key
. The data can only be later decrypted via the secret key in the keypair.
decrypt
string syn.crypt.seal.decrypt(ciphertext: string, public_key: string, secret_key: string)
Decrypts data
with the public_key
and secret_key
.