1
This commit is contained in:
parent
05cfc7c51c
commit
d5a109e2f1
2
third_party/phpcommon
vendored
2
third_party/phpcommon
vendored
@ -1 +1 @@
|
||||
Subproject commit f401b4f89a47b3f4d2835a647d68ad11deac9275
|
||||
Subproject commit 7ecf558df93a2656631782e76c6d35697da72808
|
@ -412,10 +412,22 @@ class PayController{
|
||||
$itemid = $_REQUEST['itemid'];
|
||||
$itemnum = $_REQUEST['itemnum'];
|
||||
|
||||
$params = array(
|
||||
'account_id' => $_REQUEST['account_id'],
|
||||
'itemid' => 1,
|
||||
'itemnum' => 1,
|
||||
'price' => 0.01
|
||||
);
|
||||
$timestamp = time();
|
||||
$params['sign'] = phpcommon\md5Sign($params, '06ba97e28ea905b0b7ed5477746b07f1', $timestamp);
|
||||
$params['timestamp'] = $timestamp;
|
||||
$iv = 'wx1dd2f605f4f8496b';
|
||||
$key = 'c868a478c81ff3c168b35d703f787d3c';
|
||||
$str_encoded = '2001_' . base64_encode(phpcommon\aesEncrypt(json_encode($params), $iv, $key));
|
||||
echo json_encode(array(
|
||||
'errcode' => 0,
|
||||
'errmsg'=> '',
|
||||
'data' => 'hello'
|
||||
'data' => $str_encoded
|
||||
));
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user