Open elliot-sawyer opened 5 years ago
It's using crypto_box_seal_open()
internally:
File:seal seems to be doing something different to Crypto:seal
eg adding the version tag, public key and salt - is libsodium's crypto_box_seal_open
able to unseal content sealed with File::seal
?
The JS library I was looking at required some knowledge of the nonce. I don't think Halite exposes it directly, but you might be able to extract it from beginning of the ciphertext
I'm using
File::seal
to encrypt an uploaded file with a public key. I would like to decrypt it withFile::unseal
in a separate application using the correct private key, but I'm not able to run a server in the decryption environment. I'd like to create an offline application that replicates what File::unseal does... I attempted to decrypt the cipher with a x25519 Javascript library, but there seems to be more to it than a simple decryption with the private key. Can you outline what steps Halite does, and which ciphers are used, as part of the decryption process?This library is excellent, thanks so much for creating it!