diff options
| author | Roy Marples <roy@marples.name> | 2007-07-18 11:26:59 +0000 |
|---|---|---|
| committer | Roy Marples <roy@marples.name> | 2007-07-18 11:26:59 +0000 |
| commit | 77659ce0359c096d8a2667541879f8a59fad8121 (patch) | |
| tree | 01a6f94b4eb5320b3f9a173398f0657734912fcc /ipv4ll.h | |
| parent | ff711cf766f3efd9dc8f79776e688a3a28f52d9a (diff) | |
| download | dhcpcd-77659ce0359c096d8a2667541879f8a59fad8121.tar.xz | |
We now do ARP checking by default as recommended by RFC 2131.
Add RFC 3927 (aka IPV4LL aka APIPA) support by default.
Diffstat (limited to 'ipv4ll.h')
| -rw-r--r-- | ipv4ll.h | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/ipv4ll.h b/ipv4ll.h new file mode 100644 index 00000000..f05d188e --- /dev/null +++ b/ipv4ll.h @@ -0,0 +1,37 @@ +/* + * dhcpcd - DHCP client daemon - + * Copyright 2005 - 2007 Roy Marples <uberlord@gentoo.org> + * + * This is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + */ + +#ifndef IPV4LL_H +#define IPV4LL_H + +#ifdef ENABLE_IPV4LL + +#include "dhcp.h" +#include "interface.h" + +#define LINKLOCAL_ADDR 0xa9fe0000 +#define LINKLOCAL_MASK 0xffff0000 +#define LINKLOCAL_BRDC 0xa9feffff + +#define IN_LINKLOCAL(addr) ((ntohl (addr) & IN_CLASSB_NET) == LINKLOCAL_ADDR) + +int ipv4ll_get_address (interface_t *iface, dhcp_t *dhcp); + +#endif +#endif |
