Fix misleading comment that stated "43-char (minimum) hash" when
the actual regex pattern requires exactly 43 characters. Update
comment to accurately reflect the implementation behavior.
Signed-off-by: Iker Pedrosa <ipedrosa@redhat.com>
Reviewed-by: Alejandro Colomar <alx@kernel.org>
if (strlen(hash) < 13)
return false;
- // Yescrypt: $y$ + algorithm parameters + $ + salt + $ + 43-char (minimum) hash
+ // Yescrypt: $y$ + algorithm parameters + $ + salt + $ + 43-char hash
if (match_regex("^\\$y\\$[./A-Za-z0-9]+\\$[./A-Za-z0-9]{1,86}\\$[./A-Za-z0-9]{43}$", hash))
return true;