diff options
| author | David Gibson <david@gibson.dropbear.id.au> | 2026-01-16 11:59:15 +1100 |
|---|---|---|
| committer | Stefano Brivio <sbrivio@redhat.com> | 2026-01-18 12:47:35 +0100 |
| commit | 9323ab97c4abeba07b43060294069b43c8c32316 (patch) | |
| tree | 9de58484e1bc93cfc779d25c69f951c9e4860cad /test/tcp | |
| parent | bd52f61e48458b4dd8a4bc4ae80d9bccca7e33d3 (diff) | |
| download | passt-9323ab97c4abeba07b43060294069b43c8c32316.tar passt-9323ab97c4abeba07b43060294069b43c8c32316.tar.gz passt-9323ab97c4abeba07b43060294069b43c8c32316.tar.bz2 passt-9323ab97c4abeba07b43060294069b43c8c32316.tar.lz passt-9323ab97c4abeba07b43060294069b43c8c32316.tar.xz passt-9323ab97c4abeba07b43060294069b43c8c32316.tar.zst passt-9323ab97c4abeba07b43060294069b43c8c32316.zip | |
conf: Accurately record ifname and address for outbound forwards
-T and -U options don't allow specifying a listening address. Usually this
will listen on *%lo in the guest. However on kernels without unprivileged
SO_BINDTODEVICE that's not possible so we instead listen separately on
127.0.0.1 and ::1.
Currently that's handled at the point we actually set up the listens,
we record both address and ifname as NULL in the forwarding table
entry. That will cause trouble for future extensions we want, so
update this to accurately create the forwarding table: either a single
rule with ifname == "lo" or two rules with addresses of 127.0.0.1 and
::1.
As a bonus, this gives the user a warning if they specify an explicit
outbound forwarding on a kernel without SO_BINDTODEVICE. The existing
warning for missing SO_BINDTODEVICE incorrectly covered only the case
of -T auto or -U auto.
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Diffstat (limited to 'test/tcp')
0 files changed, 0 insertions, 0 deletions
