]>
Commit | Line | Data |
---|---|---|
b20b78b7 | 1 | =pod |
625c781d | 2 | {- OpenSSL::safe::output_do_not_edit_headers(); -} |
9fcb9702 | 3 | |
b20b78b7 UM |
4 | =head1 NAME |
5 | ||
b6b66573 | 6 | openssl-speed - test library performance |
b20b78b7 UM |
7 | |
8 | =head1 SYNOPSIS | |
9 | ||
10 | B<openssl speed> | |
0ae9e292 | 11 | [B<-help>] |
a0474357 | 12 | [B<-elapsed>] |
e8769719 RS |
13 | [B<-evp> I<algo>] |
14 | [B<-hmac> I<algo>] | |
15 | [B<-cmac> I<algo>] | |
65718c51 RS |
16 | [B<-mb>] |
17 | [B<-aead>] | |
18 | [B<-multi> I<num>] | |
19 | [B<-async_jobs> I<num>] | |
20 | [B<-misalign> I<num>] | |
a0474357 | 21 | [B<-decrypt>] |
e8769719 RS |
22 | [B<-primes> I<num>] |
23 | [B<-seconds> I<num>] | |
24 | [B<-bytes> I<num>] | |
65718c51 | 25 | [B<-mr>] |
9fcb9702 | 26 | {- $OpenSSL::safe::opt_r_synopsis -} |
d55e4487 | 27 | {- $OpenSSL::safe::opt_engine_synopsis -}{- $OpenSSL::safe::opt_provider_synopsis -} |
b1c0cc24 | 28 | [I<algorithm> ...] |
b20b78b7 UM |
29 | |
30 | =head1 DESCRIPTION | |
31 | ||
32 | This command is used to test the performance of cryptographic algorithms. | |
33 | ||
34 | =head1 OPTIONS | |
35 | ||
5270e702 RL |
36 | =over 4 |
37 | ||
0ae9e292 RS |
38 | =item B<-help> |
39 | ||
40 | Print out a usage message. | |
41 | ||
a0474357 RS |
42 | =item B<-elapsed> |
43 | ||
44ca7565 AP |
44 | When calculating operations- or bytes-per-second, use wall-clock time |
45 | instead of CPU user time as divisor. It can be useful when testing speed | |
46 | of hardware engines. | |
a0474357 | 47 | |
e8769719 | 48 | =item B<-evp> I<algo> |
a0474357 RS |
49 | |
50 | Use the specified cipher or message digest algorithm via the EVP interface. | |
2f0ea936 RL |
51 | If I<algo> is an AEAD cipher, then you can pass B<-aead> to benchmark a |
52 | TLS-like sequence. And if I<algo> is a multi-buffer capable cipher, e.g. | |
44ca7565 | 53 | aes-128-cbc-hmac-sha1, then B<-mb> will time multi-buffer operation. |
a0474357 | 54 | |
b41ebb99 TM |
55 | To see the algorithms supported with this option, use |
56 | C<openssl list -digest-algorithms> or C<openssl list -cipher-algorithms> | |
57 | command. | |
58 | ||
65718c51 RS |
59 | =item B<-multi> I<num> |
60 | ||
61 | Run multiple operations in parallel. | |
62 | ||
63 | =item B<-async_jobs> I<num> | |
64 | ||
65 | Enable async mode and start specified number of jobs. | |
66 | ||
67 | =item B<-misalign> I<num> | |
68 | ||
69 | Misalign the buffers by the specified number of bytes. | |
70 | ||
e8769719 | 71 | =item B<-hmac> I<digest> |
f88b9b79 P |
72 | |
73 | Time the HMAC algorithm using the specified message digest. | |
74 | ||
e8769719 | 75 | =item B<-cmac> I<cipher> |
9bba2c4c | 76 | |
35a810bb RL |
77 | Time the CMAC algorithm using the specified cipher e.g. |
78 | C<openssl speed -cmac aes128>. | |
9bba2c4c | 79 | |
a0474357 RS |
80 | =item B<-decrypt> |
81 | ||
82 | Time the decryption instead of encryption. Affects only the EVP testing. | |
83 | ||
359efeac DDO |
84 | =item B<-mb> |
85 | ||
86 | Enable multi-block mode on EVP-named cipher. | |
87 | ||
88 | =item B<-aead> | |
89 | ||
90 | Benchmark EVP-named AEAD cipher in TLS-like sequence. | |
91 | ||
e8769719 | 92 | =item B<-primes> I<num> |
665d899f | 93 | |
2f0ea936 | 94 | Generate a I<num>-prime RSA key and use it to run the benchmarks. This option |
665d899f PY |
95 | is only effective if RSA algorithm is specified to test. |
96 | ||
e8769719 | 97 | =item B<-seconds> I<num> |
64daf14d | 98 | |
2f0ea936 | 99 | Run benchmarks for I<num> seconds. |
64daf14d | 100 | |
e8769719 | 101 | =item B<-bytes> I<num> |
64daf14d | 102 | |
2f0ea936 | 103 | Run benchmarks on I<num>-byte buffers. Affects ciphers, digests and the CSPRNG. |
378c50f6 KB |
104 | The limit on the size of the buffer is INT_MAX - 64 bytes, which for a 32-bit |
105 | int would be 2147483583 bytes. | |
64daf14d | 106 | |
65718c51 RS |
107 | =item B<-mr> |
108 | ||
109 | Produce the summary in a mechanical, machine-readable, format. | |
110 | ||
9fcb9702 RS |
111 | {- $OpenSSL::safe::opt_r_item -} |
112 | ||
018aaeb4 RS |
113 | {- $OpenSSL::safe::opt_engine_item -} |
114 | ||
6bd4e3f2 P |
115 | {- $OpenSSL::safe::opt_provider_item -} |
116 | ||
b1c0cc24 | 117 | =item I<algorithm> ... |
5270e702 | 118 | |
35a810bb | 119 | If any I<algorithm> is given, then those algorithms are tested, otherwise a |
44ca7565 | 120 | pre-compiled grand selection is tested. |
b20b78b7 | 121 | |
eaad02a7 LJ |
122 | =back |
123 | ||
b41ebb99 TM |
124 | =head1 BUGS |
125 | ||
126 | The I<algorithm> can be selected only from a pre-compiled subset of things | |
127 | that the C<openssl speed> command knows about. To test any additional digest | |
128 | or cipher algorithm supported by OpenSSL use the C<-evp> option. | |
129 | ||
130 | There is no way to test the speed of any additional public key algorithms | |
131 | supported by third party providers with the C<openssl speed> command. | |
132 | ||
0f221d9c P |
133 | =head1 HISTORY |
134 | ||
135 | The B<-engine> option was deprecated in OpenSSL 3.0. | |
136 | ||
e2f92610 RS |
137 | =head1 COPYRIGHT |
138 | ||
fecb3aae | 139 | Copyright 2000-2022 The OpenSSL Project Authors. All Rights Reserved. |
e2f92610 | 140 | |
449040b4 | 141 | Licensed under the Apache License 2.0 (the "License"). You may not use |
e2f92610 RS |
142 | this file except in compliance with the License. You can obtain a copy |
143 | in the file LICENSE in the source distribution or at | |
144 | L<https://www.openssl.org/source/license.html>. | |
145 | ||
146 | =cut |