需求
检测数字类型字符串参数,判断其类型
例如:38c4658d5308897a92cef9e113aefc3a
代码
from time import sleep
from re import search
from core.colors import *
from core.verbout import verbout
# token 哈希编码检测数据库,感谢一本书,Python for Penetation Testers,LOL!
HASH_DB = (
("Blowfish (Eggdrop)", r"^\+[a-zA-Z0-9\/\.]{12}$"),
("Blowfish (OpenBSD)", r"^\$2a\$[0-9]{0,2}?\$[a-zA-Z0-9\/\.]{53}$"),
("Blowfish Crypt", r"^\$2[axy]{0,1}\$[a-zA-Z0-9./]{8}\$[a-zA-Z0-9./]{1,}$"),
("DES (Unix)", r"^.{0,2}[a-zA-Z0-9\/\.]{11}$"),
("MD5 (Unix)", r"^\$1\$.{0,8}\$[a-zA-Z0-9\/\.]{22}$"),
("MD5 (APR)", r"^\$apr1\$.{0,8}\$[a-zA-Z0-9\/\.]{22}$"),
("MD5 (MyBB)", r"^[a-fA-F0-9]{32}:[a-z0-9]{8}$"),
("MD5 (ZipMonster)"