<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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/" version="2.0">

<channel>
	<title>/dev/random</title>
	
	<link>http://blog.rootshell.be</link>
	<description>Can't sleep, hackers will eat me!</description>
	<lastBuildDate>Fri, 25 May 2012 20:39:06 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/dev/rand" /><feedburner:info xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" uri="dev/rand" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
		<title>HITB Amsterdam Wrap-Up Day #2</title>
		<link>http://blog.rootshell.be/2012/05/25/hitb-amsterdam-wrap-up-day-2/</link>
		<comments>http://blog.rootshell.be/2012/05/25/hitb-amsterdam-wrap-up-day-2/#comments</comments>
		<pubDate>Fri, 25 May 2012 20:02:21 +0000</pubDate>
		<dc:creator>Xavier</dc:creator>
				<category><![CDATA[Event]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Conference]]></category>
		<category><![CDATA[HITB]]></category>

		<guid isPermaLink="false">http://blog.rootshell.be/?p=9629</guid>
		<description><![CDATA[I&#8217;m just back at $HOME. Let&#8217;s go for the second day wrap-up! This morning, I walked to the hotel in the sun to take a breakfast. Very nice weather over Amsterdam again today! Bruce Schneier was the second keynote speaker. Do I still need to present him? He came to talk about  &#8221;Trust, security and [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">I&#8217;m just back at $HOME. Let&#8217;s go for the second day wrap-up! This morning, I walked to the hotel in the sun to take a breakfast. Very nice weather over Amsterdam again today! <a href="http://www.schneier.com">Bruce Schneier</a> was the second keynote speaker.</p>
<p style="text-align: justify;"><span id="more-9629"></span></p>
<p style="text-align: justify;">Do I still need to present him? He came to talk about  &#8221;<em>Trust, security and society</em>&#8221; which is the topic of his new book. Bruce has always a new book to promote! <img src='http://blog.rootshell.be/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>
<div id="attachment_9380" class="wp-caption aligncenter" style="width: 370px"><img class="wp-image-9380 " style="text-align: justify; border: 0pt none;" title="IMG_1998.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_1998.jpg" alt="Bruce Schneier Keynote" width="360" height="270" border="0" /><p class="wp-caption-text">Bruce Schneier Keynote</p></div>
<p style="text-align: justify;">In the real life, we feel safe. We trust people all the time (the taxi driver, the server at the restaurant, the pilot who brings us to Amsterdam, etc). Society does not function without trust. How society makes this work? Trust is a really complicated concept! When you say &#8220;<em>I trust a friend</em>&#8220;, you speak about the person, not his actions. We can also trust actions of people in a specific context. Back to the first example with the taxi driver, we don&#8217;t know his motivations, we just trust him to drive us to our destination safely. Another example: trusting a server who gives us a bottle of water. For airlines, you don&#8217;t trust people (the pilot) but you trust the airline company which should produce skilled pilots. You don&#8217;t have to know how a system works, you just trust it (ATM machines are a good example). But if there are too many factors, the system will collapse. &#8220;<em>Parasites</em>&#8221; can only survive if they are not too good. Security is how we can set the level of trust to an acceptable level, otherwise it will collapse. They are different types of pressures:</p>
<ul>
<li style="text-align: justify;">Moral : We fill bad if we do, we don&#8217;t want to (Do I steal those goods or not?)</li>
<li style="text-align: justify;">Reputation: What people will think of your behavior</li>
<li style="text-align: justify;">Institutions: They have rules and enforcement has been delegated</li>
</ul>
<p style="text-align: justify;">The problem with the two first type of pressures: They don&#8217;t scale (societies are growing) And what&#8217;s the power of reputation? Bruce gave a funny example. In a company, people can buy coffee. They have to leave some coins next to the coffee machine.  At the end of the day, a comparison between the money and the number of coffee cups give the percentage of people who paid (or not). A study showed that only be adding a picture of eyes behind the coffee machine, the number of paying people increased.</p>
<p style="text-align: justify;">Technology allows our society to get better in lot of different ways (more people, more complexity, more social network, distances, frequency, etc) Wait, it looks like a definition of the Internet. Internet is just a copy of the real society from a security point of view, new attack vectors are used by criminals like in real life. Attackers can make use of innovations faster cause they are not limited by boundaries. To maintain good security is to react quickly by evaluating what attackers will do next. A final problem is that society is not always right. The assumption that a group is correct is not always true!  It this topic interest you, read Bruce&#8217;s book! Bruce is really a good speaker, no slides just stories and real-life examples!</p>
<p style="text-align: justify;">After a coffee break, <a href="http://twitter.com/mifare">Andrei Costin</a> talked about the danger of PostScript files. Why <a href="http://en.wikipedia.org/wiki/PostScript">PostScript</a>? MFP&#8217;s (&#8220;<em>Multi Functions Printers</em>&#8220;) carry a lot of abuse potentials. They contain confidential documents, they remain unpatched, they are (sometimes) facing the Internet or are available on the network. Modern printers are targets since a decade! Did you know that lot of printers are <a href="http://www.youtube.com/watch?v=t44GibiCoCM">facing</a> the Internet? And generic MFP payload delivery occurs using Word or Java. Back to PostScript! PostScript is used to handle complex procession tasks. This is a programming language: Stack based and turing-complete. PostScript printer driver transforms document to PostScript streams for specific devices and data stream on PRN. Windows based systems can process PostScrtipt files  too (via an interpreter) and execute code on your PC. PostScript is like a Java sandbox. It has simple control statements (if/else, loop, while) and simplest DoS is an infinite loop:</p>
<pre>!%
{}loop</pre>
<p>Demo time! How to kill Word with less then 10 characters.</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_2003.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_2003.jpg" alt="PostScript Killing MS Word" width="360" height="270" border="0" /><p class="wp-caption-text">PostScript Killing MS Word</p></div>
<p>Another demo: &#8220;<em>Dynamically types concatenate</em>&#8221; aspect, by example to evade IDS:</p>
<pre>({) (}) (l) (o) (o) (p)
count 1 sub { mergestr } repeat
cvx
exec</pre>
<p style="text-align: justify;">Next demo: Real world application: MS Office PostScript crash! What about <a href="http://pages.cs.wisc.edu/~ghost/">GhostScript</a>? Dynamic document forging/generation can be used with some Social Engineering techniques. Andrei gave an awesome example with a rogue PostScript file; If the file is opened with Ghostscript nothing happened otherwise the malicious code is executed. Example of a real attack? On a PC the invoice show an amount of 100 EUR but once printed: 1000 EUR <img src='http://blog.rootshell.be/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' />  Who will read the document just printed? It will be signed! As said Bruce before, we trust the printer!</p>
<p style="text-align: justify;">PostScript can also address some web2.0 issues? Some online services are also vulnerable to rogue PostScript documents. 20+ online services were found to be vulnerable at different level (Google was one of them). Some fun facts? Some GhostScript are running as root. Some runs GS without -dSAFER, some run vulnerable versions (heap and stack overflows).</p>
<p style="text-align: justify;">What about physical devices? Installation of firmware upgrades is performed via PostScript documents. Admin restriction fails to prevent memory dumping. Even if devices are protected at interface level. API&#8217;s remain available. HTTPS/IPSEC secrets are &#8220;default&#8221; and &#8220;leaky&#8221;: they are in memory! Printers protected by a PIN code or a badge reader are also vulnerable. Document is also available in the memory!</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_2006.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_2006.jpg" alt="Memory Dump of a Printer" width="360" height="270" border="0" /><p class="wp-caption-text">Memory Dump of a Printer</p></div>
<p style="text-align: justify;">Can you imagine performing a network scan via printers? Printers use lot of protocols to detect devices on the network. Guess where this information is stored? In memory of course, using the same techniques, you can retrieve information about the network topology without using any active scanner on the network. To perform social engineering, coupons, discount codes are great! People like free stuffs! Conclusions: Don&#8217;t print suspicious documents. Printing is bad for environment but also for your security <img src='http://blog.rootshell.be/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' />  Andrei&#8217;s papers are available <a href="http://andreicostin.com/papers">online</a>.</p>
<p>The next talk I attended was &#8220;<em>How to use Taint to find vulnerabilities?</em>&#8221; by <a href="http://twitter.com/ABazhanyuk">Alex Bazhanyuk</a> and <a href="http://twitter.com/ntarakamov">Nikita Tarakamov</a>. In parallel to this track, there was the one about the new IOS jailbreak. But I decided to stay in the same room to follow Nikita&#8217;s talk. Too many people went to the jailbreak session.</p>
<div class="wp-caption aligncenter" style="width: 280px"><img style="display: block; border: 0pt none;" title="IMG_2008.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_2008.jpg" alt="Nikita Tarakamov" width="270" height="360" border="0" /><p class="wp-caption-text">Nikita Tarakamov</p></div>
<p style="text-align: justify;">What is taint analysis theory? Taint sources are network, keyboard, memory, disk, function outputs. Taint propagation is a data flow technique.  Static taint analysis is performed over multiple paths of a program. More information about taint analysis can be found <a href="http://en.wikipedia.org/wiki/Taint_checking">here</a>. BitBlaze is a binary analysis infrastructure to automatically extract security-related properties from binary code. SASV main parts are IDA pro plugins and BitBlaze: <a href="http://bitblaze.cs.berkeley.edu/vine.html">Vine</a> + utils, <a href="http://bitblaze.cs.berkeley.edu/temu.html">TEMU</a> + plugins. Then I was lost, too complex for me! <img src='http://blog.rootshell.be/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>
<p style="text-align: justify;">After the lunch break, there was two talks in parallel about mobile operating systems: &#8220;<em>Bypassing the Android Permission Model</em>&#8221; or the second part of the IOS jailbreak. I decided to attend the IOS one for the fun. There were rumours that the new jailbreak will be released! The talk covered the <a href="http://en.wikipedia.org/wiki/Apple_A5">A5</a>. There is no tethered jailbreak on A5 because there is currently no public boot level exploit for it. But they found a way to use <a title="Link to the website" href="http://www.howtoforge.com/racoon_roadwarrior_vpn">Racoon</a> as an injection vector. The problem was: How to copy Corona files on the file system which is read-only at boot and how to bypass ASLR? VPN settings are not validated by configd before being passed to Racoon. The dream team explained step by step how they successfully exploited the while stuff. One the payload installed, the next step was to find a way to trigger a VPN connection? They discovered that Safari can trigger this to perform certificate based authentication.  But typing an URL in Safari is boring, they used a Webclip.</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_2011.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_2011.jpg" alt="The Dream Team" width="360" height="270" border="0" /><p class="wp-caption-text">The Dream Team</p></div>
<p style="text-align: justify;">Next step, the sandbox. What&#8217;s the sandbox? Code name &#8220;<em>Seatbelt</em>&#8220;, based off the TrustedBSD MAC (&#8220;<em>Mandatory Access Control</em>&#8220;). Sandbox.kext is a registered MAC policy. How to get the patched copy of raccoon (1-modified byte) onto the device? ptrace is not working well and Apple makes it unrestricted but it can control an unsandboxed process. To resume:</p>
<ul>
<li>Create a non sandbox version of raccoon</li>
<li>Find notified PID</li>
<li>Put notifyd&#8217;s main thread on the IPC thread</li>
<li>Block notified with our exploit IPC message</li>
<li>Write rest of ROP stack to shm</li>
<li>Launch the exploit</li>
</ul>
<p style="text-align: justify;">The team explained in details all the steps to own the IOS devices. More information available here:</p>
<ul>
<li><a href="http://www.semantiscope.com/research/BHDC2011/BHDC2011-Slides.pdf">http://www.semantiscope.com/research/BHDC2011/BHDC2011-Slides.pdf</a></li>
<li><a href="https://guthub.com/dionthegod/XNUSandbox">https://guthub.com/dionthegod/XNUSandbox</a></li>
</ul>
<p style="text-align: justify;">So, after the talk, the official news of the day was there: the jailbreak for 5.1.1 is publicly available but <a href="https://greenpois0n.com">greenpois0n.com</a> was temporary down. My opinion, they brought it down during the talk to be sure to release the exploit at the right time. This announce caused a flood of Twitter messages! People were following the talk worldwide waiting for &#8220;the&#8221; announce. Congratulations to the Dream Team. Once you see the talk it seems easy but they passed days of investigations to achieve this!</p>
<p style="text-align: justify;">The next talk was about the Amazon cloud services. It started later because the speaker, Kenneth White, was unavailable!? When he started the presentation, he first talked for a long time about health researches (viruses, diseases) and the associated processed to remediate to them. Finally, he switched to the main topic: Amazon! Everybody knows this major player in cloud technologies. What are the promises of AWS (&#8220;<em>Amazon Cloud Services</em>&#8220;)?</p>
<ul>
<li>Scaling</li>
<li>They are busy with the boring part of the infrastructure</li>
<li>On demand</li>
<li>Pain reduction</li>
<li>Zero procurement headaches</li>
<li>Cost (!)</li>
</ul>
<p style="text-align: justify;">The killer feature is indeed the cost of the public cloud! You will fail if you compare VM&#8217;s to a cloud. Your SAN/NAS is not the cloud. Could you survive to a DDoS without the cloud? Finally, by using the cloud you can focus on more interesting stuffs in your job. Kenneth reviewed interesting information about AWS. Who&#8217;s behind?</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_2019.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_2019.jpg" alt="Who's Behind AWS?" width="360" height="270" border="0" /><p class="wp-caption-text">Who&#39;s Behind AWS?</p></div>
<p>What&#8217;s their grow? Some interesting numbers: They hired 22.5K new employees. They advertise 800K public IP addresses. What about their data centers infrastructure? Most information is publicly available:</p>
<ul>
<li>Facility built-outs, availability zones &amp; regions</li>
<li>Power capacity and redundancy</li>
<li>Pictures</li>
<li>Physical , process and technical controls.</li>
</ul>
<p>About the data centers, did you know that they are build by one of the most powerful company called <a title="Link to the website" href="http://digitalreality.com">Digital Reality</a>? To analyse their backbone, BGP is your best friend. But you&#8217;ll have to take time to analyze all the peers!</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_2020.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_2020.jpg" alt="AWS Datacenters Locations" width="360" height="270" border="0" /><p class="wp-caption-text">AWS Datacenters Locations</p></div>
<p style="text-align: justify;">I expected more details about Amazon. I was a bit disappointed by the content of the presentation. The real Amazon stuff started at the middle of the talk!</p>
<p style="text-align: justify;">Finally the last presentation was performed by <a href="http://twitter.com/embyte">Marco Balduzzi</a> about &#8220;<em>SatanCloud &#8211; a journey into the privacy and security risks of a cloud computing</em>&#8220;.</p>
<div class="wp-caption aligncenter" style="width: 280px"><img style="display: block; border: 0pt none;" title="IMG_2026.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_2026.jpg" alt="Marco Balduzzi on Stage" width="270" height="360" border="0" /><p class="wp-caption-text">Marco Balduzzi on Stage</p></div>
<p style="text-align: justify;">The talk used Amazon (again!) EC2 &#8211; IaaS (&#8220;<em>Infrastructure as a Service</em>&#8220;). Marco refreshed our brain with a brief review of the cloud computing. Most of us are using the cloud everything. You use gmail.com isn&#8217;t it? Three models exist:</p>
<ul>
<li>SaaS: Software is provided (ex: salesforce.com)</li>
<li>PaaS: Computing or solution platform (ex: Google apps)</li>
<li>IaaS: Computers, Storage, firewall, networks are provided (ex: EC2)</li>
</ul>
<p style="text-align: justify;">The talk focused on IaaS where the market leader is Amazon. EC2 provides access to a virtualized server (Amazon Machine Images). AMI&#8217;s are provided by Amazon but users may provide their own images as well as third-party companies. AMI&#8217;s can be build from a live system, from an ISO or another AMI. Configuration is simple: credentials, resources (sizing), the region where start the instance and an inbound firewall. The instance will be available via a public IP like &#8220;<em>ec2-IP-region.computer.amazonaws.com</em>&#8221; over SSH/RDP. First important thing to keep in mind, Amazon don&#8217;t care about the AMI security! Then Marco reviewed the problem of sharing images via the Amazon catalog. What are the threats:</p>
<ul>
<li>Secure it against external attacks</li>
<li>Malicious image providers?</li>
<li>Sanitizing the image to protect the privacy of the provider</li>
</ul>
<p style="text-align: justify;">A tool has been created to automate the security analysis of images: SatanCloud. It performs a remote scan using Nmap and a local scan using Nessus for local vulnerabilities (only the critical ones for performance reasons). What were the findings?</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_2028.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_2028.jpg" alt="Detected Vulnerabilities in AMI's" width="360" height="270" border="0" /><p class="wp-caption-text">Detected Vulnerabilities in AMI&#39;s</p></div>
<p style="text-align: justify;">Incredible: 98% of Windows and 58% of Linux AMI&#8217;s came with critical vulnerabilities! 87 Debians AMI&#8217;s still had the notorious SSH vulnerability. Two AMI&#8217;s where infected by viruses. Some Trojans with key logger were found. Two Linux AMI&#8217;s were configured to send logs to a remote host! Some private keys can be installed on images and left behind the execution and use to make new images.</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_2029.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_2029.jpg" alt="Leftover Credentials on AMI's" width="360" height="270" border="0" /><p class="wp-caption-text">Leftover Credentials on AMI&#39;s</p></div>
<p style="text-align: justify;">About forgotten keys? 56 private keys were found to log in to other machines. 54 of them even not protected by a pass-phrase! Linux systems have shells which generate history files. Those files were also scanned and 869 history files were found:</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_2030.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_2030.jpg" alt="Interesting Data Extracted from History Files" width="360" height="270" border="0" /><p class="wp-caption-text">Interesting Data Extracted from History Files</p></div>
<p style="text-align: justify;">The next investigation was: Are deleted data really removed? AMI&#8217;s can be bundled using different methods. Block based building methods are vulnerable to file undelete attacks. 1100 Linux AMI&#8217;s were inspected using extundelete. They recovered 28GB of data! (SSH private keys, PGP keys, password files and many documents). And for Windows AMI&#8217;s? WinUndelete is your best friend! Same issue&#8230;</p>
<p style="text-align: justify;">This research was performed with the contribution of Amazon Security Team. Vulnerable AMI&#8217;s status was changed from public to private. A tutorial was created to help customers to share their images in a secure way. Good collaboration from Amazon!</p>
<p style="text-align: justify;">Lessons learned? Prepare your own image otherwise update the software, enable the firewall, delete (safely) unwanted data, check for outgoing connections =&gt; harden your server as if it was local (best practices). A very good talk to share with all system admins who play with Amazon EC2! My preferred one for the second day.</p>
<p style="text-align: justify;">The closing keynote was given by Jaya Baloo from Verizon: &#8220;<em>Identify, Privacy and Security</em>&#8220;. Jaya&#8217;s first question was: &#8220;<em>Isn&#8217;t it time the Internet had an identity solution?</em>&#8220;.</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_2031.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_2031.jpg" alt="Jaya Baloo on Stage" width="360" height="270" border="0" /><p class="wp-caption-text">Jaya Baloo on Stage</p></div>
<p style="text-align: justify;">We have too many passwords. This generates too much risks and, for enterprise, it&#8217;s complex and cost money. A question immediately raised from the audience: &#8220;<em>Why complexity is bad?</em>&#8221; Jaya think that a simple authentication mechanism could benefit to the security of users. &#8220;<em>We need an identity ecosystem in the cloud</em>&#8220;, Really? The challenge is a good balance between privacy and identity insurance.</p>
<p style="text-align: justify;">A mention to an interesting online service provided by <a href="http://rapleaf.com">rapleaf.com</a>: They grab data from the Internet and based on email addresses lists you have access to plenty of information (age, gender and location are free). Why collect identifies? advertising market! Privacy legislation is principally aims to protect you against government and specific organizations. But it does not address against organizations or the mistake of their employees.  Jaya made a good review of the problematic of the implementation of a unique authentication system.</p>
<p style="text-align: justify;">Then the closing ceremony with the results of the different contests and a word from the organizers. This year, the venue changed and it was (IMHO) positive. The hotel was nice and close to restaurants, bars. I left immediately after the talks and was unable to say goodbye to old and new friends. So I do it now: It was nice to meet you once again (for some), for the first time (for others). See you soon!</p>
<img src="http://feeds.feedburner.com/~r/dev/rand/~4/jrOI2vB6Jjk" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.rootshell.be/2012/05/25/hitb-amsterdam-wrap-up-day-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>HITB Amsterdam Wrap-Up Day #1</title>
		<link>http://blog.rootshell.be/2012/05/24/hitb-amsterdam-wrap-up-day-1/</link>
		<comments>http://blog.rootshell.be/2012/05/24/hitb-amsterdam-wrap-up-day-1/#comments</comments>
		<pubDate>Thu, 24 May 2012 15:39:13 +0000</pubDate>
		<dc:creator>Xavier</dc:creator>
				<category><![CDATA[Event]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Conference]]></category>
		<category><![CDATA[HITB]]></category>

		<guid isPermaLink="false">http://blog.rootshell.be/?p=9602</guid>
		<description><![CDATA[I&#8217;m back in Amsterdam for the third time to attend the Hack in the Box security conference! Thanks to the organizers, I received again a press pass to cover the event. Thanks to them! So, here is my wrap-up of the first day. This year, I was also present as a speaker for SIGINT. SIGINT [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft  wp-image-9380" style="border: 0pt none;" title="IMG_1969.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_1969.jpg" alt="IMG 1969" width="270" height="360" border="0" /></p>
<p style="text-align: justify;">I&#8217;m back in Amsterdam for the third time to attend the <a title="Link to the website" href="http://conference.hitb.org/hitbsecconf2012ams/">Hack in the Box</a> security conference! Thanks to the organizers, I received again a press pass to cover the event. Thanks to them! So, here is my wrap-up of the first day. This year, I was also present as a speaker for <a title="Link to the website" href="http://conference.hitb.org/hitbsecconf2012ams/pagelist2/hitb-sigint/">SIGINT</a>. SIGINT is a bunch of &#8220;<em>small talks between the talks</em>&#8221; where people are free to present their research, their tool in a limited time window. After a safe travel from Belgium and the classic registration procedure, it was time for a small breakfast before the start of the busy day.</p>
<p style="text-align: justify;"><span id="more-9602"></span>The opening keynote was presented by <a href="http://twitter.com/csoandy">Andy Elis</a>, CEO of Akamai. The keynote title was &#8220;<em>Staying ahead of the Security poverty line</em>&#8220;. He started with a fact: To measure the quality of your security, just count the number of phone calls you receive outside the business hours! But what&#8217;s the security poverty line? Another fact: Organizations don&#8217;t have enough resources to implement perceived basic security needs. The syndrome of security subsystems is &#8220;<em>I can&#8217;t even do the barest minimum to cover my ass. So I&#8217;d better not do anything but cover my ass</em>&#8220;. Then accruing Technical Debt: With every step forward, the undone work increases risks and makes future steps harder.</p>
<p style="text-align: justify;">The value of your security can be computed with the following formula:</p>
<pre style="text-align: justify;">Value = Resources x capabilities"</pre>
<p style="text-align: justify;">Where:</p>
<pre style="text-align: justify;">resources = time + money
capabilities = skill x effort x effectiveness</pre>
<p style="text-align: justify;">Keep in mind: Nobody is going to implement perfect security. This means you have no risk but doing business is taking risks! Another reference is the <a title="Link to the website" href="http://en.wikipedia.org/wiki/Peltzman_effect">Peltzman</a> effect: What your organization thinks it can get away with… If you take away risks, you&#8217;ll take more risks. Andy gave a nice example with the NASCAR races in the United States. Very popular and safe but pilots take more and more risks!</p>
<p style="text-align: justify;">The security value and perceived risks should be in balance. Security is an habit to remove risks. What are the perceived risks vs actual risks?</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_1976.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_1976.jpg" alt="Perceived Risks vs Active Risks" width="360" height="270" border="0" /><p class="wp-caption-text">Perceived Risks vs Active Risks</p></div>
<p style="text-align: justify;">Another fact: Don&#8217;t beg for money! Based on security news, people decides to spend money for security solutions! Example: Wikipedia got DDoS, we need an anti-DDoS protection. Hackers break a website, we need a WAF! That&#8217;s not the best way to implement security.</p>
<p style="text-align: justify;">What about security awareness? The problem: auditors believe that if we just train people, we&#8217;ll get rid of problems. That&#8217;s bad. The solution is to perform simple security awareness training, web-based and automated. Don&#8217;t blame people for being pwn3d, let them share their experience! Andy&#8217;s slides are available <a href="http://bit.ly/LrZtw8">here</a>.</p>
<p style="text-align: justify;">Then the real talk started. The first one was about performing Android forensic: &#8220;<em>Turning Android inside out</em>&#8221; by Ivo Pooters. The idea of the talk was: Can an Android phone be used to investigate a man&#8217;s death (is it a suicide?) or to investigate a data breach? Those examples were not real cases but were part of the <a title="Link to the website" href="http://www.dfrws.org/2011/challenge/index.shtml">DFRWS Forensics Challenges 2011</a>.  First step: How to perform the data acquisition? Useful data are present on memory cards (easy to read) or in the internal storage (NAND flash) with multiple partitions like /data &amp; /cache. To make a copy of the internal flash, common tools remains useful:</p>
<pre># dd if=/dev/block/mtdblockX of=/sdcard/mtdblockX.img</pre>
<p style="text-align: justify;">What about the tools? There exists specific forensic tools like enCase, FTK (&#8220;<em>Forensic Tool Kit</em>&#8220;), Photorestore. Android uses the YAFFS2 file system (&#8220;<em>Yet Another Flash File System version 2</em>&#8220;). How to read such file system? Via forensic toolkits (Cellebrite UFED), via the Android emulator or load the YAFFS2 support into the Linux kernel:</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_1981.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_1981.jpg" alt="Enable YAFFS2 on Linux" width="360" height="270" border="0" /><p class="wp-caption-text">Enable YAFFS2 on Linux</p></div>
<p style="text-align: justify;">Once the file system mounted, use your regular tools to find for relevant information (IP addresses, names, file names, &#8230;)</p>
<p style="text-align: justify;">Two types of analysis can be performed:</p>
<ul style="text-align: justify;">
<li>Live analysis: Using an Android emulator + ADB, Wireshark, Dalvik debug monitor and logcat</li>
<li>Statis analysis: Retrieve the APK&#8217;s, use APT-tool to convert AndroidManifest to clear text XML. Convert dex (Dalvik VM) to regular Jar (dex2jar). Decompile using jd-gui or another java decompiler.</li>
</ul>
<p style="text-align: justify;">Then Ivo wend deeper about the YAFFS2 and explained a technique to retrieve content when the file system is corrupted. Normally, on classic file systems, even if they are damaged, it&#8217;s possible to get files back by using file <a title="Link to the website" href="http://www.forensicswiki.org/wiki/File_Carving">carving</a> techniques (Note that the new Android devices do not use YAFFS2 anymore but they are a lot our there). Nice presentation which proves that our preferred toys contain a lot of personal details which can be almost always retrieved using the right tools and techniques.</p>
<p style="text-align: justify;">The next presentation was about automatic malware analysis using <a title="Link to the website" href="http://www.cuckoobox.org">Cuckoo</a> by <a title="Link to the website" href="http://twitter.com/botherder">Claudio Guarnieri</a>. I was waiting for this presentation because I&#8217;m currently playing with commercial solutions to analyze malware and I&#8217;d like to compare them with an open source one. What are the problems with malware analysis? There are way too many  pieces of malwares. Manual analysis is simple impossible. Static analysis requires strong skill sets! So sandboxes are the best solution?</p>
<ul style="text-align: justify;">
<li>Pro: Automatic, process lot of work, usable by anyone, get the code executed</li>
<li>Cons: Commercial solutions are expensive! Some portions of the code cannot be executed, VM&#8217;s could be detected and it&#8217;s difficult to successfully automate the exploit analysis. Finally, without proper consumptions of the results, it&#8217;s useless.</li>
</ul>
<p style="text-align: justify;">The preparation is mandatory to define requirements and expectations, the environment must be properly designed for data and integration with other systems or storage solutions. Some questions to ask to yourself:</p>
<ul style="text-align: justify;">
<li>Why do you need a sandbox?</li>
<li>What do you expect to achieve?</li>
<li>What information is most relevant to you?</li>
<li>Who will use the results?</li>
<li>Which types? (PDF, browser exploits, Microsoft Office document, PHP/Perl scripts)</li>
</ul>
<p style="text-align: justify;">In most cases, Cuckoo can provide an answer to those questions. It can analyze lot of stuff, can be customized and integrated with other frameworks. It generates Win32 call traces, dropped lines, screenshots, network traffic dump and reports. It is based on three components: Scheduler -&gt; Analyzer -&gt; Reporter.</p>
<p style="text-align: justify;"> Claudio performed several demos of Cuckoo analyzing different types of malwares.</p>
<div class="mceTemp mceIEcenter" style="text-align: justify;">
<dl id="attachment_9608" class="wp-caption aligncenter" style="width: 310px;">
<dt class="wp-caption-dt"><img class="size-medium wp-image-9608" title="IMG_1983" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_1983-300x225.jpg" alt="Live Cuckoo Demo" width="300" height="225" /></dt>
<dd class="wp-caption-dd">Live Cuckoo Demo</dd>
</dl>
</div>
<p style="text-align: justify;">It looks to be very reliable and I recommend you to test it (who never received a mail with a suspicious attachment?). If you don&#8217;t have time to play or resources to run your own instance of Cuckoo, why not have a look at: <a title="Link to the website" href="http://malwr.com">malwr.com</a>. This website is a front-end for Cuckoo and work like virustotal.com. You submit your files and they are analyzed. Claudio and his team made a great job. This tool is definitively on my todo-list! Note that the current version only supports Windows VM&#8217;s but they are working on MacOSX and Linux versions.</p>
<p style="text-align: justify;">During the lunch break, I presented my tool <a title="Link to the website" href="https://github.com/xme/pastemon">pastemon.pl</a> and the associated website <a title="Link to the website" href="http://leakedin.com">leakedin.com</a>. This is the second time that I present it (first time was during BlackHat in March) and I received positive comments about it. It seems that people are interested in the pastebin.com content. The session was well organized and I was very happy to see many people take time to listen to me. Thanks to all of them!</p>
<p style="text-align: justify;">After the lunch, I attended the presentation called &#8220;<em>Whistling over the wire…</em>&#8221; by Arnauld Mascret. Behind this title, Arnault explained how to find interesting information from open sources (OSINT) and how to create new tools to perform the intelligence phase? He explained from A to Z how an attack can be conducted against a victim using mainly the social network Twitter and an URL shortener service. Is it possible to perform stealth targeted attacks? Yes, the main idea is to use your own (rogue) short URL service and promote it on Twitter to attract your victim to use it.</p>
<div class="wp-caption aligncenter" style="width: 370px"><img style="display: block; border: 0pt none;" title="IMG_1987.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_1987.jpg" alt="Twitter Attack Surface" width="360" height="270" border="0" /><p class="wp-caption-text">Twitter Attack Surface</p></div>
<p style="text-align: justify;">The different steps were deeply explained one by one up the live demo of the victim&#8217;s compromised computer. Conclusions for this talk: The risk is low. You need other vulnerabilities but all the tools are available and it works! Question from audience: How long does it take to realize this kind of attack? Arnault&#8217;s answer: &#8220;<em>It depends on the victim but a few weeks at least!</em>&#8220;. This proves that attackers have plenty of time to conduct their attacks! (compared to limited scope assigned to pentesters).</p>
<p style="text-align: justify;">The next presentation was about digital satellite television. Adam Gowdiak gave a deep overview of the security threats in this domain. Let&#8217;s be clear: modern Set-Top-Boxes are complete computers and became more and more complex. They are online and users don&#8217;t have a clue about the risks (&#8220;<em>Hey, it&#8217;s just television after all!</em>&#8220;). Most of them runs on Linux with a Java VM for applications. I learned that Java Applications (Xlets) can be broadcasted in MPEG streams! Even if Set-Top-Boxes have good security mechanisms (Embedded SSL Certificates, HTTPS scheme only, chroot sandbox, IP tables, no listening TCP ports, statically linked binaries, custom JAVA file system, binary code obfuscation, etc), Adam demonstrated that they are also vulnerable.</p>
<div id="attachment_9380" class="wp-caption aligncenter" style="width: 370px"><img class="wp-image-9380 " style="border: 0pt none;" title="IMG_1989.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_1989.jpg" alt="Set-Top-Box Architecture" width="360" height="270" border="0" /><p class="wp-caption-text">Set-Top-Box Architecture</p></div>
<p style="text-align: justify;">How to get device access? Adam explained all the steps to fully pwn the box starting with a Java script injection via a rogue photos album name. He successfully executed code, accessed the file system and memory and leaked file descriptors (/dev/kmem, /dev/mtd0). A demo was the capture of some streams outside of the box. Nice talk but less interesting for me. In parallel to this one, a talk about SAP (again!) was held. To conclude his presentation, Adam expressed his curiosity about the new connected television. For sure, they are also vulnerable to similar attacks.</p>
<p style="text-align: justify;">The last talk of this day: &#8220;<em>Windows shopping, Browser bug hunting in 2012</em>&#8221; by <a title="Link to the website" href="http://twitter.com/malerisch">Roberto Liverani</a> and Scott Bell. Why Browsers? Because they are everywhere and nice targets with all their extensions! This talk could be called &#8220;<em>The browsers wall of shame!</em>&#8220;. Roberto reviewed in details several attacks on different browsers:</p>
<ul>
<li style="text-align: justify;">Firefox Use After Free &lt; 11</li>
<li style="text-align: justify;">Maxthon – XCS and SOP Bypass</li>
<li style="text-align: justify;">Avant Browser XCS &amp; SOP Bypass</li>
<li style="text-align: justify;">Firefox, patched in 3.6.14</li>
<li style="text-align: justify;">Opera Use-After-Free</li>
<li style="text-align: justify;">Firefox/Opera – XCS</li>
</ul>
<div id="attachment_9610" class="wp-caption aligncenter" style="width: 310px"><img class="size-medium wp-image-9610 " title="IMG_1994" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_1994-300x225.jpg" alt="Firefox Use-After-Free PoC" width="300" height="225" /><p class="wp-caption-text">Firefox Use-After-Free PoC</p></div>
<p style="text-align: justify;">I won&#8217;t give details about the exploits here, they are fully reviewed and explained in Roberto&#8217;s slides. Just some conclusions:</p>
<ul>
<li style="text-align: justify;">Disclosure fail! (Opera this one is for you!)</li>
<li style="text-align: justify;">Bug complexity vs impact (injection bugs are simple but impact can be significant)</li>
<li style="text-align: justify;">Delegated security (presenting browsers as secure as IE or Chrome give false sense of security to end-users)</li>
</ul>
<p style="text-align: justify;">Last but not least, <a href="http://twitter.com/rob_g">Rop Gonggrijp</a> &#8211; a well-known Dutch Hacker &amp; Activist &#8211; presented the closing keynote. He came in emergency to replace the scheduled speaker. Rob is a great speaker. What did he say? The repression is there! (instead of fixing the security issues) Governments dreamed of controlling us. It&#8217;s done! Are you aware of the <a title="Link to the website" href="http://en.wikipedia.org/wiki/Printer_steganography">printers yellow dots</a>? They want total surveillance but &#8220;<em>If cyber-crime increases by a factor of 10, can it be stopped by surveillance?</em>&#8221; asked Rop. Data centralization is already over, we are now decentralizing everything (in the cloud). We continuously update our profiles online (linked in, twitter, etc). If you are living in Europe, you already uploading your data to a power block you don&#8217;t control. Is working for a national security agency safer than for a Romanian cyber-crime cartel? How to make the world a better place, safer? Selling security problems to nations is not responsible disclosure!</p>
<div id="attachment_9380" class="wp-caption aligncenter" style="width: 280px"><img class="wp-image-9380 " style="border: 0pt none;" title="IMG_1995.jpg" src="http://blog.rootshell.be/wp-content/uploads/2012/05/IMG_1995.jpg" alt="Rob Gonggrijp" width="270" height="360" border="0" /><p class="wp-caption-text">Rob Gonggrijp</p></div>
<p style="text-align: justify;">This closes the first day! Note that all presentations are made available online a few minutes after each talk. You find them <a title="Link to the website" href="http://conference.hitb.org/hitbsecconf2012ams/materials/">here</a>. Tomorrow, I&#8217;ll write the second wrap-up. If you need to follow real-time reactions, don&#8217;t hesitate to follow me on Twitter (<a title="Link to the website" href="http://twitter.com/xme">@xme</a>) or friends like <a title="Link to the website" href="http://twitter.com/corelanc0d3r">@corelanc0der</a> or <a title="Link to the website" href="http://twitter.com/seccubus">@seccubus</a> who are also covering the event. Tomorrow will be for sure the &#8220;Apple Day&#8221; <img src='http://blog.rootshell.be/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<img src="http://feeds.feedburner.com/~r/dev/rand/~4/EQ7_Vnq1JXA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.rootshell.be/2012/05/24/hitb-amsterdam-wrap-up-day-1/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Pastemon.pl Upgrade</title>
		<link>http://blog.rootshell.be/2012/05/21/pastemon-pl-upgrade/</link>
		<comments>http://blog.rootshell.be/2012/05/21/pastemon-pl-upgrade/#comments</comments>
		<pubDate>Mon, 21 May 2012 18:02:18 +0000</pubDate>
		<dc:creator>Xavier</dc:creator>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[pastebin.com]]></category>
		<category><![CDATA[Pastemon]]></category>

		<guid isPermaLink="false">http://blog.rootshell.be/?p=9581</guid>
		<description><![CDATA[Just a quick blog post to announce that I just committed a new version of my pastemon.pl tool on github.com. I&#8217;ll present it (and the associated website leakedin.com) this Thursday at HITB Amsterdam during a SIGINT session. What&#8217;s new with this version? First some bug fixes! (yes, I&#8217;m writing buggy code!) But there are also [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;"><img class="alignleft  wp-image-9380" style="float: left;" title="Screen Shot 2012-03-16 at 22.19.29.png" src="http://blog.rootshell.be/wp-content/uploads/2012/03/Screen-Shot-2012-03-16-at-22.19.29.png" alt="Screen Shot 2012 03 16 at 22 19 29" width="150" height="245" border="0" />Just a quick blog post to announce that I just committed a new version of my pastemon.pl tool on <a title="Link to the website" href="https://github.com/xme/pastemon">github.com</a>. I&#8217;ll present it (and the associated website <a title="Link to the website" href="http://leakedin.com">leakedin.com</a>) this Thursday at HITB Amsterdam during a <a title="Link to the website" href="http://conference.hitb.org/hitbsecconf2012ams/pagelist2/hitb-sigint/">SIGINT</a> session.</p>
<p style="text-align: justify;">What&#8217;s new with this version? First some bug fixes! (yes, I&#8217;m writing buggy code!) But there are also new features/options.</p>
<ul>
<li style="text-align: justify;">Opposite to the &#8220;<em>_EXCLUDE_</em>&#8221; feature, I added the &#8220;<em>_INCLUDE_</em>&#8221; one. This could help you to give more granularity to your regular expressions. Example: To search for references to the Visa credit card, use:
<pre>+4[0-9]{12}(?:[0-9]{3})? _INCLUDE_ (visa|credit|card)</pre>
<p>This will reduce false positives. The pastie will be flagged only if it contains a credit card number and one of the three words in the same text.</li>
</ul>
<ul>
<li style="text-align: justify;"> All the configuration has been moved from command line arguments to an XML file. It became difficult to maintain them in a single command line. The new syntax is simply:
<pre>./pastemon.pl --config=filepath [--debug] [--help]</pre>
<p>An XML sample configuration is provided in the repository.</li>
</ul>
<ul>
<li style="text-align: justify;">If you enable the dump of pasties to a directory, the matching regular expressions are added as headers to help you to remind why they were dumped.</li>
</ul>
<ul>
<li style="text-align: justify;">SMTP notifications have been added.</li>
<li style="text-align: justify;">Detection of duplicate pasties is performed based on the <a title="Link to Wikipedia" href="http://en.wikipedia.org/wiki/Jaro%E2%80%93Winkler_distance">Jaro-Winkler</a> algorithm. Pasties which are &#8220;<em>close</em>&#8221; to an already matching one won&#8217;t be reported.</li>
</ul>
<p style="text-align: justify;">If you&#8217;ll attend Hack In The Box in Amsterdam, feel free to come and say hello!</p>
<p>&nbsp;</p>
<img src="http://feeds.feedburner.com/~r/dev/rand/~4/5GX39wi9Zr0" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.rootshell.be/2012/05/21/pastemon-pl-upgrade/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>What Are You Sharing with Dropbox?</title>
		<link>http://blog.rootshell.be/2012/05/19/what-are-you-sharing-with-dropbox/</link>
		<comments>http://blog.rootshell.be/2012/05/19/what-are-you-sharing-with-dropbox/#comments</comments>
		<pubDate>Sat, 19 May 2012 14:15:51 +0000</pubDate>
		<dc:creator>Xavier</dc:creator>
				<category><![CDATA[Privacy]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Dropbox]]></category>

		<guid isPermaLink="false">http://blog.rootshell.be/?p=9558</guid>
		<description><![CDATA[Dropbox is a well-known online service which allows you to share files between computers. If, in the past few months, new outsiders came on the same market, Dropbox remains the number one. If files are synchronized between Dropbox software clients, they also provide features to share files with third-party who don&#8217;t have a Dropbox account. [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;"><img class="alignleft  wp-image-9559" title="I like Dropbox" src="http://blog.rootshell.be/wp-content/uploads/2012/05/ILikeDropbox.png" alt="I like Dropbox" width="147" height="216" /><a title="Link to the website" href="http://www.dropbox.com">Dropbox</a> is a well-known online service which allows you to share files between computers. If, in the past few months, new outsiders came on the same market, Dropbox remains the number one. If files are synchronized between Dropbox software clients, they also provide features to share files with third-party who don&#8217;t have a Dropbox account. How? By creating &#8220;<em>links</em>&#8221; to those files. It&#8217;s easy: In your Dropbox folder, select a file, right click and select &#8220;<em>Dropbox -&gt; Get Link</em>&#8220;. Your direct URL will look like this: &#8220;<em>http://www.dropbox.com/s/wg0ih0qywujn77y/myfile.zip</em>&#8220;. Then, share the URL with your peers who just have to point their browser to it to access your file. Easy!</p>
<p style="text-align: justify;">But if your files are available via HTTP(S), this means that anybody can access them. We just have to guess valid URLs. Guessing the 15-characters strings is doable (brute-force) but will require a <del>lot</del> waste of time. Where can we find plenty of existing URLs? In search engines of course!</p>
<p style="text-align: justify;"><span id="more-9558"></span></p>
<p style="text-align: justify;">I wrote a Google crawler and let it run during approximatively ten days. It was not easy. If Google is a champion to grab our data, they don&#8217;t allow extensive use of their search engine! You are often blacklisted and have to fill a CAPTCHA. They present you a  &#8220;<em>sorry page</em>&#8221; to prove you are not a bot:</p>
<p style="text-align: center;"><img class="aligncenter  wp-image-9569" title="Google Sorry Page" src="http://blog.rootshell.be/wp-content/uploads/2012/05/google-sorry-262x300.png" alt="Google Sorry Page" width="210" height="240" /></p>
<p style="text-align: justify;">But some techniques can be implemented to evade their tests:</p>
<ul>
<li>Search across multiple TLD&#8217;s (easy, they have all of them <img src='http://blog.rootshell.be/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </li>
<li>Change your User-Agent string randomly</li>
<li>Use open-proxies randomly</li>
<li>Do NOT use Tor, they blacklist the exit-nodes</li>
<li>Use other anonymizing services (like <a title="Link to the website" href="http://anonymouse.org">anonymouse.org</a>)</li>
<li>Add random sleep() between queries</li>
</ul>
<p style="text-align: justify;">My crawler searched for pages containing &#8220;<em>http[s]://[dl|www].dropbox/s/*</em>&#8220;. For every hit returned by Google, the corresponding URL was also visited to parse and extract the Dropbox shared links. Finally, all found URLs were visited (500.000+ pages were processed) and data downloaded. Of course, a lot of them provided the same content or same links (example: all conversations in forums, mailing-lists archives).</p>
<p style="text-align: justify;">Interesting to mention, when I downloaded all the files in batch from Dropbox, I did not implement special techniques like the ones to search on Google. And I was never blacklisted! I&#8217;m just wondering if Dropbox have controls in place? Did they see my traffic?</p>
<p>All the files were reviewed and here are some findings. Let&#8217;s start with some statistics:</p>
<ul>
<li>2240 unique Dropbox URLs were found</li>
<li>1762 files were downloaded (HTTP 200)</li>
<li>116 requests returned an HTTP 403 error</li>
<li>332 requests returned an HTTP 404 error</li>
<li>45.57 GBytes was downloaded</li>
<li>The biggest file was 2.09GB (a RAR archive with WAV files).</li>
<li>Average file size: 26.32MB</li>
</ul>
<p style="text-align: justify;">A &#8220;<em>403</em>&#8221; error corresponds to a bad file name (ex: typo error in the URL). A &#8220;<em>404</em>&#8221; means that the file was removed by the Dropbox user. Here we can already make a conclusion/recommendations. When users share files with open links, they often don&#8217;t remove it once the file has been downloaded by the third parties. For me, shared links are temporary links! Dropbox allows to &#8220;cancel&#8221; a shared link without deleting the file.</p>
<p>What are the most shared file types?</p>
<table class="aligncenter">
<tbody>
<tr>
<td><strong>File Type</strong></td>
<td><strong>Found</strong></td>
</tr>
<tr>
<td>data</td>
<td>1088</td>
</tr>
<tr>
<td>Zip archive data</td>
<td>383</td>
</tr>
<tr>
<td>JPEG image data</td>
<td>354</td>
</tr>
<tr>
<td>ZIP archive data, at least v2.0 to extract</td>
<td>295</td>
</tr>
<tr>
<td>JPEG image data, EXIF standard</td>
<td>167</td>
</tr>
<tr>
<td>JPEG image data, JFIF standard 1.01</td>
<td>140</td>
</tr>
<tr>
<td>RAR archive data, v1d, os: Win32</td>
<td>86</td>
</tr>
<tr>
<td>ZIP archive data, at least v1.0 to extract</td>
<td>83</td>
</tr>
<tr>
<td>PDF document, version 1.5</td>
<td>71</td>
</tr>
<tr>
<td>PDF document, version 1.3</td>
<td>63</td>
</tr>
<tr>
<td>PDF document, version 1.4</td>
<td>62</td>
</tr>
<tr>
<td>ISO Media</td>
<td>60</td>
</tr>
<tr>
<td>JPEG image data, JFIF standard 1.02</td>
<td>45</td>
</tr>
<tr>
<td>JPEG image data, EXIF standard 2.2</td>
<td>44</td>
</tr>
<tr>
<td>Audio file with ID3 version 2.3.0</td>
<td>41</td>
</tr>
<tr>
<td>ASCII text</td>
<td>41</td>
</tr>
<tr>
<td>PE32 executable (GUI) Intel 80386, for MS Windows</td>
<td>36</td>
</tr>
<tr>
<td>Microsoft Word 2007+</td>
<td>30</td>
</tr>
<tr>
<td>Microsoft Excel 2007+</td>
<td>22</td>
</tr>
<tr>
<td>JPEG image data, EXIF standard 2.21</td>
<td>18</td>
</tr>
</tbody>
</table>
<p style="text-align: justify;">What were the most obscure file type? Just two examples:</p>
<ul>
<li>A Fortran source code</li>
<li>A x86 boot sector</li>
</ul>
<p style="text-align: justify;">Some filenames were explicit and attracted my attention immediately (like &#8220;<em>Report-04-2012.xls</em>&#8220;). By doing this exercises, you immediately understand why social engineering attacks are so successful and why people suffer of &#8220;<em>clickmania</em>&#8220;. It&#8217;s really tempting to open such files!</p>
<p style="text-align: justify;">First, the pictures. I was surprised: only one picture was pornographic material. Lot of screenshots and error messages were found. I also saw a lot of pictures of good for sale and, a classic, network schema&#8217;s! 50% of the pictures were took using smartphones and contained of course interesting EXIF data (GPS coordinates).</p>
<p style="text-align: justify;">The office documents were also a good source of findings. To briefly resume, I found:</p>
<ul>
<li style="text-align: justify;">A list of weapons (!) for sale (pictures, prices, stocks)</li>
<li style="text-align: justify;">Political documents (propaganda)</li>
<li style="text-align: justify;">Resumes (with all private details of course)</li>
<li style="text-align: justify;">Employees lists</li>
<li style="text-align: justify;">MDB files (Microsoft Access)</li>
<li style="text-align: justify;">Business plans</li>
<li style="text-align: justify;">Attorneys documents (infringements reports)</li>
<li style="text-align: justify;">Meeting minutes</li>
<li style="text-align: justify;">Manuals (cars, mobile phones, tools)</li>
<li style="text-align: justify;">Student thesis</li>
</ul>
<p style="text-align: justify;">The best one was for sure a complete scan of a real-estate contract completed with all details:</p>
<div id="attachment_9565" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.rootshell.be/wp-content/uploads/2012/05/dropbpox-realestate.png"><img class="size-medium wp-image-9565" title="Real Estate Contract" src="http://blog.rootshell.be/wp-content/uploads/2012/05/dropbpox-realestate-300x61.png" alt="Real Estate Contract" width="300" height="61" /></a><p class="wp-caption-text">(Click to enlarge)</p></div>
<p style="text-align: justify;">Of course, I scanned the files with an anti-virus (ClamAV). On the 56 executable files found, only 6 were infected with Trojans (10.71%). I also found a lot of Android application packages (*.apk) files. I did not extract meta-data from those Office files but I&#8217;m sure I could find interesting stuff too.</p>
<p style="text-align: justify;">Another interesting finding? Developers also enjoy the Dropbox sharing feature. I found lot of source code (HTML, JavaScript, XML, PHP). It&#8217;s easy to develop and share your source code, no need to upload your source files, just share them and include them in your applications. However, when you download the file directly, the source code is disclosed. Example: <a title="Link to the website" href="https://www.dropbox.com/s/388v3j55z4210e1/test.php">https://www.dropbox.com/s/388v3j55z4210e1/test.php</a>.</p>
<p style="text-align: justify;">What can we conclude from this small analysis? Dropbox links do not reveal who shared the file. There is no way to find back the account owner, except if personal information are disclosed in the shared file. And&#8230; they are! Shared files are difficult to exploit to collect information about a target (during the reconnaissance phase of a coming attack). Anyway, keep in mind that shared files can be read by anybody! This feature must be used with due care and attention. If you really need to share sensitive data, encrypt them! Which is always good when sending files into the Dropbox cloud&#8230;</p>
<img src="http://feeds.feedburner.com/~r/dev/rand/~4/u6Y6NnOJBbM" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.rootshell.be/2012/05/19/what-are-you-sharing-with-dropbox/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Monitor your Monitoring Tools</title>
		<link>http://blog.rootshell.be/2012/05/10/monitor-your-monitoring-tools/</link>
		<comments>http://blog.rootshell.be/2012/05/10/monitor-your-monitoring-tools/#comments</comments>
		<pubDate>Thu, 10 May 2012 18:14:39 +0000</pubDate>
		<dc:creator>Xavier</dc:creator>
				<category><![CDATA[Logs Management / SIEM]]></category>
		<category><![CDATA[OSSEC]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[monitoring]]></category>
		<category><![CDATA[SIEM]]></category>
		<category><![CDATA[tools]]></category>

		<guid isPermaLink="false">http://blog.rootshell.be/?p=9542</guid>
		<description><![CDATA[We (and I&#8217;m fully part of it) deploy and use plenty of security monitoring tools daily. As our beloved data is often spread across complex infrastructures or simply across multiple physical locations, we have to collect interesting information and bring them in a central place for further analysis. That&#8217;s called &#8220;log management&#8220;. Based on your [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;"><img class="alignleft  wp-image-9544" title="Check Yuorself" src="http://blog.rootshell.be/wp-content/uploads/2012/05/checkyourself-300x225.png" alt="Check Yuorself" width="240" height="180" />We (and I&#8217;m fully part of it) deploy and use plenty of security monitoring tools daily. As our beloved data is often spread across complex infrastructures or simply across multiple physical locations, we have to collect interesting information and bring them in a central place for further analysis. That&#8217;s called &#8220;<em>log management</em>&#8220;. Based on your collected events, you can generate alerts, build reports. Nice! But&#8230; if systems and applications generate [hundreds|thousands|millions] of events, those ones are processed by the same kind of hardware running some piece of software. Hardware may fail (network outage, power outage, disk crash) and softwares have bugs (plenty of).</p>
<p style="text-align: justify;"><span id="more-9542"></span></p>
<p style="text-align: justify;">This morning, I received several alerts like this:</p>
<pre>** Alert 1336642415.2196887: mail  - ossec,
2012 May 10 11:33:35 xxxxxxxx-&gt;ossec-monitord
Rule: 504 (level 10) -&gt; 'Ossec agent disconnected.'
Src IP: (none)
User: (none)
ossec: Agent disconnected: 'xxxxxxxx-10.0.0.1'.</pre>
<p style="text-align: justify;">This message warns that an OSSEC agent is not alive and is very suspicious. And a few minutes later, same message for another server, and so on, one by one&#8230; After a quick check, all servers and network connections were fine. The problem was on the <a title="Link to the website" href="http://www.ossec.net">OSSEC</a> server itself. A typo error in a new rule put some processes in a fuzzy state. Killing and the process and restarting properly the OSSEC server solved the problem. This example based on OSSEC is just an introduction to the topic of this quick blogpost: When you deploy security monitoring solutions, be sure to monitor them too!</p>
<p style="text-align: justify;">In parallel to the security checks performed by your log management solution, extra verifications must be performed to control the flow of events and, when required, trigger other types of alerts. A classic situation is when events are pushed to the log management platform. It will  wait passively for incoming events. This can be resumed as &#8220;<em>No event received? Everything ok! Let&#8217;s have some sleep&#8230;</em>&#8220;. Examples of suspicious situations:</p>
<ul>
<li style="text-align: justify;">You did not receive any new Syslog events from a specific host for x minutes.<br />
→ The Syslog daemon might be down or a network outage prevent UDP packets to reach the Syslog concentrator.</li>
<li style="text-align: justify;">If you did not process new lines from an Apache log file.<br />
→Apache might be in trouble or the file system might be full. Can you read the log file? (wrong permissions)</li>
<li style="text-align: justify;">You did not receive any new alerts for x hours.<br />
→Your log management system might be overloaded, some process killed or a file system being full.</li>
</ul>
<p>There are plenty of nightmare example like those. How to prevent them?</p>
<ul>
<li style="text-align: justify;">Like any other information system, keep an eye on the system health (control the CPU, memory, storage, processes). Disk space is critical and directly depends on your amount of data and retention policies.</li>
<li style="text-align: justify;">Send keep-alives to your remote [pollers|sensors|agents] (whatever you name them).</li>
<li style="text-align: justify;">Control any derivation of your regular events flow (compared to a baseline for a defined period &#8211; hourly/daily/etc). Example, is it normal to not see any login events from your Active Directory on a Monday morning?</li>
<li style="text-align: justify;">Implement queuing mechanisms to prevent events to be lost (when they are automatically pushed to the central system).</li>
<li style="text-align: justify;">When possible, collect events using pull technologies. If the log management platform has troubles, events won&#8217;t be lost and will wait until being retrieved later.</li>
</ul>
<p style="text-align: justify;">Don&#8217;t forget: Log management solutions are your best friends when you need to investigate a security incident. There is nothing more frustrating than gaps in your events timeline!</p>
<img src="http://feeds.feedburner.com/~r/dev/rand/~4/repWegAH_eE" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.rootshell.be/2012/05/10/monitor-your-monitoring-tools/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Hack in Paris and La Nuit du Hack (10th Edition)</title>
		<link>http://blog.rootshell.be/2012/05/05/hack-in-paris-and-la-nuit-du-hack-10th-edition/</link>
		<comments>http://blog.rootshell.be/2012/05/05/hack-in-paris-and-la-nuit-du-hack-10th-edition/#comments</comments>
		<pubDate>Sat, 05 May 2012 09:03:55 +0000</pubDate>
		<dc:creator>Xavier</dc:creator>
				<category><![CDATA[Event]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Conference]]></category>
		<category><![CDATA[Paris]]></category>

		<guid isPermaLink="false">http://blog.rootshell.be/?p=9537</guid>
		<description><![CDATA[The French hacking event is back! This year is a special one, it&#8217;s the tenth edition of &#8220;La Nuit du Hack&#8221; which follows the conference &#8220;Hack in Paris&#8220;. Yes, as the previous editions, there are three distinguished parts in this major event. Trainings are organized from June 18th to 20th (more info here). Then, two [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft  wp-image-9380" style="float: left;" title="300-250_white.gif" src="http://blog.rootshell.be/wp-content/uploads/2012/05/300-250_white.gif" alt="Hack in Paris Logo" width="200" height="166" border="0" /></p>
<p style="text-align: justify;">The French hacking event is back! This year is a special one, it&#8217;s the tenth edition of &#8220;<em>La Nuit du Hack</em>&#8221; which follows the conference &#8220;<em>Hack in Paris</em>&#8220;. Yes, as the previous editions, there are three distinguished parts in this major event. Trainings are organized from June 18th to 20th (more info <a href="http://www.hackinparis.com/trainings">here</a>). Then, two days (June 21st &#8211; 22nd) of talks with famous speakers. And finally, an &#8220;<em>event into the event</em>&#8220;: <a href="http://nuitduhack.com">La Nuit du Hack</a> will be held on June 23rd.</p>
<p style="text-align: justify;">During the last edition, 950 hackers registered to follow more talks and participate to the CTP challenge. This year, a public <a href="http://wargame.nuitduhack.com/">wargame</a> is also available! Feel free to test the 2011 challenges!</p>
<p style="text-align: justify;">I&#8217;ll be present the Thursday and Friday to cover the talks and I&#8217;ve also some gifts for you: Like for the previous edition, the organization provided me 10  discount codes (-10%) on &#8220;<em>conference only</em>&#8221; <a href="http://www.hackinparis.com/talks-only-tickets">tickets</a>. The contest is now open! The first ten people who drop me an email (xavier{at}rootshell{dot}be) will receive a discount code… (FIFO!)</p>
<img src="http://feeds.feedburner.com/~r/dev/rand/~4/n9cbZMvhwXc" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.rootshell.be/2012/05/05/hack-in-paris-and-la-nuit-du-hack-10th-edition/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Integrating OSVDB into Ubuntu/Unity</title>
		<link>http://blog.rootshell.be/2012/05/02/integrating-osvdb-into-ubuntuunity/</link>
		<comments>http://blog.rootshell.be/2012/05/02/integrating-osvdb-into-ubuntuunity/#comments</comments>
		<pubDate>Wed, 02 May 2012 14:06:27 +0000</pubDate>
		<dc:creator>Xavier</dc:creator>
				<category><![CDATA[OS]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Unix]]></category>
		<category><![CDATA[OSVDB]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Vulnerabilities]]></category>

		<guid isPermaLink="false">http://blog.rootshell.be/?p=9513</guid>
		<description><![CDATA[Recently I upgraded my laptop with the latest Ubuntu release (12.04-LTS). For a few releases, Ubuntu switched from Gnome to Unity and I&#8217;m happy to use it since the 11.04 version! I know that this choice has caused a lot of debates between the aficionados of both GUI but it always worked fine for me. [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;"><img class="alignleft  wp-image-9525" title="OSVDB Lens" src="http://blog.rootshell.be/wp-content/uploads/2012/05/osvdb-lens.png" alt="OSVDB Lens" width="240" height="180" />Recently I upgraded my laptop with the latest <a href="http://www.ubuntu.com">Ubuntu</a> release (12.04-LTS). For a few releases, Ubuntu switched from Gnome to <a href="http://unity.ubuntu.com/">Unity</a> and I&#8217;m happy to use it since the 11.04 version! I know that this choice has caused a lot of debates between the aficionados of both GUI but it always worked fine for me. Of course, no interface is perfect but it does its job. I just like the way it presents applications and files. Most are accessible with a few key presses. After the upgrade, I made the new proprietary tour and decided to look deeper into the Unity &#8220;<em>Dash</em>&#8221; feature. This is the main feature of Unity. It allows you to quickly search for information on your local filesystems (applications, files, bookmarks, &#8230;) or on the Internet (<a title="Link to the website" href="http://news.softpedia.com/news/Introducing-Ubuntu-Wikipedia-Lens-for-Unity-267048.shtml">Wikipedia</a>). To achieve this, the &#8220;<em>Dash</em>&#8221; uses &#8220;<em>Lenses</em>&#8220;. And those use &#8220;<em>Scopes</em>&#8221; that are small scripts which perform the search requests. &#8220;<em>Lenses</em>&#8221; are based on (briefly resumed):</p>
<ul style="text-align: justify;">
<li>A .lens file to let Unity load it</li>
<li>A daemon with a well-known name on <a title="Link to Wikipedia" href="http://en.wikipedia.org/wiki/D-Bus">D-Bus</a></li>
<li>A D-Bus .service file to let Unity activate the Lens</li>
</ul>
<p style="text-align: justify;">When Unity is started, it parses the configuration files and spawns the small daemons responsible for the searches. On a stock Ubuntu, you can see the following daemons running:</p>
<pre>$ ps ax|grep lens
 2741 ?        Sl     0:05 /usr/lib/unity-lens-applications/unity-applications-daemon
 2743 ?        Sl     0:04 /usr/lib/unity-lens-files/unity-files-daemon
 2745 ?        Sl     0:00 /usr/lib/unity-lens-music/unity-music-daemon
 2747 ?        Sl     0:01 /usr/bin/python /usr/lib/unity-lens-video/unity-lens-video
 2777 ?        Sl     0:00 /usr/lib/unity-lens-music/unity-musicstore-daemon</pre>
<p style="text-align: justify;">If you&#8217;re interested in learning more about Lenses, there is a good documentation available <a title="Link to the website" href="https://wiki.ubuntu.com/Unity/Lenses">here</a>. Some people started to write their own Lenses to search for useful online data. Some popular ones are:</p>
<ul>
<li>Wikipedia</li>
<li>Google Contacts</li>
<li>Youtube</li>
<li>Torrents</li>
<li>Flickr</li>
</ul>
<p style="text-align: justify;">Basically, any website that proposes a search feature can be integrated into Unity as well as any online service! (ex: whois) The daemon needs to send the query based on the provided keywords and format the results into something usable by Unity (via D-Bus).</p>
<p style="text-align: justify;">I decided to learn how to build my own Lens. Why not create one with more focus on information security? What can be interesting to search for if you&#8217;re an infosec guy? Vulnerabilities of course! Let&#8217;s imagine, you are performing a pentest and you find a unpatched Solaris box running an Apache server. It could be nice to search for vulnerabilities affecting those solutions. That&#8217;s the purpose of my Lens: searching the <a title="Link to the website" href="http://www.osvdb.org">OSVDB</a> database for vulnerabilities.</p>
<p style="text-align: justify;">Type some terms (or dates) and relevant OSVDB entries will be displayed directly in Unity. Click on them to open a browser to the direct page!</p>
<div id="attachment_9518" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.rootshell.be/wp-content/uploads/2012/05/unity-lens-osvdb-screenshot.png"><img class="size-medium wp-image-9518" title="Unity Lens OSVDB Screenshot" src="http://blog.rootshell.be/wp-content/uploads/2012/05/unity-lens-osvdb-screenshot-300x93.png" alt="Unity Lens OSVDB Screenshot" width="300" height="93" /></a><p class="wp-caption-text">(Click to enlarge)</p></div>
<p style="text-align: justify;">By default (empty search), the latest vulnerabilities are displayed (sorted by time). You can also search for a specific period by specifying a month and a year (ex: &#8220;<em>Apr 2012</em>&#8220;). The full-text search feature of OSVDB is used (ex: &#8220;<em>Cisco IOS 12.1</em>&#8220;). There is nothing fancy, most of the code is based on another publicly available Lens. It was first of all a good opportunity for me to write my first piece of code in Python! <img src='http://blog.rootshell.be/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>
<p style="text-align: justify;">Source files are available on <a title="Link to the website" href="https://github.com/xme/unity-lens-osvdb">github.com</a>. A Debian package (.deb) is ready to be installed. A logout is required to restart Unity and makes it recognize the new Lens. Once installed click on the little &#8220;<em>OSVDB</em>&#8221; icon on the bottom of your Dash to search for vulnerabilities. Feel free to use it, patch it or submit your comments! Enjoy!</p>
<img src="http://feeds.feedburner.com/~r/dev/rand/~4/Tho3dZ0sbQk" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.rootshell.be/2012/05/02/integrating-osvdb-into-ubuntuunity/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>London… a Nest of Infosec People</title>
		<link>http://blog.rootshell.be/2012/04/26/london-a-nest-of-infosec-people/</link>
		<comments>http://blog.rootshell.be/2012/04/26/london-a-nest-of-infosec-people/#comments</comments>
		<pubDate>Thu, 26 Apr 2012 05:09:21 +0000</pubDate>
		<dc:creator>Xavier</dc:creator>
				<category><![CDATA[Event]]></category>
		<category><![CDATA[People / Places]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[BSides]]></category>
		<category><![CDATA[London]]></category>

		<guid isPermaLink="false">http://blog.rootshell.be/?p=9485</guid>
		<description><![CDATA[I&#8217;m back from a small trip to London where is happening some kind of a &#8220;security marathon&#8221; this week! In parallel to InfoSecurity Europe 2012, several &#8220;alternative&#8221; events where organized in the same area. However I did not visited InfoSecurity. I was present at the Benelux edition a few weeks ago and saw enough vendors/products [...]]]></description>
			<content:encoded><![CDATA[<div id="attachment_9488" class="wp-caption alignleft" style="width: 250px"><img class=" wp-image-9488 " title="BSidesLondon Track 1" src="http://blog.rootshell.be/wp-content/uploads/2012/04/IMG_1872-300x225.jpg" alt="" width="240" height="180" /><p class="wp-caption-text">BSidesLondon Track 1</p></div>
<p style="text-align: justify;">I&#8217;m back from a small trip to London where is happening some kind of a &#8220;security marathon&#8221; this week! In parallel to <a href="http://www.infosec.co.uk/">InfoSecurity Europe 2012</a>, several &#8220;alternative&#8221; events where organized in the same area. However I did not visited InfoSecurity. I was present at the Benelux edition a few weeks ago and saw enough vendors/products (ties overflow). After a nice ride under the sea and having dropped my luggage at the hotel, I reached my first step: the <a title="Link to the website" href="http://bhconsulting.ie/securitywatch/?p=1236">Information Security Blogger Meetup</a>. The pub was fully dedicated to people from InfoSecurity (sponsored by Firemon) and a space was reserved to the bloggers but not so many people present (although 40 people registered). It was a bit disappointing but, anyway, it was a good opportunity to meet <a title="Link to the website" href="http://twitter.com/andrewsmhay">Andrew</a> &amp; <a title="Link to the website" href="http://twitter.com/klhay">Kelly</a> Hay and <a title="Link to the website" href="http://twitter.com/J4vv4d">Javvad Malik</a>. Thanks for the sponsor for the open bar! By the way, I missed <a title="Link to the website" href="http://ow.ly/i/AnPI">Brian</a> Honan with a bow tie! <img src='http://blog.rootshell.be/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>
<p style="text-align: justify;"><span id="more-9485"></span></p>
<p style="text-align: justify;">The next step was a few streets far away: the <a title="Link to the website" href="http://44con.com/2012/02/05/44cafe/">44Café</a> and <a title="Link to the website" href="http://dc4420.org/">DC4420</a> were organized in another pub, the &#8220;Troubadour&#8221;. There was much more people and an atmosphere close to the one of real security conferences (read:  &#8221;beers and talks&#8221;). I came late and I was only able to watch the <a title="Link to the website" href="http://rfidiot.org/">Adam Laurie</a>&#8216;s talk about the security of RF communications (based on  433Mhz frequency). More and more gadgets with RF interfaces, are found in our houses. A good example are the remote controls for electric devices (to turn them off/on via your sofa or bed). Most of those devices are made in China and do not implement any security control at all. Adam performed a nice demo. He sniffed the original RF signal using a specific dongle and the &#8220;rfcap&#8221; tool. The captured .wav file can be analyzed and replayed using the same device. And he successfully powered off/on the LED lamp on the stage. Awesome! Of course, this has a limited impact (a very low operational range) but… Once the DC4420 over, I went to an Italian restaurant with friends to continue discussions about security.</p>
<p style="text-align: justify;">After a short night, let&#8217;s commute to the next step: <a title="Link to the website" href="http://www.securitybsides.com/w/page/46661833/BSidesLondon-2012">BSidesLondon</a>! This was the second edition. I won&#8217;t come back on the history of BSides conferences, here is a <a title="Link to the website" href="http://www.securitybsides.com/w/page/12194138/BSides">reminder</a>. The conference moved to a new venue, the Barbican center, a very nice place!</p>
<div id="attachment_9490" class="wp-caption aligncenter" style="width: 310px"><img class="size-medium wp-image-9490" title="The Barbican Center Garden" src="http://blog.rootshell.be/wp-content/uploads/2012/04/IMG_1896-300x225.jpg" alt="The Barbican Center Garden" width="300" height="225" /><p class="wp-caption-text">The Barbican Center Garden</p></div>
<p style="text-align: justify;">First talk of the day was the one of Robin Wood (<a title="Link to the website" href="http://twitter.com/digininja">@digininja</a>) about &#8220;<em>Breaking in to security</em>&#8220;. A few weeks ago, Robin asked to Infosec professional to answer a few questions about their career (via an online survey). The goal was to produce a definitive answer to people frequently asking &#8220;<em>How to start a career in information security?</em>&#8220;, &#8220;<em>What programming language learn to become a pentester?</em>&#8221; or &#8220;<em>Which certification should I get?</em>&#8221; First, it seems that people are not aware of the reality and media report often a bad idea of the &#8220;hackers&#8221;:</p>
<div id="attachment_9493" class="wp-caption aligncenter" style="width: 310px"><img class="size-medium wp-image-9493" title="Infosec Job Reality" src="http://blog.rootshell.be/wp-content/uploads/2012/04/photo1-e1335418942364-300x225.jpg" alt="Infosec Job Reality" width="300" height="225" /><p class="wp-caption-text">Infosec Job Reality</p></div>
<p style="text-align: justify;">Some stats extracted from the survey:</p>
<ul>
<li style="text-align: justify;">43% of people who answered are active in information security for more than seven years</li>
<li style="text-align: justify;">Interesting job types: 33% reported being &#8220;log analyst&#8221; and 25% busy with &#8220;incident response&#8221;</li>
<li style="text-align: justify;">Do you need to be a programmer to pen test: no but it helps (62%), yes (26%). The goal of programs is to automate boring tasks.</li>
<li style="text-align: justify;">Which language are preferred? Top-3: python, bash, ruby</li>
<li style="text-align: justify;">Which Certs are useful? SANS/GIAC, CISSP, Offensive security (PWB, AWE, …)</li>
<li style="text-align: justify;">Is attending conference important: YES (88%)</li>
<li style="text-align: justify;">Which con? All of them had a mention <img src='http://blog.rootshell.be/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </li>
</ul>
<p style="text-align: justify;">Then a live interview (real case study) was performed with Wicked Clown. Don&#8217;t forget that security involves also dealing with people, public speaking, negotiation skills, writing report (boring ok!) and networking. Security conferences are a must to attend even if they are often bad for your liver! Have also a look at mailing lists, podcasts, forums. Don&#8217;t be afraid to ask questions and to learn. Today it&#8217;s easy to build a lab at home using virtualization.  As a conclusion to this talk, only one word is important: &#8220;passion&#8221;! Remember: It cannot only be &#8220;a job&#8221;! Robin&#8217;s slides are already available <a title="Link to the website" href="www.digininja.org/projects/breaking_in_bsides.php">here</a>.</p>
<p style="text-align: justify;">The second talk was about Social Engineering: &#8220;<em>What is it &amp; how is it done?</em>&#8221; by Ian Maxted (<a title="Link to the website" href="http://twitter.com/TheJeffVader">@TheJeffVader</a>). He started the presentation with an history of social engineering. Did you know that it started with a book published in 1946 (name). Then he reviewed several techniques to collect sensitive information. Classic places are smoking areas or coffee machine in companies or pubs! Of course, with the new &#8220;Y&#8221; generation, social networks are a great place to search for useful details to contact further attacks. Ian showed some examples of fake websites. Note that such interfaces are quite easy to build, even by script kiddies but it&#8217;s sometimes not easy to persuade the victim to visit them. That&#8217;s what makes social engineering interesting. The goal is to establish relationships! Great introduction!</p>
<div id="attachment_9498" class="wp-caption aligncenter" style="width: 310px"><img class="size-medium wp-image-9498" title="Social Engineering" src="http://blog.rootshell.be/wp-content/uploads/2012/04/photo-21-e1335419508476-300x225.jpg" alt="Socian Engineering" width="300" height="225" /><p class="wp-caption-text">Social Engineering</p></div>
<p style="text-align: justify;">Next, the security of Windows Phone 7 was analyzed by David Rook (<a title="Link to the website" href="http://twitter.com/securityninja">@securityninja</a>). As other systems, <a title="Link to the website" href="http://www.microsoft.com/windowsphone/en-us/default.aspx?pf=true">Windows Phone 7</a> will suffer of security issues. Why? Today, 31% of mobile devices are smartphones. And those devices are really useful when you install apps. Remember the slogan: &#8220;<em>There is an app for that!</em>&#8220;. And apps introduce vulnerabilities. The market share of Windows Phone 7 is today only 1.9% but it will grow in the coming years. After this introduction, David explained how apps are developed and are running. First, if you are a .Net developer, you are already a Windows Phone 7 develop! .Net is also used but in a compact framework for resource constrained devices. The applications run in a &#8220;<a title="Link to the website" href="http://en.wikipedia.org/wiki/Common_Language_Runtime">CLR</a>&#8221; (&#8220;<em>Common Language Runtime</em>&#8221; &#8211; some kind of Java VM) and cannot access restricted code. The security model is the following:</p>
<ul>
<li style="text-align: justify;">Chambers concept to enforce app isolation and least privilege</li>
<li style="text-align: justify;">The chambers provide a security boundary to restrict the apps</li>
<li style="text-align: justify;">For chambers and apps runs in one of them</li>
<li style="text-align: justify;">3 chambers have fixed permission sets</li>
<li style="text-align: justify;">4th chamber is capabilities based</li>
</ul>
<p style="text-align: justify;">An interesting tool: Windows Phone App Analyzer 1.0</p>
<p style="text-align: justify;">Note that all apps must be signed by Microsoft after reviewing process before being published on the Microsoft market. For the rest, the same features are used: application sandboxing, isolated storage. Security remains the same but think more about the root causes like input/output validation, error handling, etc. Robin&#8217;s Top-3 is: secure storage, authentication &amp; access and privacy. Nothing really new, the same best practices must be implemented: Never store data locally if not needed. About encryption, Windows Phone 7 allows to encrypt data &amp; databases, do it!</p>
<div id="attachment_9501" class="wp-caption aligncenter" style="width: 310px"><img class="size-medium wp-image-9501" title="SecurityNinja &amp; Windows Phone 7" src="http://blog.rootshell.be/wp-content/uploads/2012/04/photo3-e1335426225512-300x225.jpg" alt="SecurityNinja &amp; Windows Phone 7" width="300" height="225" /><p class="wp-caption-text">SecurityNinja &amp; Windows Phone 7</p></div>
<p style="text-align: justify;">The next talk was not schedule (planning change?) but it was really interesting. <a title="Link to the website" href="https://twitter.com/#!/pacohope">Paco Hope</a> talked about &#8220;randomness&#8221;. Where are random numbers used? In many fields: games (poker), gambling, lottery, casino but also in more &#8220;technical application&#8221; like SSL, filename generators etc. What&#8217;s important with randomness?</p>
<ul>
<li style="text-align: justify;">The uniformity (no pattern)</li>
<li style="text-align: justify;">The forward security (can&#8217;t know previous values)</li>
<li style="text-align: justify;">The backward security (can&#8217;t know future values)</li>
</ul>
<p style="text-align: justify;">Developing a good random generator is not easy (as seen on <a title="Link to the website" href="xkcd.com/221">xkcd.com</a>). Plenty of mistakes can be done making the generator predictable (even if sometimes it&#8217;s not easy at all). Random numbers can be generated by hardware solutions (PCI cards, built-in chips on motherboards or USB dongle) but they also have vulnerabilities: environmental (temperature, voltage). And the throughput remains critical in some applications. About software solutions, common problems are where to gt the entropy, how often reseed occur, the period and seed size. Vulnerabilities are a disclosed seed or attacking the entropy sources. Some example of bad implementation: using the system time or a process ID. Paco showed examples of algorithm to shuffle cards. Very interesting!</p>
<div id="attachment_9491" class="wp-caption aligncenter" style="width: 310px"><img class="size-medium wp-image-9491  " title="Paco Hope about Randomness" src="http://blog.rootshell.be/wp-content/uploads/2012/04/IMG_1880-300x225.jpg" alt="Paco Hope about Randomness" width="300" height="225" /><p class="wp-caption-text">Paco Hope about Randomness</p></div>
<p style="text-align: justify;">Let&#8217;s continue with a good talk about HTML5 by Robert McArdle (<a title="Link to the website" href="http://twitter.com/robmcardle">@robmcardle</a>). The next version of the HTML is more and more used and tested by web developers. It will introduce cool features but cool features sometimes say… security issues! The talk was divided in three parts: the good, the bad and the &#8220;???&#8221;</p>
<p style="text-align: justify;">What&#8217;s cool with HTML5?</p>
<ul>
<li style="text-align: justify;">HTML5 Canvas &#8211; 2D &amp; 3D easy to make nice graphics and add more interaction with users. A good example is <a title="Link to the website" href="http://googlecode.blogspot.com/2010/04/html5-quake-ii.html">Quake2 demo</a> in HTML5</li>
<li style="text-align: justify;">Embedding videos in pages is very easy as wall as the interaction with the users (pause, CSS)</li>
<li style="text-align: justify;">Geolocalisation (mainly on mobile devices) is possible in a few lines of codes</li>
<li style="text-align: justify;">Drag &amp; Drop!</li>
<li style="text-align: justify;">Web notifications</li>
</ul>
<p>But what&#8217;s bad?</p>
<ul>
<li style="text-align: justify;">XSS attackes remain valid with new tags (&#8220;&lt;video&gt;&#8221;)</li>
<li style="text-align: justify;">XMLHTTPRequest() extends the local file inclusing problem! Instead of &#8220;<em>http://site.com&amp;page=../../../../etc/passwd</em>&#8220;, we could see &#8220;<em>page=http://www.evilsite.com/c99shell.php</em>&#8220;</li>
<li style="text-align: justify;">Based on JavaScript, obfuscation is easy and not detected by AV&#8217;s)</li>
<li style="text-align: justify;">Web notification coupled with social engineering could be evil! (pop-ups looking like the operating system ones)</li>
</ul>
<p style="text-align: justify;">Finally, the ???: A nice demo of a BitB (&#8220;<em>BotNets in the Browser</em>&#8220;) attack. Based on HTML5 code, it&#8217;s possible to perform DDoS attacks, to send spam, to geolocate the victim, grab information about his system. Awesome (depending on the point of view). Keep an eye on HTML5! For sure, it will become a nice platform to conduct attacks. Have a look at <a title="Link to the website" href="http://html5security.org/">html5security.org</a> for updates on this topic.</p>
<div id="attachment_9503" class="wp-caption aligncenter" style="width: 310px"><img class="size-medium wp-image-9503" title="HTML5 Attacks" src="http://blog.rootshell.be/wp-content/uploads/2012/04/photo11-e1335427467214-300x225.jpg" alt="HTML5 Attacks" width="300" height="225" /><p class="wp-caption-text">HTML5 Attacks</p></div>
<p style="text-align: justify;">After the lunch, another talk about social engineering by Gavin Ewan (<a title="Link to the website" href="http://twitter.com/jac0byterebel">@jac0byterebel</a>). &#8220;<em>A salesman&#8217;s guide to social engineering</em>&#8221; was really complimentary to the first one presented in the morning. The Gavin&#8217;s definition of social engineering is: &#8220;Hacking the human mind, bypassing the human IDS&#8221;. How? There are several channels: Face 2 face, telephone or online . Then Gavin focused on a comparison between a salesman and a social engineer. If you look close to their methods, they are very close to each other! Both recognize that each target (sale/attack) is different, they can play different roles, they use a variety of questioning techniques and recognize that &#8220;no&#8221; does not mean &#8220;no&#8221;. A really nice talk given with a Scottish humor! Great.</p>
<div id="attachment_9495" class="wp-caption aligncenter" style="width: 310px"><img class="size-medium wp-image-9495" title="Gavin Ewan about Social Engineering " src="http://blog.rootshell.be/wp-content/uploads/2012/04/IMG_1886-300x225.jpg" alt="Gavin Ewan about Social Engineering " width="300" height="225" /><p class="wp-caption-text">Gavin Ewan about Social Engineering</p></div>
<p style="text-align: justify;">Then, the security of <a title="Link to the website" href="http://en.wikipedia.org/wiki/SCADA">SCADA</a> environments was reviewed by Amol Sarwate (<a title="Link to the website" href="http://twitter.com/amolsarwate">@amolsarwate</a>). After a review of the components used in a SCADA environment (I/O &#8211; remote &#8211; communication &#8211; master), Amol reviewed the threats that affect each components. Two protocols used in SCADA environment were reviewed: Modbus and DNP 3.0 (over TCP).  (Did you know that Wireshark was able to decode them?). The main issues with those protocols: they don&#8217;t follow the CIA principle (no authentication, no encryption). What are common issues within SCADA environments?</p>
<div>
<ul>
<li style="text-align: justify;">HMI (Human Machine Interfaces) are sometimes connected on corporate network or Internet</li>
<li style="text-align: justify;">Shared or simple passwords are used (what&#8217;s new in this world?)</li>
<li style="text-align: justify;">No patching policy and Windows systems</li>
<li style="text-align: justify;">Not restarted for years (will it boot again?)</li>
<li style="text-align: justify;">System long life cycle (often they are installed for a decade)</li>
<li style="text-align: justify;">Outdated techs</li>
<li style="text-align: justify;">SCADA administrators are not system administrators.</li>
</ul>
<p>Note that no only SCADA systems (in industrial environments) are to blame but also medical systems (ex: imagery systems in hospitals). More precisely, it&#8217;s not the systems themselves (after all they do the job they have been developed for) to blame but more the way they are deployed and managed. To close the presentation, Amol presented the tool developed by Qualys: scandascan.pl (The first release if available <a title="Link to the website" href="http://code.google.com/p/scadascan">here</a>). It scans networks for SCADA devices responding to Modbus or DNP3. If you are looking for online (publicly available) SCADA devices, <a title="Link to the website" href="http://www.shodanhq.com/browse/tag/scada">Shodan</a> can be also a great tool.</p>
<div id="attachment_9505" class="wp-caption aligncenter" style="width: 310px"><img class="size-medium wp-image-9505" title="Security of SCADA Environments" src="http://blog.rootshell.be/wp-content/uploads/2012/04/photo21-e1335427913897-300x225.jpg" alt="Security of SCADA Environments" width="300" height="225" /><p class="wp-caption-text">Security of SCADA Environments</p></div>
</div>
<p style="text-align: justify;">My last choice was the presentation of Abraham Aranguren(<a title="Link to the website" href="http://twitter.com/7a_">@7a_</a>) about his tool called &#8220;owtf&#8221; which stands for &#8220;<em>Offensive Web Testing Framework</em>&#8220;. After a short introduction why and how web app testing is important, Abraham explained his tool with multiple demos. Testing web applications is important. Did you know that 32 out of 66 OWASp tests can be performed legally (depending on the local laws &#8211; take care!). Abraham&#8217;s tool is available <a title="Link to the website" href="https://github.com/7a/owtf">here</a>. Unfortunately, I was not able to attend the end of his presentation as well as the last track due to travel constraints.</p>
<div style="text-align: justify;"></div>
<div style="text-align: justify;">
<p>What else? In parallel to the two tracks, there was a third one left open for last-minute initiatives (with 15 minutes slots). I attended some of them which where interesting. Security researchers are doing a great job. As said Robin during his talk: security conferences and networking is a key point, so I did. This second edition of BSidesLondon was a great opportunity to meet new (and old) friends. Thanks to my new followers in Twitter. I think that London was never so full of infosec people! Kudos to the crew (especially to <a title="Link to the website" href="http://twitter.com/geekchickuk">@geekchickuk</a>!) and see you in 2013! May I already book my ticket?</p>
<div id="attachment_9507" class="wp-caption aligncenter" style="width: 235px"><img class="size-medium wp-image-9507" title="It's Over!" src="http://blog.rootshell.be/wp-content/uploads/2012/04/photo31-e1335428263413-225x300.jpg" alt="It's Over!" width="225" height="300" /><p class="wp-caption-text">It&#39;s Over!</p></div>
<p>&nbsp;</p>
</div>
<img src="http://feeds.feedburner.com/~r/dev/rand/~4/OOLy6k72IIc" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.rootshell.be/2012/04/26/london-a-nest-of-infosec-people/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Some News About HiTB Amsterdam</title>
		<link>http://blog.rootshell.be/2012/04/20/some-news-about-hitb-amsterdam/</link>
		<comments>http://blog.rootshell.be/2012/04/20/some-news-about-hitb-amsterdam/#comments</comments>
		<pubDate>Fri, 20 Apr 2012 16:10:14 +0000</pubDate>
		<dc:creator>Xavier</dc:creator>
				<category><![CDATA[Event]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Hack In The Box]]></category>

		<guid isPermaLink="false">http://blog.rootshell.be/?p=9479</guid>
		<description><![CDATA[Some news about the upcoming edition of the &#8220;Hack in The Box&#8221; security conference. This third edition (already!) will be held at a new venue: The hotel Okura in the center of Amsterdam. Apart of trainings, the conference itself will be organized during two days (May 24th &#8211; 25th) and propose a quad-tracks schedule. You [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;"><img class="alignleft  wp-image-9481" title="HiTB Amsterdam" src="http://blog.rootshell.be/wp-content/uploads/2012/04/index-hitbams.png.jpeg" alt="HiTB Amsterdam" width="204" height="186" />Some news about the upcoming edition of the &#8220;<em>Hack in The Box</em>&#8221; security conference. This third edition (already!) will be held at a new venue: The hotel <a title="Amsterdam Map" href="http://maps.google.com/maps/place?cid=1143581155793872117&amp;q=Okura+Hotel+Amsterdam+-+Amsterdam,+Ferdinand+Bolstraat,+Amsterdam,+The+Netherlands&amp;hl=en&amp;checkin_date=&amp;num_nights=0&amp;ved=0CBoQ-gswAA&amp;sa=X&amp;ei=BYuRT-OyKdCGOpa1xQk&amp;sig2=n4bwLh2bsSj6GmJA2S8t5w">Okura</a> in the center of Amsterdam. Apart of trainings, the conference itself will be organized during two days (May 24th &#8211; 25th) and propose a quad-tracks schedule. You can already have a look <a href="http://conference.hitb.org/hitbsecconf2012ams/draft-agenda.pdf">here</a> (warning, this is still a draft version). Two great keynote speakers were already announced: <a title="Link to the website" href="http://www.csoandy.com/">Andy Ellis</a>, Chief Security Officer of Akamai on day 1. <a title="Link to the website" href="http://www.schneier.com/">Bruce Schneier</a> (do we need to present him again?) on day 2. Based on the current agenda, here is my wishlist:</p>
<ul>
<li style="text-align: justify;">Turning Android inside-out (forensics)</li>
<li style="text-align: justify;">One flew over the cuckoos nest (automatic malware analysis)</li>
<li style="text-align: justify;">Whistling over the wire (Twitter &amp; URL shorteners security)</li>
<li style="text-align: justify;">Security threads in the world of digital satellite television (set-top-boxes security)</li>
<li style="text-align: justify;">PostScript &#8211; danger ahead</li>
<li style="text-align: justify;">Automatically searching for vulnerabilities (taint analysis)</li>
<li style="text-align: justify;">Bypassing the Android permission model (mobile security)</li>
<li style="text-align: justify;">Attacking XML processing</li>
<li style="text-align: justify;">Smashing VMDK files for fun and profit (virtualization)</li>
</ul>
<p style="text-align: justify;">The CFT contest is also back but in a new format called &#8220;<em>Bank0verflow</em>&#8220;.  Based on both attack and defense modules, it will see teams of three provided with a set of custom vulnerable services and web applications. Teams need to exploit their rivals’ machines to retrieve pre configured flags to score offensive points and obtain defensive points by keeping their own vulnerable services running. Another new &#8220;<em>event in the event</em>&#8220;: The Hackaton will be organized for the first time in Amsterdam. The principle is simple: put hackers in a room and let them write some code during 12 hours. The topic of this edition is the implementation of a proof of concept to problems related to browsers and their extensions. First price will be: 1337 EUR in cash!</p>
<p style="text-align: justify;" dir="ltr">A few words about the talks, the proposed topics are not only focusing on classic computers but also other electronic devices that we use daily. Adam Gowdiak will present his researches about  security flaws in digital satellite TV set-top-boxes and DVB chipsets used by many satellite TV providers worldwide. The hackers (aka “<em>iOS Jailbreak Dream Team</em>”) who released the jailbreak of Apple’s popular iPhone 4S and iPad 2 devices will also be there to present their research.</p>
<p style="text-align: justify;" dir="ltr">Finally, <a href="http://conference.hitb.org/hitbsecconf2012ams/pagelist2/hitb-sigint/">SIGINT</a> sessions (15-30 minutes max) will be organized during coffee &amp; lunch breaks to let other people to present their project or researches. During one of those sessions, I&#8217;ll present my tool <a title="Link to the website" href="http://blog.rootshell.be/2012/01/17/monitoring-pastebin-com-within-your-siem/">pastemon</a> and the associated blog <a title="Link to the website" href="http://www.leakedin.com">leakedin.com</a>. This will be my (very small) contribution to this event.</p>
<p style="text-align: justify;" dir="ltr">I&#8217;ll attend the conference and write a wrap-up. Feel free to ping me if you want to meet&#8230;</p>
<p dir="ltr">
<img src="http://feeds.feedburner.com/~r/dev/rand/~4/uLBWx5Knxiw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.rootshell.be/2012/04/20/some-news-about-hitb-amsterdam/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The value of HTTP 404 Errors</title>
		<link>http://blog.rootshell.be/2012/04/16/the-value-of-http-404-errors/</link>
		<comments>http://blog.rootshell.be/2012/04/16/the-value-of-http-404-errors/#comments</comments>
		<pubDate>Mon, 16 Apr 2012 17:32:46 +0000</pubDate>
		<dc:creator>Xavier</dc:creator>
				<category><![CDATA[Logs Management / SIEM]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Websites]]></category>
		<category><![CDATA[Log Management]]></category>

		<guid isPermaLink="false">http://blog.rootshell.be/?p=9459</guid>
		<description><![CDATA[The HTTP protocol has a list of response status codes to help communication between the server and the browser. Everytime a server responds to a browser request, a status code is sent. The most common ones are: &#8220;200&#8221; which means &#8220;Everything is ok, here is some food!&#8221; and &#8220;404&#8221; which means &#8220;Not found&#8220;. The second [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;"><img class="alignleft  wp-image-9467" title="404 Error" src="http://blog.rootshell.be/wp-content/uploads/2012/04/404-not-found-error-300x186.png" alt="404 Error" width="210" height="130" />The HTTP protocol has a list of response status <a title="Link to the website" href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html">codes</a> to help communication between the server and the browser. Everytime a server responds to a browser request, a status code is sent. The most common ones are: &#8220;<em>200</em>&#8221; which means &#8220;<em>Everything is ok</em>, <em>here is some food!</em>&#8221; and &#8220;<em>404</em>&#8221; which means &#8220;<em>Not found</em>&#8220;. The second error may be caused by the client (example: an error in the URL typed in the browser) or by the developer/administrator who forgot to copy files or also made typo errors in his code. That&#8217;s why the amount of 404 errors is directly related to the type of environment. During development and test phases, it&#8217;s common to have more errors. On the other side, in a production environment, the amount of 404 errors should be limited and the main source of errors will be the client/browser.</p>
<p style="text-align: justify;">Sometimes, &#8220;<em>404</em>&#8221; errors are considered useless by webmasters and are simply ignored in their reports. After all, their goal is to know how many visitors browsed to their websites. From a security perspective, those errors could be very helpful to detect unusual traffic targeting a web sites.</p>
<p style="text-align: justify;">I analyzed one year of my blog logs (yes, I&#8217;ve a long retention policy!). Some facts to start:</p>
<ul style="text-align: justify;">
<li>Total hits: 9.534.062</li>
<li>404 errors: 343.606 (3.6%)</li>
</ul>
<p style="text-align: justify;">As you can see on the graph below, the 404 error code comes in the fifth position after the classic 200 and 3xx codes.</p>
<div id="attachment_9461" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.rootshell.be/wp-content/uploads/2012/04/http-responses.png"><img class="size-medium wp-image-9461 " title="HTTP Responses" src="http://blog.rootshell.be/wp-content/uploads/2012/04/http-responses-300x118.png" alt="HTTP Responses" width="300" height="118" /></a><p class="wp-caption-text">(Click to enlarge)</p></div>
<p style="text-align: justify;">As I&#8217;m trying to keep the blog clean, this huge amount of &#8220;<em>not found</em>&#8221; errors looked strange to me. I decided to generate more statistics. What can we deduct? For a while, the big winner is the <a href="http://www.exploit-db.com/exploits/17602/">TimThumb vulnerability</a> discovered in Augustus 2011. The exploit was released the 3rd of Augustus and the first attempt hit me on the 4th! Still today, I received plenty of probes (see this month):</p>
<div id="attachment_9462" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.rootshell.be/wp-content/uploads/2012/04/timthumb-probes.png"><img class="size-medium wp-image-9462" title="Timthumb Requests" src="http://blog.rootshell.be/wp-content/uploads/2012/04/timthumb-probes-300x87.png" alt="Timthumb Requests" width="300" height="87" /></a><p class="wp-caption-text">(Click to enlarge)</p></div>
<p>The TimThumb scans are coming from three main sources as see on the Google map below (the live map is available <a href="http://blog.rootshell.be/stuff/timthumb/">here</a>).</p>
<div id="attachment_9463" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.rootshell.be/wp-content/uploads/2012/04/Screen-Shot-2012-04-16-at-18.09.49.png"><img class="size-medium wp-image-9463" title="Timthumb Google Map" src="http://blog.rootshell.be/wp-content/uploads/2012/04/Screen-Shot-2012-04-16-at-18.09.49-300x154.png" alt="Timthumb Google Map" width="300" height="154" /></a><p class="wp-caption-text">(Click to enlarge)</p></div>
<p style="text-align: justify;"> Another trend this month: more and more .rar archive files are tested. Especially this month. Why? I&#8217;ve absolutely no idea! If you have ideas, feel free to post your comments!</p>
<div id="attachment_9464" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.rootshell.be/wp-content/uploads/2012/04/rar.png"><img class="size-medium wp-image-9464" title=".rar File Requests" src="http://blog.rootshell.be/wp-content/uploads/2012/04/rar-300x128.png" alt=".rar File Requests" width="300" height="128" /></a><p class="wp-caption-text">(Click to enlarge)</p></div>
<p>The top-10 of requested .rar files is:</p>
<ul>
<li>/mirserver.rar</li>
<li>/web.rar</li>
<li>/www.rar</li>
<li>/mirserver1.rar</li>
<li>/wwwroot.rar</li>
<li>/youxi.rar</li>
<li>/mh.rar</li>
<li>/manhua.rar</li>
<li>/mirserver2.rar</li>
<li>/mirserver3.rar</li>
</ul>
<p style="text-align: justify;">Some of them look like performed by scanners which are looking for websites backups. But I did not see the same amount of requests for .tar.gz or .zip files! (Except for &#8220;<em>www.zip</em>&#8220;) I also saw request for files based on numbers: 5555.rar, 8888.rar, 444.rar, etc. Based on Google, those file are massively infected with malwares but why look for them on my server?</p>
<p>Finally, scanners are looking for .asp (Microsoft .Net) pages. Especially for the last two months:</p>
<div id="attachment_9465" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.rootshell.be/wp-content/uploads/2012/04/asp.png"><img class="size-medium wp-image-9465" title=".asp File Requests" src="http://blog.rootshell.be/wp-content/uploads/2012/04/asp-300x141.png" alt=".asp File Requests" width="300" height="141" /></a><p class="wp-caption-text">(Click to enlarge)</p></div>
<p>The top-10 of requested .asp pages is:</p>
<ul>
<li>/save.asp</li>
<li>/plug/save.asp</li>
<li>/gmsave.asp</li>
<li>/diy.asp</li>
<li>/shell.asp</li>
<li>/dama.asp</li>
<li>/upfile_flash.asp</li>
<li>/FCKeditor/editor/filemanager/connectors/asp/connector.asp</li>
<li>/xiaoma.asp</li>
<li>/up_BookPicPro.asp</li>
</ul>
<p style="text-align: justify;">And what about common tools or web interfaces? The top-10 is:</p>
<ul>
<li>/setup.php</li>
<li>/scripts/setup.php</li>
<li>/admin</li>
<li>/login.php</li>
<li>/phpmyadmin/</li>
<li>/myadmin/</li>
<li>/mysql/</li>
<li>/db/</li>
<li>/administrator/</li>
<li>/db/</li>
</ul>
<p style="text-align: justify;">As you can see, there is plenty of useful information in your Apache (or any other webserver) log files! Keep an eye on your 404 errors to discover new trends! A temporary peak of 404 errors could mean that your server is under an attack&#8230;</p>
<img src="http://feeds.feedburner.com/~r/dev/rand/~4/rvM7e5QIDVU" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.rootshell.be/2012/04/16/the-value-of-http-404-errors/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

