<?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>caustik&#039;s blog &#187; Hacking</title>
	<atom:link href="http://blog.caustik.com/tag/hacking/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.caustik.com</link>
	<description>gnireenigne</description>
	<lastBuildDate>Sat, 21 Jan 2012 09:04:10 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>autoblitz + source code</title>
		<link>http://blog.caustik.com/2009/04/12/autoblitz-source-code/</link>
		<comments>http://blog.caustik.com/2009/04/12/autoblitz-source-code/#comments</comments>
		<pubDate>Sun, 12 Apr 2009 22:10:01 +0000</pubDate>
		<dc:creator>caustik</dc:creator>
				<category><![CDATA[Games]]></category>
		<category><![CDATA[Hacking]]></category>
		<category><![CDATA[Programming]]></category>

		<guid isPermaLink="false">http://blog.caustik.com/?p=346</guid>
		<description><![CDATA[Since some folks have expressed interest in trying this bot for themselves, I decided to share the source code and binary It&#8217;s not perfect, but you can tweak the source code (for example, changing how long rp_thread::sleep() is called, and where), and probably get some better performance. If you&#8217;re up for a challenge, you can [...]]]></description>
			<content:encoded><![CDATA[<p>Since some folks have expressed interest in trying this bot for themselves, I decided to share the source code and binary <img src='http://blog.caustik.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>It&#8217;s not perfect, but you can tweak the source code (for example, changing how long rp_thread::sleep() is called, and where), and probably get some better performance. If you&#8217;re up for a challenge, you can also try to improve the code that decides on the next move! (if you do, it&#8217;d be great if you shared the changes!).</p>
<p>Anyway, here is the zip file. [ <a href="http://caustik.com/blog/autoblitz-export.zip">autoblitz-export.zip</a> ]</p>
<p>The binaries are in the export directory. You will be asked for a &#8220;hWnd&#8221; (window handle), which can be found using the program &#8220;Spyxx&#8221; which comes with visual studio.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.caustik.com/2009/04/12/autoblitz-source-code/feed/</wfw:commentRss>
		<slash:comments>161</slash:comments>
		</item>
		<item>
		<title>Game playing AI bot</title>
		<link>http://blog.caustik.com/2009/04/08/game-playing-ai-bot/</link>
		<comments>http://blog.caustik.com/2009/04/08/game-playing-ai-bot/#comments</comments>
		<pubDate>Thu, 09 Apr 2009 00:04:30 +0000</pubDate>
		<dc:creator>caustik</dc:creator>
				<category><![CDATA[Games]]></category>
		<category><![CDATA[Hacking]]></category>

		<guid isPermaLink="false">http://blog.caustik.com/?p=274</guid>
		<description><![CDATA[Every once in a while a silly idea grips you and you decide &#8220;Screw it, I&#8217;m going to do it&#8221;. That happened with me with a game called Bejeweled Blitz on Facebook. My friends online have been competing for high score for the past few weeks. I got to thinking&#8230;&#8221;How hard would it be to [...]]]></description>
			<content:encoded><![CDATA[<p>Every once in a while a silly idea grips you and you decide &#8220;Screw it, I&#8217;m going to do it&#8221;.</p>
<p>That happened with me with a game called Bejeweled Blitz on Facebook. My friends online have been competing for high score for the past few weeks. I got to thinking&#8230;&#8221;How hard would it be to write a program to automate playing this game..?&#8221;.</p>
<p>This is the result of that question. It took a few days at a few hours per day. Probably about 6 hours combined time. Right now the bot is able to play pretty well. It can do better than I can most the time (although my high score currently beats the bot&#8217;s high score). With some improvements, I expect that will dramatically change.</p>
<p>Anyway, here&#8217;s a video of the program in action.</p>
<p>[youtube=http://www.youtube.com/watch?v=WRqGzqnip-w]</p>
<p><strong>Update:</strong></p>
<p>The autoblitz bot just scored 258,400.</p>
<p><img src="http://i42.tinypic.com/1zmi2yp.jpg" alt="http://i42.tinypic.com/1zmi2yp.jpg" /></p>
<p><img src="/DOCUME%7E1/caustik/LOCALS%7E1/Temp/moz-screenshot-10.jpg" alt="" /></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.caustik.com/2009/04/08/game-playing-ai-bot/feed/</wfw:commentRss>
		<slash:comments>20</slash:comments>
		</item>
		<item>
		<title>Smiley Chat</title>
		<link>http://blog.caustik.com/2009/01/14/smiley-chat/</link>
		<comments>http://blog.caustik.com/2009/01/14/smiley-chat/#comments</comments>
		<pubDate>Thu, 15 Jan 2009 05:05:17 +0000</pubDate>
		<dc:creator>caustik</dc:creator>
				<category><![CDATA[Funny]]></category>
		<category><![CDATA[Hacking]]></category>

		<guid isPermaLink="false">http://caustik.wordpress.com/?p=201</guid>
		<description><![CDATA[text made out of smileys. kthx.]]></description>
			<content:encoded><![CDATA[<p><a href="http://dev.caustik.com/blog/wp-content/uploads/2009/01/smileychat3.jpg" target="_blank"><img class="alignnone size-full wp-image-213" style="border:1px solid black;" title="smileychatt1" src="http://dev.caustik.com/blog/wp-content/uploads/2009/01/smileychatt1.jpg" alt="smileychatt1" width="300" height="257" /></a></p>
<p>text made out of smileys. kthx.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.caustik.com/2009/01/14/smiley-chat/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Cxbx Update (Smashing Drive in-game)</title>
		<link>http://blog.caustik.com/2008/12/02/cxbx-update-smashing-drive-in-game/</link>
		<comments>http://blog.caustik.com/2008/12/02/cxbx-update-smashing-drive-in-game/#comments</comments>
		<pubDate>Wed, 03 Dec 2008 03:51:23 +0000</pubDate>
		<dc:creator>caustik</dc:creator>
				<category><![CDATA[Cxbx]]></category>
		<category><![CDATA[Hacking]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[emulation]]></category>
		<category><![CDATA[Games]]></category>
		<category><![CDATA[xbox]]></category>

		<guid isPermaLink="false">http://caustik.wordpress.com/?p=179</guid>
		<description><![CDATA[Updated the official Cxbx site, with an update from shogun: http://caustik.com/cxbx/]]></description>
			<content:encoded><![CDATA[<p>Updated the official Cxbx site, with an update from shogun: <a href="http://caustik.com/cxbx/" target="_blank">http://caustik.com/cxbx/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.caustik.com/2008/12/02/cxbx-update-smashing-drive-in-game/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Amazon EC2 SSH from Blackberry</title>
		<link>http://blog.caustik.com/2008/08/05/amazon-ec2-ssh-from-blackberry/</link>
		<comments>http://blog.caustik.com/2008/08/05/amazon-ec2-ssh-from-blackberry/#comments</comments>
		<pubDate>Tue, 05 Aug 2008 07:04:03 +0000</pubDate>
		<dc:creator>caustik</dc:creator>
				<category><![CDATA[Funny]]></category>
		<category><![CDATA[Hacking]]></category>

		<guid isPermaLink="false">http://caustik.wordpress.com/?p=95</guid>
		<description><![CDATA[Why Not?]]></description>
			<content:encoded><![CDATA[<div class="mceTemp">
<dl class="wp-caption alignnone">
<dt class="wp-caption-dt"><a href="http://dev.caustik.com/blog/wp-content/uploads/2008/08/whynot.jpg"><img class="size-medium wp-image-96" src="http://dev.caustik.com/blog/wp-content/uploads/2008/08/whynot.jpg?w=226" alt="" width="226" height="300" /></a></dt>
</dl>
</div>
<p>Why Not?</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.caustik.com/2008/08/05/amazon-ec2-ssh-from-blackberry/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Cxbx Progress</title>
		<link>http://blog.caustik.com/2007/09/25/cxbx-progress/</link>
		<comments>http://blog.caustik.com/2007/09/25/cxbx-progress/#comments</comments>
		<pubDate>Wed, 26 Sep 2007 00:05:41 +0000</pubDate>
		<dc:creator>caustik</dc:creator>
				<category><![CDATA[Cxbx]]></category>
		<category><![CDATA[Hacking]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[emulation]]></category>
		<category><![CDATA[Games]]></category>
		<category><![CDATA[xbox]]></category>

		<guid isPermaLink="false">http://caustik.wordpress.com/2007/09/25/cxbx-progress/</guid>
		<description><![CDATA[There was some amount of activity in a private branch in the Cxbx project recently.. I have been talking to a developer, Martin, who has spent some of his extra time fiddling with Cxbx. He was able to get some teaser screenshots from Battlestar Galactica. The game displays the menu, and even some in-game. I [...]]]></description>
			<content:encoded><![CDATA[<p>There was some amount of activity in a private branch in the Cxbx project recently..</p>
<p>I have been talking to a developer, Martin, who has spent some of his extra time fiddling with Cxbx. He was able to get some teaser screenshots from Battlestar Galactica. The game displays the menu, and even some in-game. I won&#8217;t get into too many details, but here are a couple screenshots.</p>
<p><a href="http://www.caustik.com/blog/BSG_EUREKA_2.PNG" target="_blank"><img src="http://www.caustik.com/blog/BSG_EUREKA_2-t.png" alt="Battlestar Galactica - menu 2" border="1" height="130" width="160" /></a>   <a href="http://www.caustik.com/blog/BSG_EUREKA_3.PNG" target="_blank"><img src="http://www.caustik.com/blog/BSG_EUREKA_3-t.png" alt="Battlestar Galactica - menu 3" border="1" height="130" width="160" /></a></p>
<p><a href="http://www.caustik.com/blog/BSG_BUG_FULLSCREEN.PNG" target="_blank"><img src="http://www.caustik.com/blog/BSG_BUG_FULLSCREEN-t.png" alt="Battlestar Galactica - in-game (fullscreen)" border="1" height="120" width="160" /></a>   <a href="http://www.caustik.com/blog/BSG_BUG_WINDOWED.PNG" target="_blank"><img src="http://www.caustik.com/blog/BSG_BUG_WINDOWED-t.png" alt="Battlestar Galactica - in-game (windowed)" border="1" height="132" width="160" /></a></p>
<p>I have not started to work on Cxbx on a regular basis &#8212; but I think this progress is very motivating, and it is tempting me to boot back up my development setup and take another look after a very long absence.</p>
<p>Many thanks to Martin for the contributions and for allowing me to post about his progress. Cheers.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.caustik.com/2007/09/25/cxbx-progress/feed/</wfw:commentRss>
		<slash:comments>78</slash:comments>
		</item>
		<item>
		<title>Chumby Antics</title>
		<link>http://blog.caustik.com/2007/09/15/chumby-antics/</link>
		<comments>http://blog.caustik.com/2007/09/15/chumby-antics/#comments</comments>
		<pubDate>Sun, 16 Sep 2007 02:42:09 +0000</pubDate>
		<dc:creator>caustik</dc:creator>
				<category><![CDATA[Funny]]></category>
		<category><![CDATA[Hacking]]></category>
		<category><![CDATA[Chumby]]></category>

		<guid isPermaLink="false">http://caustik.wordpress.com/2007/09/15/chumby-antics/</guid>
		<description><![CDATA[I have been working at Chumby for a few months now. If you have never heard about Chumby &#8211; basically, it is a small squishy wifi-internet connected device with a touchscreen and some other nifty hardware features. So, I am around Chumby devices pretty often, obviously, since it is my full time job. Sometime&#8217;s I [...]]]></description>
			<content:encoded><![CDATA[<p>I have been working at <a href="http://www.chumby.com/" target="_blank">Chumby</a> for a few months now. If you have never heard about Chumby &#8211; basically, it is a small squishy wifi-internet connected device with a touchscreen and some other nifty hardware features. So, I am around Chumby devices pretty often, obviously, since it is my full time job.</p>
<p>Sometime&#8217;s I goof off a little..</p>
<p>This is a video of a small application I made on the Chumby. You touch the screen, and a small blob of &#8220;lava&#8221; follows your finger around. You basically get the sense of smearing the blobs around the touch screen.</p>
<p>[googlevideo=http://video.google.com/videoplay?docid=-3183080343701099686&amp;hl=en]</p>
<p>And this is a funny video of a Chumby with two USB dogs humping it.</p>
<p>[googlevideo=http://video.google.com/videoplay?docid=-2315250673640190670&amp;hl=en]</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.caustik.com/2007/09/15/chumby-antics/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Function Hijacking via Export Directory</title>
		<link>http://blog.caustik.com/2007/08/20/function-hijacking-via-export-directory/</link>
		<comments>http://blog.caustik.com/2007/08/20/function-hijacking-via-export-directory/#comments</comments>
		<pubDate>Tue, 21 Aug 2007 00:52:14 +0000</pubDate>
		<dc:creator>caustik</dc:creator>
				<category><![CDATA[Hacking]]></category>
		<category><![CDATA[assembly]]></category>
		<category><![CDATA[Detours]]></category>

		<guid isPermaLink="false">http://caustik.wordpress.com/2007/08/20/function-hijacking-via-export-directory/</guid>
		<description><![CDATA[I have been working on a contract that has necessitated the use of function hooking. Basically, I need to intercept an arbitrary program&#8217;s usage of a system dll library in order to interject my own logic, and interact with the objects produced by that binary. There is a nice tool created by Microsoft Research, called [...]]]></description>
			<content:encoded><![CDATA[<p>I have been working on a contract that has necessitated the use of function hooking. Basically, I need to intercept an arbitrary program&#8217;s usage of a system dll library in order to interject my own logic, and interact with the objects produced by that binary.</p>
<p>There is a nice tool created by <a href="http://research.microsoft.com/" target="_blank">Microsoft Research</a>, called <a href="http://research.microsoft.com/sn/detours/" target="_blank">Detours</a>. This is basically an API which helps you to perform binary function interception and instrumentation. This API is fairly robust and well thought out, and I use it in this project. However, there is certainly a fair amount of missing functionality.</p>
<p>While testing my application against a popular product that uses the &#8220;<a href="http://msdn.microsoft.com/msdnmag/issues/01/10/MSLU/" target="_blank">unicows</a>&#8221; library, I stumbled across a very interesting situation during which the Detours method of function interception will not apply.</p>
<p>Basically, unicows has it&#8217;s own custom version of <a href="http://msdn2.microsoft.com/en-us/library/ms683212.aspx" target="_blank">GetProcAddress</a> build in. This custom code crawls through the in memory PE header and obtains function offsets by hand. This means that, for dynamically loaded function addresses, using the Detours functionality I am unable to intercept functions loaded at run-time.</p>
<p>So,  in order to properly intercept these functions, it was necessary to create an additional API from within Detours. This function needs to crawl through the PE header, and replace the Export Directory entry for a given API with the virtual address of the function you wish to be called, instead. The function will also return the original virtual address, so that you can call that function within your intercepted version.</p>
<p>The new code is here: <a href="http://www.caustik.com/blog/DetourReplaceExport.txt" target="_blank">DetourReplaceExport.txt</a></p>
<p>So, now I have a working solution for hijacking an API which is linked dynamically using a non-standard GetProcAddress. Yays!</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.caustik.com/2007/08/20/function-hijacking-via-export-directory/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Ignignokt / Megaman Laser Etches</title>
		<link>http://blog.caustik.com/2007/02/03/ignignokt-laser-etch/</link>
		<comments>http://blog.caustik.com/2007/02/03/ignignokt-laser-etch/#comments</comments>
		<pubDate>Sun, 04 Feb 2007 05:48:13 +0000</pubDate>
		<dc:creator>caustik</dc:creator>
				<category><![CDATA[Funny]]></category>
		<category><![CDATA[Hacking]]></category>

		<guid isPermaLink="false">http://caustik.wordpress.com/2007/02/03/ignignokt-laser-etch/</guid>
		<description><![CDATA[Hehe. Last night we used bunnie&#8216;s laser etcher to put Ignignokt on a Treo cell phone. Classy. Also, I got megaman on mine. Here is a video of the etching of Ignignokt in progress: [youtube=http://www.youtube.com/v/Q1u3H6NpbHQ]]]></description>
			<content:encoded><![CDATA[<p>Hehe. Last night we used <a href="http://www.bunniestudios.com/wordpress/" target="_blank">bunnie</a>&#8216;s laser etcher to put <a href="http://www.youtube.com/watch?v=Q1u3H6NpbHQ" target="_blank">Ignignokt</a> on a Treo cell phone. Classy. Also, I got <a href="http://www.caustik.com/blog/megaman-pearl.jpg" target="_blank">megaman</a> on mine.</p>
<p align="left"><a href="http://www.caustik.com/blog/treo.jpg" target="_blank"><img src="http://www.caustik.com/blog/treo-t.jpg" border="1" height="213" width="160" /></a>             <a href="http://www.caustik.com/blog/megaman-pearl.jpg" target="_blank"><img src="http://www.caustik.com/blog/megaman-pearl-t.jpg" border="1" height="213" width="160" /></a></p>
<p>Here is a video of the etching of Ignignokt in progress:</p>
<p>[youtube=http://www.youtube.com/v/Q1u3H6NpbHQ]</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.caustik.com/2007/02/03/ignignokt-laser-etch/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>DOS &quot;debug&quot; fun</title>
		<link>http://blog.caustik.com/2006/08/20/dos-debug-fun/</link>
		<comments>http://blog.caustik.com/2006/08/20/dos-debug-fun/#comments</comments>
		<pubDate>Sun, 20 Aug 2006 22:00:06 +0000</pubDate>
		<dc:creator>caustik</dc:creator>
				<category><![CDATA[Hacking]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[assembly]]></category>

		<guid isPermaLink="false">https://caustik.wordpress.com/2006/08/20/dos-debug-fun/</guid>
		<description><![CDATA[Sometimes you get the urge to do some programming, but you don&#8217;t have access to a compiler. Luckily, virtually every Windows PC in the world has a utility called &#8220;debug&#8221; installed. This little program lets you input 16-bit x86 assembly language, and allows you to write it out to create a .com file. This file [...]]]></description>
			<content:encoded><![CDATA[<p>Sometimes you get the urge to do some programming, but you don&#8217;t have access to a compiler. Luckily, virtually every Windows PC in the world has a utility called &#8220;debug&#8221; installed. This little program lets you input 16-bit x86 assembly language, and allows you to write it out to create a .com file. This file can then be executed inside of a DOS shell.</p>
<p>The following is an example of something simple but cool you can do with this program. I will be using some basic DOS interrupts in order to do console input and output. (Lookup &#8216;DOS interrupt 21h&#8217; on google to find out more).</p>
<p>I&#8217;ll highlight everything i&#8217;m typing in green so you can try this at home. You won&#8217;t need to type the optional comments (anything after the semicolon is ignored), and they get lost when you write the file anyway.</p>
<pre><code><font face="lucida console, courier new">C:&gt;<font color="#00aa00">debug kthx.com</font>

-<font color="#00aa00">a 100</font>
1476:0100 <font color="#00aa00">mov cl, d7 ; default cl to character 'd7'</font>
1476:0102 <font color="#00aa00">mov ah, 6  ; ah:6 is console input/output</font>
1476:0104 <font color="#00aa00">mov dl, ff ; dl:ff specifies input</font>
1476:0106 <font color="#00aa00">int 21     ; interrupt 21 call</font>
1476:0108 <font color="#00aa00">jz 10c     ; skip next instruction if failure</font>
1476:010A <font color="#00aa00">mov cl, al ; save result of console input</font>
1476:010C <font color="#00aa00">mov dl, cl ; load current character as output</font>
1476:010E <font color="#00aa00">int 21     ; interrupt 21 call</font>
1476:0110 <font color="#00aa00">jmp 102    ; loop forever!</font>
1476:0112
-<font color="#00aa00">r cx</font>
CX 0012
:<font color="#00aa00">12</font>
-<font color="#00aa00">w</font>
Writing 00012 bytes
-<font color="#00aa00">q</font>
C:&gt;
</font></code></pre>
<p>Now, when you execute &#8220;kthx.com&#8221;, you will see the screen swamped with the funky &#8216;d7&#8242; ASCII character.</p>
<p><a href="http://www.caustik.com/blog/kthx-01.jpg" target="_blank"><img src="http://www.caustik.com/blog/kthx-01-s.jpg" height="243" width="430" /></a></p>
<p>Whenever you type a character, the screen with update to display that character. Try alternating between visible characters and not visible characters (like space). For more fun, try to as quickly as possible type &#8220;\|/-\|/-&#8221; (animates like a little progress bar).</p>
<p>Note that you cant really exit the program. Pressing ctrl+c will actually just display a little heart character. It would be easy to modify the code to accept a character (like escape or control+c) to exit, but i&#8217;ll leave that up to you :].</p>
<p><a href="http://www.caustik.com/blog/kthx-02.jpg" target="_blank"><img src="http://www.caustik.com/blog/kthx-02-s.jpg" height="243" width="430" /></a></p>
<p>This is just one basic thing you can make a .com file do. For a cooler example, check out <a href="http://www.caustik.com/neetro/" target="_blank" title="neetro">neetro</a>. Neetro is a little bit more complex than the program above, so it would have been a pain to write using &#8220;debug&#8221;. The source is instead compiled using <a href="http://sourceforge.net/projects/nasm" target="_blank" title="nasm">nasm</a>.</p>
<p><code></code></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.caustik.com/2006/08/20/dos-debug-fun/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

