Fix detection of ipv4 adresses for stopforumspam integration
authorjoshuaruesweg <ruesweg@woltlab.com>
Thu, 3 Mar 2022 12:56:27 +0000 (13:56 +0100)
committerjoshuaruesweg <ruesweg@woltlab.com>
Thu, 3 Mar 2022 12:56:27 +0000 (13:56 +0100)
wcfsetup/install/files/lib/data/blacklist/entry/BlacklistEntry.class.php

index 0be5fbfa56c38c3f489269d549d7c3b78e6f6c2d..ee1bfd1c3ce40df429c91b722411cb0e3cae85cd 100644 (file)
@@ -39,7 +39,7 @@ class BlacklistEntry extends DatabaseObject {
                        $conditions->add('(type = ? AND hash = ?)', ['email', self::getHash($email)]);
                }
                if (BLACKLIST_SFS_IP_ADDRESS) {
-                       UserUtil::convertIPv6To4($ipAddress);
+                       $ipAddress = UserUtil::convertIPv6To4($ipAddress);
                        if ($ipAddress) {
                                if (filter_var($ipAddress, FILTER_VALIDATE_IP, FILTER_FLAG_IPV4) !== false) {
                                        $conditions->add('(type = ? AND hash = ?)', ['ipv4', self::getHash($ipAddress)]);