Bug->Doc #77217 [Opn]: FILTER_FLAG_NO_RES_RANGE means Reserved-By-Protocol

From: Date: Thu, 29 Nov 2018 02:41:26 +0000
Subject: Bug->Doc #77217 [Opn]: FILTER_FLAG_NO_RES_RANGE means Reserved-By-Protocol
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-16180@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=77217&edit=1

 ID:                 77217
 Updated by:         requinix@php.net
 Reported by:        dan dot franklin at fen dot com
-Summary:            FILTER_FLAG_NO_RES_RANGE should match 100.64.0.0/10
+Summary:            FILTER_FLAG_NO_RES_RANGE means Reserved-By-Protocol
 Status:             Open
-Type:               Bug
+Type:               Documentation Problem
-Package:            Unknown/Other Function
+Package:            Filter related
 Operating System:   Linux
 PHP Version:        7.1.24
 Block user comment: N
 Private report:     N

 New Comment:

FILTER_FLAG_NO_RES_RANGE refers specifically to ranges marked as Reserved-By-Protocol in RFC 6890,
which covers the addresses mentioned in the documentation. What Wikipedia labels as
"reserved" is really more about the range having a special meaning.

If anything, 100./10 would be part of the the PRIV_RANGE, except the range isn't entirely
private. Debatable.


Previous Comments:
------------------------------------------------------------------------
[2018-11-29 02:25:34] dan dot franklin at fen dot com

Description:
------------
According to https://en.wikipedia.org/wiki/Reserved_IP_addresses
the IPv4 address range 100.64.0.0/10 is reserved for carrier-grade NAT.  But in PHP 7.1.24
filter_var with FILTER_FLAG_NO_RES_RANGE thinks it's fine.



Test script:
---------------
<?php
var_export(filter_var('100.74.11.184', FILTER_VALIDATE_IP, FILTER_FLAG_NO_RES_RANGE));


Expected result:
----------------
false

Actual result:
--------------
'100.74.11.184'



------------------------------------------------------------------------



--
Edit this bug report at https://bugs.php.net/bug.php?id=77217&edit=1


Thread (5 messages)

« previous php.doc.bugs (#16180) next »