Open hohaidang opened 2 months ago
extern crate pam; pub fn main() { let service = ""; let user = ""; let password = "";
let mut auth = pam::Authenticator::with_password(service).unwrap(); auth.handler_mut().set_credentials(user, password); if auth.authenticate().is_ok() && auth.open_session().is_ok() { println!("Successfully opened a session!"); } else { println!("Authentication failed =/"); }
}
There is no pam::Authenticator anymore??
extern crate pam; pub fn main() { let service = "";
let user = "";
let password = "";
}
There is no pam::Authenticator anymore??