Class: Ccrypto::RSAConfig

Inherits:
KeypairConfig show all
Defined in:
lib/ccrypto/configs/keypair_config.rb

Instance Attribute Summary collapse

Attributes inherited from KeypairConfig

#algo, #keypair, #private_key, #public_key

Attributes included from AlgoConfig

#provider_config

Instance Method Summary collapse

Methods inherited from KeypairConfig

#has_keypair?, #has_private_key?, #has_public_key?

Methods included from AlgoConfig

include, #provider_info

Constructor Details

#initialize(keysize = 2048) ⇒ RSAConfig

Returns a new instance of RSAConfig.



45
46
47
# File 'lib/ccrypto/configs/keypair_config.rb', line 45

def initialize(keysize = 2048)
  @keysize = keysize
end

Instance Attribute Details

#keysizeObject

Returns the value of attribute keysize.



44
45
46
# File 'lib/ccrypto/configs/keypair_config.rb', line 44

def keysize
  @keysize
end

Instance Method Details

#to_sObject



49
50
51
# File 'lib/ccrypto/configs/keypair_config.rb', line 49

def to_s
  "RSA-#{keysize} bits"
end