Roy Marples
d358684f82
Added -T test option. This just sends a DHCP_DISCOVER message and then
...
prints the configuration data to stdout - we don't request a lease,
configure the interface or write the info file.
2007-07-12 12:52:27 +00:00
Roy Marples
3cd8e9867a
chdir to / for sanity
2007-06-26 12:02:26 +00:00
Roy Marples
d6293b37c3
-HH sets the hostname to the full dns name looked up if we need to.
2007-05-28 12:15:27 +00:00
Roy Marples
6c3b1c2a59
Enable DHCP_INFORM support via the -s option again, moving DHCP_REQUEST
...
to the -r option. This makes us more compatible with dhcpcd-1.x and 2.x.
2007-05-15 13:34:17 +00:00
Roy Marples
49f0bcb56c
Stop using optional arguments, use '' instead so we're more compatible with dhcpcd-1.x and 2.x. Install /var/lib if it doesn't exist
2007-05-14 22:12:01 +00:00
Roy Marples
d56e00adb0
Rename ch to opt
2007-05-14 13:34:36 +00:00
Roy Marples
cefc00ea6f
Keep flock on pidfile open for while running.
2007-05-13 13:46:39 +00:00
Roy Marples
438263e057
flock the pidfile and stop writing the parent pid to it so we're more robst.
2007-05-13 12:28:54 +00:00
Roy Marples
9afd5b0238
Avoid using sizeof for hostname length check
2007-05-11 21:31:14 +00:00
Roy Marples
7f1b42ce4f
Enable DHCP_INFORM support via the -S option
2007-05-11 19:55:00 +00:00
Roy Marples
ff962a3c31
Allow -I to have an optional argument, when missing don't use DUID's
2007-05-11 10:51:32 +00:00
Roy Marples
c3d07f4c70
Add support for RFC 4361
2007-05-10 16:08:49 +00:00
Roy Marples
4549f7a4dd
config.h now has the compile time options, instead of being dotted around.
...
Added -E option, which reads the last info file and uses the information there
if we timeout and the lease is still valid, thanks to Roberto Angelino.
2007-05-10 09:39:26 +00:00
Roy Marples
0731074b52
Send a FQDN hostname if it contains dots, strip the domain from a looked up hostname if it matches our domain or search and sanitize our fd's a little better.
2007-04-26 16:16:56 +00:00
Roy Marples
6e9e8a1d4b
Use MAXHOSTNAMELEN instead of our define
2007-04-18 15:14:55 +00:00
Roy Marples
7cbb81afc3
Style updates
2007-04-12 13:12:25 +00:00
Roy Marples
378dcbd5d5
Cuddle up to LKML style C
2007-04-11 13:18:33 +00:00
Roy Marples
96ccff7a06
Fix indentation
2007-04-10 11:27:37 +00:00
Roy Marples
93573fa302
Use strlcpy if available, if not define our own.
2007-04-05 17:31:05 +00:00
Roy Marples
235ce0896d
Add safe_strncpy function to ensure everything is NULL terminated
2007-04-05 16:56:58 +00:00
Roy Marples
bc3f8ad57d
Cast NULL as char * when terminating lists, and use printf like attributes on our logging functions.
2007-04-05 14:33:39 +00:00
Roy Marples
d3b66c05ec
Add --nomtu/-M option. Also, if MTU is used we restore it to how it was at when we exist, don't get an MTU from the server or get an invalid MTU from the server.
2007-04-04 14:28:07 +00:00
Roy Marples
522a128c72
You can now build dhcpcd without support for writing ntp, nis and info files
...
which makes the binary a few k smaller.
Support OpenNTP as well as NTP.
Re-work the state engine a little, so we renew and rebind correctly.
Subsequent debug options stop dhcpcd from daemonising.
2007-04-03 07:03:04 +00:00
Roy Marples
ffb6d9d1b8
Test to see if the pid in the pidfile is actually running before claiming
...
that we are.
Fix the error since 3.0.6.
We now ensure that our renewal and rebind times are sane.
Fix flushing interfaces for systems without getifaddrs and >1 interface.
All netlink error messages are now prefixed with netlink.
2007-02-20 22:57:10 +00:00
Roy Marples
092592331f
Add DHCP over FireWire 1394 (RFC 2855) and InfiniBand (RFC 4390) support.
2007-02-12 16:12:50 +00:00
Roy Marples
3d19de577b
For infinite timeout, we now resent the last request at TIMEOUT_MINI
...
intervals like we do otherwise.
We now return a non zero exit code on SIGTERM and SIGINT if we have not
forked into the background.
When NIS and/or NTP servers are updated, we restart the service for them
if we can.
2007-01-16 17:54:07 +00:00
Roy Marples
32d928bfd3
Define _BSD_SOURCE and change to c99 - more warnings cleaned up.
2006-12-15 11:23:32 +00:00
Roy Marples
262fe7db60
Add loads of debugging CFLAGS so we can remove all compiler warnings
2006-12-14 23:17:27 +00:00
Roy Marples
71b1afde0f
Send the current hostname by default.
2006-12-06 09:37:15 +00:00
Roy Marples
91fe3f5a69
Fix NIS, #define RESOLVCONF and send the parameter list with DISCOVER messages
2006-12-05 09:38:10 +00:00
Roy Marples
be950ddfb8
Clean some style and stop using %m (use %s + strerror (errno) instead)
2006-12-04 12:56:30 +00:00
Roy Marples
5f581197c4
Add userlen back
2006-12-01 16:22:15 +00:00
Roy Marples
479225b66b
Quote all vars in the info file.
...
-n and -G options now work as stated in the man page.
Handle select loops with large timeouts and infinite lease times.
Correctly set the broadcast flag.
make_dhcp_packet already has byte ordered addresses, thanks to TGL
for the fix.
If we get a NAK then always re-enter the INIT state.
2006-11-30 13:04:23 +00:00
Roy Marples
cced195e70
Add dhcpcd-3 re-write
2006-11-27 20:23:22 +00:00