TA的每日心情 | 奋斗 2019-10-1 12:54 |
---|
签到天数: 313 天 连续签到: 1 天 [LV.8]以坛为家I
|
OpenSSL开放式安全套接层协议是一个强大的安全套接字层密码库,囊括主要的密码算法、常用的密钥和证书封装管理功能及SSL协议,并提供丰富的应用程序供测试或其它目的使用,OpenSSL整个软件包大概可以分成三个主要的功能部分:SSL协议库、应用程序以及密码算法库。OpenSSL的目录结构自然也是围绕这三个功能部分进行规划的。基本功能有:主要的密码算法(MD5、SHA、DH、BASE64等等)、常用的密钥和证书封装管理功能以及SSL协议,并提供了丰富的应用程序供测试或其它目的使用,辅助功能:如从口令生成密钥的API,证书签发和管理中的配置文件机制等,ESPRESSObin开发板支持使用OpenSSL协议,但是需要安装配置,下面介绍具体实现方法
首先给开发板上电,然后将开发板的MicroUSB口用手机数据线插到电脑,查看设备管理器的串口号,按笔者之前帖子进行串口诊断,然后将开发板联网,输入如下命令安装openssl组件
apt-get install openssl libssl-dev libssl-ocaml libssl1.0.0然后输入下面命令查看支持的加密方式openssl ciphers -v返回如下ECDHE-RSA-AES256-GCM-SHA384 TLSv1.2 Kx=ECDH Au=RSA Enc=AESGCM(256) Mac=AEADECDHE-ECDSA-AES256-GCM-SHA384 TLSv1.2 Kx=ECDH Au=ECDSA Enc=AESGCM(256) Mac=AEADECDHE-RSA-AES256-SHA384 TLSv1.2 Kx=ECDH Au=RSA Enc=AES(256) Mac=SHA384ECDHE-ECDSA-AES256-SHA384 TLSv1.2 Kx=ECDH Au=ECDSA Enc=AES(256) Mac=SHA384ECDHE-RSA-AES256-SHA SSLv3 Kx=ECDH Au=RSA Enc=AES(256) Mac=SHA1ECDHE-ECDSA-AES256-SHA SSLv3 Kx=ECDH Au=ECDSA Enc=AES(256) Mac=SHA1SRP-DSS-AES-256-CBC-SHA SSLv3 Kx=SRP Au=DSS Enc=AES(256) Mac=SHA1SRP-RSA-AES-256-CBC-SHA SSLv3 Kx=SRP Au=RSA Enc=AES(256) Mac=SHA1SRP-AES-256-CBC-SHA SSLv3 Kx=SRP Au=SRP Enc=AES(256) Mac=SHA1DHE-DSS-AES256-GCM-SHA384 TLSv1.2 Kx=DH Au=DSS Enc=AESGCM(256) Mac=AEADDHE-RSA-AES256-GCM-SHA384 TLSv1.2 Kx=DH Au=RSA Enc=AESGCM(256) Mac=AEADDHE-RSA-AES256-SHA256 TLSv1.2 Kx=DH Au=RSA Enc=AES(256) Mac=SHA256DHE-DSS-AES256-SHA256 TLSv1.2 Kx=DH Au=DSS Enc=AES(256) Mac=SHA256DHE-RSA-AES256-SHA SSLv3 Kx=DH Au=RSA Enc=AES(256) Mac=SHA1DHE-DSS-AES256-SHA SSLv3 Kx=DH Au=DSS Enc=AES(256) Mac=SHA1DHE-RSA-CAMELLIA256-SHA SSLv3 Kx=DH Au=RSA Enc=Camellia(256) Mac=SHA1DHE-DSS-CAMELLIA256-SHA SSLv3 Kx=DH Au=DSS Enc=Camellia(256) Mac=SHA1ECDH-RSA-AES256-GCM-SHA384 TLSv1.2 Kx=ECDH/RSA Au=ECDH Enc=AESGCM(256) Mac=AEADECDH-ECDSA-AES256-GCM-SHA384 TLSv1.2 Kx=ECDH/ECDSA Au=ECDH Enc=AESGCM(256) Mac=AEADECDH-RSA-AES256-SHA384 TLSv1.2 Kx=ECDH/RSA Au=ECDH Enc=AES(256) Mac=SHA384ECDH-ECDSA-AES256-SHA384 TLSv1.2 Kx=ECDH/ECDSA Au=ECDH Enc=AES(256) Mac=SHA384ECDH-RSA-AES256-SHA SSLv3 Kx=ECDH/RSA Au=ECDH Enc=AES(256) Mac=SHA1ECDH-ECDSA-AES256-SHA SSLv3 Kx=ECDH/ECDSA Au=ECDH Enc=AES(256) Mac=SHA1AES256-GCM-SHA384 TLSv1.2 Kx=RSA Au=RSA Enc=AESGCM(256) Mac=AEADAES256-SHA256 TLSv1.2 Kx=RSA Au=RSA Enc=AES(256) Mac=SHA256AES256-SHA SSLv3 Kx=RSA Au=RSA Enc=AES(256) Mac=SHA1CAMELLIA256-SHA SSLv3 Kx=RSA Au=RSA Enc=Camellia(256) Mac=SHA1PSK-AES256-CBC-SHA SSLv3 Kx=PSK Au=PSK Enc=AES(256) Mac=SHA1ECDHE-RSA-DES-CBC3-SHA SSLv3 Kx=ECDH Au=RSA Enc=3DES(168) Mac=SHA1ECDHE-ECDSA-DES-CBC3-SHA SSLv3 Kx=ECDH Au=ECDSA Enc=3DES(168) Mac=SHA1SRP-DSS-3DES-EDE-CBC-SHA SSLv3 Kx=SRP Au=DSS Enc=3DES(168) Mac=SHA1SRP-RSA-3DES-EDE-CBC-SHA SSLv3 Kx=SRP Au=RSA Enc=3DES(168) Mac=SHA1SRP-3DES-EDE-CBC-SHA SSLv3 Kx=SRP Au=SRP Enc=3DES(168) Mac=SHA1EDH-RSA-DES-CBC3-SHA SSLv3 Kx=DH Au=RSA Enc=3DES(168) Mac=SHA1EDH-DSS-DES-CBC3-SHA SSLv3 Kx=DH Au=DSS Enc=3DES(168) Mac=SHA1ECDH-RSA-DES-CBC3-SHA SSLv3 Kx=ECDH/RSA Au=ECDH Enc=3DES(168) Mac=SHA1ECDH-ECDSA-DES-CBC3-SHA SSLv3 Kx=ECDH/ECDSA Au=ECDH Enc=3DES(168) Mac=SHA1DES-CBC3-SHA SSLv3 Kx=RSA Au=RSA Enc=3DES(168) Mac=SHA1PSK-3DES-EDE-CBC-SHA SSLv3 Kx=PSK Au=PSK Enc=3DES(168) Mac=SHA1ECDHE-RSA-AES128-GCM-SHA256 TLSv1.2 Kx=ECDH Au=RSA Enc=AESGCM(128) Mac=AEADECDHE-ECDSA-AES128-GCM-SHA256 TLSv1.2 Kx=ECDH Au=ECDSA Enc=AESGCM(128) Mac=AEADECDHE-RSA-AES128-SHA256 TLSv1.2 Kx=ECDH Au=RSA Enc=AES(128) Mac=SHA256ECDHE-ECDSA-AES128-SHA256 TLSv1.2 Kx=ECDH Au=ECDSA Enc=AES(128) Mac=SHA256ECDHE-RSA-AES128-SHA SSLv3 Kx=ECDH Au=RSA Enc=AES(128) Mac=SHA1ECDHE-ECDSA-AES128-SHA SSLv3 Kx=ECDH Au=ECDSA Enc=AES(128) Mac=SHA1SRP-DSS-AES-128-CBC-SHA SSLv3 Kx=SRP Au=DSS Enc=AES(128) Mac=SHA1SRP-RSA-AES-128-CBC-SHA SSLv3 Kx=SRP Au=RSA Enc=AES(128) Mac=SHA1SRP-AES-128-CBC-SHA SSLv3 Kx=SRP Au=SRP Enc=AES(128) Mac=SHA1DHE-DSS-AES128-GCM-SHA256 TLSv1.2 Kx=DH Au=DSS Enc=AESGCM(128) Mac=AEADDHE-RSA-AES128-GCM-SHA256 TLSv1.2 Kx=DH Au=RSA Enc=AESGCM(128) Mac=AEADDHE-RSA-AES128-SHA256 TLSv1.2 Kx=DH Au=RSA Enc=AES(128) Mac=SHA256DHE-DSS-AES128-SHA256 TLSv1.2 Kx=DH Au=DSS Enc=AES(128) Mac=SHA256DHE-RSA-AES128-SHA SSLv3 Kx=DH Au=RSA Enc=AES(128) Mac=SHA1DHE-DSS-AES128-SHA SSLv3 Kx=DH Au=DSS Enc=AES(128) Mac=SHA1DHE-RSA-SEED-SHA SSLv3 Kx=DH Au=RSA Enc=SEED(128) Mac=SHA1DHE-DSS-SEED-SHA SSLv3 Kx=DH Au=DSS Enc=SEED(128) Mac=SHA1DHE-RSA-CAMELLIA128-SHA SSLv3 Kx=DH Au=RSA Enc=Camellia(128) Mac=SHA1DHE-DSS-CAMELLIA128-SHA SSLv3 Kx=DH Au=DSS Enc=Camellia(128) Mac=SHA1ECDH-RSA-AES128-GCM-SHA256 TLSv1.2 Kx=ECDH/RSA Au=ECDH Enc=AESGCM(128) Mac=AEADECDH-ECDSA-AES128-GCM-SHA256 TLSv1.2 Kx=ECDH/ECDSA Au=ECDH Enc=AESGCM(128) Mac=AEADECDH-RSA-AES128-SHA256 TLSv1.2 Kx=ECDH/RSA Au=ECDH Enc=AES(128) Mac=SHA256ECDH-ECDSA-AES128-SHA256 TLSv1.2 Kx=ECDH/ECDSA Au=ECDH Enc=AES(128) Mac=SHA256ECDH-RSA-AES128-SHA SSLv3 Kx=ECDH/RSA Au=ECDH Enc=AES(128) Mac=SHA1ECDH-ECDSA-AES128-SHA SSLv3 Kx=ECDH/ECDSA Au=ECDH Enc=AES(128) Mac=SHA1AES128-GCM-SHA256 TLSv1.2 Kx=RSA Au=RSA Enc=AESGCM(128) Mac=AEADAES128-SHA256 TLSv1.2 Kx=RSA Au=RSA Enc=AES(128) Mac=SHA256AES128-SHA SSLv3 Kx=RSA Au=RSA Enc=AES(128) Mac=SHA1SEED-SHA SSLv3 Kx=RSA Au=RSA Enc=SEED(128) Mac=SHA1CAMELLIA128-SHA SSLv3 Kx=RSA Au=RSA Enc=Camellia(128) Mac=SHA1PSK-AES128-CBC-SHA SSLv3 Kx=PSK Au=PSK Enc=AES(128) Mac=SHA1ECDHE-RSA-RC4-SHA SSLv3 Kx=ECDH Au=RSA Enc=RC4(128) Mac=SHA1ECDHE-ECDSA-RC4-SHA SSLv3 Kx=ECDH Au=ECDSA Enc=RC4(128) Mac=SHA1ECDH-RSA-RC4-SHA SSLv3 Kx=ECDH/RSA Au=ECDH Enc=RC4(128) Mac=SHA1ECDH-ECDSA-RC4-SHA SSLv3 Kx=ECDH/ECDSA Au=ECDH Enc=RC4(128) Mac=SHA1RC4-SHA SSLv3 Kx=RSA Au=RSA Enc=RC4(128) Mac=SHA1RC4-MD5 SSLv3 Kx=RSA Au=RSA Enc=RC4(128) Mac=MD5 PSK-RC4-SHA SSLv3 Kx=PSK Au=PSK Enc=RC4(128) Mac=SHA1EDH-RSA-DES-CBC-SHA SSLv3 Kx=DH Au=RSA Enc=DES(56) Mac=SHA1EDH-DSS-DES-CBC-SHA SSLv3 Kx=DH Au=DSS Enc=DES(56) Mac=SHA1DES-CBC-SHA SSLv3 Kx=RSA Au=RSA Enc=DES(56) Mac=SHA1输入下面命令测量openssl速度openssl speed返回如下Doing md4 for 3s on 16 size blocks: 1316204 md4's in 3.00sDoing md4 for 3s on 64 size blocks: 1128906 md4's in 2.99sDoing md4 for 3s on 256 size blocks: 800417 md4's in 3.00sDoing md4 for 3s on 1024 size blocks: 368037 md4's in 3.00sDoing md4 for 3s on 8192 size blocks: 60983 md4's in 3.00sDoing md5 for 3s on 16 size blocks: 1019228 md5's in 3.00sDoing md5 for 3s on 64 size blocks: 858145 md5's in 3.00sDoing md5 for 3s on 256 size blocks: 570934 md5's in 2.99sDoing md5 for 3s on 1024 size blocks: 244087 md5's in 3.00sDoing md5 for 3s on 8192 size blocks: 38492 md5's in 3.00sDoing hmac(md5) for 3s on 16 size blocks: 1275713 hmac(md5)'s in 2.99sDoing hmac(md5) for 3s on 64 size blocks: 1018086 hmac(md5)'s in 3.00sDoing hmac(md5) for 3s on 256 size blocks: 637830 hmac(md5)'s in 3.00sDoing hmac(md5) for 3s on 1024 size blocks: 255503 hmac(md5)'s in 3.00sDoing hmac(md5) for 3s on 8192 size blocks: 38772 hmac(md5)'s in 3.00sDoing sha1 for 3s on 16 size blocks: 896503 sha1's in 3.00sDoing sha1 for 3s on 64 size blocks: 650332 sha1's in 2.99sDoing sha1 for 3s on 256 size blocks: 357609 sha1's in 3.00sDoing sha1 for 3s on 1024 size blocks: 127644 sha1's in 3.00sDoing sha1 for 3s on 8192 size blocks: 18238 sha1's in 2.99sDoing sha256 for 3s on 16 size blocks: 828771 sha256's in 3.00sDoing sha256 for 3s on 64 size blocks: 498831 sha256's in 3.00sDoing sha256 for 3s on 256 size blocks: 227738 sha256's in 3.00sDoing sha256 for 3s on 1024 size blocks: 72021 sha256's in 3.00sDoing sha256 for 3s on 8192 size blocks: 9749 sha256's in 3.00sDoing sha512 for 3s on 16 size blocks: 513239 sha512's in 2.99sDoing sha512 for 3s on 64 size blocks: 513496 sha512's in 3.00sDoing sha512 for 3s on 256 size blocks: 217166 sha512's in 3.00sDoing sha512 for 3s on 1024 size blocks: 79631 sha512's in 2.99sDoing sha512 for 3s on 8192 size blocks: 11528 sha512's in 3.00sDoing whirlpool for 3s on 16 size blocks: 209463 whirlpool's in 3.00sDoing whirlpool for 3s on 64 size blocks: 107109 whirlpool's in 3.00sDoing whirlpool for 3s on 256 size blocks: 43367 whirlpool's in 2.99sDoing whirlpool for 3s on 1024 size blocks: 12836 whirlpool's in 3.00sDoing whirlpool for 3s on 8192 size blocks: 1694 whirlpool's in 3.00sDoing rmd160 for 3s on 16 size blocks: 708558 rmd160's in 3.00sDoing rmd160 for 3s on 64 size blocks: 468422 rmd160's in 2.99sDoing rmd160 for 3s on 256 size blocks: 232798 rmd160's in 3.00sDoing rmd160 for 3s on 1024 size blocks: 77260 rmd160's in 3.00sDoing rmd160 for 3s on 8192 size blocks: 10678 rmd160's in 3.00sDoing rc4 for 3s on 16 size blocks: 9768347 rc4's in 3.00sDoing rc4 for 3s on 64 size blocks: 2659340 rc4's in 2.99sDoing rc4 for 3s on 256 size blocks: 678661 rc4's in 3.00sDoing rc4 for 3s on 1024 size blocks: 171064 rc4's in 3.00sDoing rc4 for 3s on 8192 size blocks: 21431 rc4's in 3.00sDoing des cbc for 3s on 16 size blocks: 2709701 des cbc's in 2.99sDoing des cbc for 3s on 64 size blocks: 720035 des cbc's in 3.00sDoing des cbc for 3s on 256 size blocks: 183449 des cbc's in 3.00sDoing des cbc for 3s on 1024 size blocks: 46081 des cbc's in 3.00sDoing des cbc for 3s on 8192 size blocks: 5767 des cbc's in 3.00sDoing des ede3 for 3s on 16 size blocks: 1062088 des ede3's in 3.00sDoing des ede3 for 3s on 64 size blocks: 272558 des ede3's in 2.99sDoing des ede3 for 3s on 256 size blocks: 68657 des ede3's in 3.00sDoing des ede3 for 3s on 1024 size blocks: 17198 des ede3's in 3.00sDoing des ede3 for 3s on 8192 size blocks: 2150 des ede3's in 3.00sDoing aes-128 cbc for 3s on 16 size blocks: 5235761 aes-128 cbc's in 2.99sDoing aes-128 cbc for 3s on 64 size blocks: 1430841 aes-128 cbc's in 3.00sDoing aes-128 cbc for 3s on 256 size blocks: 369001 aes-128 cbc's in 3.00sDoing aes-128 cbc for 3s on 1024 size blocks: 92987 aes-128 cbc's in 3.00sDoing aes-128 cbc for 3s on 8192 size blocks: 11642 aes-128 cbc's in 3.00sDoing aes-192 cbc for 3s on 16 size blocks: 4618970 aes-192 cbc's in 2.99sDoing aes-192 cbc for 3s on 64 size blocks: 1248698 aes-192 cbc's in 3.00sDoing aes-192 cbc for 3s on 256 size blocks: 320738 aes-192 cbc's in 3.00sDoing aes-192 cbc for 3s on 1024 size blocks: 80738 aes-192 cbc's in 3.00sDoing aes-192 cbc for 3s on 8192 size blocks: 10107 aes-192 cbc's in 2.99sDoing aes-256 cbc for 3s on 16 size blocks: 4132203 aes-256 cbc's in 3.00sDoing aes-256 cbc for 3s on 64 size blocks: 1107663 aes-256 cbc's in 3.00sDoing aes-256 cbc for 3s on 256 size blocks: 283626 aes-256 cbc's in 3.00sDoing aes-256 cbc for 3s on 1024 size blocks: 71341 aes-256 cbc's in 3.00sDoing aes-256 cbc for 3s on 8192 size blocks: 8930 aes-256 cbc's in 3.00sDoing aes-128 ige for 3s on 16 size blocks: 5069004 aes-128 ige's in 2.99sDoing aes-128 ige for 3s on 64 size blocks: 1408909 aes-128 ige's in 3.00sDoing aes-128 ige for 3s on 256 size blocks: 364177 aes-128 ige's in 3.00sDoing aes-128 ige for 3s on 1024 size blocks: 91807 aes-128 ige's in 3.00sDoing aes-128 ige for 3s on 8192 size blocks: 11403 aes-128 ige's in 2.99sDoing aes-192 ige for 3s on 16 size blocks: 4489327 aes-192 ige's in 3.00sDoing aes-192 ige for 3s on 64 size blocks: 1231935 aes-192 ige's in 3.00sDoing aes-192 ige for 3s on 256 size blocks: 317064 aes-192 ige's in 3.00sDoing aes-192 ige for 3s on 1024 size blocks: 79841 aes-192 ige's in 3.00sDoing aes-192 ige for 3s on 8192 size blocks: 9933 aes-192 ige's in 3.00sDoing aes-256 ige for 3s on 16 size blocks: 4027708 aes-256 ige's in 2.99sDoing aes-256 ige for 3s on 64 size blocks: 1092734 aes-256 ige's in 3.00sDoing aes-256 ige for 3s on 256 size blocks: 280771 aes-256 ige's in 3.00sDoing aes-256 ige for 3s on 1024 size blocks: 70642 aes-256 ige's in 2.99sDoing aes-256 ige for 3s on 8192 size blocks: 8792 aes-256 ige's in 3.00sDoing ghash for 3s on 16 size blocks: 5068630 ghash's in 3.00sDoing ghash for 3s on 64 size blocks: 1352499 ghash's in 3.00sDoing ghash for 3s on 256 size blocks: 346969 ghash's in 3.00sDoing ghash for 3s on 1024 size blocks: 87319 ghash's in 3.00sDoing ghash for 3s on 8192 size blocks: 10934 ghash's in 2.99sDoing camellia-128 cbc for 3s on 16 size blocks: 4161207 camellia-128 cbc's in 3.00sDoing camellia-128 cbc for 3s on 64 size blocks: 1123379 camellia-128 cbc's in 3.00sDoing camellia-128 cbc for 3s on 256 size blocks: 287885 camellia-128 cbc's in 3.00sDoing camellia-128 cbc for 3s on 1024 size blocks: 72435 camellia-128 cbc's in 2.99sDoing camellia-128 cbc for 3s on 8192 size blocks: 9053 camellia-128 cbc's in 3.00sDoing camellia-192 cbc for 3s on 16 size blocks: 3314067 camellia-192 cbc's in 3.00sDoing camellia-192 cbc for 3s on 64 size blocks: 879750 camellia-192 cbc's in 3.00sDoing camellia-192 cbc for 3s on 256 size blocks: 224375 camellia-192 cbc's in 3.00sDoing camellia-192 cbc for 3s on 1024 size blocks: 56378 camellia-192 cbc's in 3.00sDoing camellia-192 cbc for 3s on 8192 size blocks: 7046 camellia-192 cbc's in 2.99sDoing camellia-256 cbc for 3s on 16 size blocks: 3314137 camellia-256 cbc's in 3.00sDoing camellia-256 cbc for 3s on 64 size blocks: 879790 camellia-256 cbc's in 3.00sDoing camellia-256 cbc for 3s on 256 size blocks: 224392 camellia-256 cbc's in 3.00sDoing camellia-256 cbc for 3s on 1024 size blocks: 56379 camellia-256 cbc's in 2.99sDoing camellia-256 cbc for 3s on 8192 size blocks: 7046 camellia-256 cbc's in 3.00sDoing seed cbc for 3s on 16 size blocks: 2688399 seed cbc's in 3.00sDoing seed cbc for 3s on 64 size blocks: 704796 seed cbc's in 3.00sDoing seed cbc for 3s on 256 size blocks: 178191 seed cbc's in 3.00sDoing seed cbc for 3s on 1024 size blocks: 44718 seed cbc's in 2.99sDoing seed cbc for 3s on 8192 size blocks: 5595 seed cbc's in 3.00sDoing rc2 cbc for 3s on 16 size blocks: 1742983 rc2 cbc's in 3.00sDoing rc2 cbc for 3s on 64 size blocks: 456754 rc2 cbc's in 3.00sDoing rc2 cbc for 3s on 256 size blocks: 115491 rc2 cbc's in 2.99sDoing rc2 cbc for 3s on 1024 size blocks: 29045 rc2 cbc's in 3.00sDoing rc2 cbc for 3s on 8192 size blocks: 3624 rc2 cbc's in 3.00sDoing blowfish cbc for 3s on 16 size blocks: 3438140 blowfish cbc's in 3.00sDoing blowfish cbc for 3s on 64 size blocks: 934694 blowfish cbc's in 3.00sDoing blowfish cbc for 3s on 256 size blocks: 238803 blowfish cbc's in 3.00sDoing blowfish cbc for 3s on 1024 size blocks: 60081 blowfish cbc's in 2.99sDoing blowfish cbc for 3s on 8192 size blocks: 7522 blowfish cbc's in 3.00sDoing cast cbc for 3s on 16 size blocks: 3846931 cast cbc's in 3.00sDoing cast cbc for 3s on 64 size blocks: 1053603 cast cbc's in 3.00sDoing cast cbc for 3s on 256 size blocks: 270846 cast cbc's in 2.99sDoing cast cbc for 3s on 1024 size blocks: 68193 cast cbc's in 3.00sDoing cast cbc for 3s on 8192 size blocks: 8539 cast cbc's in 3.00sDoing 512 bit private rsa's for 10s: 8243 512 bit private RSA's in 9.99sDoing 512 bit public rsa's for 10s: 103463 512 bit public RSA's in 9.99sDoing 1024 bit private rsa's for 10s: 1785 1024 bit private RSA's in 9.99sDoing 1024 bit public rsa's for 10s: 35280 1024 bit public RSA's in 9.99sDoing 2048 bit private rsa's for 10s: 296 2048 bit private RSA's in 10.01sDoing 2048 bit public rsa's for 10s: 10902 2048 bit public RSA's in 9.98sDoing 4096 bit private rsa's for 10s: 46 4096 bit private RSA's in 10.09sDoing 4096 bit public rsa's for 10s: 3115 4096 bit public RSA's in 9.95sDoing 512 bit sign dsa's for 10s: 9069 512 bit DSA signs in 9.97sDoing 512 bit verify dsa's for 10s: 8925 512 bit DSA verify in 9.97sDoing 1024 bit sign dsa's for 10s: 3315 1024 bit DSA signs in 9.95sDoing 1024 bit verify dsa's for 10s: 3047 1024 bit DSA verify in 9.95sDoing 2048 bit sign dsa's for 10s: 1029 2048 bit DSA signs in 9.97sDoing 2048 bit verify dsa's for 10s: 945 2048 bit DSA verify in 9.98sDoing 160 bit sign ecdsa's for 10s: 9464 160 bit ECDSA signs in 9.98sDoing 160 bit verify ecdsa's for 10s: 2673 160 bit ECDSA verify in 9.98sDoing 192 bit sign ecdsa's for 10s: 9500 192 bit ECDSA signs in 9.97sDoing 192 bit verify ecdsa's for 10s: 2834 192 bit ECDSA verify in 9.98sDoing 224 bit sign ecdsa's for 10s: 6988 224 bit ECDSA signs in 9.97sDoing 224 bit verify ecdsa's for 10s: 2000 224 bit ECDSA verify in 9.98sDoing 256 bit sign ecdsa's for 10s: 6427 256 bit ECDSA signs in 9.97sDoing 256 bit verify ecdsa's for 10s: 1866 256 bit ECDSA verify in 9.97sDoing 384 bit sign ecdsa's for 10s: 2908 384 bit ECDSA signs in 9.97sDoing 384 bit verify ecdsa's for 10s: 874 384 bit ECDSA verify in 9.97sDoing 521 bit sign ecdsa's for 10s: 1395 521 bit ECDSA signs in 9.89sDoing 521 bit verify ecdsa's for 10s: 453 521 bit ECDSA verify in 9.95sDoing 163 bit sign ecdsa's for 10s: 5891 163 bit ECDSA signs in 9.96sDoing 163 bit verify ecdsa's for 10s: 1679 163 bit ECDSA verify in 9.96sDoing 233 bit sign ecdsa's for 10s: 3014 233 bit ECDSA signs in 9.96sDoing 233 bit verify ecdsa's for 10s: 1217 233 bit ECDSA verify in 9.98sDoing 283 bit sign ecdsa's for 10s: 1833 283 bit ECDSA signs in 9.95sDoing 283 bit verify ecdsa's for 10s: 598 283 bit ECDSA verify in 9.96sDoing 409 bit sign ecdsa's for 10s: 748 409 bit ECDSA signs in 9.96sDoing 409 bit verify ecdsa's for 10s: 292 409 bit ECDSA verify in 9.99sDoing 571 bit sign ecdsa's for 10s: 335 571 bit ECDSA signs in 9.97sDoing 571 bit verify ecdsa's for 10s: 134 571 bit ECDSA verify in 9.98sDoing 163 bit sign ecdsa's for 10s: 5929 163 bit ECDSA signs in 9.94sDoing 163 bit verify ecdsa's for 10s: 1613 163 bit ECDSA verify in 9.96sDoing 233 bit sign ecdsa's for 10s: 3031 233 bit ECDSA signs in 9.94sDoing 233 bit verify ecdsa's for 10s: 1155 233 bit ECDSA verify in 9.96sDoing 283 bit sign ecdsa's for 10s: 1837 283 bit ECDSA signs in 9.97sDoing 283 bit verify ecdsa's for 10s: 555 283 bit ECDSA verify in 9.98sDoing 409 bit sign ecdsa's for 10s: 749 409 bit ECDSA signs in 9.98sDoing 409 bit verify ecdsa's for 10s: 265 409 bit ECDSA verify in 9.98sDoing 571 bit sign ecdsa's for 10s: 336 571 bit ECDSA signs in 9.97sDoing 571 bit verify ecdsa's for 10s: 121 571 bit ECDSA verify in 10.05sDoing 160 bit ecdh's for 10s: 3205 160-bit ECDH ops in 9.98sDoing 192 bit ecdh's for 10s: 3446 192-bit ECDH ops in 9.97sDoing 224 bit ecdh's for 10s: 2424 224-bit ECDH ops in 9.98sDoing 256 bit ecdh's for 10s: 2260 256-bit ECDH ops in 9.98sDoing 384 bit ecdh's for 10s: 1065 384-bit ECDH ops in 9.98sDoing 521 bit ecdh's for 10s: 547 521-bit ECDH ops in 9.97sDoing 163 bit ecdh's for 10s: 3435 163-bit ECDH ops in 9.98sDoing 233 bit ecdh's for 10s: 2497 233-bit ECDH ops in 9.98sDoing 283 bit ecdh's for 10s: 1222 283-bit ECDH ops in 9.98sDoing 409 bit ecdh's for 10s: 591 409-bit ECDH ops in 9.98sDoing 571 bit ecdh's for 10s: 271 571-bit ECDH ops in 9.99sDoing 163 bit ecdh's for 10s: 3252 163-bit ECDH ops in 9.98sDoing 233 bit ecdh's for 10s: 2363 233-bit ECDH ops in 9.98sDoing 283 bit ecdh's for 10s: 1122 283-bit ECDH ops in 9.98sDoing 409 bit ecdh's for 10s: 535 409-bit ECDH ops in 10.00sDoing 571 bit ecdh's for 10s: 242 571-bit ECDH ops in 9.99sOpenSSL 1.0.1f 6 Jan 2014built on: Mon Jan 30 20:42:11 UTC 2017options:bn(64,64) rc4(ptr,char) des(idx,cisc,16,int) aes(partial) blowfish(ptr)compiler: cc -fPIC -DOPENSSL_PIC -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -DL_ENDIAN -DTERMIO -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -Wl,-Bsymbolic-functions -Wl,-z,relro -Wa,--noexecstack -WallThe 'numbers' are in 1000s of bytes per second processed.type 16 bytes 64 bytes 256 bytes 1024 bytes 8192 bytesmd2 0.00 0.00 0.00 0.00 0.00mdc2 0.00 0.00 0.00 0.00 0.00md4 7019.75k 24163.87k 68302.25k 125623.30k 166524.25kmd5 5435.88k 18307.09k 48882.64k 83315.03k 105108.82khmac(md5) 6826.56k 21719.17k 54428.16k 87211.69k 105873.41ksha1 4781.35k 13920.15k 30515.97k 43569.15k 49968.46krmd160 3778.98k 10026.42k 19865.43k 26371.41k 29158.06krc4 52097.85k 56922.33k 57912.41k 58389.85k 58520.92kdes cbc 14500.07k 15360.75k 15654.31k 15728.98k 15747.75kdes ede3 5664.47k 5834.02k 5858.73k 5870.25k 5870.93kidea cbc 0.00 0.00 0.00 0.00 0.00seed cbc 14338.13k 15035.65k 15205.63k 15314.79k 15278.08krc2 cbc 9295.91k 9744.09k 9888.19k 9914.03k 9895.94krc5-32/12 cbc 0.00 0.00 0.00 0.00 0.00blowfish cbc 18336.75k 19940.14k 20377.86k 20576.24k 20540.07kcast cbc 20516.97k 22476.86k 23189.49k 23276.54k 23317.16kaes-128 cbc 28017.45k 30524.61k 31488.09k 31739.56k 31790.42kaes-192 cbc 24716.90k 26638.89k 27369.64k 27558.57k 27691.15kaes-256 cbc 22038.42k 23630.14k 24202.75k 24351.06k 24384.85kcamellia-128 cbc 22193.10k 23965.42k 24566.19k 24807.17k 24720.73kcamellia-192 cbc 17675.02k 18768.00k 19146.67k 19243.69k 19304.63kcamellia-256 cbc 17675.40k 18768.85k 19148.12k 19308.39k 19240.28ksha256 4420.11k 10641.73k 19433.64k 24583.17k 26621.27ksha512 2746.43k 10954.58k 18531.50k 27271.62k 31479.13kwhirlpool 1117.14k 2284.99k 3713.03k 4381.35k 4625.75kaes-128 ige 27125.11k 30056.73k 31076.44k 31336.79k 31241.93kaes-192 ige 23943.08k 26281.28k 27056.13k 27252.39k 27123.71kaes-256 ige 21552.95k 23311.66k 23959.13k 24193.11k 24008.02kghash 27032.69k 28853.31k 29608.02k 29804.89k 29956.97k sign verify sign/s verify/srsa 512 bits 0.001212s 0.000097s 825.1 10356.7rsa 1024 bits 0.005597s 0.000283s 178.7 3531.5rsa 2048 bits 0.033818s 0.000915s 29.6 1092.4rsa 4096 bits 0.219348s 0.003194s 4.6 313.1 sign verify sign/s verify/sdsa 512 bits 0.001099s 0.001117s 909.6 895.2dsa 1024 bits 0.003002s 0.003266s 333.2 306.2dsa 2048 bits 0.009689s 0.010561s 103.2 94.7 sign verify sign/s verify/s 160 bit ecdsa (secp160r1) 0.0011s 0.0037s 948.3 267.8 192 bit ecdsa (nistp192) 0.0010s 0.0035s 952.9 284.0 224 bit ecdsa (nistp224) 0.0014s 0.0050s 700.9 200.4 256 bit ecdsa (nistp256) 0.0016s 0.0053s 644.6 187.2 384 bit ecdsa (nistp384) 0.0034s 0.0114s 291.7 87.7 521 bit ecdsa (nistp521) 0.0071s 0.0220s 141.1 45.5 163 bit ecdsa (nistk163) 0.0017s 0.0059s 591.5 168.6 233 bit ecdsa (nistk233) 0.0033s 0.0082s 302.6 121.9 283 bit ecdsa (nistk283) 0.0054s 0.0167s 184.2 60.0 409 bit ecdsa (nistk409) 0.0133s 0.0342s 75.1 29.2 571 bit ecdsa (nistk571) 0.0298s 0.0745s 33.6 13.4 163 bit ecdsa (nistb163) 0.0017s 0.0062s 596.5 161.9 233 bit ecdsa (nistb233) 0.0033s 0.0086s 304.9 116.0 283 bit ecdsa (nistb283) 0.0054s 0.0180s 184.3 55.6 409 bit ecdsa (nistb409) 0.0133s 0.0377s 75.1 26.6 571 bit ecdsa (nistb571) 0.0297s 0.0831s 33.7 12.0 op op/s 160 bit ecdh (secp160r1) 0.0031s 321.1 192 bit ecdh (nistp192) 0.0029s 345.6 224 bit ecdh (nistp224) 0.0041s 242.9 256 bit ecdh (nistp256) 0.0044s 226.5 384 bit ecdh (nistp384) 0.0094s 106.7 521 bit ecdh (nistp521) 0.0182s 54.9 163 bit ecdh (nistk163) 0.0029s 344.2 233 bit ecdh (nistk233) 0.0040s 250.2 283 bit ecdh (nistk283) 0.0082s 122.4 409 bit ecdh (nistk409) 0.0169s 59.2 571 bit ecdh (nistk571) 0.0369s 27.1 163 bit ecdh (nistb163) 0.0031s 325.9 233 bit ecdh (nistb233) 0.0042s 236.8 283 bit ecdh (nistb283) 0.0089s 112.4 409 bit ecdh (nistb409) 0.0187s 53.5 571 bit ecdh (nistb571) 0.0413s 24.2输入openssl version可以查看版本号,输入下面命令加密文件
openssl enc -e -des -a -salt -in /etc/passwd -out ./passwd.crypt加密的后文件打开如下图
|
|