Sha256: 7ee057c37adb72db6beb0774f93cce16d20e6a7117a8c30b6aab5902aefe2032
Contents?: true
Size: 656 Bytes
Versions: 20
Compression:
Stored size: 656 Bytes
Contents
require 'spec_helper' describe Puppet::SSL::CertificateSigner do include PuppetSpec::Files let(:wrong_key) { OpenSSL::PKey::RSA.new(512) } let(:client_cert) { cert_fixture('signed.pem') } # jruby-openssl >= 0.13.0 (JRuby >= 9.3.5.0) raises an error when signing a # certificate when there is a discrepancy between the certificate and key. it 'raises if client cert signature is invalid', if: Puppet::Util::Platform.jruby? && RUBY_VERSION.to_f >= 2.6 do expect { client_cert.sign(wrong_key, OpenSSL::Digest::SHA256.new) }.to raise_error(OpenSSL::X509::CertificateError, 'invalid public key data') end end
Version data entries
20 entries across 20 versions & 1 rubygems