Library for the Signal Private Group System.
Work in progress. Subject to change without notice, use outside Signal not yet recommended.
This library provides zero-knowledge group functionality through several layers of APIs. From lower-level to higher-level:
-
internal.rs
provides the actual Rust implementations, based on Rust structures. -
simpleapi.rs
provides wrapper functions around internal.rs functions that useserde
to serialize/deseralize byte arrays into Rust structures. -
ffiapi.rs
andffiapijava.rs
provide wrapper functions aroundsimpleapi.rs
functions to export them via C and JNI, respectively. -
The subdirectories under
ffi
contain code in various host languages for accessing the exported functions:-
Under
c
is azkgroup.h
header file. -
Under
android
is aZKGroup.java
file and instructions for building an aar. -
Under
node
is some example code for declaring the FFI functions in javascript.
-
The rust-toolchain.toml file should get things automatically setup for you provided you are using rustup. See it for the toolchain and channel and targets in use for this build.
Run ./gradlew tasks
and see make
tasks under the "Rust tasks" group.