You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if (sourcelen < 2 * SHA_DIGEST_LENGTH - 1) // this will take false blockreturnfalse;
saltlen = sourcelen - 2 * SHA_DIGEST_LENGTH - 1; // sourcelen == 2 * SHA_DIGEST_LENGTH - 1, then saltlen should be assigned 0;
salt = tr_malloc (saltlen); // malloc(0), then salt = NULLmemcpy (salt, ssha1 + 2 * SHA_DIGEST_LENGTH + 1, saltlen); // <== pass invalid null pointer into memcpy,
I think most of memcpy implementations would do nothing if len argument is 0, but passing null pointer into is an undefined behaviour, may be you could take a look and see if there are any problems
The text was updated successfully, but these errors were encountered:
need a look,
In function tr_ssha1_matches, in line 165 ,if sourcelen equals 2 * SHA_DIGEST_LENGTH - 1,
then
I think most of memcpy implementations would do nothing if len argument is 0, but passing null pointer into is an undefined behaviour, may be you could take a look and see if there are any problems
The text was updated successfully, but these errors were encountered: