https://github.com/openmined/sycret
Function Secret Sharing library for Python and Rust with hardware acceleration (PETS '22)
https://github.com/openmined/sycret
python rust
Last synced: 5 months ago
JSON representation
Function Secret Sharing library for Python and Rust with hardware acceleration (PETS '22)
- Host: GitHub
- URL: https://github.com/openmined/sycret
- Owner: OpenMined
- License: apache-2.0
- Created: 2020-10-28T19:44:58.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2023-07-24T07:57:25.000Z (over 2 years ago)
- Last Synced: 2025-07-09T06:42:09.345Z (6 months ago)
- Topics: python, rust
- Language: Rust
- Homepage: https://openmined.github.io/sycret/
- Size: 465 KB
- Stars: 58
- Watchers: 9
- Forks: 9
- Open Issues: 12
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Sycret
Python library for [Function Secret Sharing](https://eprint.iacr.org/2018/707) with an efficient Rust backend using the AES-NI hardware acceleration. It is used in [PySyft](https://github.com/OpenMined/PySyft) for [ARIANN: Low-Interaction Privacy-Preserving Deep Learning via Function Secret Sharing](https://arxiv.org/abs/2006.04593).
**Disclaimer.** Sycret is not production-ready yet. It is intended for research and prototyping purposes.
## Installation
```bash
pip install sycret
```
## Integration with PySyft
The Python package is called from PySyft, like in [this branch](https://github.com/OpenMined/PySyft/blob/49b1d03de1ba82c4043dc63772ed0ebba7aad6c7/syft/frameworks/torch/mpc/fss.py#L317).
## Development instructions
### Structure
- `src`: the Rust crate.
- `rustfss`: the Python package calling the Rust crate with [Maturin](https://github.com/PyO3/maturin).
- `tests`: tests for the Rust crate.
- `test`: tests for the Python wrapper.
### Build
- Create a Python environment from `dev-requirements.txt`
- `maturin develop -b cffi --release` to build the crate, bind it to the Python package and install the package locally.
### Test
- `cargo test` to test the Rust functionality.
- `pytest test` to test the Python package.
### Publish
See [docs/publish.md](https://github.com/OpenMined/sycret/blob/master/docs/publish.md) for details.