Issue #1787876 by Albert Volkman, cirage, BrockBoland: Add return docs for drupal_get_token() function

8.0.x
Jennifer Hodgdon 2012-12-04 09:50:15 -08:00
parent 5e69528167
commit dd8e0db601
1 changed files with 5 additions and 0 deletions

View File

@ -4728,6 +4728,11 @@ function drupal_get_private_key() {
* *
* @param $value * @param $value
* An additional value to base the token on. * An additional value to base the token on.
*
* @return string
* A 43-character URL-safe token for validation, based on the user session ID,
* the global $drupal_hash_salt variable from settings.php, and the
* 'drupal_private_key' configuration variable.
*/ */
function drupal_get_token($value = '') { function drupal_get_token($value = '') {
return drupal_hmac_base64($value, session_id() . drupal_get_private_key() . drupal_get_hash_salt()); return drupal_hmac_base64($value, session_id() . drupal_get_private_key() . drupal_get_hash_salt());