[Python-Dev] PEP 3144 review.
R. David Murray
rdmurray at bitdance.com
Mon Sep 28 16:35:57 CEST 2009
On Sun, 27 Sep 2009 at 10:06, David Moss wrote:
> On 27 Sep 2009, at 07:56, "Martin v. LÃ¶wis" <martin at v.loewis.de> wrote:
>> I wouldn't ask for that: it should certainly be possible to supply
>> masks. However, I would want to reject masks that don't correspond to
>> a prefix, and have only the prefix length in the internal representation.
> +1 on rejection of netmasks without direct CIDR prefix equivalents. AFAIK
> Cisco routers accept them but I don't see how they would be useful in
> practice (unless someone can demonstrate their need for this).
Several years ago I ran into a network with a non-CIDR netmask. This
was in the early days of CIDR, and I hope that that network is no longer
configured that way....
A little googling produced this hit:
which while not a standard itself clearly believes that non-contiguous
netmasks are valid, and is dated 2008. Earlier RFCs (950 and 1219)
give them as valid but discouraged.
The linux stack (or at least the ifconfig command on my system) does not
appear to support non-contiguous netmasks. From a brief search on Cisco's
site it looks like Cisco only partially supports non-contiguous masks
(you can use them in wildmasks in access lists, but not in subnet masks
on interfaces). (I just tried setting a non-contiguous netmask on an
interface on one of my Ciscos, and it gave me a 'bad mask' error message.)
I think support for non-contiguous netmasks could be safely omitted,
but it would mean the module did not fully support the standards, which
should be noted in the docs (and why).
More information about the Python-Dev