diff --git a/internal/routing/vpn.go b/internal/routing/vpn.go index ef620280..96a69849 100644 --- a/internal/routing/vpn.go +++ b/internal/routing/vpn.go @@ -31,7 +31,7 @@ func (r *Routing) VPNLocalGatewayIP(vpnIntf string) (ip netip.Addr, err error) { } switch { - case route.Dst.IsValid() && route.Dst.Addr().IsUnspecified(): // OpenVPN + case route.Dst.IsValid() && route.Dst.Addr().IsUnspecified() && route.Gw.IsValid(): // OpenVPN return route.Gw, nil case route.Dst.IsSingleIP() && route.Dst.Addr().Compare(route.Src) == 0 &&