lib/sepa/utilities.rb
def verify_certificate_against_root_certificate(certificate, root_certificate)
      return false unless certificate && root_certificate
      return false unless root_certificate.subject == certificate.issuer

      certificate.verify(root_certificate.public_key)
    end
# Verifies that a certificate has been signed by the private key of a root certificate
#
# @param certificate [OpenSSL::X509::Certificate] the certificate to verify
# @param root_certificate [OpenSSL::X509::Certificate] the root certificate
# @return [true] if the certificate has been signed by the private key of the root certificate
# @return [false] if the certificate has not been signed by the private key of the root
#   certificate, the certificates are nil or the subject of the root certificate is not the
#   issuer of the certificate
Verifies that a certificate has been signed by the private key of a root certificate
Verifies that a certificate has been signed by the private key of a root certificate
def verify_certificate_against_root_certificate(certificate, root_certificate)
      return false unless certificate && root_certificate
      return false unless root_certificate.subject == certificate.issuer
      certificate.verify(root_certificate.public_key)
    end
def verify_certificate_against_root_certificate ( certificate , root_certificate ) return false unless certificate && root_certificate return false unless root_certificate . subject == certificate . issuer certificate . verify ( root_certificate . public_key ) end
Verifies that a certificate has been signed by the private key of a root certificate
Verifies that a certificate has been signed by the private key of a root certificate
if the certificate has been signed by the private key of the root certificate
if the certificate has been signed by the private key of the root certificate
true
if the certificate has not been signed by the private key of the root certificate, the certificates are nil or the subject of the root certificate is not the issuer of the certificate
if the certificate has not been signed by the private key of the root certificate the certificates are nil or the subject of the root certificate is not the issuer of the certificate
false
certificate
the certificate to verify
the certificate to verify
root_certificate
the root certificate
the root certificate