aboutsummaryrefslogtreecommitdiffstats
path: root/ext
Commit message (Collapse)AuthorAgeFilesLines
* ext/openssl: use SSL_CTX_get_ciphers()Kazuki Yamaguchi2016-04-273-1/+6
|
* ext/openssl: avoid using deprecated protocol version specific methods.Kazuki Yamaguchi2016-04-272-35/+43
| | | | | They emit warnings with OpenSSL 1.1.0. Instead use SSL_CTX_set_{min,max}_proto_version().
* ext/openssl: EVP_PKEY, DH, DSA, RSA, EC_KEY are made opaqueKazuki Yamaguchi2016-04-279-144/+372
| | | | | | | | | | | | | | | | | | | | Use EVP_PKEY_get0_* instead of pkey->pkey.* Use EVP_PKEY_base_id(pkey) instead of EVP_PKEY_type(pkey->type) Because of this, we can no longer set the parameters/keys directly, and the newly added functions as alternative require setting all relevant values at the same time. So this patch contains incompatibility: the following code no longer works (if using 1.1.0): dh = OpenSSL::PKey::DH.new(...) dh.priv_key = OpenSSL::BN.new(...) ...and we have to write like: dh = OpenSSL::PKey::DH.new(...) priv = OpenSSL::BN.new(...) pub = <calculate (dh.g ** priv) % dh.p> dh.set_key(pub, priv)
* ext/openssl: use EVP_MD_CTX_new() to allocate EVP_MD_CTXKazuki Yamaguchi2016-04-273-12/+25
|
* ext/openssl: use X509_STORE_CTX_get0_store() instead of store_ctx->ctxKazuki Yamaguchi2016-04-273-3/+8
|
* ext/openssl: fix (mainly) opaque related compilation of ossl_x509*.cKazuki Yamaguchi2016-04-2711-63/+173
| | | | | | | | | | | | | Fix following files: - ossl_x509attr.c - ossl_x509cert.c - ossl_x509store.c - ossl_x509name.c - ossl_x509req.c - ossl_x509crl.c - ossl_x509revoked.c - ossl_x509ext.c
* ext/openssl: use *_up_ref() functionsKazuki Yamaguchi2016-04-277-10/+45
|
* ext/openssl: support new threading API of OpenSSL 1.1.0Kazuki Yamaguchi2016-04-272-0/+5
| | | | Setting locking callbacks is no longer needed.
* ext/openssl: SSL_SESSION is made opaqueKazuki Yamaguchi2016-04-272-4/+14
|
* ext/openssl: the return type of HMAC_CTX_copy() is intKazuki Yamaguchi2016-04-272-3/+4
|
* ext/openssl: BIGNUM and BN_GENCB is made opaqueKazuki Yamaguchi2016-04-277-23/+47
|
* ext/openssl: OCSP_SINGLERESP and OCSP_CERTID are also made opaqueKazuki Yamaguchi2016-04-273-4/+11
|
* ext/openssl: use HMAC_CTX_{new,free,reset} to allocate HMAC_CTXKazuki Yamaguchi2016-04-274-52/+107
| | | | HMAC_CTX is made opaque in OpenSSL 1.1.0
* ext/openssl: use EVP_CIPHER_CTX_{new,free} to allocate EVP_CIPHER_CTXKazuki Yamaguchi2016-04-274-22/+51
| | | | EVP_CIPHER_CTX was made opaque in OpenSSL 1.1.0
* ext/openssl: d2i_ASN1_BOOLEAN is removedKazuki Yamaguchi2016-04-271-6/+7
|
* ext/openssl: disable OpenSSL::Random.pseudo_bytes if deprecatedKazuki Yamaguchi2016-04-272-0/+5
|
* ext/openssl: avoid deprecated BN primes functionsKazuki Yamaguchi2016-04-271-3/+3
| | | | | BN_generate_prime(), BN_is_prime(), BN_is_prime_fasttest() is deprecated and the replacements are available on all versions of OpenSSL >= 0.9.8.
* ext/openssl: simplify extconf.rbKazuki Yamaguchi2016-04-272-54/+34
|
* ext/openssl: include openssl/asn1.h instead of openssl/asn1_mac.hKazuki Yamaguchi2016-04-271-1/+1
|
* ext/openssl: drop support for OPENSSL_NO_HMACKazuki Yamaguchi2016-04-272-16/+1
| | | | | | It has not been actually supported: since ossl.h includes openssl/hmac.h without any guards, it wouldn't compile if OPENSSL_NO_HMAC is enabled.
* ext/openssl: drop support for OpenSSL 0.9.6/0.9.7Kazuki Yamaguchi2016-04-2723-772/+90
| | | | | | | | | The last release of OpenSSL 0.9.7 series was over 9 years ago (!) and even 0.9.8/1.0.0 are no longer supported (EOL was 2015-12-31). It actually doesn't compile since r40461 (ext/openssl/ossl_bn.c (ossl_bn_initialize): allow Fixnum and Bignum. [ruby-core:53986] [Feature #8217], 2013-04-25, 2.1.0) and it looks like nobody noticed it.
* ext/openssl: always use our implementation of SSL_SESSION_cmp()Kazuki Yamaguchi2016-04-274-5/+26
| | | | | | | | | Implement CRYPTO_memcmp() if it is not available. Always use our SSL_SESSION_cmp() (renamed to ossl_SSL_SESSION_cmp()). SSL_SESSION_cmp() was removed in OpenSSL 1.0.0 and we have used a reimplemented one. However our implementation is better than the original (it uses CRYPTO_memcmp() instead of plain memcmp).
* ext/openssl: check if SSL_CTX_clear_options() is availableKazuki Yamaguchi2016-04-272-0/+6
| | | | | | | Fix build with very very old versions of OpenSSL. SSL_CTX_clear_options() is new in OpenSSL 0.9.8m but some Linux distributions still uses 0.9.8e.
* stringio.c: warn block for newnobu2016-04-271-0/+14
| | | | | | | * ext/stringio/stringio.c (strio_s_new): warn if a block is given, as well as IO.new. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54792 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* tk/extconf.rb: refactornobu2016-04-251-20/+13
| | | | | | | | | | | * ext/tk/extconf.rb (collect_tcltk_defs): split by -D at the beginning or preceded by a space. exclude empty strings from $defs. * ext/tk/extconf.rb: test if value is set and has non-blank by matching /\S/ at once. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54763 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ripper: fix ripper.Enobu2016-04-252-5/+4
| | | | | | | | | * ext/ripper/depend (ripper.E): add missing $(INCFLAGS). * ext/ripper/tools/strip.rb: insert an empty line for blank or line directive lines. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54761 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* extmk.rb: refactornobu2016-04-251-1/+1
| | | | | | | * ext/extmk.rb: extract non-blank part without intermediate objects. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54760 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* rbconfig/sizeof: calculate at compilation timenobu2016-04-251-30/+30
| | | | | | | | | * ext/rbconfig/sizeof/extconf.rb: just check the existence of each types, to reduce configuration time, especially cross-compiling. * template/sizes.c.tmpl: calculate sizes of checked types at compilation time. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54759 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * encoding.c: Fix return value of `Encoding::ISO8859_1.name`hsbt2016-04-251-1/+1
| | | | | | | [Bug #12313][ruby-core:75147][ci skip] * ext/bigdecimal/bigdecimal.c: Fix code sample of `BigDecimal.new` git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54755 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* date_core.c: [DOC] markdown to rdoc [ci skip]nobu2016-04-231-148/+136
| | | | | | | | * ext/date/date_core.c (Init_date_core): [DOC] Convert DateTime documentation to RDoc from Markdown. [ruby-core:75136] [Bug #12311] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54721 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * variable.c: use uint32_t instead of long to avoid confusion aboutnaruse2016-04-221-1/+1
| | | | | | the type of ivtbl->numiv. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54700 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* tk: suppress progress indicatorsnobu2016-04-221-1/+1
| | | | | | | * ext/tk/extconf.rb: hack to disable progress indicators with parallel build, not to interleave other messages. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54682 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* cgi/util.rb: remove CGI::Util#_unescapenobu2016-04-201-4/+21
| | | | | | | | | | * ext/cgi/escape/escape.c (cgiesc_unescape): define unescape method instead of _unescape, and should pass the optional argument to the super method. * lib/cgi/util.rb (CGI::Util#_unescape): remove intermediate method. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54655 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/date/date_core.c : remove not used f_getlocal macro.yui-knk2016-04-161-1/+0
| | | | | | After r54553 f_getlocal macro is not used. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54614 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/date/date_core.c : remove not used f_utc6 macro.yui-knk2016-04-161-2/+0
| | | | | | After r54169 f_utc6 macro is not used. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54613 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* struct.c: unique membersnobu2016-04-161-0/+24
| | | | | | | * struct.c (struct_make_members_list, rb_struct_s_def): member names should be unique. [ruby-core:74971] [Bug #12291] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54612 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* win32/console: io_handlenobu2016-04-151-8/+16
| | | | | | | * ext/-test-/win32/console/attribute.c (io_handle): extract conversion from IO instance to HANDLE. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54599 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io/console: bump upnobu2016-04-151-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54593 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io/console: unknown key code for names with nulnobu2016-04-151-2/+5
| | | | | | | | | | * ext/io/console/console.c (console_key_pressed_p): raise the same exception, "unknown virtual key code", for names with nul chars. though console_win32_vk() considers the length and can deal with nul chars, rb_sprintf() raised at PRIsVALUE previously, so quote it if it is unprintable. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54589 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io/console: rb_sym2strnobu2016-04-152-0/+5
| | | | | | | * ext/io/console/console.c (rb_sym2str): fallback definition for older ruby. [ruby-core:74953] [Bug #12284] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54587 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io/console: use rb_funcallvnobu2016-04-152-2/+6
| | | | | | | * ext/io/console/console.c: use rb_funcallv instead of rb_funcall2, and define rb_funcallv if unavailable. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54586 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io/console: fallback RARRAY_CONST_PTRnobu2016-04-151-0/+3
| | | | | | | * ext/io/console/console.c (RARRAY_CONST_PTR): fallback definition for older ruby. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54585 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io/console: reject symbols with nul charnobu2016-04-151-4/+3
| | | | | | | * ext/io/console/console.c (console_key_pressed_p): symbol names can contain nul chars, reject them. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54584 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* tkutil.c: ary can be nilnobu2016-04-141-1/+1
| | | | | | | | * ext/tk/tkutil/tkutil.c (tk_hash_kv): the third argument can be nil not only an Array. reported by @windwiny at https://github.com/ruby/ruby/commit/cdaa94e#commitcomment-17096618 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54575 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* date_core.c: preserve timezonenobu2016-04-121-2/+2
| | | | | | | * ext/date/date_core.c (time_to_time): should preserve timezone info. [ruby-core:74889] [Bug #12271] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54553 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Update dependencies.akr2016-04-1130-1/+136
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54544 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* fiddle/import.rb: suppress warningsnobu2016-04-111-6/+9
| | | | | | | * ext/fiddle/lib/fiddle/import.rb (type_alias, handler): suppress "not initialized instance variable" warnings. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54534 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* registry.rb: fix API namesnobu2016-04-101-2/+2
| | | | | | | * ext/win32/lib/win32/registry.rb (DeleteValue, DeleteKey): fix API names. [ruby-core:74863] [Bug #12264] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54529 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/tk/extconf.rb: add newlinenobu2016-04-091-9/+18
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54524 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* tk/extconf.rb: progressnobu2016-04-081-13/+22
| | | | | | | * ext/tk/extconf.rb (progress): print progress messages only if Logging is quiet. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54516 b2dd03c8-39d4-4d8f-98ff-823fe69b080e