当前位置:网站首页>[By Pass] WAF 的绕过方式
[By Pass] WAF 的绕过方式
2022-07-26 22:39:00 【ATZXC红蓝对抗】
1.WAF的引入
使用SQL发现有WAF
http://192.168.79.147/sqli-labs-master/Less-1/?id=1' and 1=1 --+

2.WAF的指纹识别
使用工具wafw00f进行指纹识别
使用GitHub下载工具
使用工具进行识别,发现识别失败。

可以使用其余的工具或者进行修改
3.WAF的绕过
1.大小写绕过
比如waf拦截union select,可以构造Union sElEcT来绕过。
2.特殊字符替换空格或注释绕过
可以用注释来替代空格进行绕过
有些waf在检测时不会识别注释或者将注释替换掉
如sqlserver中可以用/**/代替空格,在mysql中 %0a 是换行,可以代替空格。
如union select 1,2可转换为union/*xx*/select/*xx*/1,2
3.编码绕过
少数waf不会对普通字符进行URL解码,还有一部分waf只会进行一次url解码,所以可以对payload进行二次url编码。
SQL编码有unicode、HEX、URL、ascll、base64等
XSS编码有:HTML、URL、ASCII、JS编码、base64等等。
如 union select 1,2可对其进行url编码后进行绕过waf。
4.关键字替换绕过
有些WAF会删除或者替换关键字,如遇到select union等敏感字词。
如 union select 1,2,3可替换为ununionion selselectect 1,,2,3
5.多请求拆分绕过
对于多个参数的语句,可以将注入语句分割插入。
如这样的请求:?a=[inputa]&b=[inputb]可将参数a和b拼接如:and a=[inputa] and b=[inputb]
6.利用cookies绕过
对于用了$_REQUEST来获取参数的网站可以尝试将payload放在cookie中进行绕过
REQUEST会依次从GET POST cookie中获取参数,如果WAF只检测了GET/POST而没有检测cookie,可以将语句放在cookie中进行绕过。
7.云WAF绕过之寻找网站源ip
采用云WAF的网站可以寻找网站真实ip来绕过云WAF的检测。 常见方法有:
采用多地ping的方法查看ip地址解析分析真实ip 在线ping网站有: 多个地点ping服务器-网站测速-站长工具
http://ping.chinaz.com/网站测速工具_超级ping _多地点ping检测 - 爱站网
http://ping.aizhan.com/http://ce.cloud.360.cn/
http://ce.cloud.360.cn/ 使用 nslookup 进行检测,原理同上。 寻找网站历史解析记录。 找网站的二级域名、NS、MX记录等对应的ip。 订阅网站邮件,查看邮件发送方的ip。
边栏推荐
- [4.6 detailed explanation of Chinese remainder theorem]
- 5_ Linear regression
- Operator overloading
- DOM day_ 04 (7.12) BOM, open new page (delayed opening), address bar operation, browser information reading, historical operation
- 八皇后 N皇后
- Crop TIF image
- 2022.7.13
- Linux系统中安装Redis-7.0.4
- Point to plane projection
- Promise基本用法 20211130
猜你喜欢

Two or three things about redis
![[acwing game 61]](/img/83/c9a43536705451a60252720fc41d14.jpg)
[acwing game 61]

JSCORE day_01(6.30) RegExp 、 Function
![[4.9 detailed explanation of inclusion exclusion principle]](/img/c9/673507abab48a1593486c2901adac9.png)
[4.9 detailed explanation of inclusion exclusion principle]
![[NPUCTF2020]ezinclude](/img/24/ee1a6d49a74ce09ec721c1a3b5dce4.png)
[NPUCTF2020]ezinclude

DOM day_ 02 (7.8) web page production process, picture SRC attribute, carousel chart, custom attribute, tab bar, input box event, check operation, accessor syntax
![[CISCN2019 华北赛区 Day1 Web5]CyberPunk](/img/84/b186adc8becfc9b3def7dfd8e4cd41.png)
[CISCN2019 华北赛区 Day1 Web5]CyberPunk

【 Educational Codeforces Round 132 (Rated for Div. 2) A·B·C】

Comparative simulation of LEACH protocol performance, including the number of dead nodes, data transmission, network energy consumption, the number of cluster heads and load balance

Linux系统中安装Redis-7.0.4
随机推荐
2020-12-20 99 multiplication table
输入一串字母 将里面的元音输出希望各位大佬能给指导
[WUSTCTF2020]CV Maker
10个Web API
公司给了IP地址如何使用(详细版)
Leetcode high frequency question: the choice of the inn, how many options to choose accommodation, to ensure that you can find a coffee shop with a minimum consumption of no more than p yuan in the ev
JSCORE day_05(7.6)
[Qt]元对象系统
Ah ah ah ah ah a
[BJDCTF2020]EzPHP
[4.2 approximations]
Mysql互不关联的联表查询(减少了查询的次数)
Friend friend function and singleton mode
【4.3 欧拉函数详解】
[NPUCTF2020]ezinclude
Apply with new, delete and malloc, free to free the heap space
[漏洞实战] 逻辑漏洞挖掘
2022.7.14DAY605
【 Educational Codeforces Round 132 (Rated for Div. 2) A·B·C】
MySql