summaryrefslogtreecommitdiffstats
path: root/test/openssl
Commit message (Collapse)AuthorAgeFilesLines
* * test/openssl/test_ssl.rb (test_parallel): call GC.start to closegotoyuzo2005-12-121-0/+1
| | | | | | | unused files. [ruby-dev:27981] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9680 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/openssl/extconf.rb: check for X509V3_EXT_nconf_nid.gotoyuzo2005-11-221-0/+74
| | | | | | | | | | | | | | * ext/openssl/ossl_x509ext.c (MakeX509ExtFactory): should use OPENSSL_malloc to allocate X509V3_CTX. * ext/openssl/ossl_x509ext.c (ossl_x509extfactory_create_ext): use X509V3_EXT_nconf_nid to avoid SEGV (and to build extensions which values are placed in separate section). * test/openssl/test_x509ext.rb: new file. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9592 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/openssl/ossl_cipher.c (ossl_cipher_update): input data mustgotoyuzo2005-10-301-0/+5
| | | | | | | | | not be empty. [ruby-talk:161220] * test/openssl/test_cipher.rb: add test for Cipher#update(""). git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9485 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/openssl/ossl_pkey.h, ossl_pkey_rsa.c, ossl_pkey_dsa.c:gotoyuzo2005-09-181-0/+11
| | | | | | | | | | | | an instance variable "private" is added to OpenSSL::PKey class. this ivar is a flag that shows whether there is a private key in the instance. * ext/openssl/ossl_engine.c: (ossl_engine_load_privkey): set private key flag. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9218 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/openssl/test_pkcs7.rb (test_enveloped): skip this testgotoyuzo2005-09-121-0/+6
| | | | | | | | | to avoid a bug of PKCS7_enctypt() (only if ext/openssl is compiled with OpenSSL-0.9.7d or earlier versions). http://www.mail-archive.com/openssl-dev@openssl.org/msg17376.html git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* This commit was manufactured by cvs2svn to create branch 'ruby_1_8'.(no author)2005-09-102-0/+207
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9112 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/openssl/lib/digest.rb: added SHA224, SHA256, SHA384 and SHA512.gotoyuzo2005-09-101-0/+9
| | | | | | | | | | these features are enabled if this library is compiled with OpenSSL 0.9.8 or later. * test/openssl/test_digest.rb: add test for new digests. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9111 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/openssl/ossl.c (ossl_raise): should use ERR_peek_last_errorgotoyuzo2005-09-101-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | to get last error on the current thread. And should report errors are on the stack while OpenSSL.debug is true. * ext/openssl/ossl.c (ossl_get_errors): new method for debugging this library. * ext/openssl/ossl_ssl.c (ossl_sslctx_set_ciphers): fix error message. * ext/openssl/ossl_x509req.c (ossl_x509req_set_attributes): get rid of unused variable. * ext/openssl/ossl_x509store.c (ossl_x509store_initialize): should set @time to avoid warning. * ext/openssl/ossl_x509store.c (ossl_x509store_set_default_paths, X509_STORE_add_cert, X509_STORE_add_crl): should raise error if wrapped functions failed. * test/openssl/test_x509store.rb: add test for errors. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@9110 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/openssl/test_x509store.rb: add test for expired CRLgotoyuzo2005-05-281-7/+28
| | | | | | | and refine some assertions. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@8534 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/openssl/ossl_ssl.c: add callbacks to OpenSSL::SSL::SSLContexts.gotoyuzo2005-04-083-25/+40
| | | | | | | | | | | | | | | | | | | | | | | | - SSLContext#client_cert_cb=(aProc). it is called when a client certificate is requested by a server and no certificate was not set for the SSLContext. it must return an Array which includes OpenSSL::X509::Certificate and OpenSSL::PKey::RSA/DSA objects. - SSLContext#tmp_dh_callback=(aProc). it is called in key exchange with DH algorithm. it must return an OpenSSL::PKey::DH object. * ext/openssl/ossl_ssl.c (ossl_sslctx_set_ciphers): ignore the argument if it's nil. * ext/openssl/ossl_pkey.c (GetPrivPKeyPtr, ossl_pkey_sign): should call rb_funcall first. (DupPrivPKeyPtr): new function. * ext/openssl/ossl_pkey_dh.c: add default DH parameters. * ext/openssl/ossl_pkey.h: ditto. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@8277 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/openssl/ossl_ssl.c (ossl_start_ssl, ossl_ssl_write): callgotoyuzo2005-03-091-166/+0
| | | | | | | | | rb_sys_fail if errno isn't 0. [ruby-dev:25831] * ext/openssl/lib/openssl/cipher.rb: fix typo. [ruby-dev:24285] git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@8130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* This commit was manufactured by cvs2svn to create branch 'ruby_1_8'.(no author)2005-03-071-0/+332
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@8103 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/openssl/lib/openssl/ssl.rbgotoyuzo2005-02-141-0/+49
| | | | | | | (OpenSSL::SSL::SSLSocket#post_connection_check): new method. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@7970 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* This commit was manufactured by cvs2svn to create branch 'ruby_1_8'.(no author)2004-12-211-0/+197
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@7624 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/openssl/ossl_x509store.cgotoyuzo2004-12-194-39/+171
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (ossl_x509store_set_time): add OpenSSL::X509::Store#time=. (ossl_x509stctx_set_time): add OpenSSL::X509::StoreContext#time=. * test/openssl/ossl_x509store.rb: test certificate validity times. * ext/openssl/ossl_x509name.c (ossl_x509name_to_s): add optional second argument to specify the output format (see also X509_NAME_print_ex). * ext/openssl/ossl_x509name.c (ossl_x509name_init): new constants: OpenSSL::X509::Name::COMPAT, OpenSSL::X509::Name::RFC2253, OpenSSL::X509::ONELINE, OpenSSL::X509::MULTILINE. * ext/openssl/lib/openssl/x509.rb (OpenSSL::X509::Name::RFC2253DN): new module to provide the parse for RFC2253 DN format. * ext/openssl/lib/openssl/x509.rb (OpenSSL::X509::Name.parse_rfc2253): new method to parse RFC2253 DN format. * test/openssl/ossl_x509name.rb: add tests about RFC2253 DN. * text/openssl/ssl_server.rb: try to listen ports from 20443 to 20542 while EADDRINUSE is raised. * all changes in this entry are backport from 1.9. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@7599 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* This commit was manufactured by cvs2svn to create branch 'ruby_1_8'.(no author)2004-12-051-0/+38
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@7467 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/openssl/test_ssl.rb: add workaround for Cygwin.gotoyuzo2004-07-181-1/+5
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@6674 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/openssl/ssl_server.rb, test/openssl/test_ssl.rb: workaround togotoyuzo2004-07-162-9/+2
| | | | | | | terminate child process. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@6650 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/openssl/ossl_asn1.c (ossl_asn1cons_to_der): fix type ofgotoyuzo2004-07-141-0/+2
| | | | | | | | | | argument. [ruby-dev:23891] * test/openssl/test_x509store.rb: prune tests for CRL checking unless X509::V_FLAG_CRL_CHECK is defined. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@6626 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* This commit was manufactured by cvs2svn to create branch 'ruby_1_8'.(no author)2004-07-013-0/+161
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@6554 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/openssl/ossl_ssl.c (ossl_ssl_read): take optional second argumentgotoyuzo2004-06-304-10/+27
| | | | | | | | | | | | | | | | to specify a string to be written. * ext/openssl/lib/openssl/buffering.rb (OpenSSL::Buffering#read): take optional second argument to specify a string to be written. * ext/openssl/lib/openssl/buffering.rb (OpenSSL::Buffering#gets): refine regexp for end-of-line. * ext/opnessl/lib/openssl/ssl.rb (OpenSSL::SSL::SocketForwarder#listen): fix typo. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@6550 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* This commit was manufactured by cvs2svn to create branch 'ruby_1_8'.(no author)2004-06-272-0/+269
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@6531 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* This commit was manufactured by cvs2svn to create branch 'ruby_1_8'.(no author)2004-05-211-0/+142
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@6382 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test_x509crl.rb (test_basic): add test for CRL issuer.gotoyuzo2004-05-212-0/+3
| | | | | | | | * test_x509store.rb: test for OpenSSL::X509::Store * utils.rb (issue_crl): should set issuer's subject. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@6381 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * rescue LoadError. [ruby-dev:23539]gotoyuzo2004-05-194-7/+35
| | | | git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@6367 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* This commit was manufactured by cvs2svn to create branch 'ruby_1_8'.(no author)2004-05-185-0/+799
git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@6353 b2dd03c8-39d4-4d8f-98ff-823fe69b080e