From a0de388bb92cf832ee513a207991379805d9bab6 Mon Sep 17 00:00:00 2001 From: Flaggx1 Date: Sun, 21 May 2023 00:05:08 -0400 Subject: [PATCH] Increase number of user-defined charsets from 4 to 9 This feature change increases the number of user-defined charsets from a maximum of 4 to 9. This enables more advanced and efficient attacks in certain cases. --- include/types.h | 12 ++++++- src/brain.c | 71 +++++++++++++++++++++++++++++++++++++++++ src/mpsp.c | 78 ++++++++++++++++++++++++++++++++++++++++++++-- src/status.c | 19 +++++++++-- src/usage.c | 5 +++ src/user_options.c | 58 +++++++++++++++++++++++++++++++--- 6 files changed, 234 insertions(+), 9 deletions(-) diff --git a/include/types.h b/include/types.h index 6fd4c4553..d059ab416 100644 --- a/include/types.h +++ b/include/types.h @@ -757,6 +757,11 @@ typedef enum user_options_map IDX_CUSTOM_CHARSET_2 = '2', IDX_CUSTOM_CHARSET_3 = '3', IDX_CUSTOM_CHARSET_4 = '4', + IDX_CUSTOM_CHARSET_5 = '5', + IDX_CUSTOM_CHARSET_6 = '6', + IDX_CUSTOM_CHARSET_7 = '7', + IDX_CUSTOM_CHARSET_8 = '8', + IDX_CUSTOM_CHARSET_9 = '9', IDX_DEBUG_FILE = 0xff12, IDX_DEBUG_MODE = 0xff13, IDX_DEPRECATED_CHECK_DISABLE = 0xff14, @@ -2377,7 +2382,7 @@ typedef struct user_options char *brain_session_whitelist; #endif char *cpu_affinity; - char *custom_charset_4; + char *custom_charset_9; char *debug_file; char *induction_dir; char *keyboard_layout_mapping; @@ -2396,6 +2401,11 @@ typedef struct user_options const char *custom_charset_1; const char *custom_charset_2; const char *custom_charset_3; + const char *custom_charset_4; + const char *custom_charset_5; + const char *custom_charset_6; + const char *custom_charset_7; + const char *custom_charset_8; const char *encoding_from; const char *encoding_to; const char *rule_buf_l; diff --git a/src/brain.c b/src/brain.c index bd97d9695..480170bb1 100644 --- a/src/brain.c +++ b/src/brain.c @@ -345,7 +345,43 @@ u32 brain_compute_attack (hashcat_ctx_t *hashcat_ctx) XXH64_update (state, custom_charset_4, strlen (custom_charset_4)); } + + if (user_options->custom_charset_5) + { + const char *custom_charset_5 = user_options->custom_charset_5; + + XXH64_update (state, custom_charset_5, strlen (custom_charset_5)); + } + + if (user_options->custom_charset_6) + { + const char *custom_charset_6 = user_options->custom_charset_6; + + XXH64_update (state, custom_charset_6, strlen (custom_charset_6)); + } + + if (user_options->custom_charset_7) + { + const char *custom_charset_7 = user_options->custom_charset_7; + + XXH64_update (state, custom_charset_7, strlen (custom_charset_7)); + } + + if (user_options->custom_charset_8) + { + const char *custom_charset_8 = user_options->custom_charset_8; + + XXH64_update (state, custom_charset_8, strlen (custom_charset_8)); + } + + if (user_options->custom_charset_9) + { + const char *custom_charset_9 = user_options->custom_charset_9; + + XXH64_update (state, custom_charset_9, strlen (custom_charset_9)); + } } + else if (user_options->attack_mode == ATTACK_MODE_HYBRID1) { const u64 wordlist_hash = brain_compute_attack_wordlist (straight_ctx->dict); @@ -405,6 +441,41 @@ u32 brain_compute_attack (hashcat_ctx_t *hashcat_ctx) XXH64_update (state, custom_charset_4, strlen (custom_charset_4)); } + if (user_options->custom_charset_5) + { + const char *custom_charset_5 = user_options->custom_charset_5; + + XXH64_update (state, custom_charset_5, strlen (custom_charset_5)); + } + + if (user_options->custom_charset_6) + { + const char *custom_charset_6 = user_options->custom_charset_6; + + XXH64_update (state, custom_charset_6, strlen (custom_charset_6)); + } + + if (user_options->custom_charset_7) + { + const char *custom_charset_7 = user_options->custom_charset_7; + + XXH64_update (state, custom_charset_7, strlen (custom_charset_7)); + } + + if (user_options->custom_charset_8) + { + const char *custom_charset_8 = user_options->custom_charset_8; + + XXH64_update (state, custom_charset_8, strlen (custom_charset_8)); + } + + if (user_options->custom_charset_9) + { + const char *custom_charset_9 = user_options->custom_charset_9; + + XXH64_update (state, custom_charset_9, strlen (custom_charset_9)); + } + const int hex_wordlist = user_options->hex_wordlist; XXH64_update (state, &hex_wordlist, sizeof (hex_wordlist)); diff --git a/src/mpsp.c b/src/mpsp.c index ba5511616..8e84cdba0 100644 --- a/src/mpsp.c +++ b/src/mpsp.c @@ -18,7 +18,7 @@ static const char *const DEF_MASK = "?1?2?2?2?2?2?2?3?3?3?3?d?d?d?d"; -#define MAX_MFS 5 // 4*charset, 1*mask +#define MAX_MFS 10 // 9*charset, 1*mask static int sp_comp_val (const void *p1, const void *p2) { @@ -314,6 +314,21 @@ static int mp_expand (hashcat_ctx_t *hashcat_ctx, const char *in_buf, size_t in_ case '4': if (mp_usr[3].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 4 is undefined."); return -1; } rc = mp_add_cs_buf (hashcat_ctx, mp_usr[3].cs_buf, mp_usr[3].cs_len, mp_usr, mp_usr_offset); break; + case '5': if (mp_usr[4].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 5 is undefined."); return -1; } + rc = mp_add_cs_buf (hashcat_ctx, mp_usr[4].cs_buf, mp_usr[4].cs_len, mp_usr, mp_usr_offset); + break; + case '6': if (mp_usr[5].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 6 is undefined."); return -1; } + rc = mp_add_cs_buf (hashcat_ctx, mp_usr[5].cs_buf, mp_usr[5].cs_len, mp_usr, mp_usr_offset); + break; + case '7': if (mp_usr[6].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 7 is undefined."); return -1; } + rc = mp_add_cs_buf (hashcat_ctx, mp_usr[6].cs_buf, mp_usr[6].cs_len, mp_usr, mp_usr_offset); + break; + case '8': if (mp_usr[7].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 8 is undefined."); return -1; } + rc = mp_add_cs_buf (hashcat_ctx, mp_usr[7].cs_buf, mp_usr[7].cs_len, mp_usr, mp_usr_offset); + break; + case '9': if (mp_usr[8].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 9 is undefined."); return -1; } + rc = mp_add_cs_buf (hashcat_ctx, mp_usr[8].cs_buf, mp_usr[8].cs_len, mp_usr, mp_usr_offset); + break; case '?': rc = mp_add_cs_buf (hashcat_ctx, &p0, 1, mp_usr, mp_usr_offset); break; default: event_log_error (hashcat_ctx, "Syntax error in mask: %s", in_buf); @@ -427,6 +442,21 @@ static int mp_gen_css (hashcat_ctx_t *hashcat_ctx, char *mask_buf, size_t mask_l case '4': if (mp_usr[3].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 4 is undefined."); return -1; } rc = mp_add_cs_buf (hashcat_ctx, mp_usr[3].cs_buf, mp_usr[3].cs_len, css_buf, css_pos); break; + case '5': if (mp_usr[4].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 5 is undefined."); return -1; } + rc = mp_add_cs_buf (hashcat_ctx, mp_usr[4].cs_buf, mp_usr[4].cs_len, css_buf, css_pos); + break; + case '6': if (mp_usr[5].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 6 is undefined."); return -1; } + rc = mp_add_cs_buf (hashcat_ctx, mp_usr[5].cs_buf, mp_usr[5].cs_len, css_buf, css_pos); + break; + case '7': if (mp_usr[6].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 7 is undefined."); return -1; } + rc = mp_add_cs_buf (hashcat_ctx, mp_usr[6].cs_buf, mp_usr[6].cs_len, css_buf, css_pos); + break; + case '8': if (mp_usr[7].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 8 is undefined."); return -1; } + rc = mp_add_cs_buf (hashcat_ctx, mp_usr[7].cs_buf, mp_usr[7].cs_len, css_buf, css_pos); + break; + case '9': if (mp_usr[8].cs_len == 0) { event_log_error (hashcat_ctx, "Custom-charset 9 is undefined."); return -1; } + rc = mp_add_cs_buf (hashcat_ctx, mp_usr[8].cs_buf, mp_usr[8].cs_len, css_buf, css_pos); + break; case '?': rc = mp_add_cs_buf (hashcat_ctx, &chr, 1, css_buf, css_pos); break; default: event_log_error (hashcat_ctx, "Syntax error in mask: %s", mask_buf); @@ -1416,7 +1446,7 @@ int mask_ctx_init (hashcat_ctx_t *hashcat_ctx) mask_ctx->enabled = true; mask_ctx->mp_sys = (cs_t *) hccalloc (8, sizeof (cs_t)); - mask_ctx->mp_usr = (cs_t *) hccalloc (4, sizeof (cs_t)); + mask_ctx->mp_usr = (cs_t *) hccalloc (9, sizeof (cs_t)); mask_ctx->css_buf = (cs_t *) hccalloc (256, sizeof (cs_t)); mask_ctx->css_cnt = 0; @@ -1443,6 +1473,11 @@ int mask_ctx_init (hashcat_ctx_t *hashcat_ctx) if (user_options->custom_charset_2) { if (mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_2, 1) == -1) return -1; } if (user_options->custom_charset_3) { if (mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_3, 2) == -1) return -1; } if (user_options->custom_charset_4) { if (mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_4, 3) == -1) return -1; } + if (user_options->custom_charset_5) { if (mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_5, 4) == -1) return -1; } + if (user_options->custom_charset_6) { if (mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_6, 5) == -1) return -1; } + if (user_options->custom_charset_7) { if (mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_7, 6) == -1) return -1; } + if (user_options->custom_charset_8) { if (mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_8, 7) == -1) return -1; } + if (user_options->custom_charset_9) { if (mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_9, 8) == -1) return -1; } if (user_options->benchmark == true) { @@ -1739,6 +1774,10 @@ int mask_ctx_parse_maskfile (hashcat_ctx_t *hashcat_ctx) mfs_buf[2].mf_len = 0; mfs_buf[3].mf_len = 0; mfs_buf[4].mf_len = 0; + mfs_buf[5].mf_len = 0; + mfs_buf[6].mf_len = 0; + mfs_buf[7].mf_len = 0; + mfs_buf[8].mf_len = 0; size_t mfs_cnt = 0; @@ -1796,11 +1835,21 @@ int mask_ctx_parse_maskfile (hashcat_ctx_t *hashcat_ctx) user_options->custom_charset_2 = NULL; user_options->custom_charset_3 = NULL; user_options->custom_charset_4 = NULL; + user_options->custom_charset_5 = NULL; + user_options->custom_charset_6 = NULL; + user_options->custom_charset_7 = NULL; + user_options->custom_charset_8 = NULL; + user_options->custom_charset_9 = NULL; mp_reset_usr (mask_ctx->mp_usr, 0); mp_reset_usr (mask_ctx->mp_usr, 1); mp_reset_usr (mask_ctx->mp_usr, 2); mp_reset_usr (mask_ctx->mp_usr, 3); + mp_reset_usr (mask_ctx->mp_usr, 4); + mp_reset_usr (mask_ctx->mp_usr, 5); + mp_reset_usr (mask_ctx->mp_usr, 6); + mp_reset_usr (mask_ctx->mp_usr, 7); + mp_reset_usr (mask_ctx->mp_usr, 8); for (size_t i = 0; i < mfs_cnt; i++) { @@ -1825,6 +1874,31 @@ int mask_ctx_parse_maskfile (hashcat_ctx_t *hashcat_ctx) user_options->custom_charset_4 = mfs_buf[3].mf_buf; mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_4, 3); break; + + case 4: + user_options->custom_charset_5 = mfs_buf[4].mf_buf; + mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_5, 4); + break; + + case 5: + user_options->custom_charset_6 = mfs_buf[5].mf_buf; + mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_6, 5); + break; + + case 6: + user_options->custom_charset_7 = mfs_buf[6].mf_buf; + mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_7, 6); + break; + + case 7: + user_options->custom_charset_8 = mfs_buf[7].mf_buf; + mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_8, 7); + break; + + case 8: + user_options->custom_charset_9 = mfs_buf[8].mf_buf; + mp_setup_usr (hashcat_ctx, mask_ctx->mp_sys, mask_ctx->mp_usr, user_options->custom_charset_9, 8); + break; } } diff --git a/src/status.c b/src/status.c index 4e964fd3b..ccdf520f2 100644 --- a/src/status.c +++ b/src/status.c @@ -394,6 +394,11 @@ int status_get_guess_mode (const hashcat_ctx_t *hashcat_ctx) if (user_options->custom_charset_2) has_mask_cs = true; if (user_options->custom_charset_3) has_mask_cs = true; if (user_options->custom_charset_4) has_mask_cs = true; + if (user_options->custom_charset_5) has_mask_cs = true; + if (user_options->custom_charset_6) has_mask_cs = true; + if (user_options->custom_charset_7) has_mask_cs = true; + if (user_options->custom_charset_8) has_mask_cs = true; + if (user_options->custom_charset_9) has_mask_cs = true; if ((user_options->attack_mode == ATTACK_MODE_STRAIGHT) || (user_options->attack_mode == ATTACK_MODE_ASSOCIATION)) { @@ -778,8 +783,13 @@ char *status_get_guess_charset (const hashcat_ctx_t *hashcat_ctx) const char *custom_charset_2 = user_options->custom_charset_2; const char *custom_charset_3 = user_options->custom_charset_3; const char *custom_charset_4 = user_options->custom_charset_4; + const char *custom_charset_5 = user_options->custom_charset_5; + const char *custom_charset_6 = user_options->custom_charset_6; + const char *custom_charset_7 = user_options->custom_charset_7; + const char *custom_charset_8 = user_options->custom_charset_8; + const char *custom_charset_9 = user_options->custom_charset_9; - if ((custom_charset_1 != NULL) || (custom_charset_2 != NULL) || (custom_charset_3 != NULL) || (custom_charset_4 != NULL)) + if ((custom_charset_1 != NULL) || (custom_charset_2 != NULL) || (custom_charset_3 != NULL) || (custom_charset_4 != NULL) || (custom_charset_5 != NULL) || (custom_charset_6 != NULL) || (custom_charset_7 != NULL) || (custom_charset_8 != NULL) || (custom_charset_9 != NULL)) { char *tmp_buf; @@ -787,8 +797,13 @@ char *status_get_guess_charset (const hashcat_ctx_t *hashcat_ctx) if (custom_charset_2 == NULL) custom_charset_2 = "Undefined"; if (custom_charset_3 == NULL) custom_charset_3 = "Undefined"; if (custom_charset_4 == NULL) custom_charset_4 = "Undefined"; + if (custom_charset_5 == NULL) custom_charset_5 = "Undefined"; + if (custom_charset_6 == NULL) custom_charset_6 = "Undefined"; + if (custom_charset_7 == NULL) custom_charset_7 = "Undefined"; + if (custom_charset_8 == NULL) custom_charset_8 = "Undefined"; + if (custom_charset_9 == NULL) custom_charset_9 = "Undefined"; - hc_asprintf (&tmp_buf, "-1 %s, -2 %s, -3 %s, -4 %s", custom_charset_1, custom_charset_2, custom_charset_3, custom_charset_4); + hc_asprintf (&tmp_buf, "-1 %s, -2 %s, -3 %s, -4 %s, -5 %s, -6 %s, -7 %s, -8 %s, -9 %s", custom_charset_1, custom_charset_2, custom_charset_3, custom_charset_4, custom_charset_5, custom_charset_6, custom_charset_7, custom_charset_8, custom_charset_9); return tmp_buf; } diff --git a/src/usage.c b/src/usage.c index c79a8c6ac..6de2fab85 100644 --- a/src/usage.c +++ b/src/usage.c @@ -128,6 +128,11 @@ static const char *const USAGE_BIG_PRE_HASHMODES[] = " -2, --custom-charset2 | CS | User-defined charset ?2 | -2 ?l?d?s", " -3, --custom-charset3 | CS | User-defined charset ?3 |", " -4, --custom-charset4 | CS | User-defined charset ?4 |", + " -5, --custom-charset5 | CS | User-defined charset ?5 |", + " -6, --custom-charset6 | CS | User-defined charset ?6 |", + " -7, --custom-charset7 | CS | User-defined charset ?7 |", + " -8, --custom-charset8 | CS | User-defined charset ?8 |", + " -9, --custom-charset9 | CS | User-defined charset ?9 |", " --identify | | Shows all supported algorithms for input hashes | --identify my.hash", " -i, --increment | | Enable mask increment mode |", " --increment-min | Num | Start mask incrementing at X | --increment-min=4", diff --git a/src/user_options.c b/src/user_options.c index a510c1d69..de84bd017 100644 --- a/src/user_options.c +++ b/src/user_options.c @@ -21,9 +21,9 @@ #endif #ifdef WITH_BRAIN -static const char *const short_options = "hVvm:a:r:j:k:g:o:t:d:D:n:u:T:c:p:s:l:1:2:3:4:iIbw:OMSY:z"; +static const char *const short_options = "hVvm:a:r:j:k:g:o:t:d:D:n:u:T:c:p:s:l:1:2:3:4:5:6:7:8:9:iIbw:OMSY:z"; #else -static const char *const short_options = "hVvm:a:r:j:k:g:o:t:d:D:n:u:T:c:p:s:l:1:2:3:4:iIbw:OMSY:"; +static const char *const short_options = "hVvm:a:r:j:k:g:o:t:d:D:n:u:T:c:p:s:l:1:2:3:4:5:6:7:8:9:iIbw:OMSY:"; #endif static char *const SEPARATOR = ":"; @@ -51,6 +51,11 @@ static const struct option long_options[] = {"custom-charset2", required_argument, NULL, IDX_CUSTOM_CHARSET_2}, {"custom-charset3", required_argument, NULL, IDX_CUSTOM_CHARSET_3}, {"custom-charset4", required_argument, NULL, IDX_CUSTOM_CHARSET_4}, + {"custom-charset5", required_argument, NULL, IDX_CUSTOM_CHARSET_5}, + {"custom-charset6", required_argument, NULL, IDX_CUSTOM_CHARSET_6}, + {"custom-charset7", required_argument, NULL, IDX_CUSTOM_CHARSET_7}, + {"custom-charset8", required_argument, NULL, IDX_CUSTOM_CHARSET_8}, + {"custom-charset9", required_argument, NULL, IDX_CUSTOM_CHARSET_9}, {"debug-file", required_argument, NULL, IDX_DEBUG_FILE}, {"debug-mode", required_argument, NULL, IDX_DEBUG_MODE}, {"deprecated-check-disable", no_argument, NULL, IDX_DEPRECATED_CHECK_DISABLE}, @@ -164,6 +169,11 @@ static const char *const RULE_BUF_L = ":"; static const char *const DEF_MASK_CS_1 = "?l?d?u"; static const char *const DEF_MASK_CS_2 = "?l?d"; static const char *const DEF_MASK_CS_3 = "?l?d*!$@_"; +static const char *const DEF_MASK_CS_4 = "a"; +static const char *const DEF_MASK_CS_5 = "b"; +static const char *const DEF_MASK_CS_6 = "c"; +static const char *const DEF_MASK_CS_7 = "d"; +static const char *const DEF_MASK_CS_8 = "e"; int user_options_init (hashcat_ctx_t *hashcat_ctx) { @@ -201,6 +211,11 @@ int user_options_init (hashcat_ctx_t *hashcat_ctx) user_options->custom_charset_2 = NULL; user_options->custom_charset_3 = NULL; user_options->custom_charset_4 = NULL; + user_options->custom_charset_5 = NULL; + user_options->custom_charset_6 = NULL; + user_options->custom_charset_7 = NULL; + user_options->custom_charset_8 = NULL; + user_options->custom_charset_9 = NULL; user_options->debug_file = NULL; user_options->debug_mode = DEBUG_MODE; user_options->deprecated_check_disable = DEPRECATED_CHECK_DISABLE; @@ -523,6 +538,11 @@ int user_options_getopt (hashcat_ctx_t *hashcat_ctx, int argc, char **argv) case IDX_CUSTOM_CHARSET_2: user_options->custom_charset_2 = optarg; break; case IDX_CUSTOM_CHARSET_3: user_options->custom_charset_3 = optarg; break; case IDX_CUSTOM_CHARSET_4: user_options->custom_charset_4 = optarg; break; + case IDX_CUSTOM_CHARSET_5: user_options->custom_charset_5 = optarg; break; + case IDX_CUSTOM_CHARSET_6: user_options->custom_charset_6 = optarg; break; + case IDX_CUSTOM_CHARSET_7: user_options->custom_charset_7 = optarg; break; + case IDX_CUSTOM_CHARSET_8: user_options->custom_charset_8 = optarg; break; + case IDX_CUSTOM_CHARSET_9: user_options->custom_charset_9 = optarg; break; case IDX_SLOW_CANDIDATES: user_options->slow_candidates = true; break; #ifdef WITH_BRAIN case IDX_BRAIN_CLIENT: user_options->brain_client = true; break; @@ -1313,7 +1333,12 @@ int user_options_sanity (hashcat_ctx_t *hashcat_ctx) if ((user_options->custom_charset_1 != NULL) || (user_options->custom_charset_2 != NULL) || (user_options->custom_charset_3 != NULL) - || (user_options->custom_charset_4 != NULL)) + || (user_options->custom_charset_4 != NULL) + || (user_options->custom_charset_5 != NULL) + || (user_options->custom_charset_6 != NULL) + || (user_options->custom_charset_7 != NULL) + || (user_options->custom_charset_8 != NULL) + || (user_options->custom_charset_9 != NULL)) { if ((user_options->attack_mode == ATTACK_MODE_STRAIGHT) || (user_options->attack_mode == ATTACK_MODE_ASSOCIATION)) { @@ -1465,7 +1490,12 @@ int user_options_sanity (hashcat_ctx_t *hashcat_ctx) if ((user_options->custom_charset_1 != NULL) || (user_options->custom_charset_2 != NULL) || (user_options->custom_charset_3 != NULL) - || (user_options->custom_charset_4 != NULL)) + || (user_options->custom_charset_4 != NULL) + || (user_options->custom_charset_5 != NULL) + || (user_options->custom_charset_6 != NULL) + || (user_options->custom_charset_7 != NULL) + || (user_options->custom_charset_8 != NULL) + || (user_options->custom_charset_9 != NULL)) { if (user_options->attack_mode == ATTACK_MODE_STRAIGHT) { @@ -2009,6 +2039,11 @@ void user_options_preprocess (hashcat_ctx_t *hashcat_ctx) user_options->custom_charset_1 = DEF_MASK_CS_1; user_options->custom_charset_2 = DEF_MASK_CS_2; user_options->custom_charset_3 = DEF_MASK_CS_3; + user_options->custom_charset_4 = DEF_MASK_CS_4; + user_options->custom_charset_5 = DEF_MASK_CS_5; + user_options->custom_charset_6 = DEF_MASK_CS_6; + user_options->custom_charset_7 = DEF_MASK_CS_7; + user_options->custom_charset_8 = DEF_MASK_CS_8; user_options->increment = true; } @@ -2020,6 +2055,11 @@ void user_options_preprocess (hashcat_ctx_t *hashcat_ctx) user_options->custom_charset_1 = DEF_MASK_CS_1; user_options->custom_charset_2 = DEF_MASK_CS_2; user_options->custom_charset_3 = DEF_MASK_CS_3; + user_options->custom_charset_4 = DEF_MASK_CS_4; + user_options->custom_charset_5 = DEF_MASK_CS_5; + user_options->custom_charset_6 = DEF_MASK_CS_6; + user_options->custom_charset_7 = DEF_MASK_CS_7; + user_options->custom_charset_8 = DEF_MASK_CS_8; user_options->increment = true; } @@ -2031,6 +2071,11 @@ void user_options_preprocess (hashcat_ctx_t *hashcat_ctx) user_options->custom_charset_1 = DEF_MASK_CS_1; user_options->custom_charset_2 = DEF_MASK_CS_2; user_options->custom_charset_3 = DEF_MASK_CS_3; + user_options->custom_charset_4 = DEF_MASK_CS_4; + user_options->custom_charset_5 = DEF_MASK_CS_5; + user_options->custom_charset_6 = DEF_MASK_CS_6; + user_options->custom_charset_7 = DEF_MASK_CS_7; + user_options->custom_charset_8 = DEF_MASK_CS_8; user_options->increment = true; } @@ -3167,6 +3212,11 @@ void user_options_logger (hashcat_ctx_t *hashcat_ctx) logfile_top_string (user_options->custom_charset_2); logfile_top_string (user_options->custom_charset_3); logfile_top_string (user_options->custom_charset_4); + logfile_top_string (user_options->custom_charset_5); + logfile_top_string (user_options->custom_charset_6); + logfile_top_string (user_options->custom_charset_7); + logfile_top_string (user_options->custom_charset_8); + logfile_top_string (user_options->custom_charset_9); logfile_top_string (user_options->debug_file); logfile_top_string (user_options->encoding_from); logfile_top_string (user_options->encoding_to);