From 5fa8e9ad9fcee1cbe5e0e0ae5d5617703bb7ddef Mon Sep 17 00:00:00 2001 From: Olav Morken <olav.morken@uninett.no> Date: Fri, 9 Jul 2010 12:41:41 +0000 Subject: [PATCH] Inline SimpleSAML_Utilities::generateTrackID. Only used in the SimpleSAML_Session class, so move it there. git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@2404 44740490-163a-0410-bde0-09ae8108e29a --- lib/SimpleSAML/Session.php | 2 +- lib/SimpleSAML/Utilities.php | 5 ----- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/lib/SimpleSAML/Session.php b/lib/SimpleSAML/Session.php index 3861b1913..da35c28b1 100644 --- a/lib/SimpleSAML/Session.php +++ b/lib/SimpleSAML/Session.php @@ -129,7 +129,7 @@ class SimpleSAML_Session { return; } - $this->trackid = SimpleSAML_Utilities::generateTrackID(); + $this->trackid = substr(md5(uniqid(rand(), true)), 0, 10); $this->dirty = TRUE; $this->addShutdownFunction(); diff --git a/lib/SimpleSAML/Utilities.php b/lib/SimpleSAML/Utilities.php index 203250748..5b645bdf5 100644 --- a/lib/SimpleSAML/Utilities.php +++ b/lib/SimpleSAML/Utilities.php @@ -259,11 +259,6 @@ class SimpleSAML_Utilities { } return gmdate('Y-m-d\TH:i:s\Z', $instant); } - - public static function generateTrackID() { - $uniqueid = substr(md5(uniqid(rand(), true)), 0, 10); - return $uniqueid; - } /** -- GitLab