Putting my thoughts:
so when a container is started, it runs
root 119 0.0 0.0 5580 4204 ? S 02:13 0:00 /usr/sbin/dhclient -d -q -sf /usr/libexec/nm-dhcp-helper -pf /run/NetworkManager/dhclient-eth0.pid -lf /var/lib/NetworkManager/dhclient-5fb06bd0-0bb0-7ffb-45f1-d6edd65f3e03-eth0.lease -cf /var/lib/Netwo
at (port 68)
# ss -laputen
Netid State Recv-Q Send-Q Local Address:Port Peer Address:Port Process
udp UNCONN 0 0 0.0.0.0:68 0.0.0.0:* users:(("dhclient",pid=119,fd=7)) ino:806005671 sk:3002 cgroup:/system.slice/NetworkManager.service <->
listening on the host
# tcpdump -i incusbr0 udp port 68
dropped privs to tcpdump
tcpdump: verbose output suppressed, use -v[v]... for full protocol decode
listening on incusbr0, link-type EN10MB (Ethernet), snapshot length 262144 bytes
22:17:09.321482 IP 0.0.0.0.bootpc > 255.255.255.255.bootps: BOOTP/DHCP, Request from 00:16:3e:83:46:52 (oui Unknown), length 300
and on the host, it seems the dnsmasq is correctly listening to the bridge interface but on the port 67 which is not the port the dhclient is sending requests to as shown above? port 68
]# ss -laputen | grep dnsmasq
udp UNCONN 0 0 10.46.30.1:53 0.0.0.0:* users:(("dnsmasq",pid=3098641,fd=6)) ino:788017155 sk:1 cgroup:/user.slice/user-3185488.slice/session-12351.scope <->
udp UNCONN 0 0 0.0.0.0%incusbr0:67 0.0.0.0:* users:(("dnsmasq",pid=3098641,fd=4)) ino:788013056 sk:2 cgroup:/user.slice/user-3185488.slice/session-12351.scope <->
tcp LISTEN 0 32 10.46.30.1:53 0.0.0.0:* users:(("dnsmasq",pid=3098641,fd=7)) ino:788017156 sk:1007 cgroup:/user.slice/user-3185488.slice/session-12351.scope <->
lastly, the following chains might be relevant?
chain ILO-FILTER-OUTPUT-UDP {
ip protocol udp udp sport 68 udp dport 67 counter packets 0 bytes 0 goto ILO-FILTER-ACCEPT
...
ip protocol udp udp dport 53 counter packets 36 bytes 2602 goto ILO-FILTER-ACCEPT
...
goto ILO-FILTER-OUTPUT-OTHER
}
chain ILO-FILTER-OUTPUT {
type filter hook output priority filter - 1; policy accept;
oif != "lo" ct state untracked accept
oif "lo" accept
ct state established,related goto ILO-FILTER-CONNTRACK
...
meta l4proto udp goto **ILO-FILTER-OUTPUT-UDP**
...
goto ILO-FILTER-OUTPUT-OTHER
}
the ipv4 address (10.46.30.1) of my network bridge incusbr0 is in the sets in the chains below
chain ILO-FILTER-INPUT-OTHER {
ip saddr @REDACTED counter packets 24 bytes 4253 goto ILO-FILTER-ACCEPT
ip protocol igmp counter packets 1 bytes 36 goto ILO-FILTER-ACCEPT
goto ILO-FILTER-INPUT-ENFORCE
}
chain ILO-FILTER-OUTPUT-OTHER {
ip daddr @REDACTED counter packets 46 bytes 9191 goto ILO-FILTER-ACCEPT
ip protocol igmp ip daddr REDACTED counter packets 0 bytes 0 goto ILO-FILTER-ACCEPT
goto ILO-FILTER-OUTPUT-ENFORCE
}
does this paint a better picture?