torproject / tor Public
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
Ticket31820 #1556
Closed
Closed
Ticket31820 #1556
Conversation
These are the versions that will be supported when 0.4.3.x is released.
Nearly all of the functions added in openssl 1.1.0 have since been ported to LibreSSL. The remaining functions should now be considered libressl-specific.
OpenSSL as of 1.1.0, and LibreSSL as of 2.9.0, both have a working lock implementation by default, and no longer require the caller to pass in a bunch of locking callbacks.
Tor has been carrying around its own counter mode for ages, but no current version of openssl benefits from using it.
These are no longer needed.
Pull Request Test Coverage Report for Build 7295
|
teor2345
suggested changes
Nov 26, 2019
Seems pretty good, I added some comments inline.
It also looks like you missed a OPENSSL_V_SERIES(1,1,0) in the unit tests.
| @@ -111,19 +61,22 @@ aes_new_cipher(const uint8_t *key, const uint8_t *iv, int key_bits) | |||
| EVP_EncryptInit(cipher, c, key, iv); | |||
| return (aes_cnt_cipher_t *) cipher; | |||
| } | |||
| /** | |||
Nitpick: newline?
And for the other functions following this one.
| CRYPTO_THREADID_set_numeric(threadid, tor_get_thread_id()); | ||
| } | ||
| #endif /* !defined(NEW_THREAD_API) */ | ||
| /** Helper: Construct mutexes, and set callbacks to help OpenSSL handle being | ||
| * multithreaded. Returns 0. */ | ||
| static int | ||
| setup_openssl_threading(void) |
src/lib/crypt_ops/compat_openssl.h
Outdated
| #ifndef OPENSSL_1_1_API | ||
| #define OpenSSL_version(v) SSLeay_version(v) | ||
| #define OpenSSL_version_num() SSLeay() | ||
| #ifdef LIBRESSL_VERSION_NUMBER | ||
| #define RAND_OpenSSL() RAND_SSLeay() | ||
| #define STATE_IS_SW_SERVER_HELLO(st) \ | ||
| (((st) == SSL3_ST_SW_SRVR_HELLO_A) || \ | ||
| ((st) == SSL3_ST_SW_SRVR_HELLO_B)) | ||
| #define OSSL_HANDSHAKE_STATE int | ||
| #define CONST_IF_OPENSSL_1_1_API |
|
|
||
| #if (SIZEOF_VOID_P >= 8 && \ | ||
| OPENSSL_VERSION_NUMBER >= OPENSSL_V_SERIES(1,0,1)) | ||
| #if (SIZEOF_VOID_P >= 8) | ||
| long version = OpenSSL_version_num(); | ||
|
|
||
| /* LCOV_EXCL_START : we can't test these lines on the same machine */ |
You missed a OPENSSL_V_SERIES(1,0,1) just below this line.
This is an automated commit, generated by this command:
./scripts/maint/rename_c_identifier.py \
CONST_IF_OPENSSL_1_1_API CONST_IF_OPENSSL
This test is a test for a useful feature that we can no longer implement in modern openssl. We should re-do it at some point, possibly creating a patch for openssl if needed.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
No description provided.
The text was updated successfully, but these errors were encountered: