[openssl-users] Sequential / parallel OpenSSL sessions with Async
Nicolas Brunie
nicolas.brunie at kalray.eu
Wed Aug 31 12:17:40 UTC 2016
Hi All, I have been playing around with OpenSSL ASYNC JOB and an
asynchronous offloading engine and a stupid question came to mind:
It is not possible to make several parallel/pending calls to SSL_read
(or SSL_write) on a single SSL* object (with different output/input
buffers) so that multiple offloading operation can be done in parallel
(on a single SSL object).
I am quite new to TLS but it may seem that you can not enqueue
multiple calls to the same SSL_<method> until the first one called has
returned (in the sens completely finished and not just return an
SSL_ERROR_WANT_ASYNC), it that so ?
best regards,
Nicolas Brunie
P.S:
SSL* obj = ... /* accept and init */ int err = SSL_read(obj, buf0,
READ_SIZE);
if (err < 0 && SSL_get_error(obj, err) == SSL_ERROR_WANT_ASYNC) {...}/*
pending buf0 crypto but go on */
/* the following is illegal if I have not called back SSL_read(obj,
buf0, READ_SIZE) and it
* has returned with completion (no want async error), right ? */
SSL_read(obj, buf1, READ_SIZE);
More information about the openssl-users
mailing list