[wolfssl] update to 5.6.3 (#32325)

This commit is contained in:
JacobBarthelmeh 2023-07-27 10:23:06 -06:00 committed by GitHub
parent 16eeb024de
commit c415aabf1e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
14 changed files with 94 additions and 57 deletions

View File

@ -0,0 +1,19 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 32f0332..4cec80c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -65,12 +65,12 @@ else()
target_compile_options(wolfmqtt PUBLIC ${WOLFSSL_CFLAGS_OTHER})
else()
# For support with vcpkg
- find_package(wolfssl CONFIG)
+ find_package(wolfssl CONFIG REQUIRED)
if (wolfssl_FOUND)
target_compile_definitions(wolfmqtt PUBLIC
"ENABLE_MQTT_TLS"
)
- target_link_libraries(wolfmqtt PUBLIC wolfssl)
+ target_link_libraries(wolfmqtt PUBLIC wolfssl::wolfssl)
endif()
endif()
endif()

View File

@ -1,9 +1,11 @@
vcpkg_from_github( vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH OUT_SOURCE_PATH SOURCE_PATH
REPO wolfssl/wolfmqtt REPO wolfssl/wolfmqtt
REF v1.15.0 REF v1.16.0
SHA512 9012e4723d469ce98bd5f0e6a3e001ab6c94c0fb4fef0d2de73446d702959052f6f5fe5a9d805b088f17c2d94a25abf41ae802421c99b62f8d8cd9a14c9e7271 SHA512 30d28a37b26adacae589b9cfee9a2cd8697fa1e84ac867d08123dab5434bb19152adb0d94224656d2c1f01833d76bcd7ff63b63da4dbce0873b352e93b6e6b12
HEAD_REF master HEAD_REF master
PATCHES
cmake-patch.diff
) )
vcpkg_cmake_configure(SOURCE_PATH ${SOURCE_PATH} vcpkg_cmake_configure(SOURCE_PATH ${SOURCE_PATH}

View File

@ -1,6 +1,6 @@
{ {
"name": "wolfmqtt", "name": "wolfmqtt",
"version": "1.15.0", "version": "1.16.0",
"description": "MQTT library used with wolfSSL library for many platforms", "description": "MQTT library used with wolfSSL library for many platforms",
"homepage": "https://wolfssl.com", "homepage": "https://wolfssl.com",
"license": "GPL-2.0-or-later", "license": "GPL-2.0-or-later",

View File

@ -1,11 +1,11 @@
vcpkg_from_github( vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH OUT_SOURCE_PATH SOURCE_PATH
REPO wolfssl/wolfssl REPO wolfssl/wolfssl
REF v5.5.4-stable REF v5.6.3-stable
SHA512 6ecb37d614ae7b8ea9caa5bedebe2bb16b2719e172e146fc707ce1ead09a6c4d168b8e8aa52255d4cf0341a0617f17d7f4b321ba88aaa77664861c31ca7a1163 SHA512 7c3b5c06ade7826031db089d50ec45c36970555499b6be94d1939b3002369fc98e503418128c6b2e253df7e92f86a71647d37f2cd27d57ac201e5aba32b879dc
HEAD_REF master HEAD_REF master
PATCHES PATCHES
pr_5949.patch warning-and-include.patch
) )
vcpkg_cmake_configure( vcpkg_cmake_configure(

View File

@ -1,46 +0,0 @@
diff --git a/src/internal.c b/src/internal.c
index 1afa361f9d0..c17158b34cd 100644
--- a/src/internal.c
+++ b/src/internal.c
@@ -12781,9 +12781,17 @@ static int ProcessPeerCertParse(WOLFSSL* ssl, ProcPeerCertArgs* args,
return BAD_FUNC_ARG;
}
+PRAGMA_GCC_DIAG_PUSH
+PRAGMA_GCC("GCC diagnostic ignored \"-Wstrict-overflow\"")
+ /* Surrounded in gcc pragma to avoid -Werror=strict-overflow when the
+ * compiler optimizes out the check and assumes no underflow. Keeping the
+ * check in place to handle multiple build configurations and future
+ * changes. */
+
/* check to make sure certificate index is valid */
if (args->certIdx > args->count)
return BUFFER_E;
+PRAGMA_GCC_DIAG_POP
/* check if returning from non-blocking OCSP */
/* skip this section because cert is already initialized and parsed */
diff --git a/wolfcrypt/src/sp_int.c b/wolfcrypt/src/sp_int.c
index b5199ed7352..cbff871f08a 100644
--- a/wolfcrypt/src/sp_int.c
+++ b/wolfcrypt/src/sp_int.c
@@ -4822,6 +4822,10 @@ int sp_copy(const sp_int* a, sp_int* r)
}
/* Only copy if different pointers. */
else if (a != r) {
+ PRAGMA_GCC_DIAG_PUSH
+ PRAGMA_GCC("GCC diagnostic ignored \"-Wstrict-overflow\"")
+ /* Surrounded in gcc pragma to avoid -Werror=strict-overflow when the
+ * compiler optimizes out the check and assumes no overflow. */
/* Validated space in result. */
if (a->used > r->size) {
err = MP_VAL;
@@ -4841,6 +4845,7 @@ int sp_copy(const sp_int* a, sp_int* r)
r->sign = a->sign;
#endif
}
+ PRAGMA_GCC_DIAG_POP
}
return err;

View File

@ -1,6 +1,6 @@
{ {
"name": "wolfssl", "name": "wolfssl",
"version": "5.5.4", "version": "5.6.3",
"description": "TLS and Cryptographic library for many platforms", "description": "TLS and Cryptographic library for many platforms",
"homepage": "https://wolfssl.com", "homepage": "https://wolfssl.com",
"license": "GPL-2.0-or-later", "license": "GPL-2.0-or-later",

View File

@ -0,0 +1,29 @@
diff --git a/wolfcrypt/src/asn.c b/wolfcrypt/src/asn.c
index 96f27928d90..51e6205cf9d 100644
--- a/wolfcrypt/src/asn.c
+++ b/wolfcrypt/src/asn.c
@@ -30431,9 +30431,9 @@ int wc_SetCustomExtension(Cert *cert, int critical, const char *oid,
ext = &cert->customCertExt[cert->customCertExtCount];
- ext->oid = oid;
+ ext->oid = (char*)oid;
ext->crit = (critical == 0) ? 0 : 1;
- ext->val = der;
+ ext->val = (byte*)der;
ext->valSz = derSz;
cert->customCertExtCount++;
diff --git a/wolfssl/wolfio.h b/wolfssl/wolfio.h
index 8c323840584..a7d70e01fbf 100644
--- a/wolfssl/wolfio.h
+++ b/wolfssl/wolfio.h
@@ -26,6 +26,8 @@
#ifndef WOLFSSL_IO_H
#define WOLFSSL_IO_H
+#include <wolfssl/ssl.h>
+
#ifdef __cplusplus
extern "C" {
#endif

View File

@ -0,0 +1,16 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index b77a9df..0c45975 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -146,9 +146,9 @@ else()
target_compile_options(wolftpm PUBLIC ${WOLFSSL_CFLAGS_OTHER})
else()
# For support with vcpkg
- find_package(wolfssl CONFIG)
+ find_package(wolfssl CONFIG REQUIRED)
if (wolfssl_FOUND)
- target_link_libraries(wolftpm PUBLIC wolfssl)
+ target_link_libraries(wolftpm PUBLIC wolfssl::wolfssl)
else()
list(APPEND WOLFTPM_DEFINITIONS "-DWOLFTPM2_NO_WOLFCRYPT")
endif()

View File

@ -4,6 +4,8 @@ vcpkg_from_github(
REF v2.7.0 REF v2.7.0
SHA512 1b3e1bbd9f6e35226ff30cc6de7631fb420343a2ae4c8849d1477314a5fe8a95b99800fa17e10a30a9894041142748d654c913a5c4f4dc9eaad3f5157e405276 SHA512 1b3e1bbd9f6e35226ff30cc6de7631fb420343a2ae4c8849d1477314a5fe8a95b99800fa17e10a30a9894041142748d654c913a5c4f4dc9eaad3f5157e405276
HEAD_REF master HEAD_REF master
PATCHES
cmake-patch.diff
) )
vcpkg_cmake_configure(SOURCE_PATH ${SOURCE_PATH} vcpkg_cmake_configure(SOURCE_PATH ${SOURCE_PATH}

View File

@ -1,7 +1,7 @@
{ {
"name": "wolftpm", "name": "wolftpm",
"version": "2.7.0", "version": "2.7.0",
"port-version": 1, "port-version": 2,
"description": "TPM library used with wolfSSL library for many platforms", "description": "TPM library used with wolfSSL library for many platforms",
"homepage": "https://wolfssl.com", "homepage": "https://wolfssl.com",
"license": "GPL-2.0-or-later", "license": "GPL-2.0-or-later",

View File

@ -8705,16 +8705,16 @@
"port-version": 3 "port-version": 3
}, },
"wolfmqtt": { "wolfmqtt": {
"baseline": "1.15.0", "baseline": "1.16.0",
"port-version": 0 "port-version": 0
}, },
"wolfssl": { "wolfssl": {
"baseline": "5.5.4", "baseline": "5.6.3",
"port-version": 0 "port-version": 0
}, },
"wolftpm": { "wolftpm": {
"baseline": "2.7.0", "baseline": "2.7.0",
"port-version": 1 "port-version": 2
}, },
"wordnet": { "wordnet": {
"baseline": "3.0", "baseline": "3.0",

View File

@ -1,5 +1,10 @@
{ {
"versions": [ "versions": [
{
"git-tree": "d01462c764790a2ab97815a9f16a40186b62de14",
"version": "1.16.0",
"port-version": 0
},
{ {
"git-tree": "b17cfe13abcf334e7f4563d5c5699c4b32078e98", "git-tree": "b17cfe13abcf334e7f4563d5c5699c4b32078e98",
"version": "1.15.0", "version": "1.15.0",

View File

@ -1,5 +1,10 @@
{ {
"versions": [ "versions": [
{
"git-tree": "e809eb7090657113c8f628ce22975c7f3bd3dbfd",
"version": "5.6.3",
"port-version": 0
},
{ {
"git-tree": "71789bbc13920d34e74d8bc23af6d5d480e7b610", "git-tree": "71789bbc13920d34e74d8bc23af6d5d480e7b610",
"version": "5.5.4", "version": "5.5.4",

View File

@ -1,5 +1,10 @@
{ {
"versions": [ "versions": [
{
"git-tree": "fe055978dbd963b2969e104333a2b79d49ff6cee",
"version": "2.7.0",
"port-version": 2
},
{ {
"git-tree": "d6849bfc65dbf33f5d51d9bc8c7a4e365a1d3553", "git-tree": "d6849bfc65dbf33f5d51d9bc8c7a4e365a1d3553",
"version": "2.7.0", "version": "2.7.0",