1
0
mirror of https://github.com/Yubico/yubikey-val.git synced 2025-03-03 18:29:18 +01:00

Refactor.

- KSMDecryptOTP returns array or bool false on failure.
This commit is contained in:
Jean Paul Galea 2015-07-17 22:55:00 +02:00
parent 9e81b1fd72
commit 1e2568da3c

View File

@ -274,8 +274,7 @@ if (array_key_exists('__YKVAL_KSM_CURL_OPTS__', $baseParams))
{
$curlopts = $baseParams['__YKVAL_KSM_CURL_OPTS__'];
}
$otpinfo = KSMdecryptOTP($urls, $myLog, $curlopts);
if (!is_array($otpinfo))
if (($otpinfo = KSMdecryptOTP($urls, $myLog, $curlopts)) === FALSE)
{
sendResp(S_BAD_OTP, $myLog, $apiKey);
}