mirror of
https://github.com/hashcat/hashcat.git
synced 2024-11-23 08:38:09 +00:00
Fix CID 1402873: Dereference before null check
This commit is contained in:
parent
1afc47829f
commit
6bcfca26b3
@ -619,8 +619,6 @@ int potfile_handle_show (hashcat_ctx_t *hashcat_ctx)
|
||||
|
||||
u32 user_len = 0;
|
||||
|
||||
if (hash1->hash_info != NULL)
|
||||
{
|
||||
user_t *user = hash1->hash_info->user;
|
||||
|
||||
if (user)
|
||||
@ -631,7 +629,6 @@ int potfile_handle_show (hashcat_ctx_t *hashcat_ctx)
|
||||
|
||||
username[user_len] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
u8 *tmp_buf = potfile_ctx->tmp_buf;
|
||||
|
||||
@ -641,8 +638,6 @@ int potfile_handle_show (hashcat_ctx_t *hashcat_ctx)
|
||||
|
||||
u8 mixed_len = 0;
|
||||
|
||||
if (hash1)
|
||||
{
|
||||
if (digests_shown[hashes_idx] == 1)
|
||||
{
|
||||
memcpy (mixed_buf + mixed_len, hash1->pw_buf, hash1->pw_len);
|
||||
@ -655,7 +650,6 @@ int potfile_handle_show (hashcat_ctx_t *hashcat_ctx)
|
||||
|
||||
mixed_len += strlen (LM_MASKED_PLAIN);
|
||||
}
|
||||
}
|
||||
|
||||
if (hash2)
|
||||
{
|
||||
@ -803,8 +797,6 @@ int potfile_handle_left (hashcat_ctx_t *hashcat_ctx)
|
||||
|
||||
u32 user_len = 0;
|
||||
|
||||
if (hash1->hash_info != NULL)
|
||||
{
|
||||
user_t *user = hash1->hash_info->user;
|
||||
|
||||
if (user)
|
||||
@ -815,7 +807,6 @@ int potfile_handle_left (hashcat_ctx_t *hashcat_ctx)
|
||||
|
||||
username[user_len] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
u8 *tmp_buf = potfile_ctx->tmp_buf;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user