Skip to main content

Python bindings for relic

python-relic (pyrelic for short) provides Python bindings for relic. Note though, that the bindings are driven by my personal needs and they do not cover the full relic API.

Dependencies

pyrelic requires the following dependencies to successfully build and install:

  • relic >= 0.5.0 with pairing support enabled.
  • Cython >= 0.28 (optional, only for building). If Cython is not available, the C files are not regenerated from their source.
  • pkgconfig (optional, only for building). If pkgconfig is not available, the build system assumes that relic can be linked as -lrelic.

Quick installation guide

If you are running Ubuntu 20.04, the easiest way to install pyrelic is via my PPA:

sudo add-apt-repository -u ppa:s-ramacher/ait
sudo apt install python3-pyrelic

It comes with a pre-built version of relic configured for the pairing-friendly BLS12-381 curve.

Otherwise, pyrelic can be installed via pip:

pip install python-relic

or by running:

python3 setup.py install

Note though that these two approaches require a pairing-enabled build of relic to be available.

Examples

pyrelic includes some examples that demonstrate the use of the module and also showcases some pairing-based schemes:

License

The code is licensed under the MIT license and was written by Sebastian Ramacher (AIT Austrian Institute of Technology).

Acknowledgements

This work has been partially funded by the European Union’s Horizon 2020 research and innovation programme under grant agreement No 871473 (KRAKEN) and by ECSEL Joint Undertaking under grant agreement No 826610 (Comp4Drones).

Metadata

Release files for python-relic 0.3.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for python-relic 0.3.1
File Size Uploaded Provenance
python-relic-0.3.1.tar.gz 14.2 kB Without provenance Details

Release files / python-relic-0.3.1.tar.gz

Download URL python-relic-0.3.1.tar.gz
Size 14.2 kB
Tags Source
SHA-256 checksum
How to use checksums
cc30051becf741b77bd6c028b2d69536c702acdc933c8041e8deff9c0ebfeb8b
BLAKE2b-256 checksum
How to use checksums
f48e97bcb1eb2f7e919e91f150d77984b02162852a79760d611a03d3e8329c90
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.0 CPython/3.9.12

Security for python-relic 0.3.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page