summaryrefslogtreecommitdiff
path: root/lib/flowspec.h
diff options
context:
space:
mode:
authorOndrej Zajicek (work) <santiago@crfreenet.org>2019-11-18 17:44:34 +0100
committerOndrej Zajicek (work) <santiago@crfreenet.org>2019-11-18 17:56:51 +0100
commit0f88200247cc61175c7a1d98a3e935aedce93f3b (patch)
tree15d9b25b233f2c97856365dd6653752e0c6db607 /lib/flowspec.h
parent53401bef63013dfee01b65d071ffbd88e457539f (diff)
BGP: Fix processing of IPv6 Flowspec
During NLRI parsing of IPv6 Flowspec, dst prefix was not properly extracted from NLRI, therefore a received flow was stored in a different position in flowspec routing table, and was not reachable by command 'show route <flow>'. Add proper prefix part accessors to flowspec code and use them from BGP NLRI parsing code. Thanks to Alex D. for the bugreport.
Diffstat (limited to 'lib/flowspec.h')
-rw-r--r--lib/flowspec.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/flowspec.h b/lib/flowspec.h
index fa90c70d..d486cda0 100644
--- a/lib/flowspec.h
+++ b/lib/flowspec.h
@@ -86,6 +86,14 @@ const byte *flow6_next_part(const byte *pos, const byte *end);
/*
+ * Flowspec accessors
+ */
+
+ip4_addr flow_read_ip4_part(const byte *part);
+ip6_addr flow_read_ip6_part(const byte *part);
+
+
+/*
* Flowspec Builder
*/