exim icon indicating copy to clipboard operation
exim copied to clipboard

Don't accept overly long IPv6 numbers

Open WayneD opened this issue 5 years ago • 1 comments

The current code stops parsing a hex number after 4 digits and then loops around to look for punctuation. If none is found, it just starts parsing more hex digits, so it will accept invalid IPv6 such as 1::1234567890abcdef

My simple change makes the code return 0 if a 5th hex digit in a row is found.

WayneD avatar Jun 22 '20 18:06 WayneD

The string_is_ip_address() is being reworked currently. Thx for your contribution, I'll close this PR as soon as the reworked version hits the public git (master branch and probably even 4.96.1+fixes)

HeikoSchlittermann avatar Oct 07 '23 08:10 HeikoSchlittermann