From 15f2b30165286340fad5d07a438deda333acb18f Mon Sep 17 00:00:00 2001 From: RomanTicka Date: Wed, 30 Apr 2025 12:07:13 +0200 Subject: [PATCH] Add IPv6 flag to validation of IPC field in TBCardPay --- src/Chaching/Drivers/TBCardPay/Request.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Chaching/Drivers/TBCardPay/Request.php b/src/Chaching/Drivers/TBCardPay/Request.php index 3559156..4b8ebf7 100644 --- a/src/Chaching/Drivers/TBCardPay/Request.php +++ b/src/Chaching/Drivers/TBCardPay/Request.php @@ -190,7 +190,7 @@ protected function validate() )); } - if (!filter_var($this->fields['IPC'], FILTER_VALIDATE_IP, FILTER_FLAG_IPV4 | FILTER_FLAG_NO_RES_RANGE)) + if (!filter_var($this->fields['IPC'], FILTER_VALIDATE_IP, FILTER_FLAG_IPV4 | FILTER_FLAG_IPV6 | FILTER_FLAG_NO_RES_RANGE)) throw new InvalidOptionsException(sprintf( "Field %s (or IPC) has an unacceptable value '%s'. Valid " . "client IP address has to be a properly formatted IPv4.",