Should openssl's "ENGINE_load_builtin_engines" be used by default
Some of the newer Intel chips have hardware acceleration for AES (AES-NI) -- this speeds up
SSL performance, eg with AES-NI acceleration a 2GB download with curl runs at ~130 MB/s:
$ time curl -k https:/
% Total % Received % Xferd Average Speed Time Time Time Current
100 2000M 100 2000M 0 0 131M 0 0:00:15 0:00:15 --:--:-- 132M
real 0m15.170s
Whereas if I disable where curl calls openssl's "ENGINE_
to ~80 MB/s:
$ time curl -k https:/
% Total % Received % Xferd Average Speed Time Time Time Current
100 2000M 100 2000M 0 0 83.4M 0 0:00:23 0:00:23 --:--:-- 83.3M
real 0m23.966s
user 0m20.920s
sys 0m2.980s
This is what curl does to enable the hardware AES acceleration where available:
(gdb) bt
#0 0x00007ffff67a9f40 in CRYPTO_lock () from /lib/libcrypto.
#1 0x00007ffff67ac9eb in CRYPTO_new_ex_data () from /lib/libcrypto.
#2 0x00007ffff67f94ba in ENGINE_new () from /lib/libcrypto.
#3 0x00007ffff67fdec3 in ENGINE_load_aesni () from /lib/libcrypto.
#4 0x00007ffff67fbad3 in ENGINE_
#5 0x00007ffff7baa939 in Curl_ossl_init () from /usr/lib/
#6 0x00007ffff7bb2059 in curl_global_init () from /usr/lib/
#7 0x0000000000406bab in main ()
pyopenssl doesn't seem to call 'ENGINE_
Is this something which could be considered?
Question information
- Language:
- English Edit question
- Status:
- Answered
- For:
- pyOpenSSL Edit question
- Assignee:
- No assignee Edit question
- Last query:
- Last reply:
Can you help with this problem?
Provide an answer of your own, or ask Stuart McLaren for more information if necessary.