EBCDIC bug fix from main branch.
This commit is contained in:
parent
c7410f2693
commit
60b3b2c9d0
2 changed files with 23 additions and 6 deletions
3
CHANGES
3
CHANGES
|
@ -13,6 +13,9 @@
|
||||||
return NULL from CONF_get_section.
|
return NULL from CONF_get_section.
|
||||||
[Bodo Moeller]
|
[Bodo Moeller]
|
||||||
|
|
||||||
|
*) Fix potential buffer overrun for EBCDIC.
|
||||||
|
[Ulf Moeller]
|
||||||
|
|
||||||
*) Tolerate nonRepudiation as being valid for S/MIME signing and certSign
|
*) Tolerate nonRepudiation as being valid for S/MIME signing and certSign
|
||||||
keyUsage if basicConstraints absent for a CA.
|
keyUsage if basicConstraints absent for a CA.
|
||||||
[Steve Henson]
|
[Steve Henson]
|
||||||
|
|
|
@ -85,9 +85,16 @@ void X509V3_EXT_val_prn(BIO *out, STACK_OF(CONF_VALUE) *val, int indent, int ml)
|
||||||
else BIO_printf(out, "%s:%s", nval->name, nval->value);
|
else BIO_printf(out, "%s:%s", nval->name, nval->value);
|
||||||
#else
|
#else
|
||||||
else {
|
else {
|
||||||
char tmp[10240]; /* 10k is BIO_printf's limit anyway */
|
int len;
|
||||||
ascii2ebcdic(tmp, nval->value, strlen(nval->value)+1);
|
char *tmp;
|
||||||
BIO_printf(out, "%s:%s", nval->name, tmp);
|
len = strlen(nval->value)+1;
|
||||||
|
tmp = OPENSSL_malloc(len);
|
||||||
|
if (tmp)
|
||||||
|
{
|
||||||
|
ascii2ebcdic(tmp, nval->value, len);
|
||||||
|
BIO_printf(out, "%s:%s", nval->name, tmp);
|
||||||
|
OPENSSL_free(tmp);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
if(ml) BIO_puts(out, "\n");
|
if(ml) BIO_puts(out, "\n");
|
||||||
|
@ -115,9 +122,16 @@ int X509V3_EXT_print(BIO *out, X509_EXTENSION *ext, int flag, int indent)
|
||||||
BIO_printf(out, "%*s%s", indent, "", value);
|
BIO_printf(out, "%*s%s", indent, "", value);
|
||||||
#else
|
#else
|
||||||
{
|
{
|
||||||
char tmp[10240]; /* 10k is BIO_printf's limit anyway */
|
int len;
|
||||||
ascii2ebcdic(tmp, value, strlen(value)+1);
|
char *tmp;
|
||||||
BIO_printf(out, "%*s%s", indent, "", tmp);
|
len = strlen(value)+1;
|
||||||
|
tmp = OPENSSL_malloc(len);
|
||||||
|
if (tmp)
|
||||||
|
{
|
||||||
|
ascii2ebcdic(tmp, value, len);
|
||||||
|
BIO_printf(out, "%*s%s", indent, "", tmp);
|
||||||
|
OPENSSL_free(tmp);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
} else if(method->i2v) {
|
} else if(method->i2v) {
|
||||||
|
|
Loading…
Reference in a new issue