slackhq/nebula · error
entry %v.route in tun.unsafe_routes failed to parse: %v
Error message
entry %v.route in tun.unsafe_routes failed to parse: %v
What it means
Config validation error in parseUnsafeRoutes: the i+1-th entry's `route` value, rendered with %v, was rejected by netip.ParsePrefix — not a valid CIDR (missing /len, host bits set, malformed). The ParsePrefix error is included.
Source
Thrown at overlay/route.go:292
install := true
rInstall, ok := m["install"]
if ok {
install, err = strconv.ParseBool(fmt.Sprintf("%v", rInstall))
if err != nil {
return nil, fmt.Errorf("entry %v.install in tun.unsafe_routes is not a boolean: %v", i+1, err)
}
}
r := Route{
Via: gateways,
MTU: mtu,
Metric: metric,
Install: install,
}
r.Cidr, err = netip.ParsePrefix(fmt.Sprintf("%v", rRoute))
if err != nil {
return nil, fmt.Errorf("entry %v.route in tun.unsafe_routes failed to parse: %v", i+1, err)
}
for _, network := range networks {
if network.Contains(r.Cidr.Addr()) {
return nil, fmt.Errorf(
"entry %v.route in tun.unsafe_routes is contained within the configured vpn networks; route: %v, network: %v",
i+1,
r.Cidr.String(),
network.String(),
)
}
}
routes[i] = r
}
return routes, nil
}View on GitHub (pinned to dd8f660c0a)
Solutions
- Write route as a proper network prefix like 10.1.0.0/16
- Ensure the length suffix is present and in range
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at overlay/route.go:292 when the library encounters an invalid state.
Common situations: See trigger scenarios.
Understand the failure class
- Parsing and encoding errors: unexpected token, malformed input — why parsers reject input and how to find the real culprit.
AI-assisted analysis of slackhq/nebula@dd8f660c0a (2026-09-03).
Data as JSON: /api/errors/0c4b2b5674741b58.
Report an issue: GitHub.