Deleted Added
full compact
30-test_evp.t (1.1.1.4) 30-test_evp.t (1.1.1.5)
1#! /usr/bin/env perl
1#! /usr/bin/env perl
2# Copyright 2015-2022 The OpenSSL Project Authors. All Rights Reserved.
2# Copyright 2015-2023 The OpenSSL Project Authors. All Rights Reserved.
3#
4# Licensed under the Apache License 2.0 (the "License"). You may not use
5# this file except in compliance with the License. You can obtain a copy
6# in the file LICENSE in the source distribution or at
7# https://www.openssl.org/source/license.html
8
9
10use strict;

--- 157 unchanged lines hidden (view full) ---

168 if exists $opts{expected} && $errline =~ m/$opts{expected}/;
169 }
170 close $in;
171 # $tmpfile is kept to help with investigation in case of failure
172 return $res && $found;
173}
174
175SKIP: {
3#
4# Licensed under the Apache License 2.0 (the "License"). You may not use
5# this file except in compliance with the License. You can obtain a copy
6# in the file LICENSE in the source distribution or at
7# https://www.openssl.org/source/license.html
8
9
10use strict;

--- 157 unchanged lines hidden (view full) ---

168 if exists $opts{expected} && $errline =~ m/$opts{expected}/;
169 }
170 close $in;
171 # $tmpfile is kept to help with investigation in case of failure
172 return $res && $found;
173}
174
175SKIP: {
176 skip "DSA not disabled", 2 if !disabled("dsa");
176 skip "DSA not disabled or ERR disabled", 2
177 if !disabled("dsa") || disabled("err");
177
178 ok(test_errors(key => 'server-dsa-key.pem',
179 out => 'server-dsa-key.err'),
180 "expected error loading unsupported dsa private key");
181 ok(test_errors(key => 'server-dsa-pubkey.pem',
182 out => 'server-dsa-pubkey.err',
183 args => [ '-pubin' ],
184 expected => 'unsupported'),
185 "expected error loading unsupported dsa public key");
186}
187
188SKIP: {
189 skip "SM2 not disabled", 1 if !disabled("sm2");
190
191 ok(test_errors(key => 'sm2.key', out => 'sm2.err'),
192 "expected error loading unsupported sm2 private key");
193}
178
179 ok(test_errors(key => 'server-dsa-key.pem',
180 out => 'server-dsa-key.err'),
181 "expected error loading unsupported dsa private key");
182 ok(test_errors(key => 'server-dsa-pubkey.pem',
183 out => 'server-dsa-pubkey.err',
184 args => [ '-pubin' ],
185 expected => 'unsupported'),
186 "expected error loading unsupported dsa public key");
187}
188
189SKIP: {
190 skip "SM2 not disabled", 1 if !disabled("sm2");
191
192 ok(test_errors(key => 'sm2.key', out => 'sm2.err'),
193 "expected error loading unsupported sm2 private key");
194}