A minimal JNI wrapper over libsodium. This is now deprecated. Kalium-JNI (now called libsodium-jni) seems to have come up with a similar design to this repository with regards to function exports. Since libsodium-jni has both addressed my original complaints and is actively maintained (at least more than this repository), I would advise using it instead.
Other Java Options For Libsodium
What's the difference?
Kalium is a very sensible Java wrapper over libsodium that depends on
jnr-ffi. Kalium takes an OOP approach
whereas Sodium-JNI provides a completely static API, and attempts to use Java primatives over library
Kalium-JNI mimics the Kalium API, but wraps libsodium using SWIG and the JNI. Sodium-JNI exports more
sodium_init, etc.) and doesn't attempt to provide an OOP wrapper. Sodium-JNI started as a fork
of Kalium-JNI, but has diverged significantly in both the build process and wrapper API.
- Android SDK + Android NDK
- Autotools (for building libsodium at the moment)
Make sure you clone this repo with the
--recursive flag set, it depends on libsodium as a submodule at the moment.
build-sodiumjni.sh and a folder
sodiumjni-androidlib will be generated with the debug and release version of the
.aar can be included in an Android studio project
- View issues to see what's being worked on.