Latest update
This commit is contained in:
@@ -15,7 +15,7 @@ use OpenSSL::Test qw/:DEFAULT srctop_file/;
|
||||
|
||||
setup("test_req");
|
||||
|
||||
plan tests => 9;
|
||||
plan tests => 10;
|
||||
|
||||
require_ok(srctop_file('test','recipes','tconversion.pl'));
|
||||
|
||||
@@ -58,6 +58,25 @@ subtest "generating certificate requests" => sub {
|
||||
"Verifying signature on request");
|
||||
};
|
||||
|
||||
subtest "generating SM2 certificate requests" => sub {
|
||||
plan tests => 2;
|
||||
|
||||
SKIP: {
|
||||
skip "SM2 is not supported by this OpenSSL build", 2
|
||||
if disabled("sm2");
|
||||
ok(run(app(["openssl", "req", "-config", srctop_file("test", "test.cnf"),
|
||||
"-new", "-key", srctop_file("test", "certs", "sm2.key"),
|
||||
"-sigopt", "sm2_id:1234567812345678",
|
||||
"-out", "testreq.pem", "-sm3"])),
|
||||
"Generating SM2 certificate request");
|
||||
|
||||
ok(run(app(["openssl", "req", "-config", srctop_file("test", "test.cnf"),
|
||||
"-verify", "-in", "testreq.pem", "-noout",
|
||||
"-sm2-id", "1234567812345678", "-sm3"])),
|
||||
"Verifying signature on SM2 certificate request");
|
||||
}
|
||||
};
|
||||
|
||||
my @openssl_args = ("req", "-config", srctop_file("apps", "openssl.cnf"));
|
||||
|
||||
run_conversion('req conversions',
|
||||
|
||||
Reference in New Issue
Block a user