mirror of
https://github.com/hashcat/hashcat.git
synced 2024-11-22 08:08:10 +00:00
Align loading rules log event usage with other log events
This commit is contained in:
parent
b403f622ee
commit
77c9f096db
@ -156,11 +156,13 @@ typedef enum event_identifier
|
|||||||
EVENT_POTFILE_NUM_CRACKED = 0x000000c3,
|
EVENT_POTFILE_NUM_CRACKED = 0x000000c3,
|
||||||
EVENT_POTFILE_REMOVE_PARSE_POST = 0x000000c4,
|
EVENT_POTFILE_REMOVE_PARSE_POST = 0x000000c4,
|
||||||
EVENT_POTFILE_REMOVE_PARSE_PRE = 0x000000c5,
|
EVENT_POTFILE_REMOVE_PARSE_PRE = 0x000000c5,
|
||||||
EVENT_SELFTEST_FINISHED = 0x000000d0,
|
EVENT_RULESFILES_PARSE_POST = 0x000000d4,
|
||||||
EVENT_SELFTEST_STARTING = 0x000000d1,
|
EVENT_RULESFILES_PARSE_PRE = 0x000000d5,
|
||||||
EVENT_SET_KERNEL_POWER_FINAL = 0x000000e0,
|
EVENT_SELFTEST_FINISHED = 0x000000e0,
|
||||||
EVENT_WORDLIST_CACHE_GENERATE = 0x000000f0,
|
EVENT_SELFTEST_STARTING = 0x000000e1,
|
||||||
EVENT_WORDLIST_CACHE_HIT = 0x000000f1,
|
EVENT_SET_KERNEL_POWER_FINAL = 0x000000f0,
|
||||||
|
EVENT_WORDLIST_CACHE_GENERATE = 0x00000110,
|
||||||
|
EVENT_WORDLIST_CACHE_HIT = 0x00000111,
|
||||||
|
|
||||||
// there will be much more event types soon
|
// there will be much more event types soon
|
||||||
|
|
||||||
|
20
src/main.c
20
src/main.c
@ -392,6 +392,24 @@ static void main_potfile_remove_parse_post (MAYBE_UNUSED hashcat_ctx_t *hashcat_
|
|||||||
event_log_info_nn (hashcat_ctx, "Compared hashes with potfile entries");
|
event_log_info_nn (hashcat_ctx, "Compared hashes with potfile entries");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void main_rulesfiles_parse_pre (MAYBE_UNUSED hashcat_ctx_t *hashcat_ctx, MAYBE_UNUSED const void *buf, MAYBE_UNUSED const size_t len)
|
||||||
|
{
|
||||||
|
const user_options_t *user_options = hashcat_ctx->user_options;
|
||||||
|
|
||||||
|
if (user_options->quiet == true) return;
|
||||||
|
|
||||||
|
event_log_info_nn (hashcat_ctx, "Loading rules. Please be patient...");
|
||||||
|
}
|
||||||
|
|
||||||
|
static void main_rulesfiles_parse_post (MAYBE_UNUSED hashcat_ctx_t *hashcat_ctx, MAYBE_UNUSED const void *buf, MAYBE_UNUSED const size_t len)
|
||||||
|
{
|
||||||
|
const user_options_t *user_options = hashcat_ctx->user_options;
|
||||||
|
|
||||||
|
if (user_options->quiet == true) return;
|
||||||
|
|
||||||
|
event_log_info_nn (hashcat_ctx, "Loading rules finished");
|
||||||
|
}
|
||||||
|
|
||||||
static void main_potfile_hash_show (MAYBE_UNUSED hashcat_ctx_t *hashcat_ctx, MAYBE_UNUSED const void *buf, MAYBE_UNUSED const size_t len)
|
static void main_potfile_hash_show (MAYBE_UNUSED hashcat_ctx_t *hashcat_ctx, MAYBE_UNUSED const void *buf, MAYBE_UNUSED const size_t len)
|
||||||
{
|
{
|
||||||
outfile_ctx_t *outfile_ctx = hashcat_ctx->outfile_ctx;
|
outfile_ctx_t *outfile_ctx = hashcat_ctx->outfile_ctx;
|
||||||
@ -1184,6 +1202,8 @@ static void event (const u32 id, hashcat_ctx_t *hashcat_ctx, const void *buf, co
|
|||||||
case EVENT_POTFILE_NUM_CRACKED: main_potfile_num_cracked (hashcat_ctx, buf, len); break;
|
case EVENT_POTFILE_NUM_CRACKED: main_potfile_num_cracked (hashcat_ctx, buf, len); break;
|
||||||
case EVENT_POTFILE_REMOVE_PARSE_POST: main_potfile_remove_parse_post (hashcat_ctx, buf, len); break;
|
case EVENT_POTFILE_REMOVE_PARSE_POST: main_potfile_remove_parse_post (hashcat_ctx, buf, len); break;
|
||||||
case EVENT_POTFILE_REMOVE_PARSE_PRE: main_potfile_remove_parse_pre (hashcat_ctx, buf, len); break;
|
case EVENT_POTFILE_REMOVE_PARSE_PRE: main_potfile_remove_parse_pre (hashcat_ctx, buf, len); break;
|
||||||
|
case EVENT_RULESFILES_PARSE_POST: main_rulesfiles_parse_post (hashcat_ctx, buf, len); break;
|
||||||
|
case EVENT_RULESFILES_PARSE_PRE: main_rulesfiles_parse_pre (hashcat_ctx, buf, len); break;
|
||||||
case EVENT_SET_KERNEL_POWER_FINAL: main_set_kernel_power_final (hashcat_ctx, buf, len); break;
|
case EVENT_SET_KERNEL_POWER_FINAL: main_set_kernel_power_final (hashcat_ctx, buf, len); break;
|
||||||
case EVENT_WORDLIST_CACHE_GENERATE: main_wordlist_cache_generate (hashcat_ctx, buf, len); break;
|
case EVENT_WORDLIST_CACHE_GENERATE: main_wordlist_cache_generate (hashcat_ctx, buf, len); break;
|
||||||
case EVENT_WORDLIST_CACHE_HIT: main_wordlist_cache_hit (hashcat_ctx, buf, len); break;
|
case EVENT_WORDLIST_CACHE_HIT: main_wordlist_cache_hit (hashcat_ctx, buf, len); break;
|
||||||
|
@ -289,8 +289,11 @@ int straight_ctx_init (hashcat_ctx_t *hashcat_ctx)
|
|||||||
{
|
{
|
||||||
if (user_options->rp_files_cnt)
|
if (user_options->rp_files_cnt)
|
||||||
{
|
{
|
||||||
event_log_info_nn(hashcat_ctx, "Loading Rules");
|
EVENT (EVENT_RULESFILES_PARSE_PRE);
|
||||||
|
|
||||||
if (kernel_rules_load (hashcat_ctx, &straight_ctx->kernel_rules_buf, &straight_ctx->kernel_rules_cnt) == -1) return -1;
|
if (kernel_rules_load (hashcat_ctx, &straight_ctx->kernel_rules_buf, &straight_ctx->kernel_rules_cnt) == -1) return -1;
|
||||||
|
|
||||||
|
EVENT (EVENT_RULESFILES_PARSE_POST);
|
||||||
}
|
}
|
||||||
else if (user_options->rp_gen)
|
else if (user_options->rp_gen)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user