openssl版本
# openssl version
OpenSSL 1.1.1g 21 Apr 2020
openssl支持指令
# openssl help
Standard commands
asn1parse ca ciphers cms
crl crl2pkcs7 dgst dhparam
dsa dsaparam ec ecparam
enc engine errstr gendsa
genpkey genrsa help list
nseq ocsp passwd pkcs12
pkcs7 pkcs8 pkey pkeyparam
pkeyutl prime rand rehash
req rsa rsautl s_client
s_server s_time sess_id smime
speed spkac srp storeutl
ts verify version x509
Message Digest commands (see the `dgst' command for more details)
blake2b512 blake2s256 gost md4
md5 mdc2 rmd160 sha1
sha224 sha256 sha3-224 sha3-256
sha3-384 sha3-512 sha384 sha512
sha512-224 sha512-256 shake128 shake256
sm3
Cipher commands (see the `enc' command for more details)
aes-128-cbc aes-128-ecb aes-192-cbc aes-192-ecb
aes-256-cbc aes-256-ecb aria-128-cbc aria-128-cfb
aria-128-cfb1 aria-128-cfb8 aria-128-ctr aria-128-ecb
aria-128-ofb aria-192-cbc aria-192-cfb aria-192-cfb1
aria-192-cfb8 aria-192-ctr aria-192-ecb aria-192-ofb
aria-256-cbc aria-256-cfb aria-256-cfb1 aria-256-cfb8
aria-256-ctr aria-256-ecb aria-256-ofb base64
bf bf-cbc bf-cfb bf-ecb
bf-ofb camellia-128-cbc camellia-128-ecb camellia-192-cbc
camellia-192-ecb camellia-256-cbc camellia-256-ecb cast
cast-cbc cast5-cbc cast5-cfb cast5-ecb
cast5-ofb des des-cbc des-cfb
des-ecb des-ede des-ede-cbc des-ede-cfb
des-ede-ofb des-ede3 des-ede3-cbc des-ede3-cfb
des-ede3-ofb des-ofb des3 desx
idea idea-cbc idea-cfb idea-ecb
idea-ofb rc2 rc2-40-cbc rc2-64-cbc
rc2-cbc rc2-cfb rc2-ecb rc2-ofb
rc4 rc4-40 seed seed-cbc
seed-cfb seed-ecb seed-ofb sm4-cbc
sm4-cfb sm4-ctr sm4-ecb sm4-ofb
openssl测试rsa签名结果
# openssl speed rsa
Doing 512 bits private rsa's for 10s: 2759 512 bits private RSA's in 10.01s
Doing 512 bits public rsa's for 10s: 32965 512 bits public RSA's in 10.00s
Doing 1024 bits private rsa's for 10s: 502 1024 bits private RSA's in 10.02s
Doing 1024 bits public rsa's for 10s: 10849 1024 bits public RSA's in 10.00s
Doing 2048 bits private rsa's for 10s: 82 2048 bits private RSA's in 10.07s
Doing 2048 bits public rsa's for 10s: 3219 2048 bits public RSA's in 10.00s
Doing 3072 bits private rsa's for 10s: 29 3072 bits private RSA's in 10.33s
Doing 3072 bits public rsa's for 10s: 1511 3072 bits public RSA's in 10.00s
Doing 4096 bits private rsa's for 10s: 13 4096 bits private RSA's in 10.41s
Doing 4096 bits public rsa's for 10s: 909 4096 bits public RSA's in 10.00s
Doing 7680 bits private rsa's for 10s: 3 7680 bits private RSA's in 14.16s
Doing 7680 bits public rsa's for 10s: 258 7680 bits public RSA's in 9.86s
Doing 15360 bits private rsa's for 10s: 1 15360 bits private RSA's in 35.26s
Doing 15360 bits public rsa's for 10s: 67 15360 bits public RSA's in 10.04s
OpenSSL 1.1.1g 21 Apr 2020
built on: Wed Nov 17 12:44:32 2021 UTC
options:bn(64,32) rc4(int) des(long) aes(partial) idea(int) blowfish(ptr)
compiler: /toolchain/msdk-4.8.5-mips-EB-4.4-u0.9.33-m32ut-180206/bin/msdk-linux-gcc -fPIC -Wa,--noexecstack -O2 -fno-builtin -fPIC -DEMBED -Dlinux -D__linux__ -Dunix -D_USE_RSDK_WRAPPER_ -DOPENSSL_PIC -D_REENTRANT -DNDEBUG
sign verify sign/s verify/s
rsa 512 bits 0.003628s 0.000303s 275.6 3296.5
rsa 1024 bits 0.019960s 0.000922s 50.1 1084.9
rsa 2048 bits 0.122805s 0.003107s 8.1 321.9
rsa 3072 bits 0.356207s 0.006618s 2.8 151.1
rsa 4096 bits 0.800769s 0.011001s 1.2 90.9
rsa 7680 bits 4.720000s 0.038217s 0.2 26.2
rsa 15360 bits 35.260000s 0.149851s 0.0 6.7
从结果可以看出,1024bits的只有50次/秒,2048bits的只有8次/秒,所以要想webs支持https,签名只能选择1024bits