From 51acacec80f3d20bd85f16ff574246ebb086e12d Mon Sep 17 00:00:00 2001 From: Jan Schneider Date: Mon, 8 Nov 2010 22:47:50 +0100 Subject: [PATCH] Use Randomid. --- turba/lib/Form/CreateAddressBook.php | 2 +- turba/lib/Turba.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/turba/lib/Form/CreateAddressBook.php b/turba/lib/Form/CreateAddressBook.php index d3c403907..2cfb4d282 100644 --- a/turba/lib/Form/CreateAddressBook.php +++ b/turba/lib/Form/CreateAddressBook.php @@ -42,7 +42,7 @@ class Turba_Form_CreateAddressBook extends Horde_Form 'name' => $this->_vars->get('name'), 'desc' => $this->_vars->get('description'), ); - return $driver->createShare(md5(mt_rand()), $params); + return $driver->createShare(strval(new Horde_Support_RandomId()), $params); } } diff --git a/turba/lib/Turba.php b/turba/lib/Turba.php index 2c97541db..b134c208b 100644 --- a/turba/lib/Turba.php +++ b/turba/lib/Turba.php @@ -450,7 +450,7 @@ class Turba { continue; } - $sourceKey = md5(mt_rand()); + $sourceKey = strval(new Horde_Support_RandomId()); try { $share = $driver->createShare( $sourceKey, -- 2.11.0