Bug 45

Summary: UDP automatic port forwarding detects bound ports only when pasta starts
Product: passt Reporter: Stefano Brivio <sbrivio>
Component: UDPAssignee: David Gibson <dgibson>
Status: RESOLVED FIXED    
Severity: feature CC: dgibson, kuhnchris+passt
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   

Description Stefano Brivio 2023-03-21 23:28:19 UTC
...and not, like we do for TCP, periodically, after pasta is started.

This is the same for both outbound (-U auto) and inbound (-u auto) ports, and documented in the man page, but there's no particular reason why we can't re-scan bound ports periodically, other than the fact I was in a hurry when I implemented the equivalent feature for TCP.

This would support the use case where Podman creates a network namespace, running as unprivileged user, and several containers with associated network namespaces within that one, with their interfaces bridged.

Podman controls the network namespace in the middle, whereas pasta provides connectivity between that and the init namespace. To enable port forwarding from the outer namespace (init) or external hosts all the way to the innermost namespaces, without any explicit configuration, Podman could bind ports there, then pasta would notice and dynamically forward ports. However, this needs to work with UDP too, in order to be usable.
Comment 1 Stefano Brivio 2023-06-26 19:11:01 UTC
Draft patch, very lightly tested, by KuhnChris <kuhnchris+passt@kuhnchris.eu>:
  http://ix.io/4ws8
Comment 2 David Gibson 2023-11-20 00:08:41 UTC
A fix for this is now merged.