Warning
|
The Lua bindings for libsodium provided here are in a very early stage of
development, thus do not use them in a production environment!
|
Besides having a working compiler toolchain available you will need:
-
cmake
-
libsodium
git clone git://github.com/morfoh/lua-sodium.git
cd lua-sodium
mkdir build
cd build
cmake ../
cmake ../ -DINSTALL_CMOD=/usr/local/lib/lua/5.1
make
sudo make install
By default CMake will use the pre-generated bindings that are include in the project.
To be able to re-generate the bindings, you will need to install
LuaNativeObjects and set the
CMake variable USE_PRE_GENERATED_BINDINGS
to FALSE
.
cmake ../ -DUSE_PRE_GENERATED_BINDINGS=FALSE
Mandantory for re-generating Lua bindings from *.nobj.lua
files:
-
LuaNativeObjects, this is the bindings generator used to convert the
*.nobj.lua
files into a native Lua module.
Optional for re-generating documentation
To not re-generate documentation by luadocs when re-generating the bindings
you have to to set the CMake variable GENERATE_LUADOCS
to FALSE
.
cmake ../ -DUSE_PRE_GENERATED_BINDINGS=FALSE -DGENERATE_LUADOCS=FALSE
Important
|
Currently only curve25519 is supported as it is the default used in libsodium! |
Important
|
Currently only curve25519xsalsa20poly1305 is supported as it is the default used in libsodium! |
C Function | Status |
---|---|
crypto_box_primitive |
DONE |
crypto_box_publickeybytes |
DONE |
crypto_box_secretkeybytes |
DONE |
crypto_box_beforenmbytes |
DONE |
crypto_box_noncebytes |
DONE |
crypto_box_zerobytes |
DONE |
crypto_box_boxzerobytes |
DONE |
crypto_box_macbytes |
DONE |
crypto_box_keypair |
TODO |
crypto_box_beforenm |
TODO |
crypto_box_afternm |
TODO |
crypto_box_open_afternm |
TODO |
crypto_box |
TODO |
crypto_box_open |
TODO |