Skip to content

Add support for IPv6 CIDR match#49

Open
pbiering wants to merge 6 commits intodsoares:masterfrom
pbiering:fix-ipv6-cidr-match
Open

Add support for IPv6 CIDR match#49
pbiering wants to merge 6 commits intodsoares:masterfrom
pbiering:fix-ipv6-cidr-match

Conversation

@pbiering
Copy link

@pbiering pbiering commented Mar 8, 2023

So far, IPv6 entries in $config['recaptcha_whitelist'] where not proper honored, this PR adds IPv6 support to the CIDR matching code using e.g. following config

$rcmail_config['recaptcha_whitelist'] = array('2001:db8::/32');

also add some log lines and fixes the somehow broken code mentioned in #46.

BTW: reason for config option

// Block IPv6 client IP based on prefix length
// Use an integer between 16 and 128, 0 to disable
$config['rcguard_ipv6_prefix'] = 0;

is unclear, there was no code sniplet found which blocks something, with that PR it's at least proper masking (for whatever reason...)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant