From 6dc686a29ecdfa8f8011eee17e4e6276ab175a0d Mon Sep 17 00:00:00 2001 From: Paul Jakma Date: Tue, 10 Apr 2007 19:24:45 +0000 Subject: [zebra] Bug #351: Don't redistribute routes to ipv4 link-local prefixes 2007-04-07 Paul Jakma * lib/prefix.h: Add define to match IPv4 Link-Local addresses * zebra/redistribute.c: (zebra_check_addr) Don't redistribute routes to IPv4 link-local prefixes, fixes bug #351. * zebra/redistribute.h: Export zebra_check_addr. * zebra/router-id.c: (router_id_bad_address) re-use zebra_check_addr rather than implementing similar logic. --- lib/prefix.h | 1 + 1 file changed, 1 insertion(+) (limited to 'lib/prefix.h') diff --git a/lib/prefix.h b/lib/prefix.h index f2a2adfa..9cfc1556 100644 --- a/lib/prefix.h +++ b/lib/prefix.h @@ -111,6 +111,7 @@ struct prefix_rd #define IPV4_NET0(a) ((((u_int32_t) (a)) & 0xff000000) == 0x00000000) #define IPV4_NET127(a) ((((u_int32_t) (a)) & 0xff000000) == 0x7f000000) +#define IPV4_LINKLOCAL(a) ((((u_int32_t) (a)) & 0xffff0000) == 0xa9fe0000) /* Max bit/byte length of IPv6 address. */ #define IPV6_MAX_BYTELEN 16 -- cgit v1.2.1