Watch
0
0
Fork
You've already forked hyperhive
0

swarm-nats: the pod's raw rule lets through the interfaces the firewall opens the client port on

The hostPort's raw-table drop for the queue's client port let through only the host's loopback, the bridge and the pods' interfaces, so a hive on another host, reaching the queue over wg0 where the firewall's own rule opens the port, timed out. The rule now also returns for every interface whose networking.firewall.interfaces entry opens the port. semi-spread dumps the queue's network state when the hive cannot reach it, and asserts the port answers over wg0 and not on the public address.
This commit is contained in:
atlas 2026-11-26 23:32:02 +01:00 • committed by maia
commit 7ad74b494f

View file

@ -227,8 +227,10 @@ strategy, and the removed container stops before the pod can start.
`deploy.nats.openFirewall` and the bridge's port list write, never see what it
rewrites. The module therefore adds rules to the raw table, which the kernel
reads before the DNAT: a packet for the node's address and the client port is
dropped unless it arrives on the host's loopback, the hive bridge or a pod
interface, or unless `deploy.nats.openFirewall` is on. The container's port
dropped unless it arrives on the host's loopback, the hive bridge, a pod
interface or an interface that `networking.firewall.interfaces` opens the port on
(the semi-spread example opens it on `wg0`), or unless `deploy.nats.openFirewall`
is on. The container's port
has that reach. The `hostPort` sends the bridge's agents to the cluster, which
a host with the egress intercept on refuses, so the module also adds the port
to `egress.publishedPorts`