randomly(!) assign ip's from dynamic address range

classic Classic list List threaded Threaded
24 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Re: randomly(!) assign ip's from dynamic address range

Niall O'Reilly
On Tue, 09 Jun 2015 09:33:37 +0100,
Simon Hobson wrote:
>
> So in summary :
> A process to add IPs to a list to be changed.
> A process to monitor expiring leases and check them against the list.
> A process to take matches from the previous step and take dummy leases to temporarily "lock" the address.
>
> That would seem to a fairly safe set of operations.

  Depending on "how many spare addresses you have", as you mentioned
  further up.  I'ld suggest also monitoring the balance between locked
  and available addresses.

  Best regards,
  Niall O'Reilly
 
_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: randomly(!) assign ip's from dynamic address range

Roberto Innocente
In reply to this post by glenn.satchell

Don't forget also rfc 4436 (Detect network attachment)
used in particular by iphones and ipads that are so nice to switch
almost instantaneously from a wifi ap to another (less than 1 second).
This is done (when the lease is still valid) without re-negotiating
anything with the dhcp server and , provided they recognize the mac
address
of the default router, continue to use the old lease address.
 From some checks they remember 4/5 ap.

roberto



On 2015-06-08 17:24, Glenn Satchell wrote:

> Most dhcp clients also store the last address. So even if you configure
> the server to offer different IPs to the client, the client could keep
> asking for the old address and the server would accept that.
>
> regards,
> -glenn
>
> On Tue, June 9, 2015 12:58 am, Bob Harold wrote:
>> A Windows 8 client appears to keep the last IP in the registry in:
>> HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\Interfaces\{...<Network
>> Adapter>...}\DhcpIPAddress
>>
>> Although many years ago I remember having clients that remembered the
>> last
>> 5 or 10 IP's (in different subnets).
>>
>>
>>
>> --
>> Bob Harold
>> hostmaster, UMnet, ITcom
>> Information and Technology Services (ITS)
>> [hidden email]
>> 734-647-6524 desk
>>
>> On Mon, Jun 8, 2015 at 9:11 AM, Glenn Satchell
>> <[hidden email]>
>> wrote:
>>
>>>
>>> On Mon, June 8, 2015 7:29 pm, Arne Baeumler wrote:
>>> > Hi Simon,
>>> >
>>> > thank you for your reply.
>>> >
>>> > On 2015-06-05 15:05, Simon Hobson wrote:
>>> >> Hmm, that's a variation I don't think we've seen before ;-)
>>> >> What you are seeing is correct operation according to the RFCs - the
>>> >> server is required to keep the address stable as far as is possible,
>>> and
>>> >> that means the client can come back after an arbitrary length of time
>>> >> and as long as the address has not been re-used then the client
>>> *must*
>>> >> get the same address.
>>> >
>>> > Would you please point me to the RFC you are referring to?
>>> > Can't find any requirements for the server to maintain some kind of IP
>>> > history in RFC2131.
>>> >
>>>
>>> I'm looking at https://www.ietf.org/rfc/rfc2131.txt, there are
>>> several
>>> references to this feature within the document. Section 4.3.1 is the
>>> clearest on this, even though it says it "SHOULD" rather than "MUST"
>>> be
>>> done this way.
>>>
>>> 1.6 Design goals
>>>
>>>       o Retain DHCP client configuration across DHCP client reboot.  
>>> A
>>>         DHCP client should, whenever possible, be assigned the same
>>>         configuration parameters (e.g., network address) in response
>>>         to each request,
>>>
>>>       o Retain DHCP client configuration across server reboots, and,
>>>         whenever possible, a DHCP client should be assigned the same
>>>         configuration parameters despite restarts of the DHCP
>>> mechanism,
>>>
>>> 2.2 Dynamic allocation of network addresses
>>>
>>>    The
>>>    allocation mechanism (the collection of DHCP servers) guarantees
>>> not
>>>    to reallocate that address within the requested time and attempts
>>> to
>>>    return the same network address each time the client requests an
>>>    address.
>>>
>>> 4.3.1 DHCPDISCOVER message
>>>
>>>    When a server receives a DHCPDISCOVER message from a client, the
>>>    server chooses a network address for the requesting client.  If no
>>>    address is available, the server may choose to report the problem
>>> to
>>>    the system administrator. If an address is available, the new
>>> address
>>>    SHOULD be chosen as follows:
>>>
>>>       o The client's current address as recorded in the client's
>>> current
>>>         binding, ELSE
>>>
>>>       o The client's previous address as recorded in the client's
>>> (now
>>>         expired or released) binding, if that address is in the
>>> server's
>>>         pool of available addresses and not already allocated, ELSE
>>>
>>>       o The address requested in the 'Requested IP Address' option,
>>> if
>>> that
>>>         address is valid and not already allocated, ELSE
>>>
>>>       o A new address allocated from the server's pool of available
>>>         addresses; the address is selected based on the subnet from
>>> which
>>>         the message was received (if 'giaddr' is 0) or on the address
>>> of
>>>         the relay agent that forwarded the message ('giaddr' when not
>>> 0).
>>>
>>> I hope this helps.
>>>
>>> I realise this doesn't help with your original question :) In terms
>>> of
>>> privacy there is an IPV6 feature that assigns a new IP address each
>>> day.
>>> This is part of the client functionality defined in RFC 4941 "Privacy
>>> Extensions for Stateless Address Autoconfiguration in IPv6" but
>>> doesn't
>>> help with your current IPv4 issue.
>>>
>>> regards,
>>> -glenn
>>>
>>>
>>> _______________________________________________
>>> dhcp-users mailing list
>>> [hidden email]
>>> https://lists.isc.org/mailman/listinfo/dhcp-users
>>>
>> _______________________________________________
>> dhcp-users mailing list
>> [hidden email]
>> https://lists.isc.org/mailman/listinfo/dhcp-users
>
>
> _______________________________________________
> dhcp-users mailing list
> [hidden email]
> https://lists.isc.org/mailman/listinfo/dhcp-users

--
Roberto Innocente - SISSA
[hidden email] - +39 40 3787541
_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: randomly(!) assign ip's from dynamic address range

Simon Hobson
Roberto Innocente <[hidden email]> wrote:

> Don't forget also rfc 4436 (Detect network attachment)
> used in particular by iphones and ipads that are so nice to switch
> almost instantaneously from a wifi ap to another (less than 1 second).
> This is done (when the lease is still valid) without re-negotiating
> anything with the dhcp server and , provided they recognize the mac address
> of the default router, continue to use the old lease address.

That won't matter (much). The OP has stated that they can't detect users leaving the network anyway, so the only way to determine a client is "down" is to see it's lease expire. Thus the address will only be "locked" when the lease is expired and the client should not be trying to use it. As long as the client returns to the network (even briefly) during the period the address is locked then it'll negotiate a new address with the DHCP server.

The only problem I see is a multihomed device which is "away" for so long that the locking lease expires and so allows the client to get it's old address back.


One thing I didn't see was anything about how clients connect : is this a "all devices go on the network directly" type of thing, or do users have a router on their end and their end devices behind that (and a layer of NAT) ? If the latter then it really doesn't matter what end user devices are used - it's the router that gets the public address.



_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: randomly(!) assign ip's from dynamic address range

Roberto Innocente
In reply to this post by Arne Baeumler

Are users authenticated via 802.1x
Or in anycase radius ?



On 2015-06-05 15:10, Arne Baeumler wrote:

> Hi dhcp users,
>
> we are running a DHCP Server for about 10k customers with a single isc
> dhcpd (4.2.4p2) process running.
> Our customers do almost ever get the same IP Address assigned when
> sending DHCPDISCOVER.
>
> Lease time is 1200 sec. (20 minutes), pool is 95-97% in use all day.
> Even after 10h offline,
> dhcpd will answer an DHCPDISCOVER with an DHCPOFFER for the same ip
> address as assigned 10h earlier.
>
> Some of our customers would like their ip address to change from time
> to time (e.g. every 24h)
> as they where used to when using PPP.
>
> Is there any way to accomplish this using isc dhcpd?
>
> _______________________________________________
> dhcp-users mailing list
> [hidden email]
> https://lists.isc.org/mailman/listinfo/dhcp-users

--
Roberto Innocente - SISSA
[hidden email] - +39 40 3787541
_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
12