]>
git.ipfire.org Git - thirdparty/dhcpcd.git/log
Roy Marples [Fri, 8 Aug 2008 13:47:57 +0000 (13:47 +0000)]
We should not make any restrictions on hostname. RFC2131 says that hostname field *could* be fully or partially qualified.
Roy Marples [Fri, 8 Aug 2008 12:26:05 +0000 (12:26 +0000)]
Ensure that hostname does not begin with a .
Roy Marples [Fri, 8 Aug 2008 11:31:19 +0000 (11:31 +0000)]
Skip the trailing . if it exists on the FQDN.
Roy Marples [Thu, 7 Aug 2008 11:45:29 +0000 (11:45 +0000)]
Heh, need to reserve space for FQDN option length also.
Roy Marples [Thu, 7 Aug 2008 11:42:14 +0000 (11:42 +0000)]
We need to reserve a byte for initial length also.
Roy Marples [Thu, 7 Aug 2008 10:15:15 +0000 (10:15 +0000)]
Note that we encode the hostname according to RFC1035. As such, we can't use the system defined MAX hostname length.
Roy Marples [Thu, 7 Aug 2008 10:04:16 +0000 (10:04 +0000)]
Use full dates.
Roy Marples [Thu, 7 Aug 2008 09:45:41 +0000 (09:45 +0000)]
Turns out my encoding was correct after all :)
I've now split it out into it's own function for easier maintenance though.
Roy Marples [Wed, 6 Aug 2008 22:12:37 +0000 (22:12 +0000)]
Revert FQDN to ASCII encoding as I cannot find out what RFC4702 really means for encoding :/
Roy Marples [Wed, 6 Aug 2008 21:37:34 +0000 (21:37 +0000)]
Attempt to fix FQDN encoding.
Roy Marples [Wed, 6 Aug 2008 17:31:04 +0000 (17:31 +0000)]
Fix enum name
Roy Marples [Wed, 6 Aug 2008 12:23:24 +0000 (12:23 +0000)]
Remove pointless log message.
Roy Marples [Wed, 6 Aug 2008 09:32:58 +0000 (09:32 +0000)]
Don't reset the counters unless we should. dhcpcd should now be fully conformant to RFC2131 and RFC3927 timings.
Roy Marples [Wed, 6 Aug 2008 08:31:20 +0000 (08:31 +0000)]
Allow disable for fqdn option so command line can override config.
Roy Marples [Wed, 6 Aug 2008 08:28:43 +0000 (08:28 +0000)]
Remove the MINIMAL define.
Roy Marples [Tue, 5 Aug 2008 22:07:08 +0000 (22:07 +0000)]
Fix comment.
Roy Marples [Tue, 5 Aug 2008 22:06:45 +0000 (22:06 +0000)]
Put options in correct order.
Roy Marples [Tue, 5 Aug 2008 22:06:11 +0000 (22:06 +0000)]
Use correct hostname length.
Roy Marples [Tue, 5 Aug 2008 22:04:34 +0000 (22:04 +0000)]
Respect hostname length.
Roy Marples [Sat, 2 Aug 2008 22:56:42 +0000 (22:56 +0000)]
Turns out that POSIX only requires 31 days max for select. Linux has a hard limit which is hard to work out, so we now use a poll loop again with decreasing timers.
Roy Marples [Sat, 2 Aug 2008 19:59:13 +0000 (19:59 +0000)]
Fix compile on Darwin.
Roy Marples [Fri, 1 Aug 2008 17:42:38 +0000 (17:42 +0000)]
Fix dhcp message logging.
Roy Marples [Fri, 1 Aug 2008 14:11:33 +0000 (14:11 +0000)]
Add support for mach_absolute_time if on Darwin as that platform does not have clock_gettime. I cannot test this myself, so it may have bugs or not compile.
Roy Marples [Fri, 1 Aug 2008 13:15:11 +0000 (13:15 +0000)]
Brute force detection of monotonic clock as sysconf is unreliable. Instead rely on clock_gettime failing gracefully with an invalid clockid (which it should do).
Roy Marples [Fri, 1 Aug 2008 10:22:44 +0000 (10:22 +0000)]
Don't bother waiting on a negative timeout and fix poll -> select error message.
Roy Marples [Fri, 1 Aug 2008 08:41:25 +0000 (08:41 +0000)]
Tweak README about monotonic, and improve warning message.
Roy Marples [Thu, 31 Jul 2008 23:46:37 +0000 (23:46 +0000)]
select and poll cannot be trusted to respect the timeout - sometimes they timeout just before the value. As such, the timers now decrease instead of being set times to timeout. This makes the code a bit lighter as well - the side effect is we've bloated the logger calls with timeouts as we can no longer log the waiting time in wait_for_fd.
Roy Marples [Thu, 31 Jul 2008 23:44:08 +0000 (23:44 +0000)]
Document monotonic clock warning and solution.
Roy Marples [Thu, 31 Jul 2008 23:43:37 +0000 (23:43 +0000)]
clock_monotonic now is 0 or 1 depending on if the clock is monotonic. Also, systems that have headers for monotonic but do not claim support now warn about this. You can build dhcpcd to force a monotonic clock.
Roy Marples [Thu, 31 Jul 2008 15:44:07 +0000 (15:44 +0000)]
Another usec fix.
Roy Marples [Thu, 31 Jul 2008 13:39:40 +0000 (13:39 +0000)]
It looks impossible to send our information to NM using DBus, so just call the NM dispatcher directly.
Roy Marples [Thu, 31 Jul 2008 12:26:45 +0000 (12:26 +0000)]
fd_set is not a struct.
Roy Marples [Thu, 31 Jul 2008 12:20:26 +0000 (12:20 +0000)]
Always restart ntp even config hasn't changed as it could have been configured correctly and started before dhcpcd, which means it won't actually be talking to the ntp server we want.
Roy Marples [Thu, 31 Jul 2008 12:19:14 +0000 (12:19 +0000)]
Don't lookup the hostname if we don't have an ip address (INFORM).
Roy Marples [Thu, 31 Jul 2008 12:18:37 +0000 (12:18 +0000)]
Clear stop timer for INFORM.
Roy Marples [Thu, 31 Jul 2008 09:30:42 +0000 (09:30 +0000)]
Prefer signal to poll so we avoid any possibilty of a timeval -> int/msecs overflow. We could of course loop msecs / INT_MAX times, but it then gets messy. It also saves around 200 bytes of binary size :)
Roy Marples [Wed, 30 Jul 2008 21:27:48 +0000 (21:27 +0000)]
stderr should be unbuffered by default.
Roy Marples [Wed, 30 Jul 2008 20:15:49 +0000 (20:15 +0000)]
Add correct time bit.
Roy Marples [Wed, 30 Jul 2008 14:28:53 +0000 (14:28 +0000)]
Don't log spam carrier or infinite.
Roy Marples [Wed, 30 Jul 2008 11:11:08 +0000 (11:11 +0000)]
Plug a leak.
Roy Marples [Wed, 30 Jul 2008 11:05:45 +0000 (11:05 +0000)]
We should bind to the interface if we can - for the case where we renew and there are two interfaces on the same subnet and the default subnet route goes via the wrong interface.
Roy Marples [Tue, 29 Jul 2008 16:09:56 +0000 (16:09 +0000)]
Fix background for forkless systems.
Roy Marples [Mon, 28 Jul 2008 15:43:38 +0000 (15:43 +0000)]
Use setlinebuf() at startup instead of calling fflush() for each logger call.
Roy Marples [Mon, 28 Jul 2008 14:35:20 +0000 (14:35 +0000)]
Release dhcpcd-4.0.0-rc4
Roy Marples [Mon, 28 Jul 2008 14:01:17 +0000 (14:01 +0000)]
returns
Roy Marples [Mon, 28 Jul 2008 13:39:57 +0000 (13:39 +0000)]
Check chaddr matches our hwaddr if it fits.
Roy Marples [Mon, 28 Jul 2008 13:28:08 +0000 (13:28 +0000)]
Don't use the word will so much.
Roy Marples [Mon, 28 Jul 2008 13:21:47 +0000 (13:21 +0000)]
Add -X, --blacklist option to reject DHCP messages with a matching serverid.
Roy Marples [Mon, 28 Jul 2008 12:02:24 +0000 (12:02 +0000)]
Tart up the mandoc a little, thanks to Thomas Klausner.
Roy Marples [Mon, 28 Jul 2008 09:17:07 +0000 (09:17 +0000)]
Fix --noipv4ll option from timing out right away.
Roy Marples [Sun, 27 Jul 2008 18:04:44 +0000 (18:04 +0000)]
Inherit DBDIR and LIBEXECDIR from the env.
Roy Marples [Sun, 27 Jul 2008 15:36:40 +0000 (15:36 +0000)]
Misc fixes and clarify why inform should have a CIDR.
Roy Marples [Sun, 27 Jul 2008 10:29:12 +0000 (10:29 +0000)]
Release dhcpcd-4.0.0-rc3
Roy Marples [Sun, 27 Jul 2008 10:17:36 +0000 (10:17 +0000)]
Don't set a sop timeout when bound to an infinite lease after announcing.
Roy Marples [Sat, 26 Jul 2008 12:29:02 +0000 (12:29 +0000)]
Fix sign error.
Roy Marples [Sat, 26 Jul 2008 11:40:39 +0000 (11:40 +0000)]
Save some bytes by not using timeradd so much.
Roy Marples [Sat, 26 Jul 2008 09:28:16 +0000 (09:28 +0000)]
Ensure can handle our lease time.
Roy Marples [Sat, 26 Jul 2008 07:32:44 +0000 (07:32 +0000)]
Move the seconds waiting calc into the if where it's needed.
Roy Marples [Fri, 25 Jul 2008 20:35:41 +0000 (20:35 +0000)]
Report more accurate seconds.
Roy Marples [Thu, 24 Jul 2008 21:51:11 +0000 (21:51 +0000)]
Fix signal handling and ARP announcing.
Roy Marples [Thu, 24 Jul 2008 15:50:19 +0000 (15:50 +0000)]
Fix breakage caused by last patch.
Roy Marples [Thu, 24 Jul 2008 15:09:33 +0000 (15:09 +0000)]
Normalise tv_usecs. Also, send the fd ready back to the main loop so we don't have to re-poll each fd. Saves bytes and is more efficient.
Roy Marples [Thu, 24 Jul 2008 14:30:36 +0000 (14:30 +0000)]
get_time -> clock_monotonic to be more descriptive.
Roy Marples [Wed, 23 Jul 2008 17:06:42 +0000 (17:06 +0000)]
Remove #ifdefs to disable specific bits of code. We now build everything - we're small enough :)
Roy Marples [Wed, 23 Jul 2008 16:08:27 +0000 (16:08 +0000)]
Release dhcpcd-4.0.0-rc2
Roy Marples [Wed, 23 Jul 2008 14:21:29 +0000 (14:21 +0000)]
If we fail to obtain an IPv4LL address, drop back to search for a DHCP lease.
Roy Marples [Wed, 23 Jul 2008 14:14:53 +0000 (14:14 +0000)]
Don't flap the carrier needlessly.
Roy Marples [Wed, 23 Jul 2008 10:32:00 +0000 (10:32 +0000)]
Fix mini timeouts and starting ipv4ll when link is down and we try to renew a lease.
Roy Marples [Wed, 23 Jul 2008 08:45:04 +0000 (08:45 +0000)]
Typo
Roy Marples [Tue, 22 Jul 2008 12:49:26 +0000 (12:49 +0000)]
Minor updates.
Roy Marples [Tue, 22 Jul 2008 09:10:55 +0000 (09:10 +0000)]
Release dhcpcd-4.0.0-rc1
Roy Marples [Tue, 22 Jul 2008 06:58:11 +0000 (06:58 +0000)]
Always expire lease on probe failure. We should do this as the LAN we hot swap too could deny our IPv4LL probes are a while and this is safer.
Roy Marples [Mon, 21 Jul 2008 21:48:17 +0000 (21:48 +0000)]
Fix valgrind errors, and report correct type.
Roy Marples [Mon, 21 Jul 2008 21:30:48 +0000 (21:30 +0000)]
EXPIRE on NAK and fix valgrind errors.
Roy Marples [Mon, 21 Jul 2008 16:21:53 +0000 (16:21 +0000)]
More timer fixes. Also, when a handle function returns 1, don't wait for a packet as we should drop through to the handle_timeout. Makes the code a bit cleaner.
Roy Marples [Mon, 21 Jul 2008 14:30:07 +0000 (14:30 +0000)]
Better to say which OS's have closefrom.
Roy Marples [Mon, 21 Jul 2008 14:24:18 +0000 (14:24 +0000)]
Darwin uses --rpath instead of -Wl,-rpath= - bummer.
Roy Marples [Mon, 21 Jul 2008 14:05:35 +0000 (14:05 +0000)]
OK, the loop was caused by the initial carrier timeout. Also, always log carrier waiting, but don't spam the console when backgrounding.
Roy Marples [Mon, 21 Jul 2008 13:20:59 +0000 (13:20 +0000)]
Attempt to fix dhcpcd going into a tight infinite loop after getting an IPv4LL address.
Roy Marples [Mon, 21 Jul 2008 10:32:16 +0000 (10:32 +0000)]
Fix compile on OSX.
Roy Marples [Mon, 21 Jul 2008 06:17:08 +0000 (06:17 +0000)]
Don't log waiting for carrier when backgrounding.
Roy Marples [Mon, 21 Jul 2008 06:12:33 +0000 (06:12 +0000)]
We should timeout when in background for IPv4LL.
Roy Marples [Mon, 21 Jul 2008 06:02:28 +0000 (06:02 +0000)]
Actually no, just the probing state. We should defend our announces :)
Roy Marples [Mon, 21 Jul 2008 05:40:24 +0000 (05:40 +0000)]
We should only defend when not in the probing or announcing state.
Roy Marples [Sun, 20 Jul 2008 19:33:27 +0000 (19:33 +0000)]
Remove the fork() test as compile hosts will normally have it, making it redundant.
Roy Marples [Sun, 20 Jul 2008 16:21:53 +0000 (16:21 +0000)]
fork()less fixes.
Roy Marples [Sun, 20 Jul 2008 15:56:01 +0000 (15:56 +0000)]
Don't re-up the interface - user may have brought it down.
Roy Marples [Sat, 19 Jul 2008 20:52:17 +0000 (20:52 +0000)]
Quick fix.
Roy Marples [Sat, 19 Jul 2008 20:11:03 +0000 (20:11 +0000)]
Style.
Roy Marples [Sat, 19 Jul 2008 20:04:27 +0000 (20:04 +0000)]
Fix the timeouts some more - complicated stuff!
Roy Marples [Sat, 19 Jul 2008 17:06:54 +0000 (17:06 +0000)]
Fix IPv4LL when backgrounding.
Roy Marples [Sat, 19 Jul 2008 14:14:40 +0000 (14:14 +0000)]
No need to check for this error code.
Roy Marples [Sat, 19 Jul 2008 14:04:36 +0000 (14:04 +0000)]
When daemonised, don't set bound state.
Roy Marples [Sat, 19 Jul 2008 14:04:18 +0000 (14:04 +0000)]
Don't report deleteing a non existant address on FreeBSD.
Roy Marples [Fri, 18 Jul 2008 23:31:34 +0000 (23:31 +0000)]
Fix IPv4LL
Roy Marples [Fri, 18 Jul 2008 22:00:18 +0000 (22:00 +0000)]
Rework the state engine around the timers better. timeout is now used for re-transmissions and stop is used to change state.
Roy Marples [Fri, 18 Jul 2008 16:42:47 +0000 (16:42 +0000)]
Add log_dhcp so we log server ip and name if available. Saves a few bytes.
Roy Marples [Fri, 18 Jul 2008 13:43:25 +0000 (13:43 +0000)]
Try and stop a flapping timeout.
Roy Marples [Fri, 18 Jul 2008 12:23:45 +0000 (12:23 +0000)]
We could return from a few more states here.
Roy Marples [Fri, 18 Jul 2008 12:06:35 +0000 (12:06 +0000)]
Add an exit timer so that carrier changing does not cause timeouts to flap. Also, fix renewals entering the server address.