Skip to content

Commit

Permalink
Don't use "dst" literal as sni name when host=dst is specified https.
Browse files Browse the repository at this point in the history
Fixes #916
  • Loading branch information
nathanejohnson committed Dec 7, 2022
1 parent 458c701 commit c046a9b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion route/route.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ func (r *Route) addTarget(service string, targetURL *url.URL, fixedWeight float6
t.Host = opts["host"]
t.ProxyProto = opts["pxyproto"] == "true"

if t.Host != "" && (t.URL.Scheme == "https" || opts["proto"] == "https") {
if t.Host != "" && t.Host != "dst" && (t.URL.Scheme == "https" || opts["proto"] == "https") {
t.Transport = transport.NewTransport(&tls.Config{ServerName: t.Host, InsecureSkipVerify: t.TLSSkipVerify})
}

Expand Down

0 comments on commit c046a9b

Please sign in to comment.