diff options
author | Philippe Guibert <philippe.guibert@6wind.com> | 2019-10-16 08:44:20 +0200 |
---|---|---|
committer | Philippe Guibert <philippe.guibert@6wind.com> | 2020-08-21 13:37:08 +0200 |
commit | 4088180002478f772332aefbac54f9148f20018f (patch) | |
tree | c6812a338a22003d3b58eea932bd00db65788831 /lib/pbr.h | |
parent | bgpd: ipv6 flowspec address decoding and validation (diff) | |
download | frr-4088180002478f772332aefbac54f9148f20018f.tar.xz frr-4088180002478f772332aefbac54f9148f20018f.zip |
bgpd, lib: support for flow_label flowspec type
in ipv6 flowspec, a new type is defined to be able to do filtering rules
based on 20 bits flow label field as depicted in [0]. The change include
the decoding by flowspec, and the addition of a new attribute in policy
routing rule, so that the data is ready to be sent to zebra.
The commit also includes a check on fragment option, since dont fragment
bit does not exist in ipv6, the value should always be set to 0,
otherwise the flowspec rule becomes invalid.
[0] https://tools.ietf.org/html/draft-ietf-idr-flow-spec-v6-09
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'lib/pbr.h')
-rw-r--r-- | lib/pbr.h | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -129,6 +129,8 @@ struct pbr_rule { #define MATCH_FRAGMENT_INVERSE_SET (1 << 9) #define MATCH_ICMP_SET (1 << 10) #define MATCH_PROTOCOL_SET (1 << 11) +#define MATCH_FLOW_LABEL_SET (1 << 12) +#define MATCH_FLOW_LABEL_INVERSE_SET (1 << 13) extern int zapi_pbr_rule_encode(uint8_t cmd, struct stream *s, struct pbr_rule *zrule); |