1
0
mirror of https://github.com/hashcat/hashcat.git synced 2024-11-13 19:28:56 +00:00

Wordlists: Fixed memory leak in case access a file in a wordlist folder fails

This commit is contained in:
jsteube 2017-02-14 15:47:41 +01:00
parent 1fc24cbcd3
commit a9b0f1a559
2 changed files with 25 additions and 3 deletions

View File

@ -79,6 +79,7 @@
- File Locking: Improved error detection on file locks
- Sessions: Move out handling of multiple instance from restore file into separate pidfile
- Threads: Restored strerror as %m is unsupported by the BSDs
- Wordlists: Fixed memory leak in case access a file in a wordlist folder fails
- Wordlists: Disable dictstat handling for hash-mode 3000 as it virtually creates words in the wordlist which is not the case for other modes
- WPA: Changed format for outfile and potfile from essid:mac1:mac2 to hash:essid
- WPA: Changed format for outfile_check from essid:mac1:mac2 to hash

View File

@ -288,6 +288,8 @@ int straight_ctx_init (hashcat_ctx_t *hashcat_ctx)
{
event_log_error (hashcat_ctx, "%s: %s", l1_filename, strerror (errno));
hcfree (dictionary_files);
return -1;
}
@ -295,7 +297,12 @@ int straight_ctx_init (hashcat_ctx_t *hashcat_ctx)
{
const int rc = straight_ctx_add_wl (hashcat_ctx, l1_filename);
if (rc == -1) return -1;
if (rc == -1)
{
hcfree (dictionary_files);
return -1;
}
}
}
}
@ -352,6 +359,8 @@ int straight_ctx_init (hashcat_ctx_t *hashcat_ctx)
{
event_log_error (hashcat_ctx, "%s: %s", l1_filename, strerror (errno));
hcfree (dictionary_files);
return -1;
}
@ -359,7 +368,12 @@ int straight_ctx_init (hashcat_ctx_t *hashcat_ctx)
{
const int rc = straight_ctx_add_wl (hashcat_ctx, l1_filename);
if (rc == -1) return -1;
if (rc == -1)
{
hcfree (dictionary_files);
return -1;
}
}
}
}
@ -407,6 +421,8 @@ int straight_ctx_init (hashcat_ctx_t *hashcat_ctx)
{
event_log_error (hashcat_ctx, "%s: %s", l1_filename, strerror (errno));
hcfree (dictionary_files);
return -1;
}
@ -414,7 +430,12 @@ int straight_ctx_init (hashcat_ctx_t *hashcat_ctx)
{
const int rc = straight_ctx_add_wl (hashcat_ctx, l1_filename);
if (rc == -1) return -1;
if (rc == -1)
{
hcfree (dictionary_files);
return -1;
}
}
}
}