Commit 10f74272 authored by Ryan Tandy's avatar Ryan Tandy Committed by Quanah Gibson-Mount
Browse files

ITS#7851 contrib pw-sha2 fix int/size_t comparison

parent a1968c61
......@@ -244,7 +244,7 @@ static int chk_ssha256(
rc = lutil_b64_pton(passwd->bv_val, orig_pass, decode_len);
if( rc <= sizeof(SHAdigest) ) {
if( rc <= (int)(sizeof(SHAdigest)) ) {
ber_memfree(orig_pass);
return LUTIL_PASSWD_ERR;
}
......@@ -332,7 +332,7 @@ static int chk_ssha384(
rc = lutil_b64_pton(passwd->bv_val, orig_pass, decode_len);
if( rc <= sizeof(SHAdigest) ) {
if( rc <= (int)(sizeof(SHAdigest)) ) {
ber_memfree(orig_pass);
return LUTIL_PASSWD_ERR;
}
......@@ -420,7 +420,7 @@ static int chk_ssha512(
rc = lutil_b64_pton(passwd->bv_val, orig_pass, decode_len);
if( rc <= sizeof(SHAdigest) ) {
if( rc <= (int)(sizeof(SHAdigest)) ) {
ber_memfree(orig_pass);
return LUTIL_PASSWD_ERR;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment