Roy Marples [Fri, 6 Jun 2014 20:08:07 +0000 (20:08 +0000)]
Restarting ntp/yp are not critical and their initialisation continues
in the background as well so we may as well background the restart commands
for faster dhcpcd performance.
Roy Marples [Thu, 5 Jun 2014 11:38:04 +0000 (11:38 +0000)]
Ensure OWN is set by SLAAC private before initing.
Add a link-local address before running any PREINIT script
as well as at start incase a 3rd party removed it.
Move kernel tweaks to RA to DEBUG messages.
Roy Marples [Wed, 4 Jun 2014 23:54:15 +0000 (23:54 +0000)]
Add an IPv6 link-local address before upping the interface if needed.
Bring an interface up when we start it and not during discovery.
As such, stop waiting on carrier for a second if we did.
Roy Marples [Tue, 3 Jun 2014 12:49:48 +0000 (12:49 +0000)]
Only one place should decide how netiface and netid are formed
for generating stable private addresses.
Ensure that dhcpcd.secret is readable only by dhcpcd.
Roy Marples [Thu, 29 May 2014 12:52:27 +0000 (12:52 +0000)]
-4 and -6 are now mutually exclusive and when running on a single interface
per protocol pidfiles are created.
This means that other control options suchs as -x and -n will require the
-4 or -6 option as well.
Roy Marples [Sat, 24 May 2014 13:08:29 +0000 (13:08 +0000)]
Add a compat syslog function if the libc syslog does not support LOG_PERROR.
Add a non working if-sun.c stub.
Define IN6_IFF_TENTATIVE and friends to zero so IPv6 at least compiles on Solaris.
Warn that Solaris support presently does not work.
Roy Marples [Wed, 7 May 2014 13:31:32 +0000 (13:31 +0000)]
Poll kernel neighbour reachability (SIOCGNBRINFO_IN6) for each router
instead of sending and listening for Neighbour Soliciation/Advertisement
packets. The kernel is privy to a lot more reachability information than
userland is.
Fixes [bb6153d18b].
Roy Marples [Tue, 6 May 2014 14:42:24 +0000 (14:42 +0000)]
Always send a carrier as it's no longer encapsulated in the IPv4 stack.
When stopping and not departed, run with the STOPPED reason but do
not process it in hooks.
Roy Marples [Sat, 3 May 2014 19:56:15 +0000 (19:56 +0000)]
RFC2131 section 4.4.1 states the client SHOULD wait a random time between
one and ten seconds to desynchronize the use of DHCP at startup.
Instead we wait a random time between zero and one second to mirror
the more modern IPv6RS and DHCPv6 standards unless overridden by
defining RFC2131_STRICT.
Roy Marples [Fri, 2 May 2014 23:54:29 +0000 (23:54 +0000)]
Change the readrawsocket API a little so that we know when EOF is reached.
This allows us to remove the non blocking option from our sockets due to the way BPF works.
Roy Marples [Fri, 2 May 2014 14:23:41 +0000 (14:23 +0000)]
When a node first becomes stale, fire off a NS probe anyway.
This is outside of the RFC, but it seems that some nodes do not
respond with a NA fast enough to avoid log spam.
Roy Marples [Fri, 2 May 2014 12:31:21 +0000 (12:31 +0000)]
Once reachability + randomisation has passed, wait DELAY_FIRST_PROBE_TIME
seconds and then send MAX_UNICAST_SOLICIT probes at retranstimer intervals.
If no confirmation and another retranstimer interval has passed, expire the
address.
Roy Marples [Mon, 28 Apr 2014 12:02:12 +0000 (12:02 +0000)]
Namespace all public dhcpcd.c functions.
Add ipv4, ipv6, dhcp and dhcp6 options to re-enable if disabled globally.
Try and load a delegated interface if not running on all interfaces.
Fix delegated interfaces without a prefix set.