Clean compile, basic DHCPv6 functionality is there.

TODO
     hostname handling.
     update DHCP6 configs from dns
     parse domain=<domain>,<IPv6 range>
     pretty-print counted string options.
     DECLINE messages
     lease-script fro DHCPv6
This commit is contained in:
Simon Kelley committed 2012-02-06 14:30:41 +00:00
1 parent 3268e90f5e
commit 4cb1b32009
17 files changed
+2025 -718

No files matched your search

+19 -1
View File
@@ -153,7 +153,25 @@ int iface_enumerate(int family, void *parm, int (*callback)())
ifr = (struct ifreq *)ifreq.iov_base;
memcpy(ifr, ptr, len);
#ifdef HAVE_DHCP6
if (family == AF_LOCAL)
{
unsigned int flags;
if (ioctl(fd, SIOCGIFFLAGS, ifr) != -1)
{
flags = ifr.ifr_flags;
ifr->ifr_addr.sa_family = AF_LINK;
if (ioctl(fd, SIOCGIFADDR, ifr) != -1 &&
!((*callback)((unsigned int) htons(ETHERTYPE_IP),
(unsigned int)link->ifi_flags,
LLADDR((struct sockaddr_dl *)&ifr->ifr_addr), ETHER_ADDR_LEN, parm)))
goto err;
}
continue;
}
#endif
if (ifr->ifr_addr.sa_family == family)
{
if (family == AF_INET)