From nobody Mon Nov 07 08:00:15 2022 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4N5Nv40bj5z4hHqs; Mon, 7 Nov 2022 08:00:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4N5Nv33P3Gz3kbm; Mon, 7 Nov 2022 08:00:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1667808015; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2QangfXgNTHQ5vVn9Wq2uAsAEeEFlM72EnvKXQ2grq8=; b=NokhIiAfHAX/JRNqIqgNIVSCshgGPo6BcYcKRxjlaDbQ+Q6OSQD7hc7Sy1qMH5wBQuqpw3 6vhjSeOI1fK+xLdjEZ4/9TcphV6mH48Uy5x8ezzsEB56jnscZhln41xSZ123u/Alg2tHz1 AwNEzpXg+VnRKh759XPFdKpqMNQaiG9HYghj+WWU1leQsImIDb9i56VsJgKhZm0nWHJSwG YIAqG1SnV9xdM2j7mn6WVdcMQKq64qqjMM17e4sNCVJknitX8RSYZQXR8FAS6nzHhXskRH lovTn2cqz10Z2fQ/N66wWb2akaJmBLwboTlDvoga13BAMzJSufEi18emq5goMw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4N5Nv32D2CztB3; Mon, 7 Nov 2022 08:00:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 2A780FFP003347; Mon, 7 Nov 2022 08:00:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 2A780FAu003341; Mon, 7 Nov 2022 08:00:15 GMT (envelope-from git) Date: Mon, 7 Nov 2022 08:00:15 GMT Message-Id: <202211070800.2A780FAu003341@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Felix Palmen Subject: git: 968b5605bb4d - main - databases/mysql57-client: Fix build w/ libressl3.5 List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zirias X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 968b5605bb4df8bdd78cea62715d9a06f6b7889c Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1667808015; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2QangfXgNTHQ5vVn9Wq2uAsAEeEFlM72EnvKXQ2grq8=; b=QCMq6HfG2d3TncqiYN/1BYQ3uR212vv9COqZ3Uen2pBe6nhFFQPYVqQ9qege/eRpHygJXl X20jQEvQLiarpHBVtAz2dDBp0qlw9Nrq045pH+8+ir//2bqoLD17BYeyYDzafHXRQYP2jI J1B32JnIUbOPwiJzUhyHjF1qKD/+cZXNt8YhO3VPHBf/o31lg4FCBaPhZDnTGrjJY8z+Z7 EQ3HZP3ussqF1TrXpH05Hiob94vn3014kNND/xZOfaCWqy6/VjDS7KEvlpbcxlTHjYTsza Wgk8D07pj0kkZ9qkEzyxN6gmprE6/L65CGdrsfypHqByiBp1L1tTmkEEEhxviQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1667808015; a=rsa-sha256; cv=none; b=xhCzFL/NKKv8s7u05URK2AO9QYPKLUwkGIKZjlEd0yNniSEN0fF4FnJrSSMf4oDZYjhZqw EVwaamVj+uJTpz0WXvVvrTVL6pves1nJZiG2VJVaIGyNAC9UdP3/zvfCH99SXDANkGA9Di oRQxBbKJht7PO3qPWJ+9M1P2mgxyNbKx19jL428LnNBH4+wrv+CRsVqIJ9mTmK+9i7HGb3 UyQp7nAIvc1BVVlsa70gKNtFQhVEH5xba67kMmUyz95cK8XRZN6Vh7rvq0T7n3WONp9C78 ZsmTkZ5W2KXeVB8rNOKEDz+Vn1a26eF8vJbckF2BOL/oW64BnH0z4jiNwz+Q+Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by zirias: URL: https://cgit.FreeBSD.org/ports/commit/?id=968b5605bb4df8bdd78cea62715d9a06f6b7889c commit 968b5605bb4df8bdd78cea62715d9a06f6b7889c Author: Felix Palmen AuthorDate: 2022-10-17 13:15:16 +0000 Commit: Felix Palmen CommitDate: 2022-11-07 07:58:34 +0000 databases/mysql57-client: Fix build w/ libressl3.5 Approved by: joneum (maintainer), tcberner (mentor) Differential Revision: https://reviews.freebsd.org/D37055 --- .../files/patch-mysys__ssl_my__kdf.cc | 20 +++++++ .../files/patch-mysys__ssl_my__kdf.h | 11 ++++ .../files/patch-vio_viosslfactories.c | 62 ---------------------- 3 files changed, 31 insertions(+), 62 deletions(-) diff --git a/databases/mysql57-client/files/patch-mysys__ssl_my__kdf.cc b/databases/mysql57-client/files/patch-mysys__ssl_my__kdf.cc new file mode 100644 index 000000000000..f01df5434093 --- /dev/null +++ b/databases/mysql57-client/files/patch-mysys__ssl_my__kdf.cc @@ -0,0 +1,20 @@ +--- mysys_ssl/my_kdf.cc.orig 2022-11-04 07:31:17 UTC ++++ mysys_ssl/my_kdf.cc +@@ -59,7 +59,7 @@ int create_kdf_key(const unsigned char *key, const uns + Key_derivation_function *kdf_function = NULL; + + if (kdf_name == "hkdf") { +-#if OPENSSL_VERSION_NUMBER >= 0x10100000L ++#if OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER) + kdf_function = new Key_hkdf_function(kdf_options); + #else + return 1; +@@ -87,7 +87,7 @@ Key_derivation_function::Key_derivation_function() { + options_valid_ = false; + } + +-#if OPENSSL_VERSION_NUMBER >= 0x10100000L ++#if OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER) + Key_hkdf_function::Key_hkdf_function(vector *kdf_options) { + kdf_options_ = kdf_options; + } diff --git a/databases/mysql57-client/files/patch-mysys__ssl_my__kdf.h b/databases/mysql57-client/files/patch-mysys__ssl_my__kdf.h new file mode 100644 index 000000000000..5366bfbe1d32 --- /dev/null +++ b/databases/mysql57-client/files/patch-mysys__ssl_my__kdf.h @@ -0,0 +1,11 @@ +--- mysys_ssl/my_kdf.h.orig 2022-11-04 07:35:11 UTC ++++ mysys_ssl/my_kdf.h +@@ -61,7 +61,7 @@ class Key_derivation_function { + bool options_valid_; + }; + +-#if OPENSSL_VERSION_NUMBER >= 0x10100000L ++#if OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER) + + /** Class to implement KDF method hkdf. */ + class Key_hkdf_function : public Key_derivation_function { diff --git a/databases/mysql57-client/files/patch-vio_viosslfactories.c b/databases/mysql57-client/files/patch-vio_viosslfactories.c deleted file mode 100644 index 00c32ea9dca3..000000000000 --- a/databases/mysql57-client/files/patch-vio_viosslfactories.c +++ /dev/null @@ -1,62 +0,0 @@ ---- vio/viosslfactories.c -+++ vio/viosslfactories.c -@@ -123,21 +123,19 @@ static DH *get_dh2048(void) - DH *dh; - if ((dh=DH_new())) - { -- BIGNUM *p= BN_bin2bn(dh2048_p, sizeof(dh2048_p), NULL); -- BIGNUM *g= BN_bin2bn(dh2048_g, sizeof(dh2048_g), NULL); -- if (!p || !g --#if OPENSSL_VERSION_NUMBER >= 0x10100000L -- || !DH_set0_pqg(dh, p, NULL, g) --#endif /* OPENSSL_VERSION_NUMBER >= 0x10100000L */ -- ) { -- /* DH_free() will free 'p' and 'g' at once. */ -+ BIGNUM *p = BN_bin2bn(dh2048_p,sizeof(dh2048_p), NULL); -+ BIGNUM *g = BN_bin2bn(dh2048_g,sizeof(dh2048_g), NULL); -+#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER) -+ dh->p=p; -+ dh->g=g; -+ if (! dh->p || ! dh->g) -+#else -+ if (!DH_set0_pqg(dh, p, NULL, g)) -+#endif -+ { - DH_free(dh); -- return NULL; -+ dh = NULL; - } --#if OPENSSL_VERSION_NUMBER < 0x10100000L -- dh->p= p; -- dh->g= g; --#endif /* OPENSSL_VERSION_NUMBER < 0x10100000L */ - } - return(dh); - } -@@ -503,7 +501,7 @@ new_VioSSLFd(const char *key_file, const char *cert_fi - struct st_VioSSLFd *ssl_fd; - /* MySQL 5.7 supports TLS up to v1.2, explicitly disable TLSv1.3. */ - long ssl_ctx_options= SSL_OP_NO_SSLv2 | SSL_OP_NO_SSLv3 --#ifdef HAVE_TLSv13 -+#if defined(HAVE_TLSv13) && !defined(LIBRESSL_VERSION_NUMBER) - | SSL_OP_NO_TLSv1_3 - #endif /* HAVE_TLSv13 */ - ; -@@ -536,7 +534,7 @@ new_VioSSLFd(const char *key_file, const char *cert_fi - SSL_OP_NO_TLSv1 | - SSL_OP_NO_TLSv1_1 - | SSL_OP_NO_TLSv1_2 --#ifdef HAVE_TLSv13 -+#if defined(HAVE_TLSv13) && !defined(LIBRESSL_VERSION_NUMBER) - | SSL_OP_NO_TLSv1_3 - #endif /* HAVE_TLSv13 */ - | SSL_OP_NO_TICKET -@@ -559,7 +557,7 @@ new_VioSSLFd(const char *key_file, const char *cert_fi - - SSL_CTX_set_options(ssl_fd->ssl_context, ssl_ctx_options); - --#ifdef HAVE_TLSv13 -+#if defined(HAVE_TLSv13) && !defined(LIBRESSL_VERSION_NUMBER) - /* - MySQL 5.7 doesn't support TLSv1.3 - set empty TLSv1.3 ciphersuites. - */