logo

checkpassword-ng

Uniform password checking interface for applications
commit: ff4ccaadd09034770aecc18bbe4dcd4fa3db7414
parent ef5fed245b9f1cf7eadb7bb50f799d8f8afe9d7c
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date:   Wed, 28 Apr 2021 05:01:11 +0200

chkpw: Add sleep

Diffstat:

Mchkpw.c3++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/chkpw.c b/chkpw.c @@ -11,7 +11,7 @@ #include <pwd.h> /* getpwnam */ #include <stdio.h> /* sprintf() */ #include <string.h> /* strerror, strcmp */ -#include <unistd.h> /* crypt */ +#include <unistd.h> /* crypt, sleep */ #ifdef __GLIBC__ // GNU's Not POSIX #include <crypt.h> @@ -85,6 +85,7 @@ chkpw(const char *username, const char *password, struct chkpw_extra *chkpw_extr } else { + sleep(2); return CHKPW_INVALID; }