Author Topic: Are *you* faster than Linksys?  (Read 6904 times)

0 Members and 1 Guest are viewing this topic.

Offline Sidoh

  • x86
  • Hero Member
  • *****
  • Posts: 17634
  • MHNATY ~~~~~
    • View Profile
    • sidoh
Re: Are *you* faster than Linksys?
« Reply #15 on: April 14, 2006, 12:49:49 am »
Code: [Select]
dhcpcd: MAC address = 00:e0:98:7c:82:39
dhcpcd: your IP address = 10.0.0.194

Code: [Select]
      1 # dhcpd.conf
      2 #
      3 # Configuration file for ISC dhcpd (see 'man dhcpd.conf')
      4 #
      5
      6 ddns-update-style ad-hoc;
      7
      8 subnet 10.0.0.0 netmask 255.255.255.0 {
      9     range 10.0.0.30 10.0.0.200;
     10         option subnet-mask 255.255.255.0;
     11         option routers 10.0.0.2;
     12         option domain-name-servers 10.0.0.2;
     13         option domain-name "sidoh.org";
     14         option ip-forwarding on;
     15
     16     }

Code: [Select]
C:\Documents and Settings\sidoh>ipconfig

Windows IP Configuration


Ethernet adapter Local Area Connection:

        Connection-specific DNS Suffix  . : sidoh.org
        IP Address. . . . . . . . . . . . : 10.0.0.199
        Subnet Mask . . . . . . . . . . . : 255.255.255.0
        Default Gateway . . . . . . . . . : 10.0.0.2

C:\Documents and Settings\sidoh>ipconfig /all

Windows IP Configuration

        Host Name . . . . . . . . . . . . : muaddib
        Primary Dns Suffix  . . . . . . . :
        Node Type . . . . . . . . . . . . : Unknown
        IP Routing Enabled. . . . . . . . : No
        WINS Proxy Enabled. . . . . . . . : No
        DNS Suffix Search List. . . . . . : sidoh.org

Ethernet adapter Local Area Connection:

        Connection-specific DNS Suffix  . : sidoh.org
        Description . . . . . . . . . . . : NVIDIA nForce Networking Controller
        Physical Address. . . . . . . . . : 00-11-2F-62-A4-56
        Dhcp Enabled. . . . . . . . . . . : Yes
        Autoconfiguration Enabled . . . . : Yes
        IP Address. . . . . . . . . . . . : 10.0.0.199
        Subnet Mask . . . . . . . . . . . : 255.255.255.0
        Default Gateway . . . . . . . . . : 10.0.0.2
        DHCP Server . . . . . . . . . . . : 10.0.0.15
        DNS Servers . . . . . . . . . . . : 10.0.0.2
        Lease Obtained. . . . . . . . . . : Thursday, April 13, 2006 10:21:02 P

        Lease Expires . . . . . . . . . . : Friday, April 14, 2006 10:21:02 AM

C:\Documents and Settings\sidoh>

I suppose you could be right, since there is probably no one simotaneously doing TCP/IP releases/renews on either of the networks I deal with in large.

To elaborate on my point, though, DHCP does assign IP addresses by MAC addresses.  If the local computer (in reference) has a lease, it sends the DHCP server its MAC address, which is validated.  If the server verifies the existance of the lease, it assigns it the previously designated IP address (this is why none of the IP's on my network change, even though I've been using the same DHCP server for over a year).

Offline Eric

  • Full Member
  • ***
  • Posts: 304
  • I'm new here!
    • View Profile
Re: Are *you* faster than Linksys?
« Reply #16 on: April 14, 2006, 01:15:00 am »
Sidoh is correct.  Dynamic address allocation is based almost entirely on MAC addresses; that's why most internet routers have support for MAC address "cloning."  If your lease expires (or is manually released), however, your IP address can be taken by another host, so on devices where DHCP is more appropriate (laptops, for example), but you still wish to use static IP addresses, you'll have to set up dhcpd similar to how Newby has done.
« Last Edit: April 14, 2006, 01:26:45 am by Lord[nK] »

Offline MyndFyre

  • Boticulator Extraordinaire
  • x86
  • Hero Member
  • *****
  • Posts: 4540
  • The wait is over.
    • View Profile
    • JinxBot :: the evolution in boticulation
Re: Are *you* faster than Linksys?
« Reply #17 on: April 14, 2006, 03:00:18 am »
dhcpd (and every single other DHCP server I've worked with, including ones on multiple routers)assigns IP leases according to a MAC address.  If this weren't true, releasing and renewing in IP configuration utilities would result in new IP addresses, which, in my experience, is never the case.

DHCP servers assign leases to a certain MAC address.  They will only dismiss the leases when the expiration date rolls around or if they are manually dismissed by a systems administrator.
As Newby said, I have had the opposite experience.  The only reason the DHCP server reallocates the same IP address to me is that when I released it, it was freed.  My Linksys router regularly cycles through about 2 values more than computers I have.  It's irritating.

Sidoh is correct.  Dynamic address allocation is based almost entirely on MAC addresses; that's why most internet routers have support for MAC address "cloning."  If your lease expires (or is manually released), however, your IP address can be taken by another host, so on devices where DHCP is more appropriate (laptops, for example), but you still wish to use static IP addresses, you'll have to set up dhcpd similar to how Newby has done.
Well you'll forgive me if I don't take you as a, shall we say, industry expert, but I'm sure I could think of a reason to skip MAC address cloning.  One such reason would be in the event the DHCP server had a list of valid MAC addresses and you wanted to expand the network.  You remove one device, clone its MAC, and put the device that was cloned on the new router's private network.

Why would dynamic IP addresses be based on MAC addresses?  IMO they have absolutely nothing to do with one another.
I have a programming folder, and I have nothing of value there

Running with Code has a new home!

Our species really annoys me.

Offline Sidoh

  • x86
  • Hero Member
  • *****
  • Posts: 17634
  • MHNATY ~~~~~
    • View Profile
    • sidoh
Re: Are *you* faster than Linksys?
« Reply #18 on: April 14, 2006, 03:05:24 am »
As Newby said, I have had the opposite experience.  The only reason the DHCP server reallocates the same IP address to me is that when I released it, it was freed.  My Linksys router regularly cycles through about 2 values more than computers I have.  It's irritating.

Regardless of this of this fact, the IP address leases are based on MAC addresses (if this weren't true, the DHCP server would not know who's talking to it when a request is made; it'd be forced to assign you a new lease each time you restarted your computer).  I'm sure you can set some DHCP servers so you're reassigned a new IP address every time you query for one, but the MAC address of a network card plays an important role in DHCP transactions.

Why would dynamic IP addresses be based on MAC addresses?  IMO they have absolutely nothing to do with one another.

Because DHCP server assign IP address leases.

Offline iago

  • Leader
  • Administrator
  • Hero Member
  • *****
  • Posts: 17914
  • Fnord.
    • View Profile
    • SkullSecurity
Re: Are *you* faster than Linksys?
« Reply #19 on: April 14, 2006, 12:40:42 pm »
DHCP may associate the same IP with the same MAC, but it doesn't have to.  For example, on Windows' DHCP server, I'm pretty sure the IP is randomized (I've gotten 192.168.0.221, 192.168.0.162, 192.168.0.64, and several others.. it's really weird)

Usually when I request a DHCP address, my system remembers the previous IP and requests it specifically.  Additionally, the router sometimes remembers IP:MAC mappings for a brief time (couple days, I think).  Between the two of those, the IP address often doesn't change.  But the point is that it CAN. 

Offline Sidoh

  • x86
  • Hero Member
  • *****
  • Posts: 17634
  • MHNATY ~~~~~
    • View Profile
    • sidoh
Re: Are *you* faster than Linksys?
« Reply #20 on: April 14, 2006, 03:17:11 pm »
DHCP may associate the same IP with the same MAC, but it doesn't have to.  For example, on Windows' DHCP server, I'm pretty sure the IP is randomized (I've gotten 192.168.0.221, 192.168.0.162, 192.168.0.64, and several others.. it's really weird)

If a lease has been granted, then yes, it does assign the machine the same IP address as long as that lease is not expired (or it has been manually/accidentally removed by an administrator/program bug).

Usually when I request a DHCP address, my system remembers the previous IP and requests it specifically.  Additionally, the router sometimes remembers IP:MAC mappings for a brief time (couple days, I think).  Between the two of those, the IP address often doesn't change.  But the point is that it CAN. 

I know they can, but if the DHCP server has assigned a lease and it's not facing a shortage of possible IP addresses in its specified range, it will assign the same machine the same IP address if the lease has not yet expired.

Code: [Select]
        Lease Obtained. . . . . . . . . . : Friday, April 14, 2006 8:47:14 AM
        Lease Expires . . . . . . . . . . : Saturday, April 22, 2006 8:47:14 AM

If this weren't true, what would be the point of a lease? ;)

Offline iago

  • Leader
  • Administrator
  • Hero Member
  • *****
  • Posts: 17914
  • Fnord.
    • View Profile
    • SkullSecurity
Re: Are *you* faster than Linksys?
« Reply #21 on: April 14, 2006, 03:37:50 pm »
DHCP may associate the same IP with the same MAC, but it doesn't have to.  For example, on Windows' DHCP server, I'm pretty sure the IP is randomized (I've gotten 192.168.0.221, 192.168.0.162, 192.168.0.64, and several others.. it's really weird)

If a lease has been granted, then yes, it does assign the machine the same IP address as long as that lease is not expired (or it has been manually/accidentally removed by an administrator/program bug).

Usually when I request a DHCP address, my system remembers the previous IP and requests it specifically.  Additionally, the router sometimes remembers IP:MAC mappings for a brief time (couple days, I think).  Between the two of those, the IP address often doesn't change.  But the point is that it CAN. 

I know they can, but if the DHCP server has assigned a lease and it's not facing a shortage of possible IP addresses in its specified range, it will assign the same machine the same IP address if the lease has not yet expired.

Code: [Select]
        Lease Obtained. . . . . . . . . . : Friday, April 14, 2006 8:47:14 AM
        Lease Expires . . . . . . . . . . : Saturday, April 22, 2006 8:47:14 AM

If this weren't true, what would be the point of a lease? ;)

That's fine and dandy, for that implementation.  As I said, there's no guarentees, DHCP isn't required to behave that way.  DHCP can change your IP whenever it feels like it (Windows' implementation, for example, does).  Static IP is the only way to be guarenteed the same IP.

Offline Sidoh

  • x86
  • Hero Member
  • *****
  • Posts: 17634
  • MHNATY ~~~~~
    • View Profile
    • sidoh
Re: Are *you* faster than Linksys?
« Reply #22 on: April 14, 2006, 03:58:37 pm »
That's fine and dandy, for that implementation.  As I said, there's no guarentees, DHCP isn't required to behave that way.  DHCP can change your IP whenever it feels like it (Windows' implementation, for example, does).  Static IP is the only way to be guarenteed the same IP.

For the period of time the lease isn't marked as expired, it is required to behave that way.  That was my original point. :)

I misunderstood Newby's original post, but I do say what he is saying.  I'm simply saying DHCP servers almost always assign IP addresses while concurrently reading/recording the MAC addrses of the client.  If it assigns leases (which is the case, by default; I spent 5 minutes configuring the Windows DHCP server and it assigned leases), it does deal with the MAC addresses.  You're correct, though, it doesn't guarantee that address for an undetermined amount of time.  It does, however, guarantee that address for the time that the lease is considered valid.

Offline iago

  • Leader
  • Administrator
  • Hero Member
  • *****
  • Posts: 17914
  • Fnord.
    • View Profile
    • SkullSecurity
Re: Are *you* faster than Linksys?
« Reply #23 on: April 14, 2006, 04:02:57 pm »
Well, on Windows XP, I can request an ip, reboot, and request it again in less than 2 minutes, and the ip changes to another random value in the range of (2, 254).  Maybe it has a very short lease time? :P

Offline Chavo

  • x86
  • Hero Member
  • *****
  • Posts: 2219
  • no u
    • View Profile
    • Chavoland
Re: Are *you* faster than Linksys?
« Reply #24 on: April 14, 2006, 05:06:09 pm »
Well, on Windows XP, I can request an ip, reboot, and request it again in less than 2 minutes, and the ip changes to another random value in the range of (2, 254).  Maybe it has a very short lease time? :P


Or maybe the Windows device driver is broadcasting a different MAC