pam_fail_delay -- specify delay time to use on authentication error


#include <security/pam_appl.h>

int pam_fail_delay(pam_handle_t * pamh, unsigned int micro_sec);


pam_fail_delay() specifies the minimum delay for the PAM library to use when an authentication error occurs. The actual delay can vary by as much at 25%. If this function is called multiple times, the longest time specified by any of the call will be used.

The delay is invoked if an authentication error occurs during the pam_authenticate() or pam_chauthtok() function calls.

Independent of the success of pam_authenticate() or pam_chauthtok(), the delay time is reset to its default value of 0 when the PAM library returns control to the application from these two functions.

Return Value



Note: Errors may be translated to text with pam_strerror().