diff options
author | Mikael Magnusson <mikma@users.sourceforge.net> | 2019-09-27 23:21:56 +0200 |
---|---|---|
committer | Mikael Magnusson <mikma@users.sourceforge.net> | 2019-11-15 00:11:29 +0100 |
commit | 4a402d2cdbfead5eba9eec6e955c136ad96328e0 (patch) | |
tree | 0b5d00c8be1bbb37c32fb9b3f5a828cff87008e6 /lib/tunnel_encaps.h | |
parent | c714681773bb0b932d55b2028c46e3a7982bdd6a (diff) |
Wireguard: Add struct tunnel_encapold/wireguard-bp
Diffstat (limited to 'lib/tunnel_encaps.h')
-rw-r--r-- | lib/tunnel_encaps.h | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/lib/tunnel_encaps.h b/lib/tunnel_encaps.h index 9d25e5c5..341dcf22 100644 --- a/lib/tunnel_encaps.h +++ b/lib/tunnel_encaps.h @@ -16,6 +16,22 @@ #define FLAG_BGP_TUNNEL_ENCAP_A_SUB_TLV_TUNNEL_EP (1<<BGP_TUNNEL_ENCAP_A_SUB_TLV_TUNNEL_EP) #define FLAG_BGP_TUNNEL_ENCAP_A_SUB_TLV_UDP_DEST_PORT (1<<BGP_TUNNEL_ENCAP_A_SUB_TLV_UDP_DEST_PORT) -int decode_tunnel_encap(const eattr *e, u16 wg_tunnel_type, void *encap, size_t *encap_size, u32 *as4, ip_addr *tunnel_ep, u32 *color, u16 *udp_port, u16 *flags); +/* Tunnel Encapsulation */ +struct tunnel_endpoint { + u32 asn; + ip_addr ip; +}; + +struct tunnel_encap { + int type; + void *encap; + size_t encap_len; + struct tunnel_endpoint ep; + u32 color; + u16 udp_dest_port; + u16 flags; +}; + +int decode_tunnel_encap(const eattr *e, struct tunnel_encap *encap, struct pool *pool); #endif /* _BIRD_TUNNEL_ENCAPS_ */ |