Reencode certificates in X509_sign_ctx.
Reencode certificates in X509_sign_ctx as well as X509_sign.
This was causing a problem in the x509 application when it modified an
existing certificate.
(cherry picked from commit c6d8adb8a4
)
This commit is contained in:
parent
29a546720b
commit
b9e84f007f
1 changed files with 1 additions and 0 deletions
|
@ -97,6 +97,7 @@ int X509_sign(X509 *x, EVP_PKEY *pkey, const EVP_MD *md)
|
|||
|
||||
int X509_sign_ctx(X509 *x, EVP_MD_CTX *ctx)
|
||||
{
|
||||
x->cert_info->enc.modified = 1;
|
||||
return ASN1_item_sign_ctx(ASN1_ITEM_rptr(X509_CINF),
|
||||
x->cert_info->signature,
|
||||
x->sig_alg, x->signature, x->cert_info, ctx);
|
||||
|
|
Loading…
Reference in a new issue