k8s: the queue's client port is a loadbalancer service
The queue's client port was a hostPort on 0.0.0.0, which Pod Security baseline and restricted forbid. It is a LoadBalancer Service now, which k3s's service load balancer binds on every address of the node with a hostPort of its own in kube-system, so hives on other hosts keep their URL. No node port is allocated. The stt policy allows the load balancer's pods in place of the queue's, and the prune unit waits for them to go before the host unit starts. The egress published-port rule and the raw-table rules apply to the load balancer's hostPort as to the pod's.
This commit is contained in:
parent
c2d57df7f5
commit
796fd6201f
1 changed files with 200 additions and 75 deletions
|
|
@ -763,12 +763,12 @@ also refuses the flow.
|
|||
`services.hyperhive.deploy.hive-controller.egress.publishedPorts`, in both
|
||||
modes, so such a flow leaves no count and no line. A module that publishes a
|
||||
port adds it: the queue in the cluster adds its client port, because the
|
||||
pod's `hostPort` rewrites the destination to the pod and the packet then
|
||||
leaves the bridge for the cluster. An agent dials the queue's name, which the
|
||||
hive's resolver answers with the bridge's address. A flow to the pod's own
|
||||
address has no redirect, and one to the node's address has another original
|
||||
destination, so both stay refused. The set is empty, and the chain has no
|
||||
such rule, while no module publishes a port.
|
||||
`hostPort` of the cluster's load balancer rewrites the destination, and the
|
||||
packet then leaves the bridge for the cluster. An agent dials the queue's
|
||||
name, which the hive's resolver answers with the bridge's address. A flow to
|
||||
the pod's own address has no redirect, and one to the node's address has
|
||||
another original destination, so both stay refused. The set is empty, and the
|
||||
chain has no such rule, while no module publishes a port.
|
||||
- **What `reject` refuses.** Everything from the bridge to the uplink that the
|
||||
chain didn't exempt or allow, whether a flow is new or not: TCP on any port
|
||||
but the 80 and 443 that squid takes, UDP (DNS to an outside resolver, QUIC
|
||||
|
|
|
|||
Loading…
Reference in a new issue