mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2026-01-31 04:09:15 +01:00
Merge pull request #7106 from bandi13/20231114-codesonar-fixes
20231114 codesonar fixes
This commit is contained in:
@@ -186,6 +186,7 @@ int BuildTlsFinished(WOLFSSL* ssl, Hashes* hashes, const byte* sender)
|
||||
return MEMORY_E;
|
||||
#endif
|
||||
|
||||
XMEMSET(handshake_hash, 0, HSHASH_SZ);
|
||||
ret = BuildTlsHandshakeHash(ssl, handshake_hash, &hashSz);
|
||||
if (ret == 0) {
|
||||
if (XSTRNCMP((const char*)sender, (const char*)kTlsClientStr,
|
||||
|
||||
@@ -11173,7 +11173,7 @@ err:
|
||||
pemSz = (int)(l - i);
|
||||
|
||||
/* check calculated length */
|
||||
if (pemSz > MAX_WOLFSSL_FILE_SIZE || pemSz < 0) {
|
||||
if (pemSz > MAX_WOLFSSL_FILE_SIZE || pemSz <= 0) {
|
||||
WOLFSSL_MSG("PEM_read_X509_ex file size error");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user