这个脚本是为了获取burp里面的流量,提取出url,放到awvs里面批量扫描

 

 

 

 

 

SAPP Store  Burp Extensions  Options  Extensions let you customize aurp•s behavior using your own or third-party code  Up  Type  Java  Python  Python  actives can"  Tme-based sqlinject checks  LFI scanner checks  dig injection»int  Errors  o  Output to system console  @ Save to file  o  Show in LIV  just test  Please select a file  burp_extend  burp  _int_ py  get_link py  wan me test  txt

 

 

 

burp  I mt_.py  get_link.py  Z] get link.txt  u rl.txt  wa n me Itest  2019/4/9 12:45  2019/4/9 12:45  2019/4/9 15:20  2019/4/9 15:23  2019/4/9 14:25  2019/4/9 14:25  2019/4/g 14:15  Python File  Python File  get_link.txt -  http://www.saicgroup.com/  http://c.saicdt.com/collect/web/pv?stm = 1554794589  http://c.saicdt.com/collect/web/action?stm = 1554792  http://www.saicgroup.com/chinese/xwzx/index.shtm  http://c.saicdt.com/collect/web/pv?stm = 155479459C  http://c.saicdt.com/collect/web/action?stm = 1554792  http://www.saicgroup.com/chinese/rlzy/rcln/index.sl  http://c.saicdt.com/collect/web/pv?stm = 1554794591  http://c.saicdt.com/collect/web/action?stm = 1554792  http://www.saicgroup.com/chinese/tzzgx/index.shtn  http://vip.stock.finance.sina.com.cn/quotes service/é  http://vip.stock.finance.sina.com.cn/quotes service/é  http://www.saicgroup.com/chinese/gsgk/gsjs/index.  http://c.saicdt.com/collect/web/pv?stm = 1554794592  http://c.saicdt.com/collect/web/pv?stm = 1554794593  http://hq.sinajs.cn/list=sh600104  http://c.saicdt.com/collect/web/action?stm = 1554792  http://m•m.saicgroup.com/chinese/qyshzrbg/index.!  http://c.saicdt.com/collect/web/pv?stm = 1554794593  http://c.saicdt.com/collect/web/action?stm = 1554792  http://c.saicdt.com/collect/web/action?stm = 1554792  httn• / hnnnnny •n r mm /rhinQCQ/inHav chtml  Windows 1 F , 100%

 

 

 

然后把url再去重,就可以了,放到awvs批量扫描

 

 

 

#!/usr/bin/env python
# -*- coding:utf-8 -*-
from
burp import IBurpExtender
from burp import IHttpListener
from burp import IHttpRequestResponse
from burp import IResponseInfo
from burp import IRequestInfo
from burp import IHttpService
import re
print "just test"
#这个脚本的作用是获得burp流量,然后获取url,用于awvs的后续扫描
class
BurpExtender(IBurpExtender,IHttpListener):
    def registerExtenderCallbacks(self,callbacks):
        self._callbacks = callbacks
        self._helpers = callbacks.getHelpers()
        self._callbacks.setExtensionName("get link")#定义插件的名称
       
callbacks.registerHttpListener(self)
    #以上都是标准化程序
   
def processHttpMessage(self,toolFlag,messageIsRequest,messageInfo):
        if toolFlag ==64 or toolFlag ==16 or toolFlag ==8 or toolFlag ==4:#码的含义https://portswigger.net/burp/extender/api/constant-values.html#burp.IBurpExtenderCallbacks%EF%BC%83
           
if not messageIsRequest:
                response = messageInfo.getResponse()
                analyzedResponse = self._helpers.analyzeResponse(response)
                response_headers = analyzedResponse.getHeaders()
                response_bodys = response[analyzedResponse.getBodyOffset():].tostring()
                #print  response_bodys

                #获取请求包数据
               
request = messageInfo.getRequest()
                analyzedRequest = self._helpers.analyzeResponse(request)
                request_headers = analyzedRequest.getHeaders()
                request_bodys = request[analyzedRequest.getBodyOffset():].tostring()
                #print request_headers
               
link = request_headers[0].split()[1]
                #print link
                #获取服务信息
               
httpService = messageInfo.getHttpService()
                port = httpService.getPort()
                host = httpService.getHost()
                Protocol = httpService.getProtocol()
                url = Protocol+"://"+host+link
                if '.gif' not in link and '.jpg' not in link and '.png' not in link and '.css' not in link and '.js' not in link and '.woff?' not in link:
                    print url



 

<<get_link.py>>