diff options
Diffstat (limited to 'src/crypto/internal')
| -rw-r--r-- | src/crypto/internal/fips140/rsa/keygen.go | 2 | ||||
| -rw-r--r-- | src/crypto/internal/fips140/rsa/rsa.go | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/crypto/internal/fips140/rsa/keygen.go b/src/crypto/internal/fips140/rsa/keygen.go index df96c1e525..62e0063d60 100644 --- a/src/crypto/internal/fips140/rsa/keygen.go +++ b/src/crypto/internal/fips140/rsa/keygen.go @@ -22,7 +22,7 @@ func GenerateKey(rand io.Reader, bits int) (*PrivateKey, error) { return nil, errors.New("rsa: key too small") } fips140.RecordApproved() - if bits < 2048 || bits > 16384 || bits%2 == 1 { + if bits < 2048 || bits%2 == 1 { fips140.RecordNonApproved() } diff --git a/src/crypto/internal/fips140/rsa/rsa.go b/src/crypto/internal/fips140/rsa/rsa.go index 957c266885..a65a31eb43 100644 --- a/src/crypto/internal/fips140/rsa/rsa.go +++ b/src/crypto/internal/fips140/rsa/rsa.go @@ -320,7 +320,7 @@ func checkPublicKey(pub *PublicKey) (fipsApproved bool, err error) { // FIPS 186-5, Section 5.1: "This standard specifies the use of a modulus // whose bit length is an even integer and greater than or equal to 2048 // bits." - if pub.N.BitLen() < 2048 || pub.N.BitLen() > 16384 { + if pub.N.BitLen() < 2048 { fipsApproved = false } if pub.N.BitLen()%2 == 1 { |
