• 【sql注入】浅谈sql注入中的Post注入


    【sql注入】浅谈sql注入中的Post注入

    本文来源:i春秋学院

    00x01
    在许多交流群中,我看见很多朋友对于post注入很是迷茫,曾几何,我也是这样,因为我们都被复杂化了,想的太辅助了所以导致现在感觉到难,现在,就让我们一起来谈谈,post注入是多么的轻松吧!
    PS:文中有写os-shell
    00x02
    测试站点:http://xxx.xxxxx.com/
    对于我来说,post注入无非有两种方法
    第一种利用burp抓包然后使用sqlmap -r 来进行检测注入
    第二种比较简单,直接使用sqlmap --forms 这个参数就可以了
    00x03
    第一种方法测试
    xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    使用burp大家都知道,需要jre环境来运行并且需要设置代理为127.0.0.1:8080
    然后才能进行抓包
     
     
    设置完成,然后我们开始抓取测试站点的post包,
     
    如上图,成功抓取post包
    ####需注意!
    确认intercept is on (不可抓包为yes)
    这是我抓取到的post包

    1. POST /login.aspx HTTP/1.1
    2. Host: xxx.xxxxx.com
    3. User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:43.0) Gecko/20100101 Firefox/43.0
    4. Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
    5. Accept-Language: zh-CN,zh;q=0.8,en-US;q=0.5,en;q=0.3
    6. Accept-Encoding: gzip, deflate
    7. Referer: [url]http://xxx.xxxxx.com/[/url]
    8. Cookie: ASP.NET_SessionId=2rslbt55ykuuntjvqwawax45
    9. Connection: close
    10. Content-Type: application/x-www-form-urlencoded
    11. Content-Length: 106
    12. __VIEWSTATE=%2FwEPDwUJLTMzMjAwMjk3ZGQRxhY3kgspLOxJLG8mggcuWQGyAA%3D%3D&userid=test&userpass=test&x=58&y=10
    复制代码


    可以得出,我提交的
    userid=test
    userpass=test
    主要注入也是由这个表单而起
    ,那么我们把他放入一个txt文件中并放入sqlmap目录下
     
    打开sqlmap,开始进行注入
    命令:

    1. sqlmap.py -r post.txt
    复制代码


    ..............................................想查看全文,看这里》》》本文来源:http://bbs.ichunqiu.com/thread-7762-1-1.html?from=bky

  • 相关阅读:
    第一周(LNMP-Nginx_php-fpm-80转443)
    mysql编译安装
    PB中的DataStore的应用示例
    linux 安装 rabbitmq
    php 扩展 rabbitmq popt
    mongodb基本指令
    单点登录
    js调用打印机打印
    nginx开启tls1.2及一些注意问题
    蓝桥杯2017年省赛A组题目总结
  • 原文地址:https://www.cnblogs.com/ichunqiu/p/5826983.html
Copyright © 2020-2023  润新知