Rache is a radix-based homomorphic encryption algorithm that utilizes a base scheme, leveraging the fact that in practical usage, homomorphic operations have far lower performance overhead than the encryption itself. Rache uses caching of certain "interesting" pre-computed ciphertexts (which happen to be powers of a particular number, hence radices) in order to gain performance benefits over naively encrypting new values, using homomorphic operations.
The Rache paper that premiered in SIGMOD'23 uses two schemes, Paillier and Symmetria, and shows that great performance benefits can be gained in systems using Rache over purely one or the other. This project aims to
- Apply the functionality of Rache to schemes implemented by the Microsoft SEAL library.
- Implement a novel encryption scheme, Inche, that utilizes only a single addition to construct a new ciphertext.
IMPORTANT DISCLAIMER: This project is for research purposes, it is not secure! Do not use this in production.
- CMake 3.13+
- A C++ compiler meeting the C++17 standard (Microsoft SEAL states that
clang++
results in faster binaries thang++
) - Microsoft SEAL (more here)
- Clone this repository and move into the source directory with
# Download source code and switch into directory
$ git clone https://github.com/jly02/RacheAL.git
$ cd RacheAL/src
- Run
git submodule init
, and thengit submodule update
. This will install vcpkg, which is required for building unit tests withgtest
. - Run
cmake .
to setup the project, andmake
to build the repository and/or run tests. - A benchmarking executable is provided. To run this, simply use
./bin/benchmarks
. You may also notice thattest_suite
is also generated, you may use this to re-run the tests for the version at your compilation time.
You have two options for installing Microsoft SEAL. The method you choose will greatly impact the performance of these encryption methods.
Head over to the SEAL repo, clone the repository, and follow the instructions in the repository to install SEAL locally or globally on your device.
Alternatively, you can install SEAL using vcpkg
. After step 2 and before step 3, open the file vcpkg.json
, which should currently look like this
{
"dependencies": [
"gtest"
]
}
After "gtest"
, add "seal"
so it now looks like
{
"dependencies": [
"gtest",
"seal"
]
}
And then you'll be able to continue from step 3 like normal. It should be noted that this method results in everything running far slower than it would by installing from source, and is not recommended.