]> Cypherpunks repositories - gostls13.git/commit
net/http: detect when an HTTPS client contacts an HTTP server
authorCaleb Spare <cespare@gmail.com>
Tue, 20 Oct 2015 07:35:42 +0000 (00:35 -0700)
committerBrad Fitzpatrick <bradfitz@golang.org>
Tue, 17 Nov 2015 04:06:32 +0000 (04:06 +0000)
commitbabdb3832072b6ca55e2dfe071bac25d865f8911
tree0fadcc48b7f2385eba22c9e530422f97acb173f5
parent662ab8be31d30e250716cc1abd63d6be68563543
net/http: detect when an HTTPS client contacts an HTTP server

Inspect the crypto/tls error to recognize this case and give a more
helpful error.

Fixes #11111.

Change-Id: I63f6af8c375aa892326ccccbd29655d54d68df0b
Reviewed-on: https://go-review.googlesource.com/16079
Run-TryBot: Caleb Spare <cespare@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/net/http/client.go
src/net/http/client_test.go