diff --git a/docs/changes.txt b/docs/changes.txt index 739498004..ec0a01797 100644 --- a/docs/changes.txt +++ b/docs/changes.txt @@ -42,6 +42,7 @@ - Hash Parser: Improved error detection of invalid hex characters where hex character are expected - OpenCL Runtime: Updated AMDGPU-Pro driver version check, do warn if version 16.50 is detected which is known to be broken - Potfile: In v3.10 already, the default potfile suffix changed but the note about was missing. The "hashcat.pot" became "hashcat.potfile" +- Potfile: Added old potfile detection, show warning message - Sanity: Added sanity check to disallow --speed-only in combination with -i - Threads: Replaced all calls to ctime() with ctime_r() to ensure thread safety - Threads: Replaced all calls to strerror() with %m printf() GNU extension to ensure thread safety diff --git a/src/potfile.c b/src/potfile.c index aac22d6f0..af80430a7 100644 --- a/src/potfile.c +++ b/src/potfile.c @@ -125,6 +125,26 @@ int potfile_init (hashcat_ctx_t *hashcat_ctx) potfile_ctx->tmp_buf = tmp_buf; + // old potfile detection + + if (user_options->potfile_path == NULL) + { + char *potfile_old; + + hc_asprintf (&potfile_old, "%s/hashcat.pot", folder_config->profile_dir); + + hc_stat_t st; + + if (hc_stat (potfile_old, &st) == 0) + { + event_log_warning (hashcat_ctx, "Old potfile detected: %s", potfile_old); + event_log_warning (hashcat_ctx, "New potfile is: %s ", potfile_ctx->filename); + event_log_warning (hashcat_ctx, ""); + } + + hcfree (potfile_old); + } + return 0; }