rabe-bn 0.4.23

Pairing cryptography with the Barreto-Naehrig curve. Update to use latest rand and serde crates.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// This is an example of three-party Diffie-Hellman key exchange
// Requires two rounds

extern crate rabe_bn;
extern crate rand;

use rand::Rng;
use rabe_bn::Gt;

fn main() {
    let mut rng = rand::thread_rng();

    // Construct private keys
    let alice_sk:Gt = rng.gen();
    println!("alice_sk: {}", alice_sk)
}