3 stable releases

1.0.2 Jan 22, 2024
1.0.0 Jan 19, 2024

#5 in #milagro

Download history 29421/week @ 2024-07-21 26180/week @ 2024-07-28 30650/week @ 2024-08-04 41326/week @ 2024-08-11 26803/week @ 2024-08-18 36479/week @ 2024-08-25 41354/week @ 2024-09-01 36202/week @ 2024-09-08 33376/week @ 2024-09-15 36679/week @ 2024-09-22 40128/week @ 2024-09-29 43846/week @ 2024-10-06 39937/week @ 2024-10-13 45276/week @ 2024-10-20 33600/week @ 2024-10-27 44692/week @ 2024-11-03

165,258 downloads per month
Used in 53 crates (4 directly)

Apache-2.0

1MB
28K SLoC

Apache Milagro Crypto Library - Rust Version

Updates

BLS12-381 has been updated to the the most recent standards being bls-signatures-04 and hash-to-curve-09.

Updated to Rust 2018.

This version of the library requires Version 1.31+ of Rust for the 2018 edition.

AMCL version 2 is distributed as a cargo crate.

Modulues (namespaces) are used to separate different curves.

Testing

Unit testing can be done using cargo testing framework.

Note: --all-features may be replaced by --features xx where xx is the desired feature e.g. bls381.

cargo test --all --all-features --release

Benchmarking

cargo bench --features bench

Features and Protocol

  • Elliptic Curves
    • ed25519
    • c25519
    • nist256
    • brainpool
    • anssi
    • hifive
    • goldilocks
    • nist384
    • c41417
    • nist521
    • nums256w
    • nums256e
    • nums384w
    • nums384e
    • nums512w
    • nums512e
    • secp256k1
  • Pairing-Friendly Elliptic Curves
    • bn254
    • bn254cx
    • fp256bn
    • fp512bn
    • bls383
    • bls381
    • bls461
    • bls24
    • bls48
  • RSA
    • rsa2048
    • rsa3072
    • rsa4096
  • SHA-2
    • SHA2-256
    • SHA2-384
    • SHA2-512
  • SHA-3
    • SHA3-224
    • SHA3-256
    • SHA3-384
    • SHA3-512
    • SHAKE-128
    • SHAKE-256

Note SHA-2 and SHA-3 features will always be compiled however all other features require the feature flag --features xx

Dependencies

~3.5MB
~75K SLoC