fix: accept tls:// and https:// in [[forwarding]] upstreams #101
Reference in New Issue
Block a user
Delete Branch "fix/forward-tls-upstream"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
[[forwarding]]rules now accepttls://IP[:port]#hostnameandhttps://…/dns-queryin addition to plain UDP, closing #100config.rsreached forparse_upstream_addr(UDP-only primitive) instead of the richerparse_upstreamused by[upstream].addressandfallbackForwardingRule.upstream: SocketAddr → Upstream.parse_upstream_addrdemoted topub(crate)so the same mistake can't recur from outside the cratenuma.tomlgains commented DoT and DoH[[forwarding]]examplesTest plan
forwarding_upstream_accepts_{dot,doh}_schemetests — verified they failed with the exact error from #100 before the fix, pass afterforwarding_upstream_{with_explicit_port,defaults_to_port_53,invalid_upstream_returns_error}, merge/precedence tests, and end-to-endforwarding_rule_overrides_special_use_domain+pipeline_forwarding_returns_upstream_answerinctx.rsmatches!(Upstream::Udp(_))variant pin on the UDP path so future drift (e.g. parser choosing a different variant for a bare IP) gets caughtmake allgreen (fmt, clippy-D warnings, audit, build, 284 tests)