mirror of
https://github.com/Piwigo/Piwigo.git
synced 2025-04-27 11:49:56 +03:00
fixes #373 ask a longer random string
to openssl_random_pseudo_bytes, to avoid reaching the base64 trailing "=" signs
This commit is contained in:
parent
bfe4ff3e2f
commit
034f689f8e
1 changed files with 2 additions and 2 deletions
|
@ -71,7 +71,7 @@ function generate_key($size)
|
|||
str_replace(
|
||||
array('+', '/'),
|
||||
'',
|
||||
base64_encode(openssl_random_pseudo_bytes($size))
|
||||
base64_encode(openssl_random_pseudo_bytes($size+10))
|
||||
),
|
||||
0,
|
||||
$size
|
||||
|
@ -260,4 +260,4 @@ function pwg_unset_session_var($var)
|
|||
return true;
|
||||
}
|
||||
|
||||
?>
|
||||
?>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue