Fixed invalid progress counter initialization in attack-mode 9 when using --skip or --restore

pull/2958/head
Jens Steube 3 years ago
parent aaf26dee98
commit bdd3f27239

@ -4,6 +4,7 @@
## Bugs
##
- Fixed invalid progress counter initialization in attack-mode 9 when using --skip or --restore
- Fixed out-of-boundary reads in attack-mode 9 that were caused by a missing work item limit in the refactored autotune engine
##

@ -148,11 +148,23 @@ static int inner2_loop (hashcat_ctx_t *hashcat_ctx)
return -1;
}
const u64 progress_restored = status_ctx->words_off * amplifier_cnt;
if (user_options->attack_mode == ATTACK_MODE_ASSOCIATION)
{
const u64 progress_restored = 1 * amplifier_cnt;
for (u32 i = 0; i < hashes->salts_cnt; i++)
for (u32 i = 0; i < status_ctx->words_off; i++)
{
status_ctx->words_progress_restored[i] = progress_restored;
}
}
else
{
status_ctx->words_progress_restored[i] = progress_restored;
const u64 progress_restored = status_ctx->words_off * amplifier_cnt;
for (u32 i = 0; i < hashes->salts_cnt; i++)
{
status_ctx->words_progress_restored[i] = progress_restored;
}
}
#ifdef WITH_BRAIN

Loading…
Cancel
Save