mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* ext/openssl/ossl.c: surpress warning: shorten-64-to-32.
* ext/openssl/ossl.h: ditto. * ext/openssl/ossl_asn1.c: ditto. * ext/openssl/ossl_bio.c: ditto. * ext/openssl/ossl_bn.c: ditto. * ext/openssl/ossl_cipher.c: ditto. * ext/openssl/ossl_hmac.c: ditto. * ext/openssl/ossl_ns_spki.c: ditto. * ext/openssl/ossl_ocsp.c: ditto. * ext/openssl/ossl_pkcs5.c: ditto. * ext/openssl/ossl_pkey.c: ditto. * ext/openssl/ossl_pkey_dh.c: ditto. * ext/openssl/ossl_pkey_dsa.c: ditto. * ext/openssl/ossl_pkey_ec.c: ditto. * ext/openssl/ossl_pkey_rsa.c: ditto. * ext/openssl/ossl_rand.c: ditto. * ext/openssl/ossl_ssl.c: ditto. * ext/openssl/ossl_x509ext.c: ditto. * ext/openssl/ossl_x509name.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31166 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
643f90d8db
commit
3a16cc24e8
20 changed files with 110 additions and 71 deletions
|
@ -396,7 +396,7 @@ ossl_dsa_sign(VALUE self, VALUE data)
|
|||
ossl_raise(eDSAError, "Private DSA key needed!");
|
||||
}
|
||||
str = rb_str_new(0, ossl_dsa_buf_size(pkey));
|
||||
if (!DSA_sign(0, (unsigned char *)RSTRING_PTR(data), RSTRING_LEN(data),
|
||||
if (!DSA_sign(0, (unsigned char *)RSTRING_PTR(data), RSTRING_LENINT(data),
|
||||
(unsigned char *)RSTRING_PTR(str),
|
||||
&buf_len, pkey->pkey.dsa)) { /* type is ignored (0) */
|
||||
ossl_raise(eDSAError, NULL);
|
||||
|
@ -421,8 +421,8 @@ ossl_dsa_verify(VALUE self, VALUE digest, VALUE sig)
|
|||
StringValue(digest);
|
||||
StringValue(sig);
|
||||
/* type is ignored (0) */
|
||||
ret = DSA_verify(0, (unsigned char *)RSTRING_PTR(digest), RSTRING_LEN(digest),
|
||||
(unsigned char *)RSTRING_PTR(sig), RSTRING_LEN(sig), pkey->pkey.dsa);
|
||||
ret = DSA_verify(0, (unsigned char *)RSTRING_PTR(digest), RSTRING_LENINT(digest),
|
||||
(unsigned char *)RSTRING_PTR(sig), RSTRING_LENINT(sig), pkey->pkey.dsa);
|
||||
if (ret < 0) {
|
||||
ossl_raise(eDSAError, NULL);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue