function _openid_nonce

Same name and namespace in other branches
  1. 7.x drupal-7.x/modules/openid/openid.inc \_openid_nonce()

Return a nonce value - formatted per OpenID spec.

Archivo

drupal-6.x/modules/openid/openid.inc, line 185
OpenID utility functions.

Código

function _openid_nonce() {
  // YYYY-MM-DDThh:mm:ssTZD UTC, plus some optional extra unique chars
  return gmstrftime('%Y-%m-%dT%H:%M:%S%Z') . chr(mt_rand(0, 25) + 65) . chr(mt_rand(0, 25) + 65) . chr(mt_rand(0, 25) + 65) . chr(mt_rand(0, 25) + 65);
}