- Timestamp:
- 03/12/07 14:41:02 (2 years ago)
- Files:
-
- EMS/freeauthd.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
EMS/freeauthd.php
r8 r9 414 414 if($secret != "") 415 415 { 416 // New install default, not sure what else to do here.... 417 fputs($log, "$secret\n"); 418 if($secret == "0123456789abcdef") 416 if(checkOTP($user, $output)) 419 417 { 420 fputs($log, date("M j H:i:s")." EMS FreeAuth: Login ok for ".$user."\n");421 $reason = "ACCEPT\n";422 $reply = chr(2);423 } else if(checkOTP($user, $output)) {424 418 fputs($log, date("M j H:i:s")." EMS FreeAuth: Login ok for ".$user."\n"); 425 419 $reason = "ACCEPT\n"; … … 592 586 if(strlen($otphash) != 16) 593 587 return(false); 588 589 // Treat this as a dummy/testing/initisation code and authenticated true no matter what input. 590 if($otphash == "0123456789abcdef") 591 return(true); 592 594 593 $maxperiod = 3; // in minutes +/- 3 minutes 595 594 $time = round(gmdate("U") / 60);
