/** * Token = md5(secretKey+clientIP+session+profileID) * @param $session * @param $clientIP * @param $rofileID * @return string: token+profileid. */ public static function makeTokenStream($session, $clientIP, $profileID) { $secretKey = Yii::app()->params['secretKey']; $token = self::checksum($secretKey . $clientIP . $session . $profileID); CUtils::log('SecretKey:' . $secretKey . '|session:' . $session . '|ClientIP:' . $clientIP . '|Token:' . $token); return $token . $profileID; }