ttyaskpass 2.0.0-alpha

a safely passphrase prompt library.
Documentation

ttyaskpass

travis-ci crates license docs.rs

ttyaskpass

A safely passphrase prompt library and application, support Chroma-Hash-like colorhash, use seckey protecte password.

usage

library:

extern crate ttyaskpass;
use ttyaskpass::askpass;

fn main() {
	askpass("Password:", |pass| {
        print!("Your password is {}", pass.iter().collect::<String>());

        Ok(())
    }).unwrap();
}

see readme.rs and ttyaskpass.rs.

application:

env SSH_ASKPASS=ttyaskpass ssh-add </dev/null