#big-int #gmp #num-bigint #cryptography

rust-bigint

Common traits and methods for multiple BigInt implementations

2 stable releases

1.2.0 Sep 16, 2021
1.1.0 Sep 21, 2020

#461 in Algorithms

Download history 38/week @ 2023-12-16 39/week @ 2023-12-23 33/week @ 2023-12-30 959/week @ 2024-01-06 1324/week @ 2024-01-13 1724/week @ 2024-01-20 1905/week @ 2024-01-27 1850/week @ 2024-02-03 1307/week @ 2024-02-10 1561/week @ 2024-02-17 1773/week @ 2024-02-24 811/week @ 2024-03-02 1208/week @ 2024-03-09 2371/week @ 2024-03-16 1491/week @ 2024-03-23 1285/week @ 2024-03-30

6,565 downloads per month
Used in 9 crates (5 directly)

MIT license

32KB
779 lines

rust-bigint

Provides traits for common functionality across several Rust BigInt implementations

Example interaction:

// import BigInt from this library. use a feature flag to select the BigInt you need
// also, pull one or more traits from this library into scope
use rust_bigint::BigInt;
use rust_bigint::traits::Converter;
 
let number = BigInt::from(42);
// now use one of the methods exposed by the converter trait
let hex_str = number.to_hex();

See the traits for more examples.


lib.rs:

Provides traits for common functionality across several Rust BigInt implementations

Example interaction:

// import BigInt from this library. use a feature flag to select the BigInt you need
// also, pull one or more traits from this library into scope
use rust_bigint::BigInt;
use rust_bigint::traits::Converter;

let number = BigInt::from(42);
// now use one of the methods exposed by the converter trait
let hex_str = number.to_hex();

See the traits for more examples.

Dependencies

~0.4–1.3MB
~29K SLoC