mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* ext/openssl/ossl_asn1.c (ossl_asn1_cons_to_der): Add an additional
EOC for infinite length Constructives that are supposed to be encoded with explicit tagging. Also tabify method correctly. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31698 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
9253bd7797
commit
efd99b781b
2 changed files with 51 additions and 31 deletions
11
ChangeLog
11
ChangeLog
|
@ -1,3 +1,14 @@
|
|||
Mon May 23 04:03:46 2011 Martin Bosslet <Martin.Bosslet@googlemail.com>
|
||||
|
||||
* ext/openssl/ossl_asn1.c (ossl_asn1_cons_to_der): Add an additional
|
||||
EOC for infinite length Constructives that are supposed to be encoded
|
||||
with explicit tagging. Also tabify method correctly.
|
||||
|
||||
Mon May 23 03:44:39 2011 Martin Bosslet <Martin.Bosslet@googlemail.com>
|
||||
|
||||
* ext/openssl/ossl_asn1.c (ossl_asn1data_to_der): Remove redundant
|
||||
flag tmp_cons.
|
||||
|
||||
Mon May 23 00:35:00 2001 Kenta Murata <mrkn@mrkn.jp>
|
||||
|
||||
* bignum.c (dump_bignum, bigmul1_balance, big_split, biglsh_bang,
|
||||
|
|
|
@ -1188,6 +1188,15 @@ ossl_asn1cons_to_der(VALUE self)
|
|||
}
|
||||
memcpy(p, RSTRING_PTR(value), RSTRING_LEN(value));
|
||||
p += RSTRING_LEN(value);
|
||||
|
||||
/* In this case we need an additional EOC (one for the explicit part and
|
||||
* one for the Constructive itself. The EOC for the Constructive is
|
||||
* supplied by the user, but that for the "explicit wrapper" must be
|
||||
* added here.
|
||||
*/
|
||||
if (explicit && inf_length == Qtrue) {
|
||||
ASN1_put_eoc(&p);
|
||||
}
|
||||
ossl_str_adjust(str, p);
|
||||
|
||||
return str;
|
||||
|
|
Loading…
Reference in a new issue