main函数中有这样的输入参数函数,定位到对应的定义位置,并分析它。
const int rc_options_getopt = user_options_getopt (hashcat_ctx, argc, argv);
输入命令主要依赖这个函数解析。
0.user_options.c文件
里面主要用到的结构体是user_options_t,先看看结构体里的东西吧。
主要来源三个地方,1)usage.c
2)https://www.cnblogs.com/chenxi188/p/10709159.html
3)https://www.meiwen.com.cn/subject/jkkhtxtx.html
typedef struct user_options
{
const char *hc_bin;
int hc_argc;
char **hc_argv;
bool attack_mode_chgd;\\ 猜测是攻击模式是否改变的标志,大概1就是改了的意思
\\忽略WITH_BRAIN
bool hash_mode_chgd;\\ 哈希模型改了没
bool hccapx_message_pair_chgd;\\ hccapx这个类型消息对改了没
\\下面的看着挺重要,也不知道是啥,向日葵猛回头好吧,过几天再写
bool increment_max_chgd;\\…
bool advice_disable;\\这是啥
bool benchmark;\\ 测试计算机破解速度和显示硬件相关信息,-b这个参数和它有关
bool benchmark_all;
\\忽略WITH_BRAIN
bool example_hashes;\\Show an example hash for each hash-mode
bool force;\\一看就知道,是否暴力破解
bool hwmon_disable;\\不知道,好像是驱动或者系统内核啥的
bool hex_charset;\\十六进制字符集?
bool hex_salt;\\十六进制盐
bool hex_wordlist;\\十六进制字典?还是单词表
bool increment;\\增量,主要想知道的东西
bool keep_guessing;\\还继续猜吗,你猜我猜不猜
bool keyspace;\\密钥空间
bool left;\\将hashlist与potfile进行比较; 显示未破解的哈希
bool logfile_disable;\\日志开不开
bool loopback;\\Add new plains to 导入目录
bool machine_readable;\\机器可读不,默认是0
bool markov_cla