yubico 0.11.0

Yubikey client API library
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
extern crate yubico;

use yubico::config::*;
use yubico::verify;

fn main() {
    let config = Config::default()
        .set_client_id("CLIENT_ID")
        .set_key("API_KEY");

    match verify("OTP", config) {
        Ok(answer) => println!("{}", answer),
        Err(e) => println!("Error: {}", e),
    }
}