mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
a01daab656
Methods that take both PEM-encoding and DER-encoding have not been consistent in the order in which encoding to attempt to parse. A DER-encoding may contain a valid PEM block ("\n-----BEGIN ..-----" to "-----END ...-----") embedded within it. Also, the PEM-encoding parser allows arbitrary data around the PEM block and silently skips it. As a result, attempting to parse data in DER-encoding as PEM-encoding first can incorrectly finds the embedded PEM block instead. This commit ensures that DER encoding will always be attempted before PEM encoding. OpenSSL::X509::Certificate is one of the updated classes. With this, the following will always be true: # obj is an OpenSSL::X509::Certificate obj == OpenSSL::X509::Certificate.new(obj.to_der) obj == OpenSSL::X509::Certificate.new(obj.to_pem) https://github.com/ruby/openssl/commit/b280eb1fd0 |
||
---|---|---|
.. | ||
fixtures/pkey | ||
test_asn1.rb | ||
test_bn.rb | ||
test_buffering.rb | ||
test_cipher.rb | ||
test_config.rb | ||
test_digest.rb | ||
test_engine.rb | ||
test_fips.rb | ||
test_hmac.rb | ||
test_kdf.rb | ||
test_ns_spki.rb | ||
test_ocsp.rb | ||
test_ossl.rb | ||
test_pair.rb | ||
test_pkcs7.rb | ||
test_pkcs12.rb | ||
test_pkey.rb | ||
test_pkey_dh.rb | ||
test_pkey_dsa.rb | ||
test_pkey_ec.rb | ||
test_pkey_rsa.rb | ||
test_random.rb | ||
test_ssl.rb | ||
test_ssl_session.rb | ||
test_ts.rb | ||
test_x509attr.rb | ||
test_x509cert.rb | ||
test_x509crl.rb | ||
test_x509ext.rb | ||
test_x509name.rb | ||
test_x509req.rb | ||
test_x509store.rb | ||
ut_eof.rb | ||
utils.rb |