Merge pull request #9752 from douzzer/20260207-fixes

20260207-fixes
This commit is contained in:
David Garske
2026-02-07 12:43:22 -08:00
committed by GitHub
2 changed files with 6 additions and 3 deletions
+2 -1
View File
@@ -663,8 +663,9 @@ int wolfSSL_CTX_SetTmpEC_DHE_Sz(WOLFSSL_CTX* ctx, word16 sz)
if (sz < ECC_MINSIZE) {
ret = BAD_FUNC_ARG;
}
else
#endif
else if (sz > ECC_MAXSIZE) {
if (sz > ECC_MAXSIZE) {
ret = BAD_FUNC_ARG;
}
else {
+4 -2
View File
@@ -1206,12 +1206,14 @@ PKCS7* wolfSSL_SMIME_read_PKCS7(WOLFSSL_BIO* in,
/* If line endings were added, the initial length may be
* exceeded. */
if ((canonPos + canonLineLen) >= canonSize) {
char* newCanonSection;
canonSize = canonPos + canonLineLen;
canonSection = (char*)XREALLOC(canonSection, canonSize,
newCanonSection = (char*)XREALLOC(canonSection, canonSize,
NULL, DYNAMIC_TYPE_PKCS7);
if (canonSection == NULL) {
if (newCanonSection == NULL) {
goto error;
}
canonSection = newCanonSection;
}
XMEMCPY(&canonSection[canonPos], canonLine,
(int)canonLineLen - 1);