提交 a2318e86 编写于 作者: D Dr. Stephen Henson

Fix typo. Add EVP_PKEY_CTX control function for later use by command line

utilities.
上级 a9164153
......@@ -2304,6 +2304,24 @@ int bio_to_mem(unsigned char **out, int maxlen, BIO *in)
return ret;
}
int pkey_ctrl_string(BIO *err, EVP_PKEY_CTX *ctx, char *value)
{
char *stmp, *vtmp = NULL;
stmp = BUF_strdup(value);
int rv;
if (!stmp)
return -1;
vtmp = strchr(stmp, ':');
if (vtmp)
{
*vtmp = 0;
vtmp++;
}
rv = EVP_PKEY_CTX_ctrl_str(ctx, stmp, vtmp);
OPENSSL_free(stmp);
return rv;
}
static void nodes_print(BIO *out, const char *name,
STACK_OF(X509_POLICY_NODE) *nodes)
{
......
......@@ -168,7 +168,7 @@ int MAIN(int argc, char **argv)
hexdump = 1;
else if(!strcmp(*argv, "-sign"))
pkey_op = EVP_PKEY_OP_SIGN;
else if(!strcmp(*argv, "-verifyr"))
else if(!strcmp(*argv, "-verify"))
pkey_op = EVP_PKEY_OP_VERIFY;
else if(!strcmp(*argv, "-verifyrecover"))
pkey_op = EVP_PKEY_OP_VERIFYRECOVER;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册