Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
List of Pairing Libraries

Pairings can be used for all kinds of advanced cryptographic schemes such as Encryption (Identity-based, Attribute-based, Predicate-based, etc.), Signatures, Zero-Knowledge Proofs, etc. It is in no particular order.

PBC

Provides multiple types of Elliptic Curve groups with appropriate pairings on top of them. Code repository resides here.

License: LGPL
Language: C
Thesis: On the Implementation of Pairing-Based Cryptography by Ben Lynn (2007)

RELIC Toolkit

License: LGPL v2.1
Language: C

TinyPBC

License: Unlicensed
Language: nesC

MIRACL

License: AGPL v3 or later, proprietary possible Language: C, C++ (wrapper)

TEPLA (University of Tsukuba Elliptic Curve and Pairing Library)

License: 3-clause BSD
Language: C
Paper: Software Implementation of a Pairing Function for Public Key Cryptosystems by Kanbara, Yusuke; Teruya, Tadanori; Kanayama, Naoki; Nishide, Takashi; Okamoto, Eiji (2015)

Charm

Uses PBC (or MIRACL or RELIC)

License: LGPL v3
Language: Python

jPBC

Uses PBC for performance, but is also full implemented in Java. Code can be found on SourceForge.

License: LGPL v3
Language: Java

arcanum-pbc under the arcanum umbrella

Repackaged from jPBC.

License: LGPL
Language: Java

ate-pairing

License: 3-clause BSD
Language: C++, Java (wrapper)
Paper: High-Speed Software Implementation of the Optimal Ate Pairing over Barreto-Naehrig Curves by Jean-Luc Beuchat, Jorge Enrique González Díaz, Shigeo Mitsunari, Eiji Okamoto, Francisco Rodríguez-Henríquez, Tadanori Teruya (2010)

Tate Pairing in Intel® Integrated Performance Primitives (Intel® IPP)

License: Commercial
Language: C/C++

gezel-elliptic-curve-crypto (Backup)

Contains hardware-accelerated pairings.

License: ?/unlicensed
Language: VHDL + C++

java-pairing

Implementation of etaT, Tate, modified Tate and Hyper Elliptic Pairings.

License: ?/unlicensed
Language: Java

NEON optimized pairing

Pairing with use of NEON instruction set for ARMv7+. Instantiation through ABE.

License: Public Domain
Language: C + Assembler(NEON)
Platform: ARMv7

ow_on_android

Contains an etaT pairing implementation here.

License: propietary Language: Java

libsnark

Contains an "edwards" pairing implementation here.

License: MIT
Language: C++

cryptosage

CryptoSage contains many crypto primitives built on top of SageMath.

License: ?/unlicensed
Language: Python

jspairings

Pure JavaScript implementation for Eta, Ate, Tate pairings.

License: ?/unlicensed
Language: JavaScript

bnpairings

License: GPL v2 Language: Java

bouncycastle-ext

Pairings on top of BouncyCastle.

License: GPL v3 Language: Java

FiniteFieldComputations

Efficient Pairings for NEON.

License: ?
Language: C + ASM_446/ASM_638
Platform: ARMv7 & ARMv8

Thesis: Efficient Implementations of Pairing-BasedCryptography on Embedded Systems

TinyPairing

Efficient Pairings for wireless sensors.

License: LGPL v?
Language: nesC
Platform: TinyOS

Paper: TinyPairing: A Fast and Lightweight Pairing-Based Cryptographic Library for Wireless Sensor Networks

PBC through CPABE in Priv.io

The Priv.io project uses CPABE in JavaScript and compiled it to JavaScript from C using Emscripten.

License: ?
Language: JavaScript/asm.js
Platform: Any JavaScript interpreter

Code:

DCLXVI: Pairing computation on AMD64 processors

License: Public Domain
Language: C+QHASM

Code: dclxvi-20130329.tar.bz2
Paper: New software speed records for cryptographic pairings

Patched code: agl/dclxvi for use in agl/pond (a Go library)

bn

License: MIT or Apache 2.0
Language: Rust

Notes:

  • Asymmetric pairing over Barreto-Naehrig curve

Pairing-based cryptography for Go

License: GPL 3.0 or LGPL 3.0 Language: Go

Notes:

  • Wrapper around PBC (libpbc)

Crypt::PBC

License: LGPL Language: Perl

Notes:

  • Wrapper around PBC (libpbc)

ibejs

License: AGPL 3.0 Language: JavaScript

Notes:

  • This IBE implementation contains a PBC implementation

bn256

License: BSD-style
Language: Go

Notes:

  • 256 bit Barreto-Naehrig curve for 128 bit security

herumi/mcl

License: BSD 3-clause
Language: ASM
Langauge bindings: C++, Java, C#

Notes:

arybczak/haskell-mcl

License: BSD 3-clause
Language: Haskell

ECCelerate

Java crypto provider and offers pairings over Barreto-Naehrig curves (Type-2 and Type-3).

License: commercial, special free license agreements for research and teaching available
Language: Java, JCE

@artjomb

This comment has been minimized.

Copy link
Owner Author

@artjomb artjomb commented Apr 22, 2016

Missing frameworks: PandA: Pairings and Arithmetic (paper exists, but can't find the software package)

@sebastinas

This comment has been minimized.

Copy link

@sebastinas sebastinas commented Feb 28, 2017

ECCelerate also included a pairing implementation:

ECCelerate

Java crypto provider and offers pairings on Barreto-Naehrig curves.

License: commercial, special license agreements for research and teaching available
Language: Java

@artjomb

This comment has been minimized.

Copy link
Owner Author

@artjomb artjomb commented Dec 2, 2017

ECCelerate is now integrated

@aniketpkate

This comment has been minimized.

Copy link

@aniketpkate aniketpkate commented Jul 27, 2018

@sshravan

This comment has been minimized.

Copy link

@sshravan sshravan commented Apr 4, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment