]> Cypherpunks repositories - gostls13.git/commit
crypto/tls: advertise and accept rsa_pss_rsae signature algorithms
authorFilippo Valsorda <filippo@golang.org>
Wed, 31 Oct 2018 16:14:51 +0000 (12:14 -0400)
committerFilippo Valsorda <filippo@golang.org>
Fri, 2 Nov 2018 22:05:52 +0000 (22:05 +0000)
commitee7e443389f7c8aabc58d49e42880b96f0955361
tree8c527cd14abc5f060d40399104bf80ea45824241
parent7f5dce08ad77519bfea58880492e1d290cd13cb0
crypto/tls: advertise and accept rsa_pss_rsae signature algorithms

crypto/x509 already supports PSS signatures (with rsaEncryption OID),
and crypto/tls support was added in CL 79736. Advertise support for the
algorithms and accept them as a peer.

Note that this is about PSS signatures from regular RSA public keys.
RSA-PSS only public keys (with RSASSA-PSS OID) are supported in neither
crypto/tls nor crypto/x509. See RFC 8446, Section 4.2.3.

testdata/Server-TLSv12-ClientAuthRequested* got modified because the
CertificateRequest carries the supported signature algorithms.

The net/smtp tests changed because 512 bits keys are too small for PSS.

Based on Peter Wu's CL 79738, who did all the actual work in CL 79736.

Updates #9671

Change-Id: I4a31e9c6e152ff4c50a5c8a274edd610d5fff231
Reviewed-on: https://go-review.googlesource.com/c/146258
Run-TryBot: Filippo Valsorda <filippo@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Adam Langley <agl@golang.org>
13 files changed:
src/crypto/tls/common.go
src/crypto/tls/handshake_client_test.go
src/crypto/tls/handshake_server_test.go
src/crypto/tls/handshake_test.go
src/crypto/tls/testdata/Client-TLSv12-ClientCert-RSA-RSAPKCS1v15 [new file with mode: 0644]
src/crypto/tls/testdata/Client-TLSv12-ClientCert-RSA-RSAPSS [new file with mode: 0644]
src/crypto/tls/testdata/Server-TLSv12-ClientAuthRequestedAndECDSAGiven
src/crypto/tls/testdata/Server-TLSv12-ClientAuthRequestedAndGiven
src/crypto/tls/testdata/Server-TLSv12-ClientAuthRequestedAndPKCS1v15Given [new file with mode: 0644]
src/crypto/tls/testdata/Server-TLSv12-ClientAuthRequestedNotGiven
src/crypto/tls/testdata/Server-TLSv12-RSA-RSAPKCS1v15 [new file with mode: 0644]
src/crypto/tls/testdata/Server-TLSv12-RSA-RSAPSS [new file with mode: 0644]
src/net/smtp/smtp_test.go