Skip to content

Commit b25111d

Browse files
committed
linked #7: 添加 tx 的存在的校验
1 parent 962a303 commit b25111d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

woocommerce-erc20-payment-gateway.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,9 @@ function inkerk_thankyour_request() {
7272
$data = $_POST;
7373
$order_id = $data['orderid'];
7474
$tx = $data['tx'];
75+
if (strlen($tx) != 66 || substr($tx,0,2) != '0x'){
76+
return ;
77+
}
7578
/**
7679
* 获取到订单
7780
*/

0 commit comments

Comments
 (0)