FreeBSD Bugzilla – Attachment 198490 Details for
Bug 228344
net/qt5-network: fails update to 5.11.2 with libressl
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
patch-libressl_v4
patch-libressl_v3 (text/plain), 10.88 KB, created by
Walter Schwarzenfeld
on 2018-10-23 10:46:58 UTC
(
hide
)
Description:
patch-libressl_v4
Filename:
MIME Type:
Creator:
Walter Schwarzenfeld
Created:
2018-10-23 10:46:58 UTC
Size:
10.88 KB
patch
obsolete
>Index: Makefile >=================================================================== >--- Makefile (revision 482680) >+++ Makefile (working copy) >@@ -2,6 +2,7 @@ > > PORTNAME= network > DISTVERSION= ${QT5_VERSION} >+PORTREVISION= 1 > CATEGORIES= net ipv6 > PKGNAMEPREFIX= qt5- > >Index: files/patch-qsslcontext_openssl.cpp >=================================================================== >--- files/patch-qsslcontext_openssl.cpp (nonexistent) >+++ files/patch-qsslcontext_openssl.cpp (working copy) >@@ -0,0 +1,11 @@ >+--- src/network/ssl/qsslcontext_openssl.cpp.orig 2018-10-21 16:58:39 UTC >++++ src/network/ssl/qsslcontext_openssl.cpp >+@@ -248,7 +248,7 @@ void QSslContext::applyBackendConfig(QSs >+ if (sslContext->sslConfiguration.backendConfiguration().isEmpty()) >+ return; >+ >+-#if OPENSSL_VERSION_NUMBER >= 0x10002000L >++#if OPENSSL_VERSION_NUMBER >= 0x10002000L && !defined(LIBRESSL_VERSION_NUMBER) >+ if (QSslSocket::sslLibraryVersionNumber() >= 0x10002000L) { >+ QSharedPointer<SSL_CONF_CTX> cctx(q_SSL_CONF_CTX_new(), &q_SSL_CONF_CTX_free); >+ if (cctx) { > >Property changes on: files/patch-qsslcontext_openssl.cpp >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-src_network_socket_qnet_unix_p.h >=================================================================== >--- files/patch-src_network_socket_qnet_unix_p.h (revision 482680) >+++ files/patch-src_network_socket_qnet_unix_p.h (working copy) > >Property changes on: files/patch-src_network_socket_qnet_unix_p.h >___________________________________________________________________ >Added: svn:keywords >## -0,0 +1 ## >+Author Date Id Rev URL >\ No newline at end of property >Index: files/patch-src_network_ssl_qsslsocket__openssl11__symbols__p.h >=================================================================== >--- files/patch-src_network_ssl_qsslsocket__openssl11__symbols__p.h (revision 482680) >+++ files/patch-src_network_ssl_qsslsocket__openssl11__symbols__p.h (working copy) > >Property changes on: files/patch-src_network_ssl_qsslsocket__openssl11__symbols__p.h >___________________________________________________________________ >Added: svn:keywords >## -0,0 +1 ## >+Author Date Id Rev URL >\ No newline at end of property >Index: files/patch-src_network_ssl_qsslsocket__openssl__symbols.cpp >=================================================================== >--- files/patch-src_network_ssl_qsslsocket__openssl__symbols.cpp (revision 482680) >+++ files/patch-src_network_ssl_qsslsocket__openssl__symbols.cpp (working copy) >@@ -1,10 +1,5 @@ >-* Boilerplate for SSL_CTX_set1_groups() used in qsslcontext_openssl.cpp >-* >-* Prepend the path of the SSL libraries used for building so the same libraries are >-* found and loaded at runtime. Normal search finds base SSL libraries before ports. >-* >---- src/network/ssl/qsslsocket_openssl_symbols.cpp.orig 2018-02-08 19:24:48.000000000 +0100 >-+++ src/network/ssl/qsslsocket_openssl_symbols.cpp 2018-06-29 12:22:11.265885000 +0200 >+--- src/network/ssl/qsslsocket_openssl_symbols.cpp.orig 2018-10-21 15:55:52 UTC >++++ src/network/ssl/qsslsocket_openssl_symbols.cpp > @@ -150,6 +150,14 @@ DEFINEFUNC2(int, BN_is_word, BIGNUM *a, > DEFINEFUNC(int, EVP_CIPHER_CTX_reset, EVP_CIPHER_CTX *c, c, return 0, return) > DEFINEFUNC(int, EVP_PKEY_base_id, EVP_PKEY *a, a, return NID_undef, return) >@@ -38,7 +33,16 @@ > DEFINEFUNC(EVP_PKEY *, X509_get_pubkey, X509 *a, a, return 0, return) > DEFINEFUNC2(void, X509_STORE_set_verify_cb, X509_STORE *a, a, X509_STORE_CTX_verify_cb verify_cb, verify_cb, return, DUMMYARG) > DEFINEFUNC(STACK_OF(X509) *, X509_STORE_CTX_get0_chain, X509_STORE_CTX *a, a, return 0, return) >-@@ -524,6 +535,9 @@ DEFINEFUNC(void, EC_KEY_free, EC_KEY *ec >+@@ -406,7 +417,7 @@ DEFINEFUNC2(int, SSL_CTX_use_PrivateKey, >+ DEFINEFUNC2(int, SSL_CTX_use_RSAPrivateKey, SSL_CTX *a, a, RSA *b, b, return -1, return) >+ DEFINEFUNC3(int, SSL_CTX_use_PrivateKey_file, SSL_CTX *a, a, const char *b, b, int c, c, return -1, return) >+ DEFINEFUNC(X509_STORE *, SSL_CTX_get_cert_store, const SSL_CTX *a, a, return 0, return) >+-#if OPENSSL_VERSION_NUMBER >= 0x10002000L >++#if OPENSSL_VERSION_NUMBER >= 0x10002000L && !defined(LIBRESSL_VERSION_NUMBER) >+ DEFINEFUNC(SSL_CONF_CTX *, SSL_CONF_CTX_new, DUMMYARG, DUMMYARG, return 0, return); >+ DEFINEFUNC(void, SSL_CONF_CTX_free, SSL_CONF_CTX *a, a, return ,return); >+ DEFINEFUNC2(void, SSL_CONF_CTX_set_ssl_ctx, SSL_CONF_CTX *a, a, SSL_CTX *b, b, return, return); >+@@ -537,6 +548,9 @@ DEFINEFUNC(void, EC_KEY_free, EC_KEY *ec > DEFINEFUNC2(size_t, EC_get_builtin_curves, EC_builtin_curve * r, r, size_t nitems, nitems, return 0, return) > #if OPENSSL_VERSION_NUMBER >= 0x10002000L > DEFINEFUNC(int, EC_curve_nist2nid, const char *name, name, return 0, return) >@@ -48,29 +52,29 @@ > #endif // OPENSSL_VERSION_NUMBER >= 0x10002000L > #endif // OPENSSL_NO_EC > >-@@ -769,8 +783,8 @@ static QPair<QLibrary*, QLibrary*> loadO >+@@ -782,8 +796,8 @@ static QPair<QLibrary*, QLibrary*> loadO > #endif > #if defined(SHLIB_VERSION_NUMBER) && !defined(Q_OS_QNX) // on QNX, the libs are always libssl.so and libcrypto.so > // first attempt: the canonical name is libssl.so.<SHLIB_VERSION_NUMBER> > - libssl->setFileNameAndVersion(QLatin1String("ssl"), QLatin1String(SHLIB_VERSION_NUMBER)); > - libcrypto->setFileNameAndVersion(QLatin1String("crypto"), QLatin1String(SHLIB_VERSION_NUMBER)); >-+ libssl->setFileNameAndVersion(QLatin1String("%%OPENSSLLIB%%/libssl"), QLatin1String(SHLIB_VERSION_NUMBER)); >-+ libcrypto->setFileNameAndVersion(QLatin1String("%%OPENSSLLIB%%/libcrypto"), QLatin1String(SHLIB_VERSION_NUMBER)); >++ libssl->setFileNameAndVersion(QLatin1String(""%%OPENSSLLIB%%/libssl"), QLatin1String(SHLIB_VERSION_NUMBER)); >++ libcrypto->setFileNameAndVersion(QLatin1String(""%%OPENSSLLIB%%/libcrypto"), QLatin1String(SHLIB_VERSION_NUMBER)); > if (libcrypto->load() && libssl->load()) { > // libssl.so.<SHLIB_VERSION_NUMBER> and libcrypto.so.<SHLIB_VERSION_NUMBER> found > return pair; >-@@ -787,8 +801,8 @@ static QPair<QLibrary*, QLibrary*> loadO >+@@ -800,8 +814,8 @@ static QPair<QLibrary*, QLibrary*> loadO > // macOS's /usr/lib/libssl.dylib, /usr/lib/libcrypto.dylib will be picked up in the third > // attempt, _after_ <bundle>/Contents/Frameworks has been searched. > // iOS does not ship a system libssl.dylib, libcrypto.dylib in the first place. > - libssl->setFileNameAndVersion(QLatin1String("ssl"), -1); > - libcrypto->setFileNameAndVersion(QLatin1String("crypto"), -1); >-+ libssl->setFileNameAndVersion(QLatin1String("%%OPENSSLLIB%%/libssl"), -1); >-+ libcrypto->setFileNameAndVersion(QLatin1String("%%OPENSSLLIB%%/libcrypto"), -1); >++ libssl->setFileNameAndVersion(QLatin1String(""%%OPENSSLLIB%%/libssl"), -1); >++ libcrypto->setFileNameAndVersion(QLatin1String(""%%OPENSSLLIB%%/libcrypto"), -1); > if (libcrypto->load() && libssl->load()) { > // libssl.so.0 and libcrypto.so.0 found > return pair; >-@@ -872,17 +886,30 @@ bool q_resolveOpenSslSymbols() >+@@ -885,17 +899,30 @@ bool q_resolveOpenSslSymbols() > RESOLVEFUNC(EVP_CIPHER_CTX_reset) > RESOLVEFUNC(EVP_PKEY_base_id) > RESOLVEFUNC(RSA_bits) >@@ -102,7 +106,7 @@ > RESOLVEFUNC(SSL_get_session) > RESOLVEFUNC(CRYPTO_get_ex_new_index) > RESOLVEFUNC(TLS_method) >-@@ -891,7 +918,9 @@ bool q_resolveOpenSslSymbols() >+@@ -904,7 +931,9 @@ bool q_resolveOpenSslSymbols() > RESOLVEFUNC(X509_STORE_CTX_get0_chain) > RESOLVEFUNC(X509_getm_notBefore) > RESOLVEFUNC(X509_getm_notAfter) >@@ -112,7 +116,7 @@ > RESOLVEFUNC(X509_get_pubkey) > RESOLVEFUNC(X509_STORE_set_verify_cb) > RESOLVEFUNC(CRYPTO_free) >-@@ -908,7 +937,9 @@ bool q_resolveOpenSslSymbols() >+@@ -921,7 +950,9 @@ bool q_resolveOpenSslSymbols() > > RESOLVEFUNC(SSL_SESSION_get_ticket_lifetime_hint) > RESOLVEFUNC(DH_bits) >@@ -122,7 +126,7 @@ > > #else // !opensslv11 > >-@@ -979,10 +1010,9 @@ bool q_resolveOpenSslSymbols() >+@@ -992,10 +1023,9 @@ bool q_resolveOpenSslSymbols() > RESOLVEFUNC(OPENSSL_add_all_algorithms_conf) > RESOLVEFUNC(SSLeay) > >@@ -134,7 +138,7 @@ > delete libs.first; > delete libs.second; > qCWarning(lcSsl, "Incompatible version of OpenSSL"); >-@@ -994,8 +1024,12 @@ bool q_resolveOpenSslSymbols() >+@@ -1007,8 +1037,12 @@ bool q_resolveOpenSslSymbols() > > #ifndef OPENSSL_NO_EC > #if OPENSSL_VERSION_NUMBER >= 0x10002000L >@@ -148,3 +152,12 @@ > #endif // OPENSSL_VERSION_NUMBER >= 0x10002000L > #endif // OPENSSL_NO_EC > >+@@ -1122,7 +1156,7 @@ bool q_resolveOpenSslSymbols() >+ RESOLVEFUNC(SSL_CTX_use_RSAPrivateKey) >+ RESOLVEFUNC(SSL_CTX_use_PrivateKey_file) >+ RESOLVEFUNC(SSL_CTX_get_cert_store); >+-#if OPENSSL_VERSION_NUMBER >= 0x10002000L >++#if OPENSSL_VERSION_NUMBER >= 0x10002000L && !defined(LIBRESSL_VERSION_NUMBER) >+ RESOLVEFUNC(SSL_CONF_CTX_new); >+ RESOLVEFUNC(SSL_CONF_CTX_free); >+ RESOLVEFUNC(SSL_CONF_CTX_set_ssl_ctx); >Index: files/patch-src_network_ssl_qsslsocket__openssl__symbols__p.h >=================================================================== >--- files/patch-src_network_ssl_qsslsocket__openssl__symbols__p.h (revision 482680) >+++ files/patch-src_network_ssl_qsslsocket__openssl__symbols__p.h (working copy) >@@ -1,7 +1,29 @@ >-Boilerplate for SSL_CTX_set1_groups() used in qsslcontext_openssl.cpp. >---- src/network/ssl/qsslsocket_openssl_symbols_p.h.orig 2018-02-08 18:24:48 UTC >+--- src/network/ssl/qsslsocket_openssl_symbols_p.h.orig 2018-10-21 17:04:11 UTC > +++ src/network/ssl/qsslsocket_openssl_symbols_p.h >-@@ -454,6 +454,9 @@ void q_EC_KEY_free(EC_KEY *ecdh); >+@@ -74,6 +74,13 @@ >+ >+ QT_BEGIN_NAMESPACE >+ >++#if defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER >= 0x20700000L >++# define TLS1_2_VERSION 0x0303 >++# define TLS_MAX_VERSION TLS1_2_VERSION >++# define TLS_ANY_VERSION 0x10000 >++#endif >++ >++ >+ #define DUMMYARG >+ >+ #if !defined QT_LINKED_OPENSSL >+@@ -356,7 +363,7 @@ int q_SSL_CTX_use_PrivateKey(SSL_CTX *a, >+ int q_SSL_CTX_use_RSAPrivateKey(SSL_CTX *a, RSA *b); >+ int q_SSL_CTX_use_PrivateKey_file(SSL_CTX *a, const char *b, int c); >+ X509_STORE *q_SSL_CTX_get_cert_store(const SSL_CTX *a); >+-#if OPENSSL_VERSION_NUMBER >= 0x10002000L >++#if OPENSSL_VERSION_NUMBER >= 0x10002000L && !defined(LIBRESSL_VERSION_NUMBER) >+ SSL_CONF_CTX *q_SSL_CONF_CTX_new(); >+ void q_SSL_CONF_CTX_free(SSL_CONF_CTX *a); >+ void q_SSL_CONF_CTX_set_ssl_ctx(SSL_CONF_CTX *a, SSL_CTX *b); >+@@ -468,6 +475,9 @@ void q_EC_KEY_free(EC_KEY *ecdh); > size_t q_EC_get_builtin_curves(EC_builtin_curve *r, size_t nitems); > #if OPENSSL_VERSION_NUMBER >= 0x10002000L > int q_EC_curve_nist2nid(const char *name); > >Property changes on: files/patch-src_network_ssl_qsslsocket__openssl__symbols__p.h >___________________________________________________________________ >Added: svn:keywords >## -0,0 +1 ## >+Author Date Id Rev URL >\ No newline at end of property
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 228344
:
193533
|
193536
|
193559
|
193786
|
196989
|
196994
|
198438
|
198440
|
198490
|
198491
|
198600
|
198607
|
198610
|
198611
|
198618