mirror of
https://github.com/hashcat/hashcat.git
synced 2024-12-24 07:28:10 +00:00
Fix invalid strdup of NULL in stdin mode
This commit is contained in:
parent
9ab1fefd19
commit
826de76bd6
10
src/status.c
10
src/status.c
@ -430,13 +430,17 @@ int status_get_input_mode (const hashcat_ctx_t *hashcat_ctx)
|
||||
|
||||
char *status_get_input_base (const hashcat_ctx_t *hashcat_ctx)
|
||||
{
|
||||
const user_options_t *user_options = hashcat_ctx->user_options;
|
||||
const user_options_t *user_options = hashcat_ctx->user_options;
|
||||
const user_options_extra_t *user_options_extra = hashcat_ctx->user_options_extra;
|
||||
|
||||
if (user_options->attack_mode == ATTACK_MODE_STRAIGHT)
|
||||
{
|
||||
const straight_ctx_t *straight_ctx = hashcat_ctx->straight_ctx;
|
||||
if (user_options_extra->wordlist_mode == WL_MODE_FILE)
|
||||
{
|
||||
const straight_ctx_t *straight_ctx = hashcat_ctx->straight_ctx;
|
||||
|
||||
return strdup (straight_ctx->dict);
|
||||
return strdup (straight_ctx->dict);
|
||||
}
|
||||
}
|
||||
else if (user_options->attack_mode == ATTACK_MODE_COMBI)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user