From: "cron2 (Code Review)" Date: Thu, 23 Oct 2025 15:50:53 +0000 In-Reply-To: References: Reply-To: gert@...1296..., arne-openvpn@...1227..., openvpn-devel@lists.sourceforge.net, frank@...2641... Message-ID: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Disposition: inline Content-Type: multipart/alternative; boundary="dM5a0YDqcbc="; charset=UTF-8 Subject: [Openvpn-devel] [XS] Change in openvpn[release/2.6]: Do not try to use the encrypt-then-mac ciphers from OpenSSL 3.6.0 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: plaisthos Cc: flichtenheld , openvpn-devel --dM5a0YDqcbc= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable cron2 has submitted this change. ( http://gerrit.openvpn.net/c/openvpn/+/12= 95?usp=3Demail ) Change subject: Do not try to use the encrypt-then-mac ciphers from OpenSSL= 3.6.0 ...................................................................... Do not try to use the encrypt-then-mac ciphers from OpenSSL 3.6.0 These ciphers claim to be CBC but since they are also include an HMAC are more a mix of AEAD and CBC. Nevertheless, we do not support these and also have no (good) reason to support them. Change-Id: Iafe3c94b952cd3fbecf6f3d05816e5859f425e7d Signed-off-by: Arne Schwabe Acked-by: Gert Doering Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1295 Message-Id: <20251023153514.18691-1-gert@...1296...> URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg33= 849.html Signed-off-by: Gert Doering --- M src/openvpn/crypto_openssl.c M src/openvpn/openssl_compat.h 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/openvpn/crypto_openssl.c b/src/openvpn/crypto_openssl.c index 331af99..280389c 100644 --- a/src/openvpn/crypto_openssl.c +++ b/src/openvpn/crypto_openssl.c @@ -798,7 +798,8 @@ #ifdef EVP_CIPH_FLAG_CTS && !(EVP_CIPHER_flags(cipher) & EVP_CIPH_FLAG_CT= S) #endif - && !(EVP_CIPHER_flags(cipher) & EVP_CIPH_FLAG_AE= AD_CIPHER)); + && !(EVP_CIPHER_flags(cipher) & EVP_CIPH_FLAG_AE= AD_CIPHER) + && !(EVP_CIPHER_flags(cipher) & EVP_CIPH_FLAG_EN= C_THEN_MAC)); EVP_CIPHER_free(cipher); return ret; } diff --git a/src/openvpn/openssl_compat.h b/src/openvpn/openssl_compat.h index c9fa719..03ece13 100644 --- a/src/openvpn/openssl_compat.h +++ b/src/openvpn/openssl_compat.h @@ -817,4 +817,9 @@ #endif /* OPENSSL_VERSION_NUMBER < 0x30000000L */ +/* Introduced in OpenSSL 3.6.0 */ +#ifndef EVP_CIPH_FLAG_ENC_THEN_MAC +#define EVP_CIPH_FLAG_ENC_THEN_MAC 0x10000000 +#endif + #endif /* OPENSSL_COMPAT_H_ */ -- To view, visit http://gerrit.openvpn.net/c/openvpn/+/1295?usp=3Demail To unsubscribe, or for help writing mail filters, visit http://gerrit.openv= pn.net/settings?usp=3Demail Gerrit-MessageType: merged Gerrit-Project: openvpn Gerrit-Branch: release/2.6 Gerrit-Change-Id: Iafe3c94b952cd3fbecf6f3d05816e5859f425e7d Gerrit-Change-Number: 1295 Gerrit-PatchSet: 2 Gerrit-Owner: plaisthos Gerrit-Reviewer: cron2 Gerrit-Reviewer: flichtenheld Gerrit-CC: openvpn-devel --dM5a0YDqcbc= Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

cron2 sub= mitted this change.

View Change

Do not try to use the encrypt-then-mac ciphers f=
rom OpenSSL 3.6.0

These ciphers claim to be CBC but since they are a= lso include an HMAC
are more a mix of AEAD and CBC. Nevertheless, we do = not support these
and also have no (good) reason to support them.
Change-Id: Iafe3c94b952cd3fbecf6f3d05816e5859f425e7d
Signed-off-by: Arn= e Schwabe <arne@...1227...>
Acked-by: Gert Doering <gert@...1826...= 6...>
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1295
Mess= age-Id: <20251023153514.18691-1-gert@...1296...>
URL: https://www.= mail-archive.com/openvpn-devel@lists.sourceforge.net/msg33849.html
Signe= d-off-by: Gert Doering <gert@...1296...>
---
M src/openvpn/cryp= to_openssl.c
M src/openvpn/openssl_compat.h
2 files changed, 7 insert= ions(+), 1 deletion(-)

diff --git a/src/openvpn/crypto_openssl.c b/src/openvpn/crypto_openssl.c=

index 331af99..280389c 100644
--- a/src/op= envpn/crypto_openssl.c
+++ b/src/openvpn/crypto_openssl.c
@@ -798,7 +798,8 @@
#ifdef EVP_CIPH_FLAG_CT= S
&& !(EVP_CIPHER_flags(= cipher) & EVP_CIPH_FLAG_CTS)
#endif
- && !(E= VP_CIPHER_flags(cipher) & EVP_CIPH_FLAG_AEAD_CIPHER));
+ &&= !(EVP_CIPHER_flags(cipher) & EVP_CIPH_FLAG_AEAD_CIPHER)
+ &&am= p; !(EVP_CIPHER_flags(cipher) & EVP_CIPH_FLAG_ENC_THEN_MAC));
EVP_CIPHER_free(cipher);
return ret;
}
diff --git a/src/openvpn/openssl_compat.h b/s= rc/openvpn/openssl_compat.h
index c9fa719..03ece13 100644
--- a/src/openvpn/openssl_compat.h
+++ b/src= /openvpn/openssl_compat.h
@@ -817,4 +817,9 @@

#endif /* OPENSSL_VERSION_NUMBER < 0x30000000L */<= /span>

+/*= Introduced in OpenSSL 3.6.0 */
+#ifndef EVP_CIPH_FLAG_ENC_THEN_MAC
+#define EVP_CIPH_FLAG_ENC_THEN_MAC 0x10000000
+#endif
+

#endif /* OPENSSL= _COMPAT_H_ */

To view, visit change 1295. T= o unsubscribe, or for help writing mail filters, visit settings.

Gerrit-MessageType: merged
Gerrit-Project: openvpn
Gerrit-Branch: release/2.6
Gerrit-Change-Id: Iafe3c94b952cd3fbecf6f3d0581= 6e5859f425e7d
Gerrit-Change-Number: 1295
Gerrit-PatchSet: 2
Gerrit-Owner: plaisthos <arne-openvpn@...1711...= 27...>
Gerrit-Reviewer: cron2 <gert@...1296...>=
Gerrit-Reviewer: flichtenheld <frank@...2716...= 1...>
Gerrit-CC: openvpn-devel <openvpn-devel@...1484...= ts.sourceforge.net>
= --dM5a0YDqcbc=--