diff options
| author | Roman Arutyunyan <arut@nginx.com> | 2023-02-22 19:16:53 +0400 |
|---|---|---|
| committer | Roman Arutyunyan <arut@nginx.com> | 2023-02-22 19:16:53 +0400 |
| commit | a36ebf7e95baebf445b0973bd270bc009b0b0e9a (patch) | |
| tree | 28f396ec4a7a6a828a8ee3e7f05b5e56ebbfecf4 /auto/lib | |
| parent | 76adb919138225b24280bc477ff468fd13cc9e62 (diff) | |
| download | nginx-a36ebf7e95baebf445b0973bd270bc009b0b0e9a.tar.gz nginx-a36ebf7e95baebf445b0973bd270bc009b0b0e9a.tar.bz2 | |
QUIC: OpenSSL compatibility layer.
The change allows to compile QUIC with OpenSSL which lacks BoringSSL QUIC API.
This implementation does not support 0-RTT.
Diffstat (limited to 'auto/lib')
| -rw-r--r-- | auto/lib/openssl/conf | 54 |
1 files changed, 30 insertions, 24 deletions
diff --git a/auto/lib/openssl/conf b/auto/lib/openssl/conf index 9ab062091..cfa74cf81 100644 --- a/auto/lib/openssl/conf +++ b/auto/lib/openssl/conf @@ -10,6 +10,7 @@ if [ $OPENSSL != NONE ]; then if [ $USE_OPENSSL_QUIC = YES ]; then have=NGX_QUIC . auto/have + have=NGX_QUIC_OPENSSL_COMPAT . auto/have fi case "$CC" in @@ -124,6 +125,35 @@ else CORE_INCS="$CORE_INCS $ngx_feature_path" CORE_LIBS="$CORE_LIBS $ngx_feature_libs" OPENSSL=YES + + if [ $USE_OPENSSL_QUIC = YES ]; then + + ngx_feature="OpenSSL QUIC support" + ngx_feature_name="NGX_QUIC" + ngx_feature_test="SSL_set_quic_method(NULL, NULL)" + . auto/feature + + if [ $ngx_found = no ]; then + have=NGX_QUIC_OPENSSL_COMPAT . auto/have + + ngx_feature="OpenSSL QUIC compatibility" + ngx_feature_test="SSL_CTX_add_custom_ext(NULL, 0, 0, + NULL, NULL, NULL, NULL, NULL)" + . auto/feature + fi + + if [ $ngx_found = no ]; then +cat << END + +$0: error: certain modules require OpenSSL QUIC support. +You can either do not enable the modules, or install the OpenSSL library with +QUIC support into the system, or build the OpenSSL library with QUIC support +statically from the source with nginx by using --with-openssl=<path> option. + +END + exit 1 + fi + fi fi fi @@ -140,28 +170,4 @@ END exit 1 fi - if [ $USE_OPENSSL_QUIC = YES ]; then - - ngx_feature="OpenSSL QUIC support" - ngx_feature_name="NGX_QUIC" - ngx_feature_run=no - ngx_feature_incs="#include <openssl/ssl.h>" - ngx_feature_path= - ngx_feature_libs="-lssl -lcrypto $NGX_LIBDL $NGX_LIBPTHREAD" - ngx_feature_test="SSL_set_quic_method(NULL, NULL)" - . auto/feature - - if [ $ngx_found = no ]; then - -cat << END - -$0: error: certain modules require OpenSSL QUIC support. -You can either do not enable the modules, or install the OpenSSL library with -QUIC support into the system, or build the OpenSSL library with QUIC support -statically from the source with nginx by using --with-openssl=<path> option. - -END - exit 1 - fi - fi fi |
