1From 73aa4ef762b2de67bc8c7c260bd36b34fdb91e63 Mon Sep 17 00:00:00 2001 2From: "Sergey V. Lobanov" <sergey@lobanov.in> 3Date: Mon, 3 Jan 2022 19:36:52 +0300 4Subject: [PATCH] add compatibility for wolfssl >= 5.0 5 6NTRU support has been removed in wolfssl 5.0 so it is required to 7mask NTRU specific code if wolfssl >= 5.0 8 9Signed-off-by: Sergey V. Lobanov <sergey at lobanov.in> 10[Retrieved from: 11https://github.com/zhaojh329/ssl/commit/73aa4ef762b2de67bc8c7c260bd36b34fdb91e63] 12Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> 13--- 14 openssl.c | 2 ++ 15 1 file changed, 2 insertions(+) 16 17diff --git a/src/ssl/openssl.c b/src/ssl/openssl.c 18index 5a49267..278bab5 100644 19--- a/src/ssl/openssl.c 20+++ b/src/ssl/openssl.c 21@@ -336,7 +336,9 @@ static bool handle_wolfssl_asn_error(void *ssl, int r, 22 case ASN_SIG_HASH_E: 23 case ASN_SIG_KEY_E: 24 case ASN_DH_KEY_E: 25+#if LIBWOLFSSL_VERSION_HEX < 0x05000000 26 case ASN_NTRU_KEY_E: 27+#endif 28 case ASN_CRIT_EXT_E: 29 case ASN_ALT_NAME_E: 30 case ASN_NO_PEM_HEADER: 31