mirror of
https://git.proxmox.com/git/proxmox
synced 2025-06-15 00:03:38 +00:00
auth-api: fixup examples
These were missing the new client-ip parameter in the auth function calls which was introduced to support `PAM_RHOST`. Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
parent
ec5e2a5d90
commit
4ca8dbf74f
@ -43,9 +43,9 @@ async fn run() -> Result<(), Error> {
|
|||||||
|
|
||||||
let realm = proxmox_auth_api::Pam::new("test");
|
let realm = proxmox_auth_api::Pam::new("test");
|
||||||
if changepass {
|
if changepass {
|
||||||
realm.store_password(&username, &password)?;
|
realm.store_password(&username, &password, None)?;
|
||||||
} else {
|
} else {
|
||||||
realm.authenticate_user(&username, &password).await?;
|
realm.authenticate_user(&username, &password, None).await?;
|
||||||
}
|
}
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
|
Loading…
Reference in New Issue
Block a user