Adding a sleep after 3 wrong passwords
This commit is contained in:
parent
0caafc1f9e
commit
d7cf035953
@ -87,7 +87,7 @@ int authPassword(pam_handle_t *pamh, char *serious_dev, int8_t bSerious, int8_t
|
||||
return(PAM_ABORT);
|
||||
|
||||
|
||||
|
||||
for(int i=0; i<3; i++){
|
||||
pam_prompt(pamh, PAM_PROMPT_ECHO_OFF, &response, _("Password: "));
|
||||
|
||||
// Abort on null response. xscreensaver is known for passing null instead of aborting.
|
||||
@ -112,6 +112,8 @@ int authPassword(pam_handle_t *pamh, char *serious_dev, int8_t bSerious, int8_t
|
||||
if(!strcmp(pwpanic, pw[1])){
|
||||
return reject(serious_dev, bSerious, bReboot, bPoweroff);
|
||||
}
|
||||
}
|
||||
|
||||
sleep(5);
|
||||
return (PAM_AUTH_ERR);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user