|
|
@ -55,6 +55,7 @@ static const struct option long_options[] =
|
|
|
|
{"generate-rules-seed", required_argument, NULL, IDX_RP_GEN_SEED},
|
|
|
|
{"generate-rules-seed", required_argument, NULL, IDX_RP_GEN_SEED},
|
|
|
|
{"hwmon-disable", no_argument, NULL, IDX_HWMON_DISABLE},
|
|
|
|
{"hwmon-disable", no_argument, NULL, IDX_HWMON_DISABLE},
|
|
|
|
{"hwmon-temp-abort", required_argument, NULL, IDX_HWMON_TEMP_ABORT},
|
|
|
|
{"hwmon-temp-abort", required_argument, NULL, IDX_HWMON_TEMP_ABORT},
|
|
|
|
|
|
|
|
{"hash-info", no_argument, NULL, IDX_HASH_INFO},
|
|
|
|
{"hash-type", required_argument, NULL, IDX_HASH_MODE},
|
|
|
|
{"hash-type", required_argument, NULL, IDX_HASH_MODE},
|
|
|
|
{"hccapx-message-pair", required_argument, NULL, IDX_HCCAPX_MESSAGE_PAIR},
|
|
|
|
{"hccapx-message-pair", required_argument, NULL, IDX_HCCAPX_MESSAGE_PAIR},
|
|
|
|
{"help", no_argument, NULL, IDX_HELP},
|
|
|
|
{"help", no_argument, NULL, IDX_HELP},
|
|
|
@ -188,6 +189,7 @@ int user_options_init (hashcat_ctx_t *hashcat_ctx)
|
|
|
|
user_options->force = FORCE;
|
|
|
|
user_options->force = FORCE;
|
|
|
|
user_options->hwmon_disable = HWMON_DISABLE;
|
|
|
|
user_options->hwmon_disable = HWMON_DISABLE;
|
|
|
|
user_options->hwmon_temp_abort = HWMON_TEMP_ABORT;
|
|
|
|
user_options->hwmon_temp_abort = HWMON_TEMP_ABORT;
|
|
|
|
|
|
|
|
user_options->hash_info = HASH_INFO;
|
|
|
|
user_options->hash_mode = HASH_MODE;
|
|
|
|
user_options->hash_mode = HASH_MODE;
|
|
|
|
user_options->hccapx_message_pair = HCCAPX_MESSAGE_PAIR;
|
|
|
|
user_options->hccapx_message_pair = HCCAPX_MESSAGE_PAIR;
|
|
|
|
user_options->hex_charset = HEX_CHARSET;
|
|
|
|
user_options->hex_charset = HEX_CHARSET;
|
|
|
@ -380,6 +382,7 @@ int user_options_getopt (hashcat_ctx_t *hashcat_ctx, int argc, char **argv)
|
|
|
|
case IDX_ENCODING_TO: user_options->encoding_to = optarg; break;
|
|
|
|
case IDX_ENCODING_TO: user_options->encoding_to = optarg; break;
|
|
|
|
case IDX_INDUCTION_DIR: user_options->induction_dir = optarg; break;
|
|
|
|
case IDX_INDUCTION_DIR: user_options->induction_dir = optarg; break;
|
|
|
|
case IDX_OUTFILE_CHECK_DIR: user_options->outfile_check_dir = optarg; break;
|
|
|
|
case IDX_OUTFILE_CHECK_DIR: user_options->outfile_check_dir = optarg; break;
|
|
|
|
|
|
|
|
case IDX_HASH_INFO: user_options->hash_info = true; break;
|
|
|
|
case IDX_EXAMPLE_HASHES: user_options->example_hashes = true; break;
|
|
|
|
case IDX_EXAMPLE_HASHES: user_options->example_hashes = true; break;
|
|
|
|
case IDX_FORCE: user_options->force = true; break;
|
|
|
|
case IDX_FORCE: user_options->force = true; break;
|
|
|
|
case IDX_SELF_TEST_DISABLE: user_options->self_test_disable = true; break;
|
|
|
|
case IDX_SELF_TEST_DISABLE: user_options->self_test_disable = true; break;
|
|
|
@ -1391,6 +1394,13 @@ int user_options_sanity (hashcat_ctx_t *hashcat_ctx)
|
|
|
|
show_error = false;
|
|
|
|
show_error = false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (user_options->hash_info == true)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
if (user_options->hc_argc == 0)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
show_error = false;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
else if (user_options->example_hashes == true)
|
|
|
|
else if (user_options->example_hashes == true)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
if (user_options->hc_argc == 0)
|
|
|
|
if (user_options->hc_argc == 0)
|
|
|
@ -1589,6 +1599,11 @@ void user_options_session_auto (hashcat_ctx_t *hashcat_ctx)
|
|
|
|
user_options->session = "benchmark";
|
|
|
|
user_options->session = "benchmark";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (user_options->hash_info == true)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
user_options->session = "hash_info";
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (user_options->example_hashes == true)
|
|
|
|
if (user_options->example_hashes == true)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
user_options->session = "example_hashes";
|
|
|
|
user_options->session = "example_hashes";
|
|
|
@ -1668,6 +1683,7 @@ void user_options_preprocess (hashcat_ctx_t *hashcat_ctx)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (user_options->example_hashes == true
|
|
|
|
if (user_options->example_hashes == true
|
|
|
|
|
|
|
|
|| user_options->hash_info == true
|
|
|
|
|| user_options->backend_info == true
|
|
|
|
|| user_options->backend_info == true
|
|
|
|
|| user_options->keyspace == true
|
|
|
|
|| user_options->keyspace == true
|
|
|
|
|| user_options->speed_only == true
|
|
|
|
|| user_options->speed_only == true
|
|
|
@ -1723,6 +1739,11 @@ void user_options_preprocess (hashcat_ctx_t *hashcat_ctx)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (user_options->hash_info == true)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
user_options->quiet = true;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (user_options->example_hashes == true)
|
|
|
|
if (user_options->example_hashes == true)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
user_options->quiet = true;
|
|
|
|
user_options->quiet = true;
|
|
|
@ -1840,6 +1861,10 @@ void user_options_preprocess (hashcat_ctx_t *hashcat_ctx)
|
|
|
|
if (user_options->example_hashes == true)
|
|
|
|
if (user_options->example_hashes == true)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (user_options->hash_info == true)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if (user_options->backend_info == true)
|
|
|
|
else if (user_options->backend_info == true)
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -2057,6 +2082,10 @@ void user_options_extra_init (hashcat_ctx_t *hashcat_ctx)
|
|
|
|
if (user_options->benchmark == true)
|
|
|
|
if (user_options->benchmark == true)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (user_options->hash_info == true)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if (user_options->example_hashes == true)
|
|
|
|
else if (user_options->example_hashes == true)
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -3005,6 +3034,7 @@ void user_options_logger (hashcat_ctx_t *hashcat_ctx)
|
|
|
|
logfile_top_uint (user_options->force);
|
|
|
|
logfile_top_uint (user_options->force);
|
|
|
|
logfile_top_uint (user_options->hwmon_disable);
|
|
|
|
logfile_top_uint (user_options->hwmon_disable);
|
|
|
|
logfile_top_uint (user_options->hwmon_temp_abort);
|
|
|
|
logfile_top_uint (user_options->hwmon_temp_abort);
|
|
|
|
|
|
|
|
logfile_top_uint (user_options->hash_info);
|
|
|
|
logfile_top_uint (user_options->hash_mode);
|
|
|
|
logfile_top_uint (user_options->hash_mode);
|
|
|
|
logfile_top_uint (user_options->hex_charset);
|
|
|
|
logfile_top_uint (user_options->hex_charset);
|
|
|
|
logfile_top_uint (user_options->hex_salt);
|
|
|
|
logfile_top_uint (user_options->hex_salt);
|
|
|
|