Re: [dhcwg] Any documentation for handling /32 IPv4 assignments from DHCP?

Alexandru Petrescu <alexandru.petrescu@gmail.com> Fri, 06 December 2013 16:20 UTC

Return-Path: <alexandru.petrescu@gmail.com>
X-Original-To: dhcwg@ietfa.amsl.com
Delivered-To: dhcwg@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 6B4841AE3A8 for <dhcwg@ietfa.amsl.com>; Fri, 6 Dec 2013 08:20:16 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -4.983
X-Spam-Level:
X-Spam-Status: No, score=-4.983 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_ADSP_CUSTOM_MED=0.001, FREEMAIL_FROM=0.001, HELO_EQ_FR=0.35, NML_ADSP_CUSTOM_MED=0.9, RCVD_IN_DNSWL_HI=-5, SPF_SOFTFAIL=0.665] autolearn=ham
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0dwM-olzLE5o for <dhcwg@ietfa.amsl.com>; Fri, 6 Dec 2013 08:20:14 -0800 (PST)
Received: from oxalide-out.extra.cea.fr (oxalide-out.extra.cea.fr [132.168.224.8]) by ietfa.amsl.com (Postfix) with ESMTP id 16CBE1AE07B for <dhcwg@ietf.org>; Fri, 6 Dec 2013 08:20:13 -0800 (PST)
Received: from pisaure.intra.cea.fr (pisaure.intra.cea.fr [132.166.88.21]) by oxalide.extra.cea.fr (8.14.2/8.14.2/CEAnet-Internet-out-2.3) with ESMTP id rB6GK9pv015363; Fri, 6 Dec 2013 17:20:09 +0100
Received: from pisaure.intra.cea.fr (localhost [127.0.0.1]) by localhost (Postfix) with SMTP id 01ABE200D13; Fri, 6 Dec 2013 17:20:20 +0100 (CET)
Received: from muguet2.intra.cea.fr (muguet2.intra.cea.fr [132.166.192.7]) by pisaure.intra.cea.fr (Postfix) with ESMTP id E90FA200CE8; Fri, 6 Dec 2013 17:20:19 +0100 (CET)
Received: from [127.0.0.1] (is010446-4.intra.cea.fr [10.8.33.116]) by muguet2.intra.cea.fr (8.13.8/8.13.8/CEAnet-Intranet-out-1.2) with ESMTP id rB6GK5H5005907; Fri, 6 Dec 2013 17:20:09 +0100
Message-ID: <52A1F936.3040902@gmail.com>
Date: Fri, 06 Dec 2013 17:20:06 +0100
From: Alexandru Petrescu <alexandru.petrescu@gmail.com>
User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:24.0) Gecko/20100101 Thunderbird/24.1.1
MIME-Version: 1.0
To: Matthew Dempsky <matthew@dempsky.org>, dhcwg@ietf.org
References: <CANKkrzEew4WtYpa33GL3QB-8Wd8jGZTEv5djkOr9LbOMa7+icw@mail.gmail.com>
In-Reply-To: <CANKkrzEew4WtYpa33GL3QB-8Wd8jGZTEv5djkOr9LbOMa7+icw@mail.gmail.com>
Content-Type: text/plain; charset="ISO-8859-1"; format="flowed"
Content-Transfer-Encoding: 8bit
Subject: Re: [dhcwg] Any documentation for handling /32 IPv4 assignments from DHCP?
X-BeenThere: dhcwg@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <dhcwg.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/dhcwg>, <mailto:dhcwg-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/dhcwg/>
List-Post: <mailto:dhcwg@ietf.org>
List-Help: <mailto:dhcwg-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/dhcwg>, <mailto:dhcwg-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 06 Dec 2013 16:20:16 -0000

Hello Matthew,

I see no other answer, but I have some thoughts.

First, I am not sure why this script is written that way.  When a router 
address is allocated by DHCP ('option routers') it is typically a 
default router, and hence it must have that 'default' qualifier in the 
subsequent route add command.  The first lines of the script would be 
nonsense.

On another hand, one may allocate a prefix (instead of an address), and 
hence it would need that prefix to be reachable through that router.

Le 05/12/2013 19:18, Matthew Dempsky a écrit :
> In dhcp-4.2.5-P1/client/scripts/linux, there's this code for adding
> routes based on the Router (3) and Subnet Mask (1) options:
>
>      for router in $new_routers; do
>        if [ "x$new_subnet_mask" = "x255.255.255.255" ] ; then
>          route add -host $router dev $interface

I wonder whether those two lines above have anything to do with IPv4 
Subnet Allocation RFC6656 "Description of Cisco Systems' Subnet 
Allocation Option for DHCPv4" INFORMATIONAL.

>        fi
>        route add default gw $router $metric_arg dev $interface
>      done
>
> Is this special case logic for subnet_mask==255.255.255.255 codified
> anywhere?

I dont know.

>  I'm working on adding similar logic to OpenBSD's DHCP
> client (so OpenBSD can connect to a network currently supported by ISC
> DHCP on Linux),

That is a very good goal.

> but I'm having trouble finding any authoritative
> documentation explaining the correct behavior here.

Maybe one would ask the author of that script why did s/he write it that 
way?  Does the script have a author name in the head.

> In particular, ISC DHCP 4.2.5-P1 only adds the "dev" route for Router
> (3), but I'm wondering if they should be added for Static Route (33)
> and/or Classless Static Route Option (121) too?

I dont know.

Alex

>
> Thanks
> _______________________________________________
> dhcwg mailing list
> dhcwg@ietf.org
> https://www.ietf.org/mailman/listinfo/dhcwg
>
>