#48310 [Com]: filter accepts invalid IPv6 address
| From: | birki456 at hotmail dot com | Date: | Sun, 07 Jun 2009 17:00:01 +0000 |
| Subject: | #48310 [Com]: filter accepts invalid IPv6 address | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-138080@lists.php.net to get a copy of this message | ||
ID: 48310
Comment by: birki456 at hotmail dot com
Reported By: geoffers+phpbugs at gmail dot com
Status: Open
Bug Type: Filter related
Operating System: Mac OS 10.5.6
PHP Version: 5.*, 6CVS (2009-05-16)
New Comment:
also look at http://bugs.php.net/bug.php?id=46973
this bug is _bogus_ because 1fff::a88:85a3::172.31.128.1 is not a valid
ipv6 address (TWO :: in it, that is NOT ALLOWED, see RFC4291)
please fix this.. ipv6 is coming fast
Previous Comments:
------------------------------------------------------------------------
[2009-05-17 17:18:32] geoffers+phpbugs at gmail dot com
Both 5.2 and 5.3 CVS give the same output as 5.2.9
------------------------------------------------------------------------
[2009-05-17 16:49:39] geoffers+phpbugs at gmail dot com
Description:
------------
The string '0:0:0:255.255.255.255' is not a valid IPv6 address. The
filter extension allows it.
Reproduce code:
---------------
var_dump(filter_var('0:0:0:255.255.255.255', FILTER_VALIDATE_IP,
FILTER_FLAG_IPV6));
Expected result:
----------------
bool(false)
Actual result:
--------------
string(21) "0:0:0:255.255.255.255"
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=48310&edit=1