CloudEdge SAM: OCI Ubuntu image firewall bootstrap
Experimental (CloudEdge SAM). This is host bootstrap / provider-image behavior, not a routerd dataplane concern. It applies to OCI Canonical Ubuntu images used as SAM routers.
Symptom
On OCI, the Canonical Ubuntu 24.04 image boots with iptables-nft filter rules
that reject inbound traffic except SSH/ICMP and reject all FORWARD traffic.
With these defaults a SAM router will:
- receive no WireGuard handshake even though the OCI security list allows
UDP/51820and the VNIC hasskipSourceDestCheck=true— the host firewall drops the inbound WireGuard packets before they reach thewg-hybridlistener; - not forward captured/overlay traffic — the default
FORWARDreject blocks the SAM delivery path between the VNIC interface andwg-hybrid.
This is independent of the cloud security list / VNIC source-dest-check, which operate at the fabric layer; the guest OS firewall is a separate layer that must also permit the SAM paths.
Required allowances (guest OS)
On each OCI SAM router, ensure the host firewall permits:
- inbound
UDP/51820to thewg-hybridWireGuard listener; FORWARDbetween the OCI VNIC interface (e.g.ens3) andwg-hybridin both directions.
Express these declaratively in the router config as part of host bootstrap (the
same way other "router prerequisites" are declared so a clean host proves them),
rather than relying on ad-hoc iptables rules that do not survive a rebuild.
Diagnosing it
routerctl doctor hybrid surfaces guest-firewall reject-all FORWARD/INPUT
patterns that would block the WireGuard / SAM paths, so a missing allowance is
reported rather than appearing as a silent "no handshake". Run it on the OCI router
after deploy:
routerctl doctor hybrid
If the WireGuard endpoint shows no handshake while the peer is sending keepalives, check the guest firewall first (this how-to), then the OCI security list, then the VNIC source-dest-check.
Related
- Selective Address Mobility
- OCI Ubuntu images differ from AWS/Azure images in their default
iptables-nftposture; AWS/Azure SAM smokes did not hit this because their images do not reject-allFORWARDby default.