|
|
@@ -57,7 +57,7 @@ class Lakala
|
|
|
$baseRequestVO = new BaseRequestVO();
|
|
|
$baseRequestVO->reqData = $reqInfo;
|
|
|
$baseRequestVO->termExtInfo = $termExtInfo;
|
|
|
- $baseRequestVO->timestamp = random(8);
|
|
|
+ $baseRequestVO->timestamp = mt_rand(10000000, 99999999);
|
|
|
$baseRequestVO->ver = $this->version;
|
|
|
|
|
|
return json_encode($baseRequestVO, JSON_UNESCAPED_UNICODE);
|
|
|
@@ -85,7 +85,7 @@ class Lakala
|
|
|
$baseRequestVO = new BaseRequestVO();
|
|
|
$baseRequestVO->reqData = $reqInfo;
|
|
|
$baseRequestVO->termExtInfo = $termExtInfo;
|
|
|
- $baseRequestVO->timestamp = time();
|
|
|
+ $baseRequestVO->timestamp = mt_rand(10000000, 99999999);
|
|
|
$baseRequestVO->ver = $this->version;
|
|
|
|
|
|
$body = json_encode($baseRequestVO, JSON_UNESCAPED_UNICODE);
|
|
|
@@ -119,7 +119,7 @@ class Lakala
|
|
|
//签名
|
|
|
public function getAuthorization($body)
|
|
|
{
|
|
|
- $nonceStr = random(8);
|
|
|
+ $nonceStr = mt_rand(10000000, 99999999);
|
|
|
$timestamp = time();
|
|
|
|
|
|
$message = $this->appid . "\n" . $this->mchSerialNo . "\n" . $timestamp . "\n" . $nonceStr . "\n" . $body . "\n";
|