]> Cypherpunks.ru repositories - gostls13.git/commit
crypto/rsa: refactor RSA-PSS signing and verification
authorFilippo Valsorda <filippo@golang.org>
Wed, 1 Apr 2020 21:25:40 +0000 (17:25 -0400)
committerFilippo Valsorda <filippo@golang.org>
Thu, 2 Apr 2020 17:46:57 +0000 (17:46 +0000)
commit9baafabac9a84813a336f068862207d2bb06d255
tree8fc40261a8ca4401045160e7bf0960b9fde17dc8
parentaa4d92b8aab63c847ab077417b809694a2a6ea81
crypto/rsa: refactor RSA-PSS signing and verification

Cleaned up for readability and consistency.

There is one tiny behavioral change: when PSSSaltLengthEqualsHash is
used and both hash and opts.Hash were set, hash.Size() was used for the
salt length instead of opts.Hash.Size(). That's clearly wrong because
opts.Hash is documented to override hash.

Change-Id: I3e25dad933961eac827c6d2e3bbfe45fc5a6fb0e
Reviewed-on: https://go-review.googlesource.com/c/go/+/226937
Run-TryBot: Filippo Valsorda <filippo@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Katie Hockman <katie@golang.org>
src/crypto/rsa/pss.go
src/crypto/rsa/rsa.go