Closed jeprojects closed 5 years ago
Would love to add that API, and it's working for iOS, but the Android version has a dependency on libsodium-jni, which does not include XChaCha20-Poly1305-IETF.
This needs to be sorted, there are other Android APIs missing as well. Developing...
I see that chacha20poly1305 is exposed in libsodium-jni. Can this be accessed through flutter_sodium?
I can see that there already has been a request to add XChaCha20-Poly1305-IETF to libsodium-jni 3 months ago: https://github.com/joshjdevl/libsodium-jni/issues/100
It should be no problem to add chacha20poly1305. However since xchacha20poly1305 is the preferred AEAD construction, this needs to be fixed. Look like I need to dive into libsodium-jni.
I think it would be good to add both as chacha20poly1305-ieft is compatible with other libraries where as xchacha20poly1305 can only be used with libsodium.
Agreed. Just released 1.0.6 with support for both chacha20poly1305 and chacha20poly1305-ietf. xchacha20poly1305 is also available, but only works on iOS. For both variants of chacha20poly1305, combined mode is fully supported, detached mode only works on iOS.
Awesome work. Thanks!
I just noticed that libsodium jni also has secret stream high-level api available which uses xchacha20poly1305.
https://download.libsodium.org/doc/secret-key_cryptography/secretstream.html
There are more libsodium APIs not yet available in flutter_sodium. Eventually the plan is to support them all.
Just need to do tests up for this and then can do a pull request to add the xchacha20poly1305-ieft methods + chacha20poly1305-ietf & chacha20poly1305 detached mode to libsodium-jni.
That is amazing! For your information, I've created an issue with the complete list of missing APIs in libsodiumjni (#7).
Thanks for putting together this package.
Is there anyway to get access to libsodiums XChaCha20-Poly1305-IETF?