-
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: RequireAndVerifyClientCert not rejecting bad client cert on 1.10 that it was on 1.9 #23884
Comments
/cc @agl @FiloSottile |
It's because we have this mess to try and work around the fact that CAs have repeatedly botched extended key usage in the past. It was made by running lots of tests on the CT logs and ServerAuth is counted as sufficient to allow ClientAuth. But I think there's a fair argument to be made that, while that might be needed when checking a chain, we don't need it when checking elements of the leaf cert. (Although we do need other exceptions then.) The best evidence for that is probably that we evidently didn't previously allow it and that didn't break the world. |
Change https://golang.org/cl/96379 mentions this issue: |
Reopening to consider for backport to 1.10.1. (Is this how it works these days?) |
given that 1.10.0 validates plain serving certificates as if they were client certificates, I'd expect a pick to 1.10.x |
CL 96379 OK for Go 1.10.1 |
Change https://golang.org/cl/102780 mentions this issue: |
…ed EKUs. There are, sadly, many exceptions to EKU checking to reflect mistakes that CAs have made in practice. However, the requirements for checking requested EKUs against the leaf should be tighter than for checking leaf EKUs against a CA. Fixes #23884 Change-Id: I05ea874c4ada0696d8bb18cac4377c0b398fcb5e Reviewed-on: https://go-review.googlesource.com/96379 Reviewed-by: Jonathan Rudenberg <[email protected]> Reviewed-by: Filippo Valsorda <[email protected]> Run-TryBot: Filippo Valsorda <[email protected]> TryBot-Result: Gobot Gobot <[email protected]> Reviewed-on: https://go-review.googlesource.com/102780 Run-TryBot: Andrew Bonventre <[email protected]> Reviewed-by: Filippo Valsorda <[email protected]>
This updates go to the latest version of the golang 1.10 branch. A few minor (but important) things are fixed in this version: * CVE-2018-7187 - arbitrary code execution in `go get` (when used with --insecure) [1] * Extended Key Usage verification in client certificate scenarios [3] * a bunch of stability changes The full list of changes can se been on GitHub [2] & [4]. [1] https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-7187 [2] https://github.com/golang/go/issues?q=milestone%3AGo1.10.1 [3] golang/go#23884 [4] golang/go#24563
This updates go to the latest version of the golang 1.10 branch. A few minor (but important) things are fixed in this version: * CVE-2018-7187 - arbitrary code execution in `go get` (when used with --insecure) [1] * Extended Key Usage verification in client certificate scenarios [3] * a bunch of stability changes The full list of changes can se been on GitHub [2] & [4]. [1] https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-7187 [2] https://github.com/golang/go/issues?q=milestone%3AGo1.10.1 [3] golang/go#23884 [4] golang/go#24563 (cherry picked from commit 568d30b)
This updates go to the latest version of the golang 1.10 branch. A few minor (but important) things are fixed in this version: * CVE-2018-7187 - arbitrary code execution in `go get` (when used with --insecure) [1] * Extended Key Usage verification in client certificate scenarios [3] * a bunch of stability changes The full list of changes can se been on GitHub [2] & [4]. [1] https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-7187 [2] https://github.com/golang/go/issues?q=milestone%3AGo1.10.1 [3] golang/go#23884 [4] golang/go#24563 (cherry picked from commit 568d30b)
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (
go env
)?What did you do?
Ran the following program on 1.9.4 and 1.10:
https://play.golang.org/p/gt67v9Ih7Te
The https server is requiring client certs with
RequireAndVerifyClientCert
. The client is using a weird (bad?) cert that hasExtKeyUsage: x509.ExtKeyUsageServerAuth
instead ofx509.ExtKeyUsageClientAuth
.What did you expect to see?
On 1.9.4 the https server rejects the weird client cert:
What did you see instead?
On 1.10 it accepts the client cert.
The text was updated successfully, but these errors were encountered: