From b48d9bf5d412a6f56f3f9ba4bad141ddfe175727 Mon Sep 17 00:00:00 2001 From: alecpl Date: Mon, 7 Sep 2009 12:51:21 +0000 Subject: - Use faster/secure mt_rand() (#1486094) --- program/include/session.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'program/include/session.inc') diff --git a/program/include/session.inc b/program/include/session.inc index ee9bb75ab..bd4e2a1ea 100644 --- a/program/include/session.inc +++ b/program/include/session.inc @@ -245,7 +245,7 @@ function rcube_sess_regenerate_id() $randval = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"; for ($random = "", $i=1; $i <= 32; $i++) { - $random .= substr($randval, rand(0,(strlen($randval) - 1)), 1); + $random .= substr($randval, mt_rand(0,(strlen($randval) - 1)), 1); } // use md5 value for id or remove capitals from string $randval -- cgit v1.2.3