Skip to content

Commit

Permalink
refactor on the signature generation to simplify it a bit
Browse files Browse the repository at this point in the history
  • Loading branch information
Chris Cornutt committed Nov 19, 2014
1 parent f84cfbc commit f12e259
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Yubikey/Validate.php
Original file line number Diff line number Diff line change
Expand Up @@ -300,9 +300,9 @@ public function check($otp, $multi = false)
'timestamp' => '1'
);
ksort($params);
$params['h'] = $this->generateSignature($params);

$signature = $this->generateSignature($params);
$url = '/wsapi/2.0/verify?'.http_build_query($params).'&h='.$signature;
$url = '/wsapi/2.0/verify?'.http_build_query($params);
$hosts = ($multi === false) ? array(array_shift($this->hosts)) : $this->hosts;

return $this->request($url, $hosts, $otp, $nonce);
Expand Down

0 comments on commit f12e259

Please sign in to comment.