Crunch can create a wordlist based on criteria you specify. The output from crunch can be sent to the screen, file, or to another program. crunch 可以基于你指定的标准创建一个单词表。crunch的输出key发送到屏幕、文件或者另一个程序。
Usage: crunch <min> <max> [options] 用法:crunch <最小> <最大> [选项] where min and max are numbers 其中最小值和最大值是数字
Please refer to the man page for instructions and examples on how to use crunch. 有关如何使用crunch,请参考手册页的说明和实例。
Crunch will now generate the following amount of data: 2357212 bytes crunch 现在将生成以下数量的数据:2357212 字节 2 MB 0 GB 0 TB 0 PB Crunch will now generate the following number of lines: 475228 crunch 现在将生成以下行数:475228
2.3 生成指定格式密码
1 2 3 4 5 6 7 8 9 10
# 生成7位数,以admin开头+2位数字的字典,保存到admin_num.txt中。 # -t:指定以某种格式开头 # %%:表示两位数字 crunch 7 7 -t admin%% > admin_num.txt Crunch will now generate the following amount of data: 800 bytes 0 MB 0 GB 0 TB 0 PB Crunch will now generate the following number of lines: 100
1 2 3 4 5 6 7 8
# 生成以1520003开头的手机号 crunch 11 11 -t 1520003%%%% > mobile.txt Crunch will now generate the following amount of data: 120000 bytes 0 MB 0 GB 0 TB 0 PB Crunch will now generate the following number of lines: 10000
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
# 指定的数字生成字典 crunch 6 6 0123456789 > num.txt Crunch will now generate the following amount of data: 7000000 bytes 6 MB 0 GB 0 TB 0 PB Crunch will now generate the following number of lines: 1000000
crunch 6 6 -f /usr/share/crunch/charset.lst numeric > num_repo.txt Crunch will now generate the following amount of data: 7000000 bytes 6 MB 0 GB 0 TB 0 PB Crunch will now generate the following number of lines: 1000000
2.4 依据库文件生成密码
1 2 3 4 5 6 7 8 9 10
# -f:指定库文件 crunch 6 6 -f /usr/share/crunch/charset.lst hex-lower -o repo.txt Crunch will now generate the following amount of data: 117440512 bytes 112 MB 0 GB 0 TB 0 PB Crunch will now generate the following number of lines: 16777216
# 指定生成的字典,由 ghost、99、22 三个元素组成 crunch 3 3 -p ghost 99 22 > combination.txt Crunch will now generate approximately the following amount of data: 60 bytes 0 MB 0 GB 0 TB 0 PB Crunch will now generate the following number of lines: 6