Class: FidoMetadata::Statement

Inherits:
Object
  • Object
show all
Extended by:
Attributes
Defined in:
lib/fido_metadata/statement.rb

Instance Method Summary collapse

Methods included from Attributes

from_json, json_accessor

Instance Method Details

#attestation_root_certificatesObject

Lazy load certificates for compatibility ActiveSupport::Cache. Can be removed once we require a version of OpenSSL which includes github.com/ruby/openssl/pull/281



53
54
55
# File 'lib/fido_metadata/statement.rb', line 53

def attestation_root_certificates
  Coercer::Certificates.coerce(@attestation_root_certificates)
end

#trust_storeObject



57
58
59
60
61
62
63
# File 'lib/fido_metadata/statement.rb', line 57

def trust_store
  trust_store = OpenSSL::X509::Store.new
  attestation_root_certificates.each do |certificate|
    trust_store.add_cert(certificate)
  end
  trust_store
end