1、WAF繞過方法
延遲:解決請求過快封IP的情況
代理池:在確保速度的情況下解決請求過快封IP的攔截
白名單:模擬白名單模擬WAF授權(quán)測試惠拭,解決速度及測試攔截
模擬用戶:模擬真實用戶數(shù)據(jù)包請求探針,解決WAF指紋識別
延遲:部分工具不支持庸论,需單獨開發(fā)腳本引入-工具
代理池:部分工具不支持职辅,需單獨開發(fā)腳本引入-腳本
白名單:部分工具不支持,需單獨開發(fā)腳本引入-Burp&腳本
模擬用戶:部分工具不支持聂示,需單獨開發(fā)腳本引入-Burp&腳本
不通過代理池域携,過狗
import requests,time
headers={
'User-Agent': 'Mozilla/5.0 (compatible; Baiduspider/2.0; +http://www.baidu.com/search/spider.html)',
'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
'Accept-Language': 'zh-CN,zh;q=0.8,en-US;q=0.5,en;q=0.3',
'Accept-Encoding': 'gzip, deflate',
'DNT': '1',
'Cookie': 'dguY_2132_saltkey=fo3DA8F1; dguY_2132_lastvisit=1622809396; dguY_2132_sid=A7F2S7; dguY_2132_lastact=1622813010%09index.php%09; PHPSESSID=525ba15298e7fc85c14be5864a150308',
'X-Forwarded-For': '8.8.8.8',
'Connection': 'keep-alive',
'Upgrade-Insecure-Requests': '1'
}
for paths in open('php_b.txt',encoding='utf-8'):
url='http://192.168.0.101:8081/'
paths=paths.replace('\n','')
urls=url+paths
try:
code=requests.get(urls,headers=headers).status_code
print(urls+'|'+str(code))
except Exception as err:
print('connecting error')
time.sleep(3)
通過代理池,過阿里云WAF等
import requests
import time
headers={
'Connection': 'keep-alive',
'Cache-Control': 'max-age=0',
'Upgrade-Insecure-Requests': '1',
'User-Agent': 'Mozilla/5.0 (compatible; Baiduspider-render/2.0; +http://www.baidu.com/search/spider.html)',
'Sec-Fetch-Dest': 'document',
'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9',
'Sec-Fetch-Site': 'none',
'Sec-Fetch-Mode': 'navigate',
'Sec-Fetch-User': '?1',
'Accept-Encoding': 'gzip, deflate, br',
'Accept-Language': 'zh-CN,zh;q=0.9,en-US;q=0.8,en;q=0.7',
'Cookie': 'bdshare_firstime=1581597934650; PHPSESSID=ncsajdvh39qse0qlsgqokshuc4; yx_auth=dc4fq8FAEkyiAUZ54b5zl9GGStCxXoRb1TFaAaozygMiSc5uZYHjR3gCQm%2BtKNz3bcjbTi8BRgcd%2F7LvR0lHN1j319CI6x29Z2QDI38',
}
for paths in open('php_b.txt',encoding='utf-8'):
url='http://test.xiaodi8.com/'
paths=paths.replace('\n','')
urls=url+paths
proxy = {
'http': 'tps191.kdlapi.com:15818',
}
try:
code=requests.get(urls,headers=headers,proxies=proxy).status_code
#req=requests.get(urls, headers=headers, proxies=proxy)
#print(urls)
#print(req.text)
#time.sleep()
print(urls+'|'+str(code))
if code==200 or code==403:
print(urls+'|'+str(code))
except Exception as err:
print('connecting error')
time.sleep(3)
2鱼喉、代理設(shè)置工具proxifier
3秀鞭、在漏洞發(fā)現(xiàn)中趋观,WAF會對三個方向進(jìn)行過濾攔截:
1、速度流量問題
2锋边、工具的指紋被識別
3皱坛、工具的檢測Poc或Payload