Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support reading additional data from underlying BIO for each call to SSL_read #1517

Merged
merged 3 commits into from
May 7, 2024

Conversation

andrewhop
Copy link
Contributor

Issues:

Resolves P116480532

Description of changes:

Fully support:

  • SSL_set_read_ahead
  • SSL_CTX_set_read_ahead
  • SSL_set_default_read_buffer_len
  • SSL_CTX_set_default_read_buffer_len

Call-outs:

By enabling read ahead the system may reduce the number of calls to the SSL read BIO by reading more data than is specified in the TLS record header per call to the BIO which may improve performance.

Testing:

Added new unit tests and integration tests for this change. Also manually verified the number of calls to the read BIO.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license and the ISC license.

@andrewhop andrewhop requested a review from a team as a code owner April 2, 2024 19:28
@andrewhop andrewhop force-pushed the read_ahead branch 2 times, most recently from 4d01669 to f325b72 Compare April 2, 2024 22:18
ssl/ssl_lib.cc Outdated Show resolved Hide resolved
include/openssl/ssl.h Show resolved Hide resolved
include/openssl/ssl.h Show resolved Hide resolved
ssl/internal.h Outdated Show resolved Hide resolved
ssl/ssl_buffer.cc Show resolved Hide resolved
ssl/ssl_buffer.cc Show resolved Hide resolved
ssl/ssl_lib.cc Show resolved Hide resolved
ssl/test/runner/conn.go Show resolved Hide resolved
ssl/test/runner/common.go Show resolved Hide resolved
ssl/ssl_test.cc Show resolved Hide resolved
ssl/ssl_test.cc Outdated Show resolved Hide resolved
…SSL_read:

* SSL_set_read_ahead
* SSL_CTX_set_read_ahead
* SSL_set_default_read_buffer_len
* SSL_CTX_set_default_read_buffer_len

By enabling read ahead the system may reduce the number of calls to the SSL read BIO
by reading more data than is specified in the TLS record header.
@andrewhop andrewhop merged commit 0fb67dd into aws:main May 7, 2024
77 of 78 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants