A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/openssl/openssl/issues/1903 below:

Out of date/incorrect advice in SSL_get_error docs as of 1.1.0c · Issue #1903 · openssl/openssl · GitHub

This commit changed SSL_read to return -1 rather than 0 when BIO_read returns 0: 4880672, which landed in the 1.1.0c release.

When SSL_get_error is called, it'll return SSL_ERROR_SYSCALL, and the error stack will be empty. The man page for SSL_get_error says that at that point you should check SSL_read's return code; a -1 means that there was a read error and to consult the BIO-specific error (e.g. errno), and 0 means that there was an EOF in violation of the protocol, but that doesn't appear to be correct anymore.

Is this a bug in the implementation or the docs? If the new implementation is correct, I guess the new procedure should be to check the BIO error, and check if an error actually occurred to determine if it's an EOF?


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4