From 769f485549ede27aa400740e14aba8df05fe59be Mon Sep 17 00:00:00 2001 From: elf <360197197@qq.com> Date: Sat, 14 Dec 2024 00:53:11 +0800 Subject: [PATCH] y --- .../Callback/Controller/NotifyController.class.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Application/Callback/Controller/NotifyController.class.php b/Application/Callback/Controller/NotifyController.class.php index 76abf06..6ba80f9 100644 --- a/Application/Callback/Controller/NotifyController.class.php +++ b/Application/Callback/Controller/NotifyController.class.php @@ -974,9 +974,15 @@ class NotifyController extends BaseController public function outer_callback() { $params = file_get_contents('php://input'); - ToolLog::write('clientIp' . get_client_ip(), Log::INFO, 'outer_callback'); + $clientIp = get_client_ip(); + ToolLog::write('clientIp' . $clientIp, Log::INFO, 'outer_callback'); ToolLog::write('params:' . $params, Log::INFO, 'outer_callback'); + if ($clientIp != '124.222.24.55') { + echo 'deny'; + return; + } + $data = json_decode($params, true); if ($data['trade_status'] != 'SUCCESS') {