LTI: Use received nonce in auth - refs BT#16379

pull/3114/head
Angel Fernando Quiroz Campos 6 years ago
parent fa33f5be0e
commit 46d51264e6
  1. 6
      plugin/ims_lti/auth.php

@ -101,7 +101,11 @@ try {
$jwtContent['aud'] = $tool->getClientId(); $jwtContent['aud'] = $tool->getClientId();
$jwtContent['iat'] = time(); $jwtContent['iat'] = time();
$jwtContent['exp'] = time() + 60; $jwtContent['exp'] = time() + 60;
$jwtContent['nonce'] = md5(microtime().mt_rand()); $jwtContent['nonce'] = $nonce;
if (empty($nonce)) {
$jwtContent['nonce'] = md5(microtime().mt_rand());
}
// User info // User info
if ($tool->isSharingName()) { if ($tool->isSharingName()) {

Loading…
Cancel
Save