1
mirror of https://github.com/hashcat/hashcat synced 2024-12-09 02:13:10 +01:00

Fixed checking the length of the last token in a hash if it was given the attribute TOKEN_ATTR_FIXED_LENGTH

Fixes https://github.com/hashcat/hashcat/issues/1755
This commit is contained in:
Jens Steube 2018-11-04 09:41:07 +01:00
parent c804d79eb8
commit 399bd2562a
2 changed files with 12 additions and 1 deletions

View File

@ -20,6 +20,7 @@
## Improvements
##
- Memory: Limit maximum host memory to allocate depending on bitness
- Tests: Added hash-modes 11700 (Streebog-256) and 11800 (Streebog-512)
- Tests: Added hash-mode 11850 (HMAC-Streebog-512 (key = $pass), big-endian)
@ -33,6 +34,7 @@
- Fixed ignoring --brain-client-features configuration when brain-server has attack positions information from a previous run
- Fixed missing call to WSACleanup() to cleanly shutdown windows sockets system
- Fixed missing call to WSAStartup() and client indexing in order to start the brain server on Windows
- Fixed checking the length of the last token in a hash if it was given the attribute TOKEN_ATTR_FIXED_LENGTH
- Fixed out-of-bounds write in short-term memory of the brain-server
* changes v4.2.1 -> v5.0.0

View File

@ -2556,7 +2556,16 @@ static int input_tokenizer (u8 *input_buf, int input_len, token_t *token)
}
}
token->len[token_idx] = len_left;
if (token->attr[token_idx] & TOKEN_ATTR_FIXED_LENGTH)
{
int len = token->len[token_idx];
if (len_left != len) return (PARSER_TOKEN_LENGTH);
}
else
{
token->len[token_idx] = len_left;
}
// verify data