Also show exponent

This commit is contained in:
Ruben van Staveren 2020-09-10 17:44:59 +02:00
parent b0562e1497
commit ebe467260a
Failed to extract signature

View File

@ -55,7 +55,9 @@ class PkDecoratorRSA(PkDecorator):
def __str__(self):
pk_crypto = self.pk.to_cryptography_key()
return "RSA Private key %d bits" % pk_crypto.key_size
return "RSA Private key %d bits (exponent %d)" % (
pk_crypto.key_size,
pk_crypto.private_numbers().public_numbers.e)
class PkDecoratorDSA(PkDecorator):