7 Commits

Author SHA1 Message Date
Albin Kerouanton
fc045ad139 libnet/pmapi: remove firewaller arg from Map/UnmapPorts
Signed-off-by: Albin Kerouanton <albinker@gmail.com>
2025-08-28 11:47:29 +02:00
Albin Kerouanton
268e636b2b libnet/pmapi: let portmappers specify NAT/fwding rules
Add two new fields to portmapperapi.PortBinding: NAT and Forwarding.
These can be used by portmappers to specify how they want their callers
(e.g. bridge driver) to reconfigure the host firewall to NAT a host
port, or allow forwarding to the container port.

If portmappers don't want to opt-in to these, they can implement their
own firewall rules, and not fill these fields.

Signed-off-by: Albin Kerouanton <albinker@gmail.com>
2025-08-28 09:30:17 +02:00
Derek McGowan
f74e5d48b3 Create github.com/moby/moby/v2 module
Signed-off-by: Derek McGowan <derek@mcg.dev>
2025-07-31 10:13:29 -07:00
Albin Kerouanton
4e246efcd1 libnet/d/bridge: mv portmapper to libnet/pms/{nat,routed}
Signed-off-by: Albin Kerouanton <albinker@gmail.com>
2025-07-22 12:37:01 +02:00
Albin Kerouanton
41cd92f6c0 libnet/portmapperapi: add PortMapper interface, registry
Signed-off-by: Albin Kerouanton <albinker@gmail.com>
2025-07-22 12:37:01 +02:00
Albin Kerouanton
aa36cc5d25 libnet/d/bridge: move portBinding to portmapperapi
All unexported fields in portBinding are now exported.

Signed-off-by: Albin Kerouanton <albinker@gmail.com>
2025-07-22 12:37:01 +02:00
Albin Kerouanton
429818f969 libnet/d/bridge: move portBindingReq to portmapperapi
The two unexported fields of portBindingReq (ChildHostIP and DisableNAT)
are temporarily exported. DisableNAT will be replaced in a future commit
by a 'Mapper' field indicating which portmapper should be used (e.g.
'nat' or 'routed').

Signed-off-by: Albin Kerouanton <albinker@gmail.com>
2025-07-22 12:03:33 +02:00