#time

rusthotp

A simple, pure Rust implementation of the HMAC-based One-Time Password algorithm specified in RFC 4226

1 unstable release

Uses old Rust 2015

0.1.0 Apr 23, 2017

#788 in #time


Used in 2 crates (via rustotp)

MIT license

3KB

RusTOTP

A simple Rust implementation of the Time-Based One Time Password (TOTP) and HMAC-based One-Time Password algorithms specified in RFC 6238 and RFC 4226, respectively.

Usage

Build the command-line client from the rustotp_cli crate:

$ cd rustotp_cli
$ cargo build

Generate a single OTP from a key:

$ ./target/debug/rustotp_cli 42
663792

Or, start an interactive session where a new OTP will be generated at every timestep, with a visual progress bar:

$ ./target/debug/rustotp_cli 42 --timestep=5 --interactive
495515
#####
#####
783920
#####
#####
484936
#####
####

Dependencies

~39KB