mirror of
https://github.com/hashcat/hashcat.git
synced 2025-01-10 15:51:10 +00:00
Fix salt encoding
This commit is contained in:
parent
86d7f0a95b
commit
f142651f15
@ -94,7 +94,7 @@ int module_hash_encode (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSE
|
||||
{
|
||||
const u32 *digest = (const u32 *) digest_buf;
|
||||
|
||||
const int line_len = snprintf (line_buf, line_size, "%08x:%s", digest[0], (char *) salt->salt_buf);
|
||||
const int line_len = snprintf (line_buf, line_size, "%08x:%08x", digest[0], salt->salt_buf[0]);
|
||||
|
||||
return line_len;
|
||||
}
|
||||
|
@ -15,11 +15,10 @@ sub module_constraints { [[0, 255], [8, 8], [0, 31], [8, 8], [-1, -1]] }
|
||||
sub module_generate_hash
|
||||
{
|
||||
my $word = shift;
|
||||
my $salt = shift;
|
||||
|
||||
my $digest = crc32 ($word);
|
||||
|
||||
my $hash = sprintf ("%08x:$salt", $digest);
|
||||
my $hash = sprintf ("%08x:00000000", $digest);
|
||||
|
||||
return $hash;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user