Constructors BigInteger and BigDecimal used to wrap primitives should never be used. (#3627)

Constructors BigInteger and BigDecimal used to wrap primitives should never be used.

Co-authored-by: Debasish Biswas <debasishbsws.abc@gmail.com>
This commit is contained in:
kongleong86
2022-11-06 12:10:14 +00:00
committed by GitHub
parent cc17d60d5c
commit c8ecd23183
4 changed files with 17 additions and 16 deletions

View File

@ -63,7 +63,7 @@ public class RSA {
publicKey = BigInteger.valueOf(3L);
while (m.gcd(publicKey).intValue() > 1) {
publicKey = publicKey.add(BigInteger.valueOf(2L));
publicKey = publicKey.add(BigInteger.TWO);
}
privateKey = publicKey.modInverse(m);