1
0
Fork 0
mirror of https://passt.top/passt synced 2025-05-25 18:45:37 +02:00

tap: Fill the IPv6 flow label field to represent flow association

This isn't optional: TCP streams must carry a unique, hard-to-guess,
non-zero label for each direction. Linux, probably among others,
will otherwise refuse to associate packets in a given stream to the
same connection.

Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
This commit is contained in:
Stefano Brivio 2021-07-26 07:30:57 +02:00
parent 17765f8de0
commit 16b08367a5
5 changed files with 25 additions and 10 deletions

2
tap.h
View file

@ -1,5 +1,5 @@
void tap_ip_send(struct ctx *c, struct in6_addr *src, uint8_t proto,
char *in, size_t len);
char *in, size_t len, uint32_t flow);
int tap_send(struct ctx *c, void *data, size_t len, int vnet_pre);
void tap_handler(struct ctx *c, uint32_t events, struct timespec *now);
void tap_sock_init(struct ctx *c);