Class: HasHelpers::ServiceTrust::KeyManager::EnvKey

Inherits:
Struct
  • Object
show all
Defined in:
lib/has_helpers/service_trust/key_manager.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#activeObject

Returns the value of attribute active

Returns:

  • (Object)

    the current value of active



11
12
13
# File 'lib/has_helpers/service_trust/key_manager.rb', line 11

def active
  @active
end

#algorithmObject

Returns the value of attribute algorithm

Returns:

  • (Object)

    the current value of algorithm



11
12
13
# File 'lib/has_helpers/service_trust/key_manager.rb', line 11

def algorithm
  @algorithm
end

#environmentObject

Returns the value of attribute environment

Returns:

  • (Object)

    the current value of environment



11
12
13
# File 'lib/has_helpers/service_trust/key_manager.rb', line 11

def environment
  @environment
end

#kidObject

Returns the value of attribute kid

Returns:

  • (Object)

    the current value of kid



11
12
13
# File 'lib/has_helpers/service_trust/key_manager.rb', line 11

def kid
  @kid
end

#private_key_pemObject

Returns the value of attribute private_key_pem

Returns:

  • (Object)

    the current value of private_key_pem



11
12
13
# File 'lib/has_helpers/service_trust/key_manager.rb', line 11

def private_key_pem
  @private_key_pem
end

#public_key_pemObject

Returns the value of attribute public_key_pem

Returns:

  • (Object)

    the current value of public_key_pem



11
12
13
# File 'lib/has_helpers/service_trust/key_manager.rb', line 11

def public_key_pem
  @public_key_pem
end

Instance Method Details

#idObject



20
21
22
# File 'lib/has_helpers/service_trust/key_manager.rb', line 20

def id
  nil
end

#persisted?Boolean

Returns:

  • (Boolean)


24
25
26
# File 'lib/has_helpers/service_trust/key_manager.rb', line 24

def persisted?
  false
end

#public_keyObject



16
17
18
# File 'lib/has_helpers/service_trust/key_manager.rb', line 16

def public_key
  OpenSSL::PKey.read(public_key_pem)
end

#to_opensslObject



12
13
14
# File 'lib/has_helpers/service_trust/key_manager.rb', line 12

def to_openssl
  OpenSSL::PKey.read(private_key_pem)
end