1
0
mirror of https://passt.top/passt synced 2024-06-30 23:12:39 +00:00
passt implements a translation layer between a Layer-2 network interface and native Layer-4 sockets (TCP, UDP, ICMP/ICMPv6 echo) on a host. It doesn't require any capabilities or privileges, and it can be used as a simple replacement for Slirp.
Go to file
Stefano Brivio bb9fb9e2d1 tcp: Introduce hash table for socket lookup for packets from tap
Replace the dummy, full array scan implementation, by a hash table
based on SipHash, with chained hashing for collisions.

This table is also statically allocated, and it's simply an array
of socket numbers. Connection entries are chained by pointers in
the connection entry itself, which now also contains socket number
and hash bucket index to keep removal reasonably fast.

New entries are inserted at the head of the chain, that is, the most
recently inserted entry is directly mapped from the bucket.

Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
2021-03-17 10:57:40 +01:00
doc passt: Assorted fixes from "fresh eyes" review 2021-02-21 11:55:49 +01:00
arp.c passt: Assorted fixes from "fresh eyes" review 2021-02-21 11:55:49 +01:00
arp.h passt: Assorted fixes from "fresh eyes" review 2021-02-21 11:55:49 +01:00
dhcp.c passt: Assorted fixes from "fresh eyes" review 2021-02-21 11:55:49 +01:00
dhcp.h passt: Assorted fixes from "fresh eyes" review 2021-02-21 11:55:49 +01:00
Makefile tcp: Add siphash implementation for initial sequence numbers 2021-03-17 10:57:36 +01:00
ndp.c passt: Assorted fixes from "fresh eyes" review 2021-02-21 11:55:49 +01:00
ndp.h passt: Assorted fixes from "fresh eyes" review 2021-02-21 11:55:49 +01:00
passt.c passt: Assorted fixes from "fresh eyes" review 2021-02-21 11:55:49 +01:00
passt.h passt: New design and implementation with native Layer 4 sockets 2021-02-16 09:28:55 +01:00
qrap.c passt: New design and implementation with native Layer 4 sockets 2021-02-16 09:28:55 +01:00
siphash.c tcp: Add siphash implementation for initial sequence numbers 2021-03-17 10:57:36 +01:00
siphash.h tcp: Add siphash implementation for initial sequence numbers 2021-03-17 10:57:36 +01:00
tap.c passt: New design and implementation with native Layer 4 sockets 2021-02-16 09:28:55 +01:00
tap.h passt: New design and implementation with native Layer 4 sockets 2021-02-16 09:28:55 +01:00
tcp.c tcp: Introduce hash table for socket lookup for packets from tap 2021-03-17 10:57:40 +01:00
tcp.h passt: Assorted fixes from "fresh eyes" review 2021-02-21 11:55:49 +01:00
udp.c passt: Assorted fixes from "fresh eyes" review 2021-02-21 11:55:49 +01:00
udp.h passt: New design and implementation with native Layer 4 sockets 2021-02-16 09:28:55 +01:00
util.c passt: Assorted fixes from "fresh eyes" review 2021-02-21 11:55:49 +01:00
util.h passt: New design and implementation with native Layer 4 sockets 2021-02-16 09:28:55 +01:00