1
0
mirror of https://github.com/hashcat/hashcat.git synced 2024-11-14 03:39:09 +00:00

Give an explicit feedback when invalid hash modes are requested

This commit is contained in:
Jens Steube 2022-04-06 23:38:24 +02:00
parent 5436f0d43e
commit c371caa1d5

View File

@ -37,6 +37,18 @@ bool module_load (hashcat_ctx_t *hashcat_ctx, module_ctx_t *module_ctx, const u3
module_filename (folder_config, hash_mode, module_file, HCBUFSIZ_TINY);
struct stat s;
memset (&s, 0, sizeof (struct stat));
if (stat (module_file, &s) == -1)
{
event_log_warning (hashcat_ctx, "Either the specified hash mode does not exist in the official repository,");
event_log_warning (hashcat_ctx, "or the file(s) could not be found. Please check that the hash mode number is");
event_log_warning (hashcat_ctx, "correct and that the files are in the correct place.");
event_log_warning (hashcat_ctx, NULL);
}
module_ctx->module_handle = hc_dlopen (module_file);
if (module_ctx->module_handle == NULL)