summaryrefslogtreecommitdiff
path: root/ext/openssl
diff options
context:
space:
mode:
Diffstat (limited to 'ext/openssl')
-rw-r--r--ext/openssl/History.md53
-rw-r--r--ext/openssl/depend353
-rw-r--r--ext/openssl/extconf.rb12
-rw-r--r--ext/openssl/lib/openssl/buffering.rb12
-rw-r--r--ext/openssl/lib/openssl/ssl.rb12
-rw-r--r--ext/openssl/lib/openssl/version.rb2
-rw-r--r--ext/openssl/lib/openssl/x509.rb18
-rw-r--r--ext/openssl/openssl.gemspec4
-rw-r--r--ext/openssl/openssl_missing.h29
-rw-r--r--ext/openssl/ossl.c42
-rw-r--r--ext/openssl/ossl.h13
-rw-r--r--ext/openssl/ossl_bn.c186
-rw-r--r--ext/openssl/ossl_digest.c14
-rw-r--r--ext/openssl/ossl_hmac.c4
-rw-r--r--ext/openssl/ossl_ocsp.c2
-rw-r--r--ext/openssl/ossl_pkey.c4
-rw-r--r--ext/openssl/ossl_pkey_ec.c10
-rw-r--r--ext/openssl/ossl_ssl.c310
-rw-r--r--ext/openssl/ossl_ts.c18
-rw-r--r--ext/openssl/ossl_x509name.c11
-rw-r--r--ext/openssl/ossl_x509store.c38
-rw-r--r--ext/openssl/ruby_missing.h24
22 files changed, 750 insertions, 421 deletions
diff --git a/ext/openssl/History.md b/ext/openssl/History.md
index a4a82a146c5..255c0fc50bd 100644
--- a/ext/openssl/History.md
+++ b/ext/openssl/History.md
@@ -1,3 +1,20 @@
+Version 2.2.1
+=============
+
+Merged changes in 2.1.3. Additionally, the following issues are fixed by this
+release.
+
+Bug fixes
+---------
+
+* Fix crash in `OpenSSL::Timestamp::{Request,Response,TokenInfo}.new` when
+ invalid arguments are given.
+ [[GitHub #407]](https://github.com/ruby/openssl/pull/407)
+* Fix `OpenSSL::Timestamp::Factory#create_timestamp` with LibreSSL on platforms
+ where `time_t` has a different size from `long`.
+ [[GitHub #454]](https://github.com/ruby/openssl/pull/454)
+
+
Version 2.2.0
=============
@@ -75,6 +92,42 @@ Notable changes
[[GitHub #297]](https://github.com/ruby/openssl/pull/297)
+Version 2.1.3
+=============
+
+Bug fixes
+---------
+
+* Fix deprecation warnings on Ruby 3.0.
+* Add ".include" directive support in `OpenSSL::Config`.
+ [[GitHub #216]](https://github.com/ruby/openssl/pull/216)
+* Fix handling of IPv6 address SANs.
+ [[GitHub #185]](https://github.com/ruby/openssl/pull/185)
+* Hostname verification failure with `OpenSSL::SSL::SSLContext#verify_hostname=`
+ sets a proper error code.
+ [[GitHub #350]](https://github.com/ruby/openssl/pull/350)
+* Fix crash with `OpenSSL::BN.new(nil, 2)`.
+ [[Bug #15760]](https://bugs.ruby-lang.org/issues/15760)
+* `OpenSSL::SSL::SSLSocket#sys{read,write}` prevent internal string buffers from
+ being modified by another thread.
+ [[GitHub #453]](https://github.com/ruby/openssl/pull/453)
+* Fix misuse of input record separator in `OpenSSL::Buffering` where it was
+ for output.
+* Fix wrong integer casting in `OpenSSL::PKey::EC#dsa_verify_asn1`.
+ [[GitHub #460]](https://github.com/ruby/openssl/pull/460)
+* `extconf.rb` explicitly checks that OpenSSL's version number is 1.0.1 or
+ newer but also less than 3.0. Ruby/OpenSSL v2.1.x and v2.2.x will not support
+ OpenSSL 3.0 API.
+ [[GitHub #458]](https://github.com/ruby/openssl/pull/458)
+* Activate `digest` gem correctly. `digest` library could go into an
+ inconsistent state if there are multiple versions of `digest` is installed
+ and `openssl` is `require`d before `digest`.
+ [[GitHub #463]](https://github.com/ruby/openssl/pull/463)
+* Fix GC.compact compatibility.
+ [[GitHub #464]](https://github.com/ruby/openssl/issues/464)
+ [[GitHub #465]](https://github.com/ruby/openssl/pull/465)
+
+
Version 2.1.2
=============
diff --git a/ext/openssl/depend b/ext/openssl/depend
index df84de4d719..742c8bbd195 100644
--- a/ext/openssl/depend
+++ b/ext/openssl/depend
@@ -11,7 +11,6 @@ ossl.o: $(hdrdir)/ruby/backward.h
ossl.o: $(hdrdir)/ruby/backward/2/assume.h
ossl.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl.o: $(hdrdir)/ruby/backward/2/limits.h
ossl.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -89,6 +88,15 @@ ossl.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl.o: $(hdrdir)/ruby/internal/ctype.h
ossl.o: $(hdrdir)/ruby/internal/dllexport.h
ossl.o: $(hdrdir)/ruby/internal/dosish.h
+ossl.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl.o: $(hdrdir)/ruby/internal/error.h
ossl.o: $(hdrdir)/ruby/internal/eval.h
ossl.o: $(hdrdir)/ruby/internal/event.h
@@ -167,7 +175,6 @@ ossl.o: $(hdrdir)/ruby/ruby.h
ossl.o: $(hdrdir)/ruby/st.h
ossl.o: $(hdrdir)/ruby/subst.h
ossl.o: $(hdrdir)/ruby/thread.h
-ossl.o: $(hdrdir)/ruby/thread_native.h
ossl.o: openssl_missing.h
ossl.o: ossl.c
ossl.o: ossl.h
@@ -189,7 +196,6 @@ ossl.o: ossl_rand.h
ossl.o: ossl_ssl.h
ossl.o: ossl_ts.h
ossl.o: ossl_x509.h
-ossl.o: ruby_missing.h
ossl_asn1.o: $(RUBY_EXTCONF_H)
ossl_asn1.o: $(arch_hdrdir)/ruby/config.h
ossl_asn1.o: $(hdrdir)/ruby.h
@@ -198,7 +204,6 @@ ossl_asn1.o: $(hdrdir)/ruby/backward.h
ossl_asn1.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_asn1.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_asn1.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_asn1.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_asn1.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_asn1.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_asn1.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -276,6 +281,15 @@ ossl_asn1.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_asn1.o: $(hdrdir)/ruby/internal/ctype.h
ossl_asn1.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_asn1.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_asn1.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_asn1.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_asn1.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_asn1.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_asn1.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_asn1.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_asn1.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_asn1.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_asn1.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_asn1.o: $(hdrdir)/ruby/internal/error.h
ossl_asn1.o: $(hdrdir)/ruby/internal/eval.h
ossl_asn1.o: $(hdrdir)/ruby/internal/event.h
@@ -375,7 +389,6 @@ ossl_asn1.o: ossl_rand.h
ossl_asn1.o: ossl_ssl.h
ossl_asn1.o: ossl_ts.h
ossl_asn1.o: ossl_x509.h
-ossl_asn1.o: ruby_missing.h
ossl_bio.o: $(RUBY_EXTCONF_H)
ossl_bio.o: $(arch_hdrdir)/ruby/config.h
ossl_bio.o: $(hdrdir)/ruby.h
@@ -384,7 +397,6 @@ ossl_bio.o: $(hdrdir)/ruby/backward.h
ossl_bio.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_bio.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_bio.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_bio.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_bio.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_bio.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_bio.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -462,6 +474,15 @@ ossl_bio.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_bio.o: $(hdrdir)/ruby/internal/ctype.h
ossl_bio.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_bio.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_bio.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_bio.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_bio.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_bio.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_bio.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_bio.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_bio.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_bio.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_bio.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_bio.o: $(hdrdir)/ruby/internal/error.h
ossl_bio.o: $(hdrdir)/ruby/internal/eval.h
ossl_bio.o: $(hdrdir)/ruby/internal/event.h
@@ -561,7 +582,6 @@ ossl_bio.o: ossl_rand.h
ossl_bio.o: ossl_ssl.h
ossl_bio.o: ossl_ts.h
ossl_bio.o: ossl_x509.h
-ossl_bio.o: ruby_missing.h
ossl_bn.o: $(RUBY_EXTCONF_H)
ossl_bn.o: $(arch_hdrdir)/ruby/config.h
ossl_bn.o: $(hdrdir)/ruby.h
@@ -570,7 +590,6 @@ ossl_bn.o: $(hdrdir)/ruby/backward.h
ossl_bn.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_bn.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_bn.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_bn.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_bn.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_bn.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_bn.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -648,6 +667,15 @@ ossl_bn.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_bn.o: $(hdrdir)/ruby/internal/ctype.h
ossl_bn.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_bn.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_bn.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_bn.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_bn.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_bn.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_bn.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_bn.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_bn.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_bn.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_bn.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_bn.o: $(hdrdir)/ruby/internal/error.h
ossl_bn.o: $(hdrdir)/ruby/internal/eval.h
ossl_bn.o: $(hdrdir)/ruby/internal/event.h
@@ -748,7 +776,6 @@ ossl_bn.o: ossl_rand.h
ossl_bn.o: ossl_ssl.h
ossl_bn.o: ossl_ts.h
ossl_bn.o: ossl_x509.h
-ossl_bn.o: ruby_missing.h
ossl_cipher.o: $(RUBY_EXTCONF_H)
ossl_cipher.o: $(arch_hdrdir)/ruby/config.h
ossl_cipher.o: $(hdrdir)/ruby.h
@@ -757,7 +784,6 @@ ossl_cipher.o: $(hdrdir)/ruby/backward.h
ossl_cipher.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_cipher.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_cipher.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_cipher.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_cipher.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_cipher.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_cipher.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -835,6 +861,15 @@ ossl_cipher.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_cipher.o: $(hdrdir)/ruby/internal/ctype.h
ossl_cipher.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_cipher.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_cipher.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_cipher.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_cipher.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_cipher.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_cipher.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_cipher.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_cipher.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_cipher.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_cipher.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_cipher.o: $(hdrdir)/ruby/internal/error.h
ossl_cipher.o: $(hdrdir)/ruby/internal/eval.h
ossl_cipher.o: $(hdrdir)/ruby/internal/event.h
@@ -934,7 +969,6 @@ ossl_cipher.o: ossl_rand.h
ossl_cipher.o: ossl_ssl.h
ossl_cipher.o: ossl_ts.h
ossl_cipher.o: ossl_x509.h
-ossl_cipher.o: ruby_missing.h
ossl_config.o: $(RUBY_EXTCONF_H)
ossl_config.o: $(arch_hdrdir)/ruby/config.h
ossl_config.o: $(hdrdir)/ruby.h
@@ -943,7 +977,6 @@ ossl_config.o: $(hdrdir)/ruby/backward.h
ossl_config.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_config.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_config.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_config.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_config.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_config.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_config.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -1021,6 +1054,15 @@ ossl_config.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_config.o: $(hdrdir)/ruby/internal/ctype.h
ossl_config.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_config.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_config.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_config.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_config.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_config.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_config.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_config.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_config.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_config.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_config.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_config.o: $(hdrdir)/ruby/internal/error.h
ossl_config.o: $(hdrdir)/ruby/internal/eval.h
ossl_config.o: $(hdrdir)/ruby/internal/event.h
@@ -1120,7 +1162,6 @@ ossl_config.o: ossl_rand.h
ossl_config.o: ossl_ssl.h
ossl_config.o: ossl_ts.h
ossl_config.o: ossl_x509.h
-ossl_config.o: ruby_missing.h
ossl_digest.o: $(RUBY_EXTCONF_H)
ossl_digest.o: $(arch_hdrdir)/ruby/config.h
ossl_digest.o: $(hdrdir)/ruby.h
@@ -1129,7 +1170,6 @@ ossl_digest.o: $(hdrdir)/ruby/backward.h
ossl_digest.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_digest.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_digest.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_digest.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_digest.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_digest.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_digest.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -1207,6 +1247,15 @@ ossl_digest.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_digest.o: $(hdrdir)/ruby/internal/ctype.h
ossl_digest.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_digest.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_digest.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_digest.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_digest.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_digest.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_digest.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_digest.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_digest.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_digest.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_digest.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_digest.o: $(hdrdir)/ruby/internal/error.h
ossl_digest.o: $(hdrdir)/ruby/internal/eval.h
ossl_digest.o: $(hdrdir)/ruby/internal/event.h
@@ -1306,7 +1355,6 @@ ossl_digest.o: ossl_rand.h
ossl_digest.o: ossl_ssl.h
ossl_digest.o: ossl_ts.h
ossl_digest.o: ossl_x509.h
-ossl_digest.o: ruby_missing.h
ossl_engine.o: $(RUBY_EXTCONF_H)
ossl_engine.o: $(arch_hdrdir)/ruby/config.h
ossl_engine.o: $(hdrdir)/ruby.h
@@ -1315,7 +1363,6 @@ ossl_engine.o: $(hdrdir)/ruby/backward.h
ossl_engine.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_engine.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_engine.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_engine.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_engine.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_engine.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_engine.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -1393,6 +1440,15 @@ ossl_engine.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_engine.o: $(hdrdir)/ruby/internal/ctype.h
ossl_engine.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_engine.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_engine.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_engine.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_engine.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_engine.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_engine.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_engine.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_engine.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_engine.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_engine.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_engine.o: $(hdrdir)/ruby/internal/error.h
ossl_engine.o: $(hdrdir)/ruby/internal/eval.h
ossl_engine.o: $(hdrdir)/ruby/internal/event.h
@@ -1492,7 +1548,6 @@ ossl_engine.o: ossl_rand.h
ossl_engine.o: ossl_ssl.h
ossl_engine.o: ossl_ts.h
ossl_engine.o: ossl_x509.h
-ossl_engine.o: ruby_missing.h
ossl_hmac.o: $(RUBY_EXTCONF_H)
ossl_hmac.o: $(arch_hdrdir)/ruby/config.h
ossl_hmac.o: $(hdrdir)/ruby.h
@@ -1501,7 +1556,6 @@ ossl_hmac.o: $(hdrdir)/ruby/backward.h
ossl_hmac.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_hmac.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_hmac.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_hmac.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_hmac.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_hmac.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_hmac.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -1579,6 +1633,15 @@ ossl_hmac.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_hmac.o: $(hdrdir)/ruby/internal/ctype.h
ossl_hmac.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_hmac.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_hmac.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_hmac.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_hmac.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_hmac.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_hmac.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_hmac.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_hmac.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_hmac.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_hmac.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_hmac.o: $(hdrdir)/ruby/internal/error.h
ossl_hmac.o: $(hdrdir)/ruby/internal/eval.h
ossl_hmac.o: $(hdrdir)/ruby/internal/event.h
@@ -1678,7 +1741,6 @@ ossl_hmac.o: ossl_rand.h
ossl_hmac.o: ossl_ssl.h
ossl_hmac.o: ossl_ts.h
ossl_hmac.o: ossl_x509.h
-ossl_hmac.o: ruby_missing.h
ossl_kdf.o: $(RUBY_EXTCONF_H)
ossl_kdf.o: $(arch_hdrdir)/ruby/config.h
ossl_kdf.o: $(hdrdir)/ruby.h
@@ -1687,7 +1749,6 @@ ossl_kdf.o: $(hdrdir)/ruby/backward.h
ossl_kdf.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_kdf.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_kdf.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_kdf.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_kdf.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_kdf.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_kdf.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -1765,6 +1826,15 @@ ossl_kdf.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_kdf.o: $(hdrdir)/ruby/internal/ctype.h
ossl_kdf.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_kdf.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_kdf.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_kdf.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_kdf.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_kdf.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_kdf.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_kdf.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_kdf.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_kdf.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_kdf.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_kdf.o: $(hdrdir)/ruby/internal/error.h
ossl_kdf.o: $(hdrdir)/ruby/internal/eval.h
ossl_kdf.o: $(hdrdir)/ruby/internal/event.h
@@ -1864,7 +1934,6 @@ ossl_kdf.o: ossl_rand.h
ossl_kdf.o: ossl_ssl.h
ossl_kdf.o: ossl_ts.h
ossl_kdf.o: ossl_x509.h
-ossl_kdf.o: ruby_missing.h
ossl_ns_spki.o: $(RUBY_EXTCONF_H)
ossl_ns_spki.o: $(arch_hdrdir)/ruby/config.h
ossl_ns_spki.o: $(hdrdir)/ruby.h
@@ -1873,7 +1942,6 @@ ossl_ns_spki.o: $(hdrdir)/ruby/backward.h
ossl_ns_spki.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_ns_spki.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_ns_spki.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_ns_spki.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_ns_spki.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_ns_spki.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_ns_spki.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -1951,6 +2019,15 @@ ossl_ns_spki.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_ns_spki.o: $(hdrdir)/ruby/internal/ctype.h
ossl_ns_spki.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_ns_spki.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_ns_spki.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_ns_spki.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_ns_spki.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_ns_spki.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_ns_spki.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_ns_spki.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_ns_spki.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_ns_spki.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_ns_spki.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_ns_spki.o: $(hdrdir)/ruby/internal/error.h
ossl_ns_spki.o: $(hdrdir)/ruby/internal/eval.h
ossl_ns_spki.o: $(hdrdir)/ruby/internal/event.h
@@ -2050,7 +2127,6 @@ ossl_ns_spki.o: ossl_rand.h
ossl_ns_spki.o: ossl_ssl.h
ossl_ns_spki.o: ossl_ts.h
ossl_ns_spki.o: ossl_x509.h
-ossl_ns_spki.o: ruby_missing.h
ossl_ocsp.o: $(RUBY_EXTCONF_H)
ossl_ocsp.o: $(arch_hdrdir)/ruby/config.h
ossl_ocsp.o: $(hdrdir)/ruby.h
@@ -2059,7 +2135,6 @@ ossl_ocsp.o: $(hdrdir)/ruby/backward.h
ossl_ocsp.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_ocsp.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_ocsp.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_ocsp.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_ocsp.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_ocsp.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_ocsp.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -2137,6 +2212,15 @@ ossl_ocsp.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_ocsp.o: $(hdrdir)/ruby/internal/ctype.h
ossl_ocsp.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_ocsp.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_ocsp.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_ocsp.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_ocsp.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_ocsp.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_ocsp.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_ocsp.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_ocsp.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_ocsp.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_ocsp.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_ocsp.o: $(hdrdir)/ruby/internal/error.h
ossl_ocsp.o: $(hdrdir)/ruby/internal/eval.h
ossl_ocsp.o: $(hdrdir)/ruby/internal/event.h
@@ -2236,7 +2320,6 @@ ossl_ocsp.o: ossl_rand.h
ossl_ocsp.o: ossl_ssl.h
ossl_ocsp.o: ossl_ts.h
ossl_ocsp.o: ossl_x509.h
-ossl_ocsp.o: ruby_missing.h
ossl_pkcs12.o: $(RUBY_EXTCONF_H)
ossl_pkcs12.o: $(arch_hdrdir)/ruby/config.h
ossl_pkcs12.o: $(hdrdir)/ruby.h
@@ -2245,7 +2328,6 @@ ossl_pkcs12.o: $(hdrdir)/ruby/backward.h
ossl_pkcs12.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_pkcs12.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_pkcs12.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_pkcs12.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_pkcs12.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_pkcs12.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_pkcs12.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -2323,6 +2405,15 @@ ossl_pkcs12.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_pkcs12.o: $(hdrdir)/ruby/internal/ctype.h
ossl_pkcs12.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_pkcs12.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_pkcs12.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_pkcs12.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_pkcs12.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_pkcs12.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_pkcs12.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_pkcs12.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_pkcs12.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_pkcs12.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_pkcs12.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_pkcs12.o: $(hdrdir)/ruby/internal/error.h
ossl_pkcs12.o: $(hdrdir)/ruby/internal/eval.h
ossl_pkcs12.o: $(hdrdir)/ruby/internal/event.h
@@ -2422,7 +2513,6 @@ ossl_pkcs12.o: ossl_rand.h
ossl_pkcs12.o: ossl_ssl.h
ossl_pkcs12.o: ossl_ts.h
ossl_pkcs12.o: ossl_x509.h
-ossl_pkcs12.o: ruby_missing.h
ossl_pkcs7.o: $(RUBY_EXTCONF_H)
ossl_pkcs7.o: $(arch_hdrdir)/ruby/config.h
ossl_pkcs7.o: $(hdrdir)/ruby.h
@@ -2431,7 +2521,6 @@ ossl_pkcs7.o: $(hdrdir)/ruby/backward.h
ossl_pkcs7.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_pkcs7.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_pkcs7.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_pkcs7.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_pkcs7.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_pkcs7.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_pkcs7.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -2509,6 +2598,15 @@ ossl_pkcs7.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_pkcs7.o: $(hdrdir)/ruby/internal/ctype.h
ossl_pkcs7.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_pkcs7.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_pkcs7.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_pkcs7.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_pkcs7.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_pkcs7.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_pkcs7.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_pkcs7.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_pkcs7.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_pkcs7.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_pkcs7.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_pkcs7.o: $(hdrdir)/ruby/internal/error.h
ossl_pkcs7.o: $(hdrdir)/ruby/internal/eval.h
ossl_pkcs7.o: $(hdrdir)/ruby/internal/event.h
@@ -2608,7 +2706,6 @@ ossl_pkcs7.o: ossl_rand.h
ossl_pkcs7.o: ossl_ssl.h
ossl_pkcs7.o: ossl_ts.h
ossl_pkcs7.o: ossl_x509.h
-ossl_pkcs7.o: ruby_missing.h
ossl_pkey.o: $(RUBY_EXTCONF_H)
ossl_pkey.o: $(arch_hdrdir)/ruby/config.h
ossl_pkey.o: $(hdrdir)/ruby.h
@@ -2617,7 +2714,6 @@ ossl_pkey.o: $(hdrdir)/ruby/backward.h
ossl_pkey.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_pkey.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_pkey.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_pkey.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_pkey.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_pkey.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_pkey.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -2695,6 +2791,15 @@ ossl_pkey.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_pkey.o: $(hdrdir)/ruby/internal/ctype.h
ossl_pkey.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_pkey.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_pkey.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_pkey.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_pkey.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_pkey.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_pkey.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_pkey.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_pkey.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_pkey.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_pkey.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_pkey.o: $(hdrdir)/ruby/internal/error.h
ossl_pkey.o: $(hdrdir)/ruby/internal/eval.h
ossl_pkey.o: $(hdrdir)/ruby/internal/event.h
@@ -2794,7 +2899,6 @@ ossl_pkey.o: ossl_rand.h
ossl_pkey.o: ossl_ssl.h
ossl_pkey.o: ossl_ts.h
ossl_pkey.o: ossl_x509.h
-ossl_pkey.o: ruby_missing.h
ossl_pkey_dh.o: $(RUBY_EXTCONF_H)
ossl_pkey_dh.o: $(arch_hdrdir)/ruby/config.h
ossl_pkey_dh.o: $(hdrdir)/ruby.h
@@ -2803,7 +2907,6 @@ ossl_pkey_dh.o: $(hdrdir)/ruby/backward.h
ossl_pkey_dh.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_pkey_dh.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_pkey_dh.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_pkey_dh.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_pkey_dh.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_pkey_dh.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_pkey_dh.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -2881,6 +2984,15 @@ ossl_pkey_dh.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_pkey_dh.o: $(hdrdir)/ruby/internal/ctype.h
ossl_pkey_dh.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_pkey_dh.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_pkey_dh.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_pkey_dh.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_pkey_dh.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_pkey_dh.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_pkey_dh.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_pkey_dh.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_pkey_dh.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_pkey_dh.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_pkey_dh.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_pkey_dh.o: $(hdrdir)/ruby/internal/error.h
ossl_pkey_dh.o: $(hdrdir)/ruby/internal/eval.h
ossl_pkey_dh.o: $(hdrdir)/ruby/internal/event.h
@@ -2980,7 +3092,6 @@ ossl_pkey_dh.o: ossl_rand.h
ossl_pkey_dh.o: ossl_ssl.h
ossl_pkey_dh.o: ossl_ts.h
ossl_pkey_dh.o: ossl_x509.h
-ossl_pkey_dh.o: ruby_missing.h
ossl_pkey_dsa.o: $(RUBY_EXTCONF_H)
ossl_pkey_dsa.o: $(arch_hdrdir)/ruby/config.h
ossl_pkey_dsa.o: $(hdrdir)/ruby.h
@@ -2989,7 +3100,6 @@ ossl_pkey_dsa.o: $(hdrdir)/ruby/backward.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_pkey_dsa.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -3067,6 +3177,15 @@ ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/ctype.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/error.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/eval.h
ossl_pkey_dsa.o: $(hdrdir)/ruby/internal/event.h
@@ -3166,7 +3285,6 @@ ossl_pkey_dsa.o: ossl_rand.h
ossl_pkey_dsa.o: ossl_ssl.h
ossl_pkey_dsa.o: ossl_ts.h
ossl_pkey_dsa.o: ossl_x509.h
-ossl_pkey_dsa.o: ruby_missing.h
ossl_pkey_ec.o: $(RUBY_EXTCONF_H)
ossl_pkey_ec.o: $(arch_hdrdir)/ruby/config.h
ossl_pkey_ec.o: $(hdrdir)/ruby.h
@@ -3175,7 +3293,6 @@ ossl_pkey_ec.o: $(hdrdir)/ruby/backward.h
ossl_pkey_ec.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_pkey_ec.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_pkey_ec.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_pkey_ec.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_pkey_ec.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_pkey_ec.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_pkey_ec.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -3253,6 +3370,15 @@ ossl_pkey_ec.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_pkey_ec.o: $(hdrdir)/ruby/internal/ctype.h
ossl_pkey_ec.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_pkey_ec.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_pkey_ec.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_pkey_ec.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_pkey_ec.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_pkey_ec.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_pkey_ec.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_pkey_ec.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_pkey_ec.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_pkey_ec.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_pkey_ec.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_pkey_ec.o: $(hdrdir)/ruby/internal/error.h
ossl_pkey_ec.o: $(hdrdir)/ruby/internal/eval.h
ossl_pkey_ec.o: $(hdrdir)/ruby/internal/event.h
@@ -3352,7 +3478,6 @@ ossl_pkey_ec.o: ossl_rand.h
ossl_pkey_ec.o: ossl_ssl.h
ossl_pkey_ec.o: ossl_ts.h
ossl_pkey_ec.o: ossl_x509.h
-ossl_pkey_ec.o: ruby_missing.h
ossl_pkey_rsa.o: $(RUBY_EXTCONF_H)
ossl_pkey_rsa.o: $(arch_hdrdir)/ruby/config.h
ossl_pkey_rsa.o: $(hdrdir)/ruby.h
@@ -3361,7 +3486,6 @@ ossl_pkey_rsa.o: $(hdrdir)/ruby/backward.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_pkey_rsa.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -3439,6 +3563,15 @@ ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/ctype.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/error.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/eval.h
ossl_pkey_rsa.o: $(hdrdir)/ruby/internal/event.h
@@ -3538,7 +3671,6 @@ ossl_pkey_rsa.o: ossl_rand.h
ossl_pkey_rsa.o: ossl_ssl.h
ossl_pkey_rsa.o: ossl_ts.h
ossl_pkey_rsa.o: ossl_x509.h
-ossl_pkey_rsa.o: ruby_missing.h
ossl_rand.o: $(RUBY_EXTCONF_H)
ossl_rand.o: $(arch_hdrdir)/ruby/config.h
ossl_rand.o: $(hdrdir)/ruby.h
@@ -3547,7 +3679,6 @@ ossl_rand.o: $(hdrdir)/ruby/backward.h
ossl_rand.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_rand.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_rand.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_rand.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_rand.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_rand.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_rand.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -3625,6 +3756,15 @@ ossl_rand.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_rand.o: $(hdrdir)/ruby/internal/ctype.h
ossl_rand.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_rand.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_rand.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_rand.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_rand.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_rand.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_rand.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_rand.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_rand.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_rand.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_rand.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_rand.o: $(hdrdir)/ruby/internal/error.h
ossl_rand.o: $(hdrdir)/ruby/internal/eval.h
ossl_rand.o: $(hdrdir)/ruby/internal/event.h
@@ -3724,7 +3864,6 @@ ossl_rand.o: ossl_rand.h
ossl_rand.o: ossl_ssl.h
ossl_rand.o: ossl_ts.h
ossl_rand.o: ossl_x509.h
-ossl_rand.o: ruby_missing.h
ossl_ssl.o: $(RUBY_EXTCONF_H)
ossl_ssl.o: $(arch_hdrdir)/ruby/config.h
ossl_ssl.o: $(hdrdir)/ruby.h
@@ -3733,7 +3872,6 @@ ossl_ssl.o: $(hdrdir)/ruby/backward.h
ossl_ssl.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_ssl.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_ssl.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_ssl.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_ssl.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_ssl.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_ssl.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -3811,6 +3949,15 @@ ossl_ssl.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_ssl.o: $(hdrdir)/ruby/internal/ctype.h
ossl_ssl.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_ssl.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_ssl.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_ssl.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_ssl.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_ssl.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_ssl.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_ssl.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_ssl.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_ssl.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_ssl.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_ssl.o: $(hdrdir)/ruby/internal/error.h
ossl_ssl.o: $(hdrdir)/ruby/internal/eval.h
ossl_ssl.o: $(hdrdir)/ruby/internal/event.h
@@ -3910,7 +4057,6 @@ ossl_ssl.o: ossl_ssl.c
ossl_ssl.o: ossl_ssl.h
ossl_ssl.o: ossl_ts.h
ossl_ssl.o: ossl_x509.h
-ossl_ssl.o: ruby_missing.h
ossl_ssl_session.o: $(RUBY_EXTCONF_H)
ossl_ssl_session.o: $(arch_hdrdir)/ruby/config.h
ossl_ssl_session.o: $(hdrdir)/ruby.h
@@ -3919,7 +4065,6 @@ ossl_ssl_session.o: $(hdrdir)/ruby/backward.h
ossl_ssl_session.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_ssl_session.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_ssl_session.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_ssl_session.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_ssl_session.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_ssl_session.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_ssl_session.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -3997,6 +4142,15 @@ ossl_ssl_session.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_ssl_session.o: $(hdrdir)/ruby/internal/ctype.h
ossl_ssl_session.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_ssl_session.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_ssl_session.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_ssl_session.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_ssl_session.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_ssl_session.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_ssl_session.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_ssl_session.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_ssl_session.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_ssl_session.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_ssl_session.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_ssl_session.o: $(hdrdir)/ruby/internal/error.h
ossl_ssl_session.o: $(hdrdir)/ruby/internal/eval.h
ossl_ssl_session.o: $(hdrdir)/ruby/internal/event.h
@@ -4096,7 +4250,6 @@ ossl_ssl_session.o: ossl_ssl.h
ossl_ssl_session.o: ossl_ssl_session.c
ossl_ssl_session.o: ossl_ts.h
ossl_ssl_session.o: ossl_x509.h
-ossl_ssl_session.o: ruby_missing.h
ossl_ts.o: $(RUBY_EXTCONF_H)
ossl_ts.o: $(arch_hdrdir)/ruby/config.h
ossl_ts.o: $(hdrdir)/ruby.h
@@ -4105,7 +4258,6 @@ ossl_ts.o: $(hdrdir)/ruby/backward.h
ossl_ts.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_ts.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_ts.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_ts.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_ts.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_ts.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_ts.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -4183,6 +4335,15 @@ ossl_ts.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_ts.o: $(hdrdir)/ruby/internal/ctype.h
ossl_ts.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_ts.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_ts.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_ts.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_ts.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_ts.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_ts.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_ts.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_ts.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_ts.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_ts.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_ts.o: $(hdrdir)/ruby/internal/error.h
ossl_ts.o: $(hdrdir)/ruby/internal/eval.h
ossl_ts.o: $(hdrdir)/ruby/internal/event.h
@@ -4282,7 +4443,6 @@ ossl_ts.o: ossl_ssl.h
ossl_ts.o: ossl_ts.c
ossl_ts.o: ossl_ts.h
ossl_ts.o: ossl_x509.h
-ossl_ts.o: ruby_missing.h
ossl_x509.o: $(RUBY_EXTCONF_H)
ossl_x509.o: $(arch_hdrdir)/ruby/config.h
ossl_x509.o: $(hdrdir)/ruby.h
@@ -4291,7 +4451,6 @@ ossl_x509.o: $(hdrdir)/ruby/backward.h
ossl_x509.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_x509.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_x509.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_x509.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_x509.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_x509.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_x509.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -4369,6 +4528,15 @@ ossl_x509.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_x509.o: $(hdrdir)/ruby/internal/ctype.h
ossl_x509.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_x509.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_x509.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_x509.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_x509.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_x509.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_x509.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_x509.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_x509.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_x509.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_x509.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_x509.o: $(hdrdir)/ruby/internal/error.h
ossl_x509.o: $(hdrdir)/ruby/internal/eval.h
ossl_x509.o: $(hdrdir)/ruby/internal/event.h
@@ -4468,7 +4636,6 @@ ossl_x509.o: ossl_ssl.h
ossl_x509.o: ossl_ts.h
ossl_x509.o: ossl_x509.c
ossl_x509.o: ossl_x509.h
-ossl_x509.o: ruby_missing.h
ossl_x509attr.o: $(RUBY_EXTCONF_H)
ossl_x509attr.o: $(arch_hdrdir)/ruby/config.h
ossl_x509attr.o: $(hdrdir)/ruby.h
@@ -4477,7 +4644,6 @@ ossl_x509attr.o: $(hdrdir)/ruby/backward.h
ossl_x509attr.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_x509attr.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_x509attr.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_x509attr.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_x509attr.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_x509attr.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_x509attr.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -4555,6 +4721,15 @@ ossl_x509attr.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_x509attr.o: $(hdrdir)/ruby/internal/ctype.h
ossl_x509attr.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_x509attr.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_x509attr.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_x509attr.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_x509attr.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_x509attr.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_x509attr.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_x509attr.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_x509attr.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_x509attr.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_x509attr.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_x509attr.o: $(hdrdir)/ruby/internal/error.h
ossl_x509attr.o: $(hdrdir)/ruby/internal/eval.h
ossl_x509attr.o: $(hdrdir)/ruby/internal/event.h
@@ -4654,7 +4829,6 @@ ossl_x509attr.o: ossl_ssl.h
ossl_x509attr.o: ossl_ts.h
ossl_x509attr.o: ossl_x509.h
ossl_x509attr.o: ossl_x509attr.c
-ossl_x509attr.o: ruby_missing.h
ossl_x509cert.o: $(RUBY_EXTCONF_H)
ossl_x509cert.o: $(arch_hdrdir)/ruby/config.h
ossl_x509cert.o: $(hdrdir)/ruby.h
@@ -4663,7 +4837,6 @@ ossl_x509cert.o: $(hdrdir)/ruby/backward.h
ossl_x509cert.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_x509cert.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_x509cert.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_x509cert.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_x509cert.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_x509cert.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_x509cert.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -4741,6 +4914,15 @@ ossl_x509cert.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_x509cert.o: $(hdrdir)/ruby/internal/ctype.h
ossl_x509cert.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_x509cert.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_x509cert.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_x509cert.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_x509cert.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_x509cert.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_x509cert.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_x509cert.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_x509cert.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_x509cert.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_x509cert.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_x509cert.o: $(hdrdir)/ruby/internal/error.h
ossl_x509cert.o: $(hdrdir)/ruby/internal/eval.h
ossl_x509cert.o: $(hdrdir)/ruby/internal/event.h
@@ -4840,7 +5022,6 @@ ossl_x509cert.o: ossl_ssl.h
ossl_x509cert.o: ossl_ts.h
ossl_x509cert.o: ossl_x509.h
ossl_x509cert.o: ossl_x509cert.c
-ossl_x509cert.o: ruby_missing.h
ossl_x509crl.o: $(RUBY_EXTCONF_H)
ossl_x509crl.o: $(arch_hdrdir)/ruby/config.h
ossl_x509crl.o: $(hdrdir)/ruby.h
@@ -4849,7 +5030,6 @@ ossl_x509crl.o: $(hdrdir)/ruby/backward.h
ossl_x509crl.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_x509crl.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_x509crl.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_x509crl.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_x509crl.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_x509crl.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_x509crl.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -4927,6 +5107,15 @@ ossl_x509crl.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_x509crl.o: $(hdrdir)/ruby/internal/ctype.h
ossl_x509crl.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_x509crl.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_x509crl.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_x509crl.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_x509crl.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_x509crl.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_x509crl.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_x509crl.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_x509crl.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_x509crl.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_x509crl.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_x509crl.o: $(hdrdir)/ruby/internal/error.h
ossl_x509crl.o: $(hdrdir)/ruby/internal/eval.h
ossl_x509crl.o: $(hdrdir)/ruby/internal/event.h
@@ -5026,7 +5215,6 @@ ossl_x509crl.o: ossl_ssl.h
ossl_x509crl.o: ossl_ts.h
ossl_x509crl.o: ossl_x509.h
ossl_x509crl.o: ossl_x509crl.c
-ossl_x509crl.o: ruby_missing.h
ossl_x509ext.o: $(RUBY_EXTCONF_H)
ossl_x509ext.o: $(arch_hdrdir)/ruby/config.h
ossl_x509ext.o: $(hdrdir)/ruby.h
@@ -5035,7 +5223,6 @@ ossl_x509ext.o: $(hdrdir)/ruby/backward.h
ossl_x509ext.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_x509ext.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_x509ext.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_x509ext.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_x509ext.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_x509ext.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_x509ext.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -5113,6 +5300,15 @@ ossl_x509ext.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_x509ext.o: $(hdrdir)/ruby/internal/ctype.h
ossl_x509ext.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_x509ext.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_x509ext.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_x509ext.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_x509ext.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_x509ext.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_x509ext.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_x509ext.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_x509ext.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_x509ext.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_x509ext.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_x509ext.o: $(hdrdir)/ruby/internal/error.h
ossl_x509ext.o: $(hdrdir)/ruby/internal/eval.h
ossl_x509ext.o: $(hdrdir)/ruby/internal/event.h
@@ -5212,7 +5408,6 @@ ossl_x509ext.o: ossl_ssl.h
ossl_x509ext.o: ossl_ts.h
ossl_x509ext.o: ossl_x509.h
ossl_x509ext.o: ossl_x509ext.c
-ossl_x509ext.o: ruby_missing.h
ossl_x509name.o: $(RUBY_EXTCONF_H)
ossl_x509name.o: $(arch_hdrdir)/ruby/config.h
ossl_x509name.o: $(hdrdir)/ruby.h
@@ -5221,7 +5416,6 @@ ossl_x509name.o: $(hdrdir)/ruby/backward.h
ossl_x509name.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_x509name.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_x509name.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_x509name.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_x509name.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_x509name.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_x509name.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -5299,6 +5493,15 @@ ossl_x509name.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_x509name.o: $(hdrdir)/ruby/internal/ctype.h
ossl_x509name.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_x509name.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_x509name.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_x509name.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_x509name.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_x509name.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_x509name.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_x509name.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_x509name.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_x509name.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_x509name.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_x509name.o: $(hdrdir)/ruby/internal/error.h
ossl_x509name.o: $(hdrdir)/ruby/internal/eval.h
ossl_x509name.o: $(hdrdir)/ruby/internal/event.h
@@ -5398,7 +5601,6 @@ ossl_x509name.o: ossl_ssl.h
ossl_x509name.o: ossl_ts.h
ossl_x509name.o: ossl_x509.h
ossl_x509name.o: ossl_x509name.c
-ossl_x509name.o: ruby_missing.h
ossl_x509req.o: $(RUBY_EXTCONF_H)
ossl_x509req.o: $(arch_hdrdir)/ruby/config.h
ossl_x509req.o: $(hdrdir)/ruby.h
@@ -5407,7 +5609,6 @@ ossl_x509req.o: $(hdrdir)/ruby/backward.h
ossl_x509req.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_x509req.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_x509req.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_x509req.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_x509req.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_x509req.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_x509req.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -5485,6 +5686,15 @@ ossl_x509req.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_x509req.o: $(hdrdir)/ruby/internal/ctype.h
ossl_x509req.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_x509req.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_x509req.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_x509req.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_x509req.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_x509req.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_x509req.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_x509req.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_x509req.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_x509req.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_x509req.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_x509req.o: $(hdrdir)/ruby/internal/error.h
ossl_x509req.o: $(hdrdir)/ruby/internal/eval.h
ossl_x509req.o: $(hdrdir)/ruby/internal/event.h
@@ -5584,7 +5794,6 @@ ossl_x509req.o: ossl_ssl.h
ossl_x509req.o: ossl_ts.h
ossl_x509req.o: ossl_x509.h
ossl_x509req.o: ossl_x509req.c
-ossl_x509req.o: ruby_missing.h
ossl_x509revoked.o: $(RUBY_EXTCONF_H)
ossl_x509revoked.o: $(arch_hdrdir)/ruby/config.h
ossl_x509revoked.o: $(hdrdir)/ruby.h
@@ -5593,7 +5802,6 @@ ossl_x509revoked.o: $(hdrdir)/ruby/backward.h
ossl_x509revoked.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_x509revoked.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_x509revoked.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_x509revoked.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_x509revoked.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_x509revoked.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_x509revoked.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -5671,6 +5879,15 @@ ossl_x509revoked.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_x509revoked.o: $(hdrdir)/ruby/internal/ctype.h
ossl_x509revoked.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_x509revoked.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_x509revoked.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_x509revoked.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_x509revoked.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_x509revoked.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_x509revoked.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_x509revoked.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_x509revoked.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_x509revoked.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_x509revoked.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_x509revoked.o: $(hdrdir)/ruby/internal/error.h
ossl_x509revoked.o: $(hdrdir)/ruby/internal/eval.h
ossl_x509revoked.o: $(hdrdir)/ruby/internal/event.h
@@ -5770,7 +5987,6 @@ ossl_x509revoked.o: ossl_ssl.h
ossl_x509revoked.o: ossl_ts.h
ossl_x509revoked.o: ossl_x509.h
ossl_x509revoked.o: ossl_x509revoked.c
-ossl_x509revoked.o: ruby_missing.h
ossl_x509store.o: $(RUBY_EXTCONF_H)
ossl_x509store.o: $(arch_hdrdir)/ruby/config.h
ossl_x509store.o: $(hdrdir)/ruby.h
@@ -5779,7 +5995,6 @@ ossl_x509store.o: $(hdrdir)/ruby/backward.h
ossl_x509store.o: $(hdrdir)/ruby/backward/2/assume.h
ossl_x509store.o: $(hdrdir)/ruby/backward/2/attributes.h
ossl_x509store.o: $(hdrdir)/ruby/backward/2/bool.h
-ossl_x509store.o: $(hdrdir)/ruby/backward/2/gcc_version_since.h
ossl_x509store.o: $(hdrdir)/ruby/backward/2/inttypes.h
ossl_x509store.o: $(hdrdir)/ruby/backward/2/limits.h
ossl_x509store.o: $(hdrdir)/ruby/backward/2/long_long.h
@@ -5857,6 +6072,15 @@ ossl_x509store.o: $(hdrdir)/ruby/internal/core/rtypeddata.h
ossl_x509store.o: $(hdrdir)/ruby/internal/ctype.h
ossl_x509store.o: $(hdrdir)/ruby/internal/dllexport.h
ossl_x509store.o: $(hdrdir)/ruby/internal/dosish.h
+ossl_x509store.o: $(hdrdir)/ruby/internal/encoding/coderange.h
+ossl_x509store.o: $(hdrdir)/ruby/internal/encoding/ctype.h
+ossl_x509store.o: $(hdrdir)/ruby/internal/encoding/encoding.h
+ossl_x509store.o: $(hdrdir)/ruby/internal/encoding/pathname.h
+ossl_x509store.o: $(hdrdir)/ruby/internal/encoding/re.h
+ossl_x509store.o: $(hdrdir)/ruby/internal/encoding/sprintf.h
+ossl_x509store.o: $(hdrdir)/ruby/internal/encoding/string.h
+ossl_x509store.o: $(hdrdir)/ruby/internal/encoding/symbol.h
+ossl_x509store.o: $(hdrdir)/ruby/internal/encoding/transcode.h
ossl_x509store.o: $(hdrdir)/ruby/internal/error.h
ossl_x509store.o: $(hdrdir)/ruby/internal/eval.h
ossl_x509store.o: $(hdrdir)/ruby/internal/event.h
@@ -5956,5 +6180,4 @@ ossl_x509store.o: ossl_ssl.h
ossl_x509store.o: ossl_ts.h
ossl_x509store.o: ossl_x509.h
ossl_x509store.o: ossl_x509store.c
-ossl_x509store.o: ruby_missing.h
# AUTOGENERATED DEPENDENCIES END
diff --git a/ext/openssl/extconf.rb b/ext/openssl/extconf.rb
index aa4eae824c7..1d38b569904 100644
--- a/ext/openssl/extconf.rb
+++ b/ext/openssl/extconf.rb
@@ -160,7 +160,7 @@ have_func("SSL_SESSION_get_protocol_version")
have_func("TS_STATUS_INFO_get0_status")
have_func("TS_STATUS_INFO_get0_text")
have_func("TS_STATUS_INFO_get0_failure_info")
-have_func("TS_VERIFY_CTS_set_certs")
+have_func("TS_VERIFY_CTS_set_certs(NULL, NULL)", "openssl/ts.h")
have_func("TS_VERIFY_CTX_set_store")
have_func("TS_VERIFY_CTX_add_flags")
have_func("TS_RESP_CTX_set_time_cb")
@@ -170,6 +170,16 @@ have_func("SSL_CTX_set_post_handshake_auth")
# added in 1.1.1
have_func("EVP_PKEY_check")
+# added in 3.0.0
+have_func("SSL_set0_tmp_dh_pkey")
+have_func("ERR_get_error_all")
+have_func("TS_VERIFY_CTX_set_certs(NULL, NULL)", "openssl/ts.h")
+have_func("SSL_CTX_load_verify_file")
+have_func("BN_check_prime")
+have_func("EVP_MD_CTX_get0_md")
+have_func("EVP_MD_CTX_get_pkey_ctx")
+have_func("EVP_PKEY_eq")
+
Logging::message "=== Checking done. ===\n"
create_header
diff --git a/ext/openssl/lib/openssl/buffering.rb b/ext/openssl/lib/openssl/buffering.rb
index 116179d21ff..d47e1082efd 100644
--- a/ext/openssl/lib/openssl/buffering.rb
+++ b/ext/openssl/lib/openssl/buffering.rb
@@ -99,16 +99,6 @@ module OpenSSL::Buffering
end
end
- if "".respond_to?(:unpack1)
- def unpack_byte(str)
- str.unpack1("C")
- end
- else
- def unpack_byte(str)
- str.unpack("C").first
- end
- end
-
public
# call-seq:
@@ -117,7 +107,7 @@ module OpenSSL::Buffering
# Get the next 8bit byte from `ssl`. Returns `nil` on EOF
def getbyte
byte = read(1)
- byte && unpack_byte(byte)
+ byte && byte.unpack1("C")
end
##
diff --git a/ext/openssl/lib/openssl/ssl.rb b/ext/openssl/lib/openssl/ssl.rb
index 0930a530174..a9103ecd278 100644
--- a/ext/openssl/lib/openssl/ssl.rb
+++ b/ext/openssl/lib/openssl/ssl.rb
@@ -91,15 +91,17 @@ YoaOffgTf5qxiwkjnlVZQc3whgnEt9FpVMvQ9eknyeGB5KHfayAc3+hUAvI3/Cr3
DEFAULT_CERT_STORE.set_default_paths
DEFAULT_CERT_STORE.flags = OpenSSL::X509::V_FLAG_CRL_CHECK_ALL
- # A callback invoked when DH parameters are required.
+ # A callback invoked when DH parameters are required for ephemeral DH key
+ # exchange.
#
- # The callback is invoked with the Session for the key exchange, an
+ # The callback is invoked with the SSLSocket, a
# flag indicating the use of an export cipher and the keylength
# required.
#
# The callback must return an OpenSSL::PKey::DH instance of the correct
# key length.
-
+ #
+ # <b>Deprecated in version 3.0.</b> Use #tmp_dh= instead.
attr_accessor :tmp_dh_callback
# A callback invoked at connect time to distinguish between multiple
@@ -432,10 +434,6 @@ YoaOffgTf5qxiwkjnlVZQc3whgnEt9FpVMvQ9eknyeGB5KHfayAc3+hUAvI3/Cr3
@context.tmp_dh_callback || OpenSSL::SSL::SSLContext::DEFAULT_TMP_DH_CALLBACK
end
- def tmp_ecdh_callback
- @context.tmp_ecdh_callback
- end
-
def session_new_cb
@context.session_new_cb
end
diff --git a/ext/openssl/lib/openssl/version.rb b/ext/openssl/lib/openssl/version.rb
index 9c7515ba0f3..acd53d440d4 100644
--- a/ext/openssl/lib/openssl/version.rb
+++ b/ext/openssl/lib/openssl/version.rb
@@ -1,5 +1,5 @@
# frozen_string_literal: true
module OpenSSL
- VERSION = "2.2.0"
+ VERSION = "3.0.0.pre"
end
diff --git a/ext/openssl/lib/openssl/x509.rb b/ext/openssl/lib/openssl/x509.rb
index 448941f75e3..f973f4f4dc6 100644
--- a/ext/openssl/lib/openssl/x509.rb
+++ b/ext/openssl/lib/openssl/x509.rb
@@ -279,11 +279,29 @@ module OpenSSL
end
class << self
+ # Parses the UTF-8 string representation of a distinguished name,
+ # according to RFC 2253.
+ #
+ # See also #to_utf8 for the opposite operation.
def parse_rfc2253(str, template=OBJECT_TYPE_TEMPLATE)
ary = OpenSSL::X509::Name::RFC2253DN.scan(str)
self.new(ary, template)
end
+ # Parses the string representation of a distinguished name. Two
+ # different forms are supported:
+ #
+ # - \OpenSSL format (<tt>X509_NAME_oneline()</tt>) used by
+ # <tt>#to_s</tt>. For example: <tt>/DC=com/DC=example/CN=nobody</tt>
+ # - \OpenSSL format (<tt>X509_NAME_print()</tt>)
+ # used by <tt>#to_s(OpenSSL::X509::Name::COMPAT)</tt>. For example:
+ # <tt>DC=com, DC=example, CN=nobody</tt>
+ #
+ # Neither of them is standardized and has quirks and inconsistencies
+ # in handling of escaped characters or multi-valued RDNs.
+ #
+ # Use of this method is discouraged in new applications. See
+ # Name.parse_rfc2253 and #to_utf8 for the alternative.
def parse_openssl(str, template=OBJECT_TYPE_TEMPLATE)
if str.start_with?("/")
# /A=B/C=D format
diff --git a/ext/openssl/openssl.gemspec b/ext/openssl/openssl.gemspec
index f178e7025d6..38bcb9db5f5 100644
--- a/ext/openssl/openssl.gemspec
+++ b/ext/openssl/openssl.gemspec
@@ -1,6 +1,6 @@
Gem::Specification.new do |spec|
spec.name = "openssl"
- spec.version = "2.2.0"
+ spec.version = "3.0.0.pre"
spec.authors = ["Martin Bosslet", "SHIBATA Hiroshi", "Zachary Scott", "Kazuki Yamaguchi"]
spec.email = ["ruby-core@ruby-lang.org"]
spec.summary = %q{OpenSSL provides SSL, TLS and general purpose cryptography.}
@@ -15,7 +15,7 @@ Gem::Specification.new do |spec|
spec.extra_rdoc_files = Dir["*.md"]
spec.rdoc_options = ["--main", "README.md"]
- spec.required_ruby_version = ">= 2.3.0"
+ spec.required_ruby_version = ">= 2.6.0"
spec.metadata["msys2_mingw_dependencies"] = "openssl"
end
diff --git a/ext/openssl/openssl_missing.h b/ext/openssl/openssl_missing.h
index 4d9b8801387..8629bfe505c 100644
--- a/ext/openssl/openssl_missing.h
+++ b/ext/openssl/openssl_missing.h
@@ -21,10 +21,6 @@
# define EVP_MD_CTX_free EVP_MD_CTX_destroy
#endif
-#if !defined(HAVE_EVP_MD_CTX_PKEY_CTX)
-# define EVP_MD_CTX_pkey_ctx(x) (x)->pctx
-#endif
-
#if !defined(HAVE_X509_STORE_GET_EX_DATA)
# define X509_STORE_get_ex_data(x, idx) \
CRYPTO_get_ex_data(&(x)->ex_data, (idx))
@@ -214,4 +210,29 @@ IMPL_PKEY_GETTER(EC_KEY, ec)
} while (0)
#endif
+/* added in 3.0.0 */
+#if !defined(HAVE_TS_VERIFY_CTX_SET_CERTS)
+# define TS_VERIFY_CTX_set_certs(ctx, crts) TS_VERIFY_CTS_set_certs(ctx, crts)
+#endif
+
+#ifndef HAVE_EVP_MD_CTX_GET0_MD
+# define EVP_MD_CTX_get0_md(ctx) EVP_MD_CTX_md(ctx)
+#endif
+
+/*
+ * OpenSSL 1.1.0 added EVP_MD_CTX_pkey_ctx(), and then it was renamed to
+ * EVP_MD_CTX_get_pkey_ctx(x) in OpenSSL 3.0.
+ */
+#ifndef HAVE_EVP_MD_CTX_GET_PKEY_CTX
+# ifdef HAVE_EVP_MD_CTX_PKEY_CTX
+# define EVP_MD_CTX_get_pkey_ctx(x) EVP_MD_CTX_pkey_ctx(x)
+# else
+# define EVP_MD_CTX_get_pkey_ctx(x) (x)->pctx
+# endif
+#endif
+
+#ifndef HAVE_EVP_PKEY_EQ
+# define EVP_PKEY_eq(a, b) EVP_PKEY_cmp(a, b)
+#endif
+
#endif /* _OSSL_OPENSSL_MISSING_H_ */
diff --git a/ext/openssl/ossl.c b/ext/openssl/ossl.c
index c7a755ceda0..6c532aca949 100644
--- a/ext/openssl/ossl.c
+++ b/ext/openssl/ossl.c
@@ -313,27 +313,31 @@ void
ossl_clear_error(void)
{
if (dOSSL == Qtrue) {
- unsigned long e;
- const char *file, *data, *errstr;
- int line, flags;
-
- while ((e = ERR_get_error_line_data(&file, &line, &data, &flags))) {
- errstr = ERR_error_string(e, NULL);
- if (!errstr)
- errstr = "(null)";
-
- if (flags & ERR_TXT_STRING) {
- if (!data)
- data = "(null)";
- rb_warn("error on stack: %s (%s)", errstr, data);
- }
- else {
- rb_warn("error on stack: %s", errstr);
- }
- }
+ unsigned long e;
+ const char *file, *data, *func, *lib, *reason;
+ char append[256] = "";
+ int line, flags;
+
+#ifdef HAVE_ERR_GET_ERROR_ALL
+ while ((e = ERR_get_error_all(&file, &line, &func, &data, &flags))) {
+#else
+ while ((e = ERR_get_error_line_data(&file, &line, &data, &flags))) {
+ func = ERR_func_error_string(e);
+#endif
+ lib = ERR_lib_error_string(e);
+ reason = ERR_reason_error_string(e);
+
+ if (flags & ERR_TXT_STRING) {
+ if (!data)
+ data = "(null)";
+ snprintf(append, sizeof(append), " (%s)", data);
+ }
+ rb_warn("error on stack: error:%08lX:%s:%s:%s%s", e, lib ? lib : "",
+ func ? func : "", reason ? reason : "", append);
+ }
}
else {
- ERR_clear_error();
+ ERR_clear_error();
}
}
diff --git a/ext/openssl/ossl.h b/ext/openssl/ossl.h
index 65d022c7f31..3a0ab1e5935 100644
--- a/ext/openssl/ossl.h
+++ b/ext/openssl/ossl.h
@@ -42,6 +42,18 @@
#include <openssl/evp.h>
#include <openssl/dh.h>
+#ifndef LIBRESSL_VERSION_NUMBER
+# define OSSL_IS_LIBRESSL 0
+# define OSSL_OPENSSL_PREREQ(maj, min, pat) \
+ (OPENSSL_VERSION_NUMBER >= (maj << 28) | (min << 20) | (pat << 12))
+# define OSSL_LIBRESSL_PREREQ(maj, min, pat) 0
+#else
+# define OSSL_IS_LIBRESSL 1
+# define OSSL_OPENSSL_PREREQ(maj, min, pat) 0
+# define OSSL_LIBRESSL_PREREQ(maj, min, pat) \
+ (LIBRESSL_VERSION_NUMBER >= (maj << 28) | (min << 20) | (pat << 12))
+#endif
+
/*
* Common Module
*/
@@ -155,7 +167,6 @@ void ossl_debug(const char *, ...);
* Include all parts
*/
#include "openssl_missing.h"
-#include "ruby_missing.h"
#include "ossl_asn1.h"
#include "ossl_bio.h"
#include "ossl_bn.h"
diff --git a/ext/openssl/ossl_bn.c b/ext/openssl/ossl_bn.c
index 8d0f63a986f..56fa0ec3021 100644
--- a/ext/openssl/ossl_bn.c
+++ b/ext/openssl/ossl_bn.c
@@ -792,78 +792,64 @@ BIGNUM_SELF_SHIFT(lshift)
*/
BIGNUM_SELF_SHIFT(rshift)
-#define BIGNUM_RAND(func) \
- static VALUE \
- ossl_bn_s_##func(int argc, VALUE *argv, VALUE klass) \
- { \
- BIGNUM *result; \
- int bottom = 0, top = 0, b; \
- VALUE bits, fill, odd, obj; \
- \
- switch (rb_scan_args(argc, argv, "12", &bits, &fill, &odd)) { \
- case 3: \
- bottom = (odd == Qtrue) ? 1 : 0; \
- /* FALLTHROUGH */ \
- case 2: \
- top = NUM2INT(fill); \
- } \
- b = NUM2INT(bits); \
- obj = NewBN(klass); \
- if (!(result = BN_new())) { \
- ossl_raise(eBNError, NULL); \
- } \
- if (BN_##func(result, b, top, bottom) <= 0) { \
- BN_free(result); \
- ossl_raise(eBNError, NULL); \
- } \
- SetBN(obj, result); \
- return obj; \
- }
-
-/*
- * Document-method: OpenSSL::BN.rand
- * BN.rand(bits [, fill [, odd]]) -> aBN
- */
-BIGNUM_RAND(rand)
-
/*
- * Document-method: OpenSSL::BN.pseudo_rand
- * BN.pseudo_rand(bits [, fill [, odd]]) -> aBN
- */
-BIGNUM_RAND(pseudo_rand)
-
-#define BIGNUM_RAND_RANGE(func) \
- static VALUE \
- ossl_bn_s_##func##_range(VALUE klass, VALUE range) \
- { \
- BIGNUM *bn = GetBNPtr(range), *result; \
- VALUE obj = NewBN(klass); \
- if (!(result = BN_new())) { \
- ossl_raise(eBNError, NULL); \
- } \
- if (BN_##func##_range(result, bn) <= 0) { \
- BN_free(result); \
- ossl_raise(eBNError, NULL); \
- } \
- SetBN(obj, result); \
- return obj; \
- }
-
-/*
- * Document-method: OpenSSL::BN.rand_range
* call-seq:
- * BN.rand_range(range) -> aBN
+ * BN.rand(bits [, fill [, odd]]) -> aBN
+ *
+ * Generates a cryptographically strong pseudo-random number of +bits+.
*
+ * See also the man page BN_rand(3).
*/
-BIGNUM_RAND_RANGE(rand)
+static VALUE
+ossl_bn_s_rand(int argc, VALUE *argv, VALUE klass)
+{
+ BIGNUM *result;
+ int bottom = 0, top = 0, b;
+ VALUE bits, fill, odd, obj;
+
+ switch (rb_scan_args(argc, argv, "12", &bits, &fill, &odd)) {
+ case 3:
+ bottom = (odd == Qtrue) ? 1 : 0;
+ /* FALLTHROUGH */
+ case 2:
+ top = NUM2INT(fill);
+ }
+ b = NUM2INT(bits);
+ obj = NewBN(klass);
+ if (!(result = BN_new())) {
+ ossl_raise(eBNError, "BN_new");
+ }
+ if (BN_rand(result, b, top, bottom) <= 0) {
+ BN_free(result);
+ ossl_raise(eBNError, "BN_rand");
+ }
+ SetBN(obj, result);
+ return obj;
+}
/*
- * Document-method: OpenSSL::BN.pseudo_rand_range
* call-seq:
- * BN.pseudo_rand_range(range) -> aBN
+ * BN.rand_range(range) -> aBN
*
+ * Generates a cryptographically strong pseudo-random number in the range
+ * 0...+range+.
+ *
+ * See also the man page BN_rand_range(3).
*/
-BIGNUM_RAND_RANGE(pseudo_rand)
+static VALUE
+ossl_bn_s_rand_range(VALUE klass, VALUE range)
+{
+ BIGNUM *bn = GetBNPtr(range), *result;
+ VALUE obj = NewBN(klass);
+ if (!(result = BN_new()))
+ ossl_raise(eBNError, "BN_new");
+ if (BN_rand_range(result, bn) <= 0) {
+ BN_free(result);
+ ossl_raise(eBNError, "BN_rand_range");
+ }
+ SetBN(obj, result);
+ return obj;
+}
/*
* call-seq:
@@ -1118,34 +1104,29 @@ ossl_bn_hash(VALUE self)
* bn.prime? => true | false
* bn.prime?(checks) => true | false
*
- * Performs a Miller-Rabin probabilistic primality test with _checks_
- * iterations. If _checks_ is not specified, a number of iterations is used
- * that yields a false positive rate of at most 2^-80 for random input.
+ * Performs a Miller-Rabin probabilistic primality test for +bn+.
*
- * === Parameters
- * * _checks_ - integer
+ * <b>+checks+ parameter is deprecated in version 3.0.</b> It has no effect.
*/
static VALUE
ossl_bn_is_prime(int argc, VALUE *argv, VALUE self)
{
BIGNUM *bn;
- VALUE vchecks;
- int checks = BN_prime_checks;
+ int ret;
- if (rb_scan_args(argc, argv, "01", &vchecks) == 1) {
- checks = NUM2INT(vchecks);
- }
+ rb_check_arity(argc, 0, 1);
GetBN(self, bn);
- switch (BN_is_prime_ex(bn, checks, ossl_bn_ctx, NULL)) {
- case 1:
- return Qtrue;
- case 0:
- return Qfalse;
- default:
- ossl_raise(eBNError, NULL);
- }
- /* not reachable */
- return Qnil;
+
+#ifdef HAVE_BN_CHECK_PRIME
+ ret = BN_check_prime(bn, ossl_bn_ctx, NULL);
+ if (ret < 0)
+ ossl_raise(eBNError, "BN_check_prime");
+#else
+ ret = BN_is_prime_fasttest_ex(bn, BN_prime_checks, ossl_bn_ctx, 1, NULL);
+ if (ret < 0)
+ ossl_raise(eBNError, "BN_is_prime_fasttest_ex");
+#endif
+ return ret ? Qtrue : Qfalse;
}
/*
@@ -1154,40 +1135,17 @@ ossl_bn_is_prime(int argc, VALUE *argv, VALUE self)
* bn.prime_fasttest?(checks) => true | false
* bn.prime_fasttest?(checks, trial_div) => true | false
*
- * Performs a Miller-Rabin primality test. This is same as #prime? except this
- * first attempts trial divisions with some small primes.
+ * Performs a Miller-Rabin probabilistic primality test for +bn+.
*
- * === Parameters
- * * _checks_ - integer
- * * _trial_div_ - boolean
+ * <b>Deprecated in version 3.0.</b> Use #prime? instead.
+ *
+ * +checks+ and +trial_div+ parameters no longer have any effect.
*/
static VALUE
ossl_bn_is_prime_fasttest(int argc, VALUE *argv, VALUE self)
{
- BIGNUM *bn;
- VALUE vchecks, vtrivdiv;
- int checks = BN_prime_checks, do_trial_division = 1;
-
- rb_scan_args(argc, argv, "02", &vchecks, &vtrivdiv);
-
- if (!NIL_P(vchecks)) {
- checks = NUM2INT(vchecks);
- }
- GetBN(self, bn);
- /* handle true/false */
- if (vtrivdiv == Qfalse) {
- do_trial_division = 0;
- }
- switch (BN_is_prime_fasttest_ex(bn, checks, ossl_bn_ctx, do_trial_division, NULL)) {
- case 1:
- return Qtrue;
- case 0:
- return Qfalse;
- default:
- ossl_raise(eBNError, NULL);
- }
- /* not reachable */
- return Qnil;
+ rb_check_arity(argc, 0, 2);
+ return ossl_bn_is_prime(0, argv, self);
}
/*
@@ -1306,9 +1264,9 @@ Init_ossl_bn(void)
* get_word */
rb_define_singleton_method(cBN, "rand", ossl_bn_s_rand, -1);
- rb_define_singleton_method(cBN, "pseudo_rand", ossl_bn_s_pseudo_rand, -1);
rb_define_singleton_method(cBN, "rand_range", ossl_bn_s_rand_range, 1);
- rb_define_singleton_method(cBN, "pseudo_rand_range", ossl_bn_s_pseudo_rand_range, 1);
+ rb_define_alias(rb_singleton_class(cBN), "pseudo_rand", "rand");
+ rb_define_alias(rb_singleton_class(cBN), "pseudo_rand_range", "rand_range");
rb_define_singleton_method(cBN, "generate_prime", ossl_bn_s_generate_prime, -1);
rb_define_method(cBN, "prime?", ossl_bn_is_prime, -1);
diff --git a/ext/openssl/ossl_digest.c b/ext/openssl/ossl_digest.c
index d327f718e2d..fc326ec14ab 100644
--- a/ext/openssl/ossl_digest.c
+++ b/ext/openssl/ossl_digest.c
@@ -63,7 +63,7 @@ ossl_evp_get_digestbyname(VALUE obj)
GetDigest(obj, ctx);
- md = EVP_MD_CTX_md(ctx);
+ md = EVP_MD_CTX_get0_md(ctx);
}
return md;
@@ -176,7 +176,7 @@ ossl_digest_reset(VALUE self)
EVP_MD_CTX *ctx;
GetDigest(self, ctx);
- if (EVP_DigestInit_ex(ctx, EVP_MD_CTX_md(ctx), NULL) != 1) {
+ if (EVP_DigestInit_ex(ctx, EVP_MD_CTX_get0_md(ctx), NULL) != 1) {
ossl_raise(eDigestError, "Digest initialization failed.");
}
@@ -259,7 +259,7 @@ ossl_digest_name(VALUE self)
GetDigest(self, ctx);
- return rb_str_new2(EVP_MD_name(EVP_MD_CTX_md(ctx)));
+ return rb_str_new_cstr(EVP_MD_name(EVP_MD_CTX_get0_md(ctx)));
}
/*
@@ -313,8 +313,6 @@ ossl_digest_block_length(VALUE self)
void
Init_ossl_digest(void)
{
- rb_require("digest");
-
#if 0
mOSSL = rb_define_module("OpenSSL");
eOSSLError = rb_define_class_under(mOSSL, "OpenSSLError", rb_eStandardError);
@@ -398,6 +396,12 @@ Init_ossl_digest(void)
* digest2 = sha256.digest(data2)
*
*/
+
+ /*
+ * Digest::Class is defined by the digest library. rb_require() cannot be
+ * used here because it bypasses RubyGems.
+ */
+ rb_funcall(Qnil, rb_intern_const("require"), 1, rb_str_new_cstr("digest"));
cDigest = rb_define_class_under(mOSSL, "Digest", rb_path2class("Digest::Class"));
/* Document-class: OpenSSL::Digest::DigestError
*
diff --git a/ext/openssl/ossl_hmac.c b/ext/openssl/ossl_hmac.c
index a21db6c481b..f89ff2f9a16 100644
--- a/ext/openssl/ossl_hmac.c
+++ b/ext/openssl/ossl_hmac.c
@@ -238,8 +238,8 @@ ossl_hmac_reset(VALUE self)
EVP_PKEY *pkey;
GetHMAC(self, ctx);
- pkey = EVP_PKEY_CTX_get0_pkey(EVP_MD_CTX_pkey_ctx(ctx));
- if (EVP_DigestSignInit(ctx, NULL, EVP_MD_CTX_md(ctx), NULL, pkey) != 1)
+ pkey = EVP_PKEY_CTX_get0_pkey(EVP_MD_CTX_get_pkey_ctx(ctx));
+ if (EVP_DigestSignInit(ctx, NULL, EVP_MD_CTX_get0_md(ctx), NULL, pkey) != 1)
ossl_raise(eHMACError, "EVP_DigestSignInit");
return self;
diff --git a/ext/openssl/ossl_ocsp.c b/ext/openssl/ossl_ocsp.c
index d4ca958a586..1e87484afc8 100644
--- a/ext/openssl/ossl_ocsp.c
+++ b/ext/openssl/ossl_ocsp.c
@@ -803,7 +803,7 @@ add_status_convert_time(VALUE obj)
* revocation, and must be one of OpenSSL::OCSP::REVOKED_STATUS_* constants.
* _revocation_time_ is the time when the certificate is revoked.
*
- * _this_update_ and _next_update_ indicate the time at which ths status is
+ * _this_update_ and _next_update_ indicate the time at which the status is
* verified to be correct and the time at or before which newer information
* will be available, respectively. _next_update_ is optional.
*
diff --git a/ext/openssl/ossl_pkey.c b/ext/openssl/ossl_pkey.c
index 95a2ea1ed96..f9f5162e414 100644
--- a/ext/openssl/ossl_pkey.c
+++ b/ext/openssl/ossl_pkey.c
@@ -769,14 +769,14 @@ ossl_pkey_compare(VALUE self, VALUE other)
if (EVP_PKEY_id(selfPKey) != EVP_PKEY_id(otherPKey))
ossl_raise(rb_eTypeError, "cannot match different PKey types");
- ret = EVP_PKEY_cmp(selfPKey, otherPKey);
+ ret = EVP_PKEY_eq(selfPKey, otherPKey);
if (ret == 0)
return Qfalse;
else if (ret == 1)
return Qtrue;
else
- ossl_raise(ePKeyError, "EVP_PKEY_cmp");
+ ossl_raise(ePKeyError, "EVP_PKEY_eq");
}
/*
diff --git a/ext/openssl/ossl_pkey_ec.c b/ext/openssl/ossl_pkey_ec.c
index a4a6143676f..db80d112a03 100644
--- a/ext/openssl/ossl_pkey_ec.c
+++ b/ext/openssl/ossl_pkey_ec.c
@@ -479,7 +479,7 @@ static VALUE ossl_ec_key_check_key(VALUE self)
static void
ossl_ec_group_free(void *ptr)
{
- EC_GROUP_clear_free(ptr);
+ EC_GROUP_free(ptr);
}
static const rb_data_type_t ossl_ec_group_type = {
@@ -598,9 +598,6 @@ static VALUE ossl_ec_group_initialize(int argc, VALUE *argv, VALUE self)
ossl_raise(rb_eArgError, "wrong number of arguments");
}
-#if !defined(LIKELY) && !defined(RB_LIKELY)
-#define LIKELY(x) (x)
-#endif
ASSUME(group);
RTYPEDDATA_DATA(self) = group;
@@ -1255,6 +1252,8 @@ static VALUE ossl_ec_point_is_on_curve(VALUE self)
/*
* call-seq:
* point.make_affine! => self
+ *
+ * This method is deprecated and should not be used. This is a no-op.
*/
static VALUE ossl_ec_point_make_affine(VALUE self)
{
@@ -1264,8 +1263,11 @@ static VALUE ossl_ec_point_make_affine(VALUE self)
GetECPoint(self, point);
GetECPointGroup(self, group);
+ rb_warn("OpenSSL::PKey::EC::Point#make_affine! is deprecated");
+#if !OSSL_OPENSSL_PREREQ(3, 0, 0)
if (EC_POINT_make_affine(group, point, ossl_bn_ctx) != 1)
ossl_raise(cEC_POINT, "EC_POINT_make_affine");
+#endif
return self;
}
diff --git a/ext/openssl/ossl_ssl.c b/ext/openssl/ossl_ssl.c
index a32e1dcd185..3b425ca7596 100644
--- a/ext/openssl/ossl_ssl.c
+++ b/ext/openssl/ossl_ssl.c
@@ -57,6 +57,13 @@ static int ossl_ssl_ex_ptr_idx;
static int ossl_sslctx_ex_ptr_idx;
static void
+ossl_sslctx_mark(void *ptr)
+{
+ SSL_CTX *ctx = ptr;
+ rb_gc_mark((VALUE)SSL_CTX_get_ex_data(ctx, ossl_sslctx_ex_ptr_idx));
+}
+
+static void
ossl_sslctx_free(void *ptr)
{
SSL_CTX_free(ptr);
@@ -65,7 +72,7 @@ ossl_sslctx_free(void *ptr)
static const rb_data_type_t ossl_sslctx_type = {
"OpenSSL/SSL/CTX",
{
- 0, ossl_sslctx_free,
+ ossl_sslctx_mark, ossl_sslctx_free,
},
0, 0, RUBY_TYPED_FREE_IMMEDIATELY,
};
@@ -653,7 +660,7 @@ static int
ssl_npn_advertise_cb(SSL *ssl, const unsigned char **out, unsigned int *outlen,
void *arg)
{
- VALUE protocols = (VALUE)arg;
+ VALUE protocols = rb_attr_get((VALUE)arg, id_npn_protocols_encoded);
*out = (const unsigned char *) RSTRING_PTR(protocols);
*outlen = RSTRING_LENINT(protocols);
@@ -821,10 +828,17 @@ ossl_sslctx_setup(VALUE self)
ca_file = NIL_P(val) ? NULL : StringValueCStr(val);
val = rb_attr_get(self, id_i_ca_path);
ca_path = NIL_P(val) ? NULL : StringValueCStr(val);
+#ifdef HAVE_SSL_CTX_LOAD_VERIFY_FILE
+ if (ca_file && !SSL_CTX_load_verify_file(ctx, ca_file))
+ ossl_raise(eSSLError, "SSL_CTX_load_verify_file");
+ if (ca_path && !SSL_CTX_load_verify_dir(ctx, ca_path))
+ ossl_raise(eSSLError, "SSL_CTX_load_verify_dir");
+#else
if(ca_file || ca_path){
if (!SSL_CTX_load_verify_locations(ctx, ca_file, ca_path))
rb_warning("can't set verify locations");
}
+#endif
val = rb_attr_get(self, id_i_verify_mode);
verify_mode = NIL_P(val) ? SSL_VERIFY_NONE : NUM2INT(val);
@@ -843,7 +857,7 @@ ossl_sslctx_setup(VALUE self)
if (!NIL_P(val)) {
VALUE encoded = ssl_encode_npn_protocols(val);
rb_ivar_set(self, id_npn_protocols_encoded, encoded);
- SSL_CTX_set_next_protos_advertised_cb(ctx, ssl_npn_advertise_cb, (void *)encoded);
+ SSL_CTX_set_next_protos_advertised_cb(ctx, ssl_npn_advertise_cb, (void *)self);
OSSL_Debug("SSL NPN advertise callback added");
}
if (RTEST(rb_attr_get(self, id_i_npn_select_cb))) {
@@ -987,6 +1001,52 @@ ossl_sslctx_set_ciphers(VALUE self, VALUE v)
return v;
}
+#ifndef OPENSSL_NO_DH
+/*
+ * call-seq:
+ * ctx.tmp_dh = pkey
+ *
+ * Sets DH parameters used for ephemeral DH key exchange. This is relevant for
+ * servers only.
+ *
+ * +pkey+ is an instance of OpenSSL::PKey::DH. Note that key components
+ * contained in the key object, if any, are ignored. The server will always
+ * generate a new key pair for each handshake.
+ *
+ * Added in version 3.0. See also the man page SSL_set0_tmp_dh_pkey(3).
+ *
+ * Example:
+ * ctx = OpenSSL::SSL::SSLContext.new
+ * ctx.tmp_dh = OpenSSL::DH.generate(2048)
+ * svr = OpenSSL::SSL::SSLServer.new(tcp_svr, ctx)
+ * Thread.new { svr.accept }
+ */
+static VALUE
+ossl_sslctx_set_tmp_dh(VALUE self, VALUE arg)
+{
+ SSL_CTX *ctx;
+ EVP_PKEY *pkey;
+
+ rb_check_frozen(self);
+ GetSSLCTX(self, ctx);
+ pkey = GetPKeyPtr(arg);
+
+ if (EVP_PKEY_base_id(pkey) != EVP_PKEY_DH)
+ rb_raise(eSSLError, "invalid pkey type %s (expected DH)",
+ OBJ_nid2sn(EVP_PKEY_base_id(pkey)));
+#ifdef HAVE_SSL_SET0_TMP_DH_PKEY
+ if (!SSL_CTX_set0_tmp_dh_pkey(ctx, pkey))
+ ossl_raise(eSSLError, "SSL_CTX_set0_tmp_dh_pkey");
+ EVP_PKEY_up_ref(pkey);
+#else
+ if (!SSL_CTX_set_tmp_dh(ctx, EVP_PKEY_get0_DH(pkey)))
+ ossl_raise(eSSLError, "SSL_CTX_set_tmp_dh");
+#endif
+
+ return arg;
+}
+#endif
+
#if !defined(OPENSSL_NO_EC)
/*
* call-seq:
@@ -1169,7 +1229,7 @@ ossl_sslctx_add_certificate(int argc, VALUE *argv, VALUE self)
EVP_PKEY_free(pub_pkey);
if (!pub_pkey)
rb_raise(rb_eArgError, "certificate does not contain public key");
- if (EVP_PKEY_cmp(pub_pkey, pkey) != 1)
+ if (EVP_PKEY_eq(pub_pkey, pkey) != 1)
rb_raise(rb_eArgError, "public key mismatch");
if (argc >= 3)
@@ -1383,8 +1443,16 @@ ossl_sslctx_flush_sessions(int argc, VALUE *argv, VALUE self)
static inline int
ssl_started(SSL *ssl)
{
- /* the FD is set in ossl_ssl_setup(), called by #connect or #accept */
- return SSL_get_fd(ssl) >= 0;
+ /* BIO is created through ossl_ssl_setup(), called by #connect or #accept */
+ return SSL_get_rbio(ssl) != NULL;
+}
+
+static void
+ossl_ssl_mark(void *ptr)
+{
+ SSL *ssl = ptr;
+ rb_gc_mark((VALUE)SSL_get_ex_data(ssl, ossl_ssl_ex_ptr_idx));
+ rb_gc_mark((VALUE)SSL_get_ex_data(ssl, ossl_ssl_ex_vcb_idx));
}
static void
@@ -1396,7 +1464,7 @@ ossl_ssl_free(void *ssl)
const rb_data_type_t ossl_ssl_type = {
"OpenSSL/SSL",
{
- 0, ossl_ssl_free,
+ ossl_ssl_mark, ossl_ssl_free,
},
0, 0, RUBY_TYPED_FREE_IMMEDIATELY,
};
@@ -1466,6 +1534,7 @@ ossl_ssl_initialize(int argc, VALUE *argv, VALUE self)
if (rb_respond_to(io, rb_intern("nonblock=")))
rb_funcall(io, rb_intern("nonblock="), 1, Qtrue);
+ Check_Type(io, T_FILE);
rb_ivar_set(self, id_i_io, io);
ssl = SSL_new(ctx);
@@ -1635,8 +1704,7 @@ ossl_start_ssl(VALUE self, int (*func)(), const char *funcname, VALUE opts)
* call-seq:
* ssl.connect => self
*
- * Initiates an SSL/TLS handshake with a server. The handshake may be started
- * after unencrypted data has been sent over the socket.
+ * Initiates an SSL/TLS handshake with a server.
*/
static VALUE
ossl_ssl_connect(VALUE self)
@@ -1683,8 +1751,7 @@ ossl_ssl_connect_nonblock(int argc, VALUE *argv, VALUE self)
* call-seq:
* ssl.accept => self
*
- * Waits for a SSL/TLS client to initiate a handshake. The handshake may be
- * started after unencrypted data has been sent over the socket.
+ * Waits for a SSL/TLS client to initiate a handshake.
*/
static VALUE
ossl_ssl_accept(VALUE self)
@@ -1731,7 +1798,7 @@ static VALUE
ossl_ssl_read_internal(int argc, VALUE *argv, VALUE self, int nonblock)
{
SSL *ssl;
- int ilen, nread = 0;
+ int ilen;
VALUE len, str;
rb_io_t *fptr;
VALUE io, opts = Qnil;
@@ -1741,6 +1808,9 @@ ossl_ssl_read_internal(int argc, VALUE *argv, VALUE self, int nonblock)
} else {
rb_scan_args(argc, argv, "11", &len, &str);
}
+ GetSSL(self, ssl);
+ if (!ssl_started(ssl))
+ rb_raise(eSSLError, "SSL session is not started yet");
ilen = NUM2INT(len);
if (NIL_P(str))
@@ -1756,74 +1826,60 @@ ossl_ssl_read_internal(int argc, VALUE *argv, VALUE self, int nonblock)
if (ilen == 0)
return str;
- GetSSL(self, ssl);
io = rb_attr_get(self, id_i_io);
GetOpenFile(io, fptr);
- if (ssl_started(ssl)) {
- for (;;){
- nread = SSL_read(ssl, RSTRING_PTR(str), ilen);
- switch(ssl_get_error(ssl, nread)){
- case SSL_ERROR_NONE:
- goto end;
- case SSL_ERROR_ZERO_RETURN:
- if (no_exception_p(opts)) { return Qnil; }
- rb_eof_error();
- case SSL_ERROR_WANT_WRITE:
- if (no_exception_p(opts)) { return sym_wait_writable; }
+
+ rb_str_locktmp(str);
+ for (;;) {
+ int nread = SSL_read(ssl, RSTRING_PTR(str), ilen);
+ switch (ssl_get_error(ssl, nread)) {
+ case SSL_ERROR_NONE:
+ rb_str_unlocktmp(str);
+ rb_str_set_len(str, nread);
+ return str;
+ case SSL_ERROR_ZERO_RETURN:
+ rb_str_unlocktmp(str);
+ if (no_exception_p(opts)) { return Qnil; }
+ rb_eof_error();
+ case SSL_ERROR_WANT_WRITE:
+ if (nonblock) {
+ rb_str_unlocktmp(str);
+ if (no_exception_p(opts)) { return sym_wait_writable; }
write_would_block(nonblock);
- io_wait_writable(fptr);
- continue;
- case SSL_ERROR_WANT_READ:
- if (no_exception_p(opts)) { return sym_wait_readable; }
+ }
+ io_wait_writable(fptr);
+ continue;
+ case SSL_ERROR_WANT_READ:
+ if (nonblock) {
+ rb_str_unlocktmp(str);
+ if (no_exception_p(opts)) { return sym_wait_readable; }
read_would_block(nonblock);
- io_wait_readable(fptr);
- continue;
- case SSL_ERROR_SYSCALL:
- if (!ERR_peek_error()) {
- if (errno)
- rb_sys_fail(0);
- else {
- /*
- * The underlying BIO returned 0. This is actually a
- * protocol error. But unfortunately, not all
- * implementations cleanly shutdown the TLS connection
- * but just shutdown/close the TCP connection. So report
- * EOF for now...
- */
- if (no_exception_p(opts)) { return Qnil; }
- rb_eof_error();
- }
- }
- /* fall through */
- default:
- ossl_raise(eSSLError, "SSL_read");
- }
- }
- }
- else {
- ID meth = nonblock ? rb_intern("read_nonblock") : rb_intern("sysread");
-
- rb_warning("SSL session is not started yet.");
-#if defined(RB_PASS_KEYWORDS)
- if (nonblock) {
- VALUE argv[3];
- argv[0] = len;
- argv[1] = str;
- argv[2] = opts;
- return rb_funcallv_kw(io, meth, 3, argv, RB_PASS_KEYWORDS);
- }
-#else
- if (nonblock) {
- return rb_funcall(io, meth, 3, len, str, opts);
+ }
+ io_wait_readable(fptr);
+ continue;
+ case SSL_ERROR_SYSCALL:
+ if (!ERR_peek_error()) {
+ rb_str_unlocktmp(str);
+ if (errno)
+ rb_sys_fail(0);
+ else {
+ /*
+ * The underlying BIO returned 0. This is actually a
+ * protocol error. But unfortunately, not all
+ * implementations cleanly shutdown the TLS connection
+ * but just shutdown/close the TCP connection. So report
+ * EOF for now...
+ */
+ if (no_exception_p(opts)) { return Qnil; }
+ rb_eof_error();
+ }
+ }
+ /* fall through */
+ default:
+ rb_str_unlocktmp(str);
+ ossl_raise(eSSLError, "SSL_read");
}
-#endif
- else
- return rb_funcall(io, meth, 2, len, str);
}
-
- end:
- rb_str_set_len(str, nread);
- return str;
}
/*
@@ -1863,78 +1919,55 @@ static VALUE
ossl_ssl_write_internal(VALUE self, VALUE str, VALUE opts)
{
SSL *ssl;
- int nwrite = 0;
rb_io_t *fptr;
- int nonblock = opts != Qfalse;
- VALUE io;
+ int num, nonblock = opts != Qfalse;
+ VALUE tmp, io;
- StringValue(str);
GetSSL(self, ssl);
+ if (!ssl_started(ssl))
+ rb_raise(eSSLError, "SSL session is not started yet");
+
+ tmp = rb_str_new_frozen(StringValue(str));
io = rb_attr_get(self, id_i_io);
GetOpenFile(io, fptr);
- if (ssl_started(ssl)) {
- for (;;){
- int num = RSTRING_LENINT(str);
-
- /* SSL_write(3ssl) manpage states num == 0 is undefined */
- if (num == 0)
- goto end;
-
- nwrite = SSL_write(ssl, RSTRING_PTR(str), num);
- switch(ssl_get_error(ssl, nwrite)){
- case SSL_ERROR_NONE:
- goto end;
- case SSL_ERROR_WANT_WRITE:
- if (no_exception_p(opts)) { return sym_wait_writable; }
- write_would_block(nonblock);
- io_wait_writable(fptr);
- continue;
- case SSL_ERROR_WANT_READ:
- if (no_exception_p(opts)) { return sym_wait_readable; }
- read_would_block(nonblock);
- io_wait_readable(fptr);
- continue;
- case SSL_ERROR_SYSCALL:
+
+ /* SSL_write(3ssl) manpage states num == 0 is undefined */
+ num = RSTRING_LENINT(tmp);
+ if (num == 0)
+ return INT2FIX(0);
+
+ for (;;) {
+ int nwritten = SSL_write(ssl, RSTRING_PTR(tmp), num);
+ switch (ssl_get_error(ssl, nwritten)) {
+ case SSL_ERROR_NONE:
+ return INT2NUM(nwritten);
+ case SSL_ERROR_WANT_WRITE:
+ if (no_exception_p(opts)) { return sym_wait_writable; }
+ write_would_block(nonblock);
+ io_wait_writable(fptr);
+ continue;
+ case SSL_ERROR_WANT_READ:
+ if (no_exception_p(opts)) { return sym_wait_readable; }
+ read_would_block(nonblock);
+ io_wait_readable(fptr);
+ continue;
+ case SSL_ERROR_SYSCALL:
#ifdef __APPLE__
- /*
- * It appears that send syscall can return EPROTOTYPE if the
- * socket is being torn down. Retry to get a proper errno to
- * make the error handling in line with the socket library.
- * [Bug #14713] https://bugs.ruby-lang.org/issues/14713
- */
- if (errno == EPROTOTYPE)
- continue;
+ /*
+ * It appears that send syscall can return EPROTOTYPE if the
+ * socket is being torn down. Retry to get a proper errno to
+ * make the error handling in line with the socket library.
+ * [Bug #14713] https://bugs.ruby-lang.org/issues/14713
+ */
+ if (errno == EPROTOTYPE)
+ continue;
#endif
- if (errno) rb_sys_fail(0);
- /* fallthrough */
- default:
- ossl_raise(eSSLError, "SSL_write");
- }
- }
- }
- else {
- ID meth = nonblock ?
- rb_intern("write_nonblock") : rb_intern("syswrite");
-
- rb_warning("SSL session is not started yet.");
-#if defined(RB_PASS_KEYWORDS)
- if (nonblock) {
- VALUE argv[2];
- argv[0] = str;
- argv[1] = opts;
- return rb_funcallv_kw(io, meth, 2, argv, RB_PASS_KEYWORDS);
+ if (errno) rb_sys_fail(0);
+ /* fallthrough */
+ default:
+ ossl_raise(eSSLError, "SSL_write");
}
-#else
- if (nonblock) {
- return rb_funcall(io, meth, 2, str, opts);
- }
-#endif
- else
- return rb_funcall(io, meth, 1, str);
}
-
- end:
- return INT2NUM(nwrite);
}
/*
@@ -2670,6 +2703,9 @@ Init_ossl_ssl(void)
ossl_sslctx_set_minmax_proto_version, 2);
rb_define_method(cSSLContext, "ciphers", ossl_sslctx_get_ciphers, 0);
rb_define_method(cSSLContext, "ciphers=", ossl_sslctx_set_ciphers, 1);
+#ifndef OPENSSL_NO_DH
+ rb_define_method(cSSLContext, "tmp_dh=", ossl_sslctx_set_tmp_dh, 1);
+#endif
rb_define_method(cSSLContext, "ecdh_curves=", ossl_sslctx_set_ecdh_curves, 1);
rb_define_method(cSSLContext, "security_level", ossl_sslctx_get_security_level, 0);
rb_define_method(cSSLContext, "security_level=", ossl_sslctx_set_security_level, 1);
diff --git a/ext/openssl/ossl_ts.c b/ext/openssl/ossl_ts.c
index e2fd0fe06e7..b33ff10c101 100644
--- a/ext/openssl/ossl_ts.c
+++ b/ext/openssl/ossl_ts.c
@@ -211,8 +211,10 @@ ossl_ts_req_initialize(int argc, VALUE *argv, VALUE self)
in = ossl_obj2bio(&arg);
ts_req = d2i_TS_REQ_bio(in, &ts_req);
BIO_free(in);
- if (!ts_req)
+ if (!ts_req) {
+ DATA_PTR(self) = NULL;
ossl_raise(eTimestampError, "Error when decoding the timestamp request");
+ }
DATA_PTR(self) = ts_req;
return self;
@@ -535,8 +537,10 @@ ossl_ts_resp_initialize(VALUE self, VALUE der)
in = ossl_obj2bio(&der);
ts_resp = d2i_TS_RESP_bio(in, &ts_resp);
BIO_free(in);
- if (!ts_resp)
+ if (!ts_resp) {
+ DATA_PTR(self) = NULL;
ossl_raise(eTimestampError, "Error when decoding the timestamp response");
+ }
DATA_PTR(self) = ts_resp;
return self;
@@ -822,7 +826,7 @@ ossl_ts_resp_verify(int argc, VALUE *argv, VALUE self)
X509_up_ref(cert);
}
- TS_VERIFY_CTS_set_certs(ctx, x509inter);
+ TS_VERIFY_CTX_set_certs(ctx, x509inter);
TS_VERIFY_CTX_add_flags(ctx, TS_VFY_SIGNATURE);
TS_VERIFY_CTX_set_store(ctx, x509st);
@@ -874,8 +878,10 @@ ossl_ts_token_info_initialize(VALUE self, VALUE der)
in = ossl_obj2bio(&der);
info = d2i_TS_TST_INFO_bio(in, &info);
BIO_free(in);
- if (!info)
+ if (!info) {
+ DATA_PTR(self) = NULL;
ossl_raise(eTimestampError, "Error when decoding the timestamp token info");
+ }
DATA_PTR(self) = info;
return self;
@@ -1077,7 +1083,11 @@ ossl_tsfac_serial_cb(struct TS_resp_ctx *ctx, void *data)
}
static int
+#if !defined(LIBRESSL_VERSION_NUMBER)
ossl_tsfac_time_cb(struct TS_resp_ctx *ctx, void *data, long *sec, long *usec)
+#else
+ossl_tsfac_time_cb(struct TS_resp_ctx *ctx, void *data, time_t *sec, long *usec)
+#endif
{
*sec = *((long *)data);
*usec = 0;
diff --git a/ext/openssl/ossl_x509name.c b/ext/openssl/ossl_x509name.c
index 1522c3d897c..13a2b2c030f 100644
--- a/ext/openssl/ossl_x509name.c
+++ b/ext/openssl/ossl_x509name.c
@@ -291,7 +291,14 @@ x509name_print(VALUE self, unsigned long iflag)
* * OpenSSL::X509::Name::MULTILINE
*
* If _format_ is omitted, the largely broken and traditional OpenSSL format
- * is used.
+ * (<tt>X509_NAME_oneline()</tt> format) is chosen.
+ *
+ * <b>Use of this method is discouraged.</b> None of the formats other than
+ * OpenSSL::X509::Name::RFC2253 is standardized and may show an inconsistent
+ * behavior through \OpenSSL versions.
+ *
+ * It is recommended to use #to_utf8 instead, which is equivalent to calling
+ * <tt>name.to_s(OpenSSL::X509::Name::RFC2253).force_encoding("UTF-8")</tt>.
*/
static VALUE
ossl_x509name_to_s(int argc, VALUE *argv, VALUE self)
@@ -498,7 +505,7 @@ ossl_x509name_to_der(VALUE self)
* You can create a Name by parsing a distinguished name String or by
* supplying the distinguished name as an Array.
*
- * name = OpenSSL::X509::Name.parse '/CN=nobody/DC=example'
+ * name = OpenSSL::X509::Name.parse_rfc2253 'DC=example,CN=nobody'
*
* name = OpenSSL::X509::Name.new [['CN', 'nobody'], ['DC', 'example']]
*/
diff --git a/ext/openssl/ossl_x509store.c b/ext/openssl/ossl_x509store.c
index f494dbc908a..7c546187c38 100644
--- a/ext/openssl/ossl_x509store.c
+++ b/ext/openssl/ossl_x509store.c
@@ -113,6 +113,13 @@ VALUE cX509StoreContext;
VALUE eX509StoreError;
static void
+ossl_x509store_mark(void *ptr)
+{
+ X509_STORE *store = ptr;
+ rb_gc_mark((VALUE)X509_STORE_get_ex_data(store, store_ex_verify_cb_idx));
+}
+
+static void
ossl_x509store_free(void *ptr)
{
X509_STORE_free(ptr);
@@ -121,7 +128,7 @@ ossl_x509store_free(void *ptr)
static const rb_data_type_t ossl_x509store_type = {
"OpenSSL/X509/STORE",
{
- 0, ossl_x509store_free,
+ ossl_x509store_mark, ossl_x509store_free,
},
0, 0, RUBY_TYPED_FREE_IMMEDIATELY,
};
@@ -494,23 +501,16 @@ ossl_x509store_verify(int argc, VALUE *argv, VALUE self)
}
/*
- * Public Functions
- */
-static void ossl_x509stctx_free(void*);
-
-
-static const rb_data_type_t ossl_x509stctx_type = {
- "OpenSSL/X509/STORE_CTX",
- {
- 0, ossl_x509stctx_free,
- },
- 0, 0, RUBY_TYPED_FREE_IMMEDIATELY,
-};
-
-/*
* Private functions
*/
static void
+ossl_x509stctx_mark(void *ptr)
+{
+ X509_STORE_CTX *ctx = ptr;
+ rb_gc_mark((VALUE)X509_STORE_CTX_get_ex_data(ctx, stctx_ex_verify_cb_idx));
+}
+
+static void
ossl_x509stctx_free(void *ptr)
{
X509_STORE_CTX *ctx = ptr;
@@ -521,6 +521,14 @@ ossl_x509stctx_free(void *ptr)
X509_STORE_CTX_free(ctx);
}
+static const rb_data_type_t ossl_x509stctx_type = {
+ "OpenSSL/X509/STORE_CTX",
+ {
+ ossl_x509stctx_mark, ossl_x509stctx_free,
+ },
+ 0, 0, RUBY_TYPED_FREE_IMMEDIATELY,
+};
+
static VALUE
ossl_x509stctx_alloc(VALUE klass)
{
diff --git a/ext/openssl/ruby_missing.h b/ext/openssl/ruby_missing.h
deleted file mode 100644
index 069acc8b140..00000000000
--- a/ext/openssl/ruby_missing.h
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * 'OpenSSL for Ruby' project
- * Copyright (C) 2001-2003 Michal Rokos <m.rokos@sh.cvut.cz>
- * All rights reserved.
- */
-/*
- * This program is licensed under the same licence as Ruby.
- * (See the file 'LICENCE'.)
- */
-#if !defined(_OSSL_RUBY_MISSING_H_)
-#define _OSSL_RUBY_MISSING_H_
-
-/* Ruby 2.4 */
-#ifndef RB_INTEGER_TYPE_P
-# define RB_INTEGER_TYPE_P(obj) (RB_FIXNUM_P(obj) || RB_TYPE_P(obj, T_BIGNUM))
-#endif
-
-/* Ruby 2.5 */
-#ifndef ST2FIX
-# define RB_ST2FIX(h) LONG2FIX((long)(h))
-# define ST2FIX(h) RB_ST2FIX(h)
-#endif
-
-#endif /* _OSSL_RUBY_MISSING_H_ */