本地签发证书时,密钥用法不copy原证书。https://git.mesalab.cn/tango/certstore/issues/8
This commit is contained in:
@@ -666,9 +666,7 @@ X509 * ssl_x509_forge(X509 * cacrt, EVP_PKEY * cakey, X509 * origcrt, EVP_PKEY *
|
|||||||
if (rv == -1)
|
if (rv == -1)
|
||||||
goto errout;
|
goto errout;
|
||||||
|
|
||||||
rv = ssl_x509_v3ext_copy_by_nid(crt, origcrt,
|
//Not copy keyUsage, because RSA is not compatibel with "Key Agreement".
|
||||||
NID_key_usage);
|
|
||||||
if (rv == 0)
|
|
||||||
rv = ssl_x509_v3ext_add(&ctx, crt, "keyUsage",
|
rv = ssl_x509_v3ext_add(&ctx, crt, "keyUsage",
|
||||||
"digitalSignature,"
|
"digitalSignature,"
|
||||||
"keyEncipherment");
|
"keyEncipherment");
|
||||||
|
|||||||
Reference in New Issue
Block a user