diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/iperf_auth.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/iperf_auth.c b/src/iperf_auth.c index 5ba2e08..d0484e4 100644 --- a/src/iperf_auth.c +++ b/src/iperf_auth.c @@ -62,7 +62,7 @@ void sha256(const char *string, char outputBuffer[65]) int check_authentication(const char *username, const char *password, const time_t ts, const char *filename){ time_t t = time(NULL); time_t utc_seconds = mktime(localtime(&t)); - if ( (utc_seconds - ts) < 10 && (utc_seconds - ts) > 0 ){ + if ( (utc_seconds - ts) > 10 || (utc_seconds - ts) < -10 ) { return 1; } |