-
Notifications
You must be signed in to change notification settings - Fork 17.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
crypto/tls: remote error: tls: handshake failure #46270
Comments
In fact, $ openssl s_client -connect epp.nic.fr:700
CONNECTED(00000003)
depth=2 C = US, O = DigiCert Inc, OU = www.digicert.com, CN = DigiCert Global Root CA
verify return:1
depth=1 C = US, O = DigiCert Inc, OU = www.digicert.com, CN = RapidSSL RSA CA 2018
verify return:1
depth=0 CN = *.nic.fr
verify return:1
139815768130880:error:14094410:SSL routines:ssl3_read_bytes:sslv3 alert handshake failure:../ssl/record/rec_layer_s3.c:1543:SSL alert number 40
...
$ curl -v https://epp.nic.fr:700
* Trying 192.134.5.10:700...
* TCP_NODELAY set
* Trying 2001:67c:2218:e::51:41:700...
* TCP_NODELAY set
* Connected to epp.nic.fr (192.134.5.10) port 700 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully set certificate verify locations:
* CAfile: /etc/ssl/certs/ca-certificates.crt
CApath: /etc/ssl/certs
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* TLSv1.3 (IN), TLS handshake, Server hello (2):
* TLSv1.2 (IN), TLS handshake, Certificate (11):
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
* TLSv1.2 (IN), TLS handshake, Request CERT (13):
* TLSv1.2 (IN), TLS handshake, Server finished (14):
* TLSv1.2 (OUT), TLS handshake, Certificate (11):
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
* TLSv1.2 (OUT), TLS change cipher, Change cipher spec (1):
* TLSv1.2 (OUT), TLS handshake, Finished (20):
* TLSv1.2 (IN), TLS alert, handshake failure (552):
* error:14094410:SSL routines:ssl3_read_bytes:sslv3 alert handshake failure
* Closing connection 0
curl: (35) error:14094410:SSL routines:ssl3_read_bytes:sslv3 alert handshake failure The output of |
Closing for the same reason as #9446 the protocol doesn't provide extra information on why it is a failure Unlike many projects, the Go project does not use GitHub Issues for general discussion or asking questions. GitHub Issues are used for tracking bugs and proposals only. For questions please refer to https://github.com/golang/go/wiki/Questions |
This issue can be similar to https://github.com/golang/go/issues/9446, but that one was closed in time, and recipes didn't help.
### What version of Go are you using (
go version
)?go version go1.16.3 darwin/amd64
but reproducing also on linux:
go version go1.16 linux/amd64
### Does this issue reproduce with the latest release?
Yes
### What operating system and processor architecture are you using (
go env
)?go env
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/Users/dzehv/Library/Caches/go-build"
GOENV="/Users/dzehv/Library/Application Support/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOINSECURE=""
GOMODCACHE="/Users/dzehv/gocode/pkg/mod"
GONOPROXY=""
GONOSUMDB=""
GOOS="darwin"
GOPATH="/Users/dzehv/gocode"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local/opt/go/libexec"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/opt/go/libexec/pkg/tool/darwin_amd64"
GOVCS=""
GOVERSION="go1.16.3"
GCCGO="gccgo"
AR="ar"
CC="clang"
CXX="clang++"
CGO_ENABLED="1"
GOMOD="/dev/null"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/th/wlk6yc_14yddwsg85jltxnc80000gn/T/go-build1880165201=/tmp/go-build -gno-record-gcc-switches -fno-common"
### What did you do
There were similar topics few years ago, but no solutions worked for my case. I took one of debug examples from that topic https://github.com/golang/go/issues/9446 to demostrate reproducing error:
### What did you expect to see?
Handshake was done, like using openssl cli, which is working properly:
openssl s_client -connect epp.nic.fr:700
### What did you see instead?
CLIENT_RANDOM e84c46303892b2073e4cb09cf63f99541bacaf21ccd173a454ef737fcd4412e0 0a60ebce23a314a459867985a00cc35cd6b148f12762e41e07fb818a1f8e6f91262a0c51a6e5e411e183dee577facf51
epp.nic.fr:700 remote error: tls: handshake failure
NOTE: using certs gives the same result, but openssl works properly.
How can I additionaly debug this case to see more information from crypto/tls or server output? There were also more playarounds with tls.Config, cipher suites, etc. Nothing helps for now.
The text was updated successfully, but these errors were encountered: