<?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:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>david mccuskey.com</title>
	
	<link>http://www.davidmccuskey.com</link>
	<description>my slice of the Internet</description>
	<pubDate>Wed, 23 Sep 2009 03:19:10 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.2</generator>
	<language>en</language>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/davidmccuskey" /><feedburner:info uri="davidmccuskey" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
		<title>Generating Random Session IDs</title>
		<link>http://feedproxy.google.com/~r/davidmccuskey/~3/XbxAg9vKg48/</link>
		<comments>http://www.davidmccuskey.com/2009/09/generating-random-session-ids/#comments</comments>
		<pubDate>Sun, 13 Sep 2009 21:03:36 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[Code Sample]]></category>

		<category><![CDATA[Geek]]></category>

		<category><![CDATA[Programming]]></category>

		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://www.mccuskey.com/?p=578</guid>
		<description><![CDATA[For any online service you must login so you can gain access to your stuff.  So that you only have to put in your password once, the website must maintain a special unique character sequence called a session key to know that you have already authenticated.

There is a problem with these keys, however, if [...]]]></description>
			<content:encoded><![CDATA[<p>For any online service you must login so you can gain access to your stuff.  So that you only have to put in your password once, the website must maintain a special unique character sequence called a <em>session key</em> to know that you have already authenticated.</p>

<p>There is a problem with these keys, however, if they are not truly random. This is detailed in a paper I stumbled upon entitled &#8220;Brute-Force Exploitation of Web Application Session IDs&#8221; by David Endler. It covers ways in which these keys can be &#8220;hacked&#8221; because they are not unique, but rather follow some sequence which can be guessed. He lists some major websites which he was able to get access to information that should have been private.</p>

<p>The paper got me thinking about how to generate random session keys, so I created some quick Python scripts using Twisted which demonstrates my solution. (This was my first time using Twisted, so it&#8217;s very possible that there is a better way to structure the code).</p>

<h4>Solution</h4>

<p>The character buffer in the server is used to generate new keys.</p>

<p>To fill the buffer:</p>

<p>0. Create a list of websites which themselves deliver random web pages (eg, wikipedia)<br />
1. Select a website from random and ask for a random page<br />
2. Grab the data within the <span class="caps">HTML </span><em>body</em> tags and put that string in the character buffer<br />
3. When the buffer needs more data, go back to 1.</p>

<p>To generate X number of keys:</p>

<p>0. Grab two random lengths of the character buffer. Use one to re-seed the random generator and the other as the basis for the new session key. Create the session key using <span class="caps">MD5 </span>and the key seed<br />
1. Update() the current <span class="caps">MD5 </span>session key using a generated random character / string<br />
2. Add that key to the buffer.<br />
3. When the key buffer needs more keys, go back to Step 1. For every Y number of keys generated, go back to Step 0.</p>


<h4>Notes</h4>

<p>We don&#8217;t use a a new seed for each <span class="caps">MD5 </span>session key because the buffer will be emptied too quickly. Of course, the settings for the buffer size, etc could be tweaked.</p>

<h4>Performance</h4>

<p>Running the server code on my Mac Mini (2.16GHz Dual Core) and 5 clients on another machine, I was able to service ~8000 keys/sec (~750 million keys/day).</p>

<h4>Conclusion</h4>

<p>My experiment satisfied my curiosity and answered the questions from my own project.</p>

<p>There are, of course, many tweaks that can be made. Send me the code changes to your favorites and I&#8217;ll include them.</p>

<p><a href="/download/HTTP-Session-Key.zip">Click to download the client server files.</a></p>

<h3>Resources</h3>


<ul>
<li><a href="http://www.cgisecurity.com/lib/SessionIDs.pdf">Brute-Force Exploitation fo Web Application Session IDs</a> (PDF)</li>
</ul>

<img src="http://feeds.feedburner.com/~r/davidmccuskey/~4/XbxAg9vKg48" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.davidmccuskey.com/2009/09/generating-random-session-ids/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.davidmccuskey.com/2009/09/generating-random-session-ids/</feedburner:origLink></item>
		<item>
		<title>KryptoPhoto Photo Viewer is Released</title>
		<link>http://feedproxy.google.com/~r/davidmccuskey/~3/dtpYRlyPcQQ/</link>
		<comments>http://www.davidmccuskey.com/2009/08/kryptophoto-photo-viewer-is-released/#comments</comments>
		<pubDate>Tue, 11 Aug 2009 19:38:44 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[Flex]]></category>

		<category><![CDATA[Photography]]></category>

		<category><![CDATA[KryptoPhoto release]]></category>

		<guid isPermaLink="false">http://www.mccuskey.com/?p=572</guid>
		<description><![CDATA[I have released my new photo viewer, so now I can once again show my photography on this site. It currently supports the API at SmugMug.com, but I have plans for compatibility with other photo-sharing sites.

I built it using the Adobe Flex framework. You can get more information about KryptoPhoto at MentalHijack.com.]]></description>
			<content:encoded><![CDATA[<p>I have released my new photo viewer, so now I can once again show <a href="/photography/">my photography</a> on this site. It currently supports the <span class="caps">API </span>at SmugMug.com, but I have plans for compatibility with other photo-sharing sites.</p>

<p>I built it using the Adobe Flex framework. You can <a href="http://www.mentalhijack.com/software/kryptophoto/">get more information about KryptoPhoto at MentalHijack.com.</a></p><img src="http://feeds.feedburner.com/~r/davidmccuskey/~4/dtpYRlyPcQQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.davidmccuskey.com/2009/08/kryptophoto-photo-viewer-is-released/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.davidmccuskey.com/2009/08/kryptophoto-photo-viewer-is-released/</feedburner:origLink></item>
		<item>
		<title>My New Camera: Canon PowerShot SD890 IS</title>
		<link>http://feedproxy.google.com/~r/davidmccuskey/~3/KZH6yLDV8N8/</link>
		<comments>http://www.davidmccuskey.com/2009/07/my-new-camera-canon-powershot-sd890-is/#comments</comments>
		<pubDate>Thu, 02 Jul 2009 20:43:30 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[Photography]]></category>

		<guid isPermaLink="false">http://www.davidmccuskey.com/?p=474</guid>
		<description><![CDATA[I just received my new Canon PowerShot SD890 IS! I purchased it for my up-and-coming Colorado trip to partake in a honest-to-gosh cattle drive (a la City Slickers).

I&#8217;ve always wanted a Point-and-Shoot in addition to my Canon Rebel XT DSLR because it&#8217;s not as convenient to carry around an SLR just to take random photos. [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.davidmccuskey.com/wp-content/uploads/canon-890is-hand.jpg" alt="The Canon PowerShot 890 IS in my hand" border="0" width="320" height="213" align="right" />I just received my new Canon PowerShot <span class="caps">SD890</span> IS! I purchased it for my up-and-coming Colorado trip to partake in a honest-to-gosh cattle drive (a la <a href="http://www.imdb.com/title/tt0101587/">City Slickers</a>).</p>

<p>I&#8217;ve always wanted a Point-and-Shoot in addition to my Canon Rebel XT <span class="caps">DSLR </span>because it&#8217;s not as convenient to carry around an <span class="caps">SLR </span>just to take random photos. However, I don&#8217;t buy things without justification, but I was able to convince myself that this trip was (finally) my reason to get one.</p>

<p>From the horse-riding lessons I have taken in preparation for the trip, I learned that horses can be devious like three year olds and some will try to annoy you when you&#8217;re not paying full attention. I imagined that this could be problematic while handling both the horse and a <span class="caps">DSLR </span>since I give the camera a lot of concentration when taking photos, basically opening myself up for horse trickery. My dream ends with me on the ground more times than I would enjoy with an expensive piece of equipment in my hands.<br />
A little Point-and-Shoot is cheaper and easier to replace, can be stowed anywhere and would be much more comfortable to fall on. </p>

<p>I like Canon because they make great equipment at a very reasonable price and they have been at the top of their game for awhile. I chose the PowerShot <span class="caps">SD890</span> IS from the entire PowerShot family because of two features: the image stabilization as well as the more powerful 5x optical zoom. The image stabilization will be handy to minimize blurred photos because horses don&#8217;t usually stand still. The bigger zoom will help make up any distance between me and the subject since maneuvering a 1,000 pound horse is an inexact science.</p>

<p>I think the camera is going to be fine for the trip. The only drawback I see is that the ergonomics of the camera are too good for what I need! This model is sloped on the right side to follow the curve of a hand and offers no edge which could be used like a camera grip. This would be immensely helpful for one-handed shooting while holding reins in the other. It&#8217;s not as much of an issue for normal use because people generally take photos holding the camera with both hands.</p>

<p>I know that I&#8217;ll have more to say about the PowerShot <span class="caps">SD890</span> IS when I return from my trip.</p><img src="http://feeds.feedburner.com/~r/davidmccuskey/~4/KZH6yLDV8N8" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.davidmccuskey.com/2009/07/my-new-camera-canon-powershot-sd890-is/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.davidmccuskey.com/2009/07/my-new-camera-canon-powershot-sd890-is/</feedburner:origLink></item>
		<item>
		<title>When I own a MacBook Air, this leather bag will be its home</title>
		<link>http://feedproxy.google.com/~r/davidmccuskey/~3/y84iBVEYN84/</link>
		<comments>http://www.davidmccuskey.com/2009/03/when-i-own-a-macbook-air-this-leather-bag-will-be-its-home/#comments</comments>
		<pubDate>Wed, 18 Mar 2009 05:51:57 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[Misc]]></category>

		<category><![CDATA[laptop bags]]></category>

		<category><![CDATA[MacBook Air]]></category>

		<guid isPermaLink="false">http://www.davidmccuskey.com/?p=402</guid>
		<description><![CDATA[Having the sexiest laptop in your possession, it&#8217;s only fitting that one get a equally uber-cool bag. And in general, there should be a law against putting a $2000 work of art in a $20 black laptop bag. After looking through hundreds of bags from around the world, I&#8217;ve settled on what I believe to [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.davidmccuskey.com/wp-content/uploads/2802-aristamahogany.jpg" alt="2802_aristamahogany.jpg" border="0" width="50%" height="50%" align="right" />Having the sexiest laptop in your possession, it&#8217;s only fitting that one get a equally uber-cool bag. <em>And in general, there should be a law against putting a $2000 work of art in a $20 black laptop bag.</em> After looking through hundreds of bags from around the world, I&#8217;ve settled on what I believe to be the best mix of form, function, and beauty - <a href="http://www.orbino.com/store/product_info.php?products_id=257">the Orbino Arista featuring handstained mahogany leather</a> <em>(pictured at right)</em>.</p>

<p>In the resources below I have included links to many of the sites I looked through in the quest to find my ultimate MacBook Air laptop bag. They should give you a good starting point for finding the bag that you love most. </p>

<p><em>It should go without saying, but I will anyway - as with anything fashionable, women have a much larger selection of cool, stylish and funky MacBook Air cases than men.</em></p>

<p><em>Here are some typical, safe, laptop bag alternatives if fashion isn&#8217;t a concern:</em> <a href="http://www.buy.com/prod/case-logic-15-4-slimline-laptop-case-nylon-black-case-logic-15-4/q/loc/16234/202778691.html">uggghh</a>, <a href="http://www.bestbuy.com/site/olspage.jsp?type=product&amp;id=1218011398693">&#8216;khaki pants and sneakers&#8217;</a>, <a href="http://www.officedepot.com/ddSKU.do?level=SK&amp;id=564380">death by extreme black-neoprene boredom</a>.</p>

<h3>Resources</h3>

<p><em>[updated 2009.03.19]</em> - added Kenakai.com to the list</p>

<h4><a href="http://www.orbino.com/">Orbino.com</a> - look no further than Orbino for stunning leather cases for iPods, laptops, handbags, etc.</h4>


<ul>
<li><a href="http://www.orbino.com/store/index.php?cPath=30_128">Arista landing page</a></li>
</ul>



<h4><a href="http://www.kolobags.com/home.php?cat=36">kolobags.com</a> has an incredible selection of men&#8217;s laptop bags.</h4>


<ul>
<li><a href="http://www.kolobags.com/product.php?productid=918">knomo by kolobag</a> is my second favorite. It&#8217;s a very stylish choice, though not sized especially for the Air.</li>
</ul>




<ul>
<li><a href="http://www.kaboodle.com/reviews/knomo-bungo-oil-tan">knomo picture - tan</a></li>
</ul>



<h4><a href="http://www.sfbags.com/">Waterfield Bags</a> has a large selection of different styles, all look very high quality.</h4>


<ul>
<li><a href="http://www.sfbags.com/products/hardcase/hardcase.htm">Waterfield HardCase</a></li>
</ul>




<ul>
<li><a href="http://blogs.zdnet.com/Apple/?p=1381">Waterfield HardCase review</a></li>
</ul>




<ul>
<li><a href="http://www.sfbags.com/products/vertigo/vertigo.htm">Waterfield Vertigo</a></li>
</ul>




<ul>
<li><a href="http://blogs.zdnet.com/Apple/?p=1280">Waterfield SleeveCase review</a></li>
</ul>




<h4><a href="http://www.tombihn.com/page/001/CTGY/MACBOOKAIR">Tom Bihn</a> has a small selection of bags for the Air, most are technically complex.</h4>


<ul>
<li><a href="http://www.tombihn.com/page/001/PROD/MACBOOKAIR/TB0223">Ristretto Messenger is a fav</a></li>
</ul>



<h4><a href="http://www.builtny.com/showPage.php?pageID=1518">Built NY</a> has some fun cases fashioned from neoprene, if you&#8217;re into that sort of thing.</h4>

<h4><a href="http://mac-case.com/MacCase13.html">MacCase.com</a> carries a whole bunch of stylish cases for the Air.</h4>

<h4><a href="http://www.mobileedge.com/">Mobile Edge</a> offers a huge selection of well made bags, Unfortunately the ones for men are more on the safe side of fashion, though the women&#8217;s cases are cute.</h4>


<ul>
<li><a href="http://www.mobileedge.com/mens-laptop-bags">Mobile Edge men&#8217;s laptop bags</a></li>
</ul>




<ul>
<li><a href="http://www.amazon.com/Mobile-Edge-Paris-Backpack-Microfiber/dp/B000B54H6C/">Mobile Edge Paris bag</a> - very European</li>
</ul>



<h4><a href="http://www.laptopstuff.co.uk/">LaptopStuff</a> has a nice selection of funky and hip bags and cases.</h4>

<h4><a href="http://www.case-mate.com/laptop/MacBook-Air-Cases">Case-Mate.com</a> offers mainly sleeves for the Air.</h4>

<h4><a href="http://www.brenthaven.com/">Brenthaven</a> has some interesting styles, including several which are airport-scanner friendly.</h4>

<h4><a href="http://www.timbuk2.com/tb2/products/laptop/">Timbuk2</a> offers a solid line of tough, durable bags and cases though mostly of the messenger-style. If you really want something special, try their <strong>Build Your Own Bag</strong> wizard.</h4>

<h4><a href="http://www.ogio.com/products.php?category=30"><span class="caps">IGIO.</span>com</a> leans towards the boring side, but their Brain Bucket Mini (in color Wasabe) is ok.</h4>


<ul>
<li><a href="http://www.amazon.com/Ogio-OGIO-Brain-Bucket-Mini/dp/B000FHE9K0">Brain Bucket mini in multicolors</a></li>
</ul>




<h4>Only sleeves</h4>


<ul>
<li><a href="http://www.kenakai.com/">Kenakai.com</a> has some fabulously rich sleeves for MacBooks, unfortunately not MacBook Air specific.</li>
</ul>




<ul>
<li><a href="http://wrappers.typepad.com/">Wrappers</a> has fun sleeves for different things.</li>
</ul>




<h4>Aggregators, blogs, etc.</h4>


<ul>
<li><a href="http://www.bizrate.com/computer-bags/">BizRate.com</a> is a store aggregator. They list products from elsewhere.</li>
</ul>




<ul>
<li><a href="http://www.squidoo.com/computerbags">squidoo.com computerbags</a> is small page with important goodies (for women).</li>
</ul>




<ul>
<li><a href="http://tech.yahoo.com/blogs/hughes/22543">Six Cool Sleeves for the MacBook Air</a></li>
</ul>

<img src="http://feeds.feedburner.com/~r/davidmccuskey/~4/y84iBVEYN84" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.davidmccuskey.com/2009/03/when-i-own-a-macbook-air-this-leather-bag-will-be-its-home/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.davidmccuskey.com/2009/03/when-i-own-a-macbook-air-this-leather-bag-will-be-its-home/</feedburner:origLink></item>
		<item>
		<title>Finally, my move to WordPress!</title>
		<link>http://feedproxy.google.com/~r/davidmccuskey/~3/4rCIGSllF3I/</link>
		<comments>http://www.davidmccuskey.com/2009/03/finally-my-move-to-wordpress/#comments</comments>
		<pubDate>Tue, 03 Mar 2009 18:37:40 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[Misc]]></category>

		<guid isPermaLink="false">http://www.davidmccuskey.com/?p=167</guid>
		<description><![CDATA[I have finally changed over to WordPress ! I have been taking my time because I am still on the hunt for a way to display my photos and I haven&#8217;t found exactly what I&#8217;m looking for. Despite that, I decided to change over anyway. For now that means no photos.]]></description>
			<content:encoded><![CDATA[<p>I have finally changed over to WordPress ! I have been taking my time because I am still on the hunt for a way to display my photos and I haven&#8217;t found exactly what I&#8217;m looking for. Despite that, I decided to change over anyway. For now that means no photos.</p><img src="http://feeds.feedburner.com/~r/davidmccuskey/~4/4rCIGSllF3I" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.davidmccuskey.com/2009/03/finally-my-move-to-wordpress/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.davidmccuskey.com/2009/03/finally-my-move-to-wordpress/</feedburner:origLink></item>
		<item>
		<title>How to do custom chart annotations in Flex</title>
		<link>http://feedproxy.google.com/~r/davidmccuskey/~3/q4xnUs9nqyQ/</link>
		<comments>http://www.davidmccuskey.com/2009/03/how-to-do-custom-chart-annotations-in-flex/#comments</comments>
		<pubDate>Tue, 03 Mar 2009 18:16:14 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[Code Sample]]></category>

		<category><![CDATA[Flex]]></category>

		<category><![CDATA[How-To]]></category>

		<category><![CDATA[Programming]]></category>

		<category><![CDATA[annotationElements]]></category>

		<category><![CDATA[backgroundElements]]></category>

		<guid isPermaLink="false">http://www.davidmccuskey.com/?p=150</guid>
		<description><![CDATA[Hunting around the &#8216;Net, I found a few good examples of creating chart annotations in Flex.

One example app which helped me greatly was from a blog posting by Ely Greenfield. If you&#8217;re interested, you can view it on his website: chart annotation demo.

Unfortunately, the code you can download from his site is a little old [...]]]></description>
			<content:encoded><![CDATA[<p>Hunting around the &#8216;Net, I found a few good examples of creating chart annotations in Flex.</p>

<p>One example app which helped me greatly was from a <a href="http://www.quietlyscheming.com/blog/2006/04/03/custom-chart-annotations/">blog posting by Ely Greenfield</a>. If you&#8217;re interested, you can view it on his website: <a href="http://demo.quietlyscheming.com/overlayDemo/index.html">chart annotation demo</a>.</p>

<p>Unfortunately, the code you can download from his site is a little old so it has problems compiling in Flex Builder 2+. I have updated the code, fixed some bugs in it and have it available here: <a href="http://www.davidmccuskey.com/wp-content/uploads/overlaydemo-fixed.zip" title="OverlayDemo-fixed.zip">download OverlayDemo-fixed.zip</a>.</p>

<p>Ely has other interesting demos on his site which are worth checking out. Some of my favorites are: the <a href="http://www.quietlyscheming.com/blog/charts/variable-radius-pie-chart/">variable radius pie chart demo</a>, the <a href="http://www.quietlyscheming.com/blog/charts/variable-radius-pie-chart/">interactive bubble chart demo</a>, and the <a href="http://www.quietlyscheming.com/blog/charts/dashed-lines/">dashed lines demo</a>.</p>

<h3>Resources</h3>

<p><em>annotation example by Ely Greenfield</em></p>


<ul>
<li><a href="http://www.quietlyscheming.com/blog/2006/04/03/custom-chart-annotations/">http://www.quietlyscheming.com/blog/2006/04/03/custom-chart-annotations/</a></li>
<li>demo: <a href="http://demo.quietlyscheming.com/overlayDemo/index.html">http://demo.quietlyscheming.com/overlayDemo/index.html</a></li>
</ul>



<p><em>annotation example by Brendan Meutzner</em></p>


<ul>
<li><a href="http://www.stretchmedia.ca/blog/index.cfm/2007/3/28/Chart-Milestones-using-annotationElements">http://www.stretchmedia.ca/blog/index.cfm/2007/3/28/Chart-Milestones-using-annotationElements</a></li>
<li>demo: <a href="http://www.stretchmedia.ca/code_examples/chart_milestone/main.html">http://www.stretchmedia.ca/code_examples/chart_milestone/main.html</a></li>
</ul>

<img src="http://feeds.feedburner.com/~r/davidmccuskey/~4/q4xnUs9nqyQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.davidmccuskey.com/2009/03/how-to-do-custom-chart-annotations-in-flex/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.davidmccuskey.com/2009/03/how-to-do-custom-chart-annotations-in-flex/</feedburner:origLink></item>
		<item>
		<title>How to build and install the Metakit DB for Python on MacOSX</title>
		<link>http://feedproxy.google.com/~r/davidmccuskey/~3/IRrnPs9rXMY/</link>
		<comments>http://www.davidmccuskey.com/2009/02/how-to-build-and-install-the-metakit-db-for-python-on-macosx/#comments</comments>
		<pubDate>Wed, 11 Feb 2009 02:39:38 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[Code Sample]]></category>

		<category><![CDATA[Geek]]></category>

		<category><![CDATA[How-To]]></category>

		<category><![CDATA[Technology]]></category>

		<category><![CDATA[macosx]]></category>

		<category><![CDATA[metakit]]></category>

		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://www.davidmccuskey.com/?p=237</guid>
		<description><![CDATA[Ever since I used it years ago on a geek-project for my Zaurus, the Metakit DB has always been a favorite of mine. I had the chance to use it again on another personal project and this time on MacOSX. Unfortunately, the prebuilt binaries on the Metakit site are for older versions of MacOSX, so [...]]]></description>
			<content:encoded><![CDATA[<p>Ever since I used it years ago on a geek-project for my Zaurus, the Metakit DB has always been a favorite of mine. I had the chance to use it again on another personal project and this time on MacOSX. Unfortunately, the prebuilt binaries on the Metakit site are for older versions of MacOSX, so I had to build it myself.</p>

<p>Normally one would simply follow the <a href="http://www.equi4.com/pub/mk/">Metakit installation instructions</a>, but they are old and didn&#8217;t work correctly with 10.5 Leopard. I scraped enough information together from the Internet to get it working, but I had to do a lot of research. To save others the same hassle, I have put together all of the changes and put them here in their entirety:</p>

<p><strong>Building Metakit</strong></p>

<p>Make sure you have Xcode installed on your system before starting.</p>

<p>Get the latest source from the <a href="http://www.equi4.com/pub/mk/">Metakit downloads page</a>. At this time the latest version is <code>metakit-2.4.9.7.tar.gz</code>.</p>

<p>Uncompress the archive in a work directory and run the following commands:</p>


<div class="wp_syntax"><div class="code"><pre class="shell" style="font-family:monospace;">&gt; cd builds
&gt; ../unix/configure --with-python=/System/Library/Frameworks/Python.framework/Versions/2.5</pre></div></div>




<p>Note: Your Python install might be in a different location. If so, give the  <code>--with-python</code> arg the proper value.</p>

<p><em>&#8220;Fat&#8221; binary setup</em></p>

<p>If you need this to run on the <span class="caps">PPC </span>architecture you will need to make a couple of modifications to <code>./builds/Makefile</code> <em>after</em> running <code>configure</code>, otherwise you can skip this step and build the binaries with <code>make</code>.</p>

<p>Find <code>CXXFLAGS = $(CXX_FLAGS)</code> and change to the following:</p>


<div class="wp_syntax"><div class="code"><pre class="make" style="font-family:monospace;">CXXFLAGS <span style="color: #004400;">=</span> <span style="color: #004400;">$</span><span style="color: #004400;">&#40;</span><span style="color: #000088;">CXX_FLAGS</span><span style="color: #004400;">&#41;</span> <span style="color: #004400;">-</span>arch ppc <span style="color: #004400;">-</span>arch i386 <span style="color: #004400;">-</span>isysroot <span style="color: #004400;">/</span>Developer<span style="color: #004400;">/</span>SDKs<span style="color: #004400;">/</span>MacOSX10<span style="color: #004400;">.</span>5<span style="color: #004400;">.</span>sdk</pre></div></div>




<p>Find <code>SHLIB_LD = g++ -dynamiclib -flat_namespace -undefined suppress</code> and change to the following:</p>


<div class="wp_syntax"><div class="code"><pre class="make" style="font-family:monospace;">SHLIB_LD <span style="color: #004400;">=</span> g<span style="color: #004400;">++</span> <span style="color: #004400;">-</span>dynamiclib <span style="color: #004400;">-</span>flat_namespace <span style="color: #004400;">-</span>undefined suppress <span style="color: #004400;">-</span>arch ppc <span style="color: #004400;">-</span>arch i386</pre></div></div>




<p><em>Build the binaries</em></p>

<p>Run your typical <code>Makefile</code> commands:</p>


<div class="wp_syntax"><div class="code"><pre class="shell" style="font-family:monospace;">&gt; make
&gt; make test</pre></div></div>




<p><strong>Installing Metakit</strong></p>

<p>Rename the shared library which is now in the <code>./builds</code> directory:</p>


<div class="wp_syntax"><div class="code"><pre class="shell" style="font-family:monospace;">&gt; mv Mk4py.dylib Mk4py.so</pre></div></div>




<p>And copy the following files to <code>/System/Library/Frameworks/Python.framework/Versions/2.5/Extras/lib/python</code> (be sure to adjust the path name for your version of Python):</p>


<div class="wp_syntax"><div class="code"><pre class="shell" style="font-family:monospace;">../python/metakit.py
./Mk4py.so</pre></div></div>




<p><strong>Testing Metakit</strong></p>

<p>At this point you should have a working system and ought to be able to run the following command in a Python shell without issue:</p>


<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;"><span style="color: #66cc66;">&gt;&gt;&gt;</span>from metakit <span style="color: #ff7700;font-weight:bold;">import</span> <span style="color: #66cc66;">*</span></pre></div></div>




<p>Enjoy !</p>

<h3>Resources</h3>


<ul>
<li><a href="http://www.equi4.com/metakit/python.html">Metakit for Python website</a></li>
</ul>




<ul>
<li><a href="http://www.ospace.net/wiki/index.php/ServerHowTo">helpful instructions from www.ospace.net</a></li>
</ul>

<img src="http://feeds.feedburner.com/~r/davidmccuskey/~4/IRrnPs9rXMY" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.davidmccuskey.com/2009/02/how-to-build-and-install-the-metakit-db-for-python-on-macosx/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.davidmccuskey.com/2009/02/how-to-build-and-install-the-metakit-db-for-python-on-macosx/</feedburner:origLink></item>
		<item>
		<title>Trying to do MVC in pure Flex</title>
		<link>http://feedproxy.google.com/~r/davidmccuskey/~3/Ldonal4CCcY/</link>
		<comments>http://www.davidmccuskey.com/2009/02/trying-to-do-mvc-in-pure-flex/#comments</comments>
		<pubDate>Mon, 02 Feb 2009 06:37:32 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[Flex]]></category>

		<category><![CDATA[Programming]]></category>

		<category><![CDATA[flex]]></category>

		<category><![CDATA[mvc]]></category>

		<guid isPermaLink="false">http://blog.davidmccuskey.com/?p=108</guid>
		<description><![CDATA[I was looking for some examples of how to structure a Flex application using MVC, but using only the Flex framework. In the long run I think I&#8217;ll be using PureMVC, but right now I am anxious to get my app working and don&#8217;t want to have to learn Yet Another Technology just to get [...]]]></description>
			<content:encoded><![CDATA[<p>I was looking for some examples of how to structure a Flex application using <span class="caps">MVC, </span>but using only the Flex framework. In the long run I think I&#8217;ll be using PureMVC, but right now I am anxious to get my app working and don&#8217;t want to have to learn <em>Yet Another Technology</em> just to get there. Besides, shouldn&#8217;t Flex be able to stand on its own?</p>

<p>I found what I was looking for in the article <a href="http://www.adobe.com/devnet/flex/articles/blueprint.html"><em>&#8220;An architectural blueprint for Flex applications&#8221;</em></a> written by Joe Berkovitz. In it he talks about a way in which he architects Flex applications using pure Flex/Actionscript constructs.</p>

<p>Being a Flex newbie, I learned a lot from his article like how to pass variables to your own <span class="caps">MXML </span>tags and even customize them using Actionscript. His architecture also solves an issue I was having with Event messaging/bubbling due to the fact that it only works automatically on DisplayObject components. His design also has an interesting way of handling multiple data-services as well as the operations required for handling service communication.</p>

<p>Source code for the project is available in the article. I would recommended downloading it and browsing through the files.</p>

<p><strong>Resources:</strong></p>


<ul>
<li>&#8220;<em>An architectural blueprint for Flex applications</em>&#8221; written by Joe Berkovitz, <a href="http://www.adobe.com/devnet/flex/articles/blueprint.html">http://www.adobe.com/devnet/flex/articles/blueprint.html</a></li>
</ul>

<img src="http://feeds.feedburner.com/~r/davidmccuskey/~4/Ldonal4CCcY" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.davidmccuskey.com/2009/02/trying-to-do-mvc-in-pure-flex/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.davidmccuskey.com/2009/02/trying-to-do-mvc-in-pure-flex/</feedburner:origLink></item>
		<item>
		<title>Moving to Wordpress</title>
		<link>http://feedproxy.google.com/~r/davidmccuskey/~3/lB5PC6klAoY/</link>
		<comments>http://www.davidmccuskey.com/2008/12/moving-to-wordpress/#comments</comments>
		<pubDate>Mon, 01 Dec 2008 21:35:05 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[Misc]]></category>

		<guid isPermaLink="false">http://www.davidmccuskey.com/files/1fe40dbcede5e82b482b85e76440cdd0-29.html#unique-entry-id-29</guid>
		<description><![CDATA[It&#8217;s time for another blog / website changeup.   This time I&#8217;m moving from RapidWeaver to Wordpress.   I think it&#8217;s going to be much better for me and my needs. 

Please update your RSS feed links: http://blog.davidmccuskey.com/feed/ 

I will make the switch permanent in the next couple of days. 

Thanks !]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s time for another blog / website changeup.   This time I&#8217;m moving from RapidWeaver to Wordpress.   I think it&#8217;s going to be much better for me and my needs. </p>

<p>Please update your <span class="caps">RSS </span>feed links: http://blog.davidmccuskey.com/feed/ </p>

<p>I will make the switch permanent in the next couple of days. </p>

<p>Thanks !</p><img src="http://feeds.feedburner.com/~r/davidmccuskey/~4/lB5PC6klAoY" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.davidmccuskey.com/2008/12/moving-to-wordpress/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.davidmccuskey.com/2008/12/moving-to-wordpress/</feedburner:origLink></item>
		<item>
		<title>My First Document Scanner</title>
		<link>http://feedproxy.google.com/~r/davidmccuskey/~3/m-oi35i3W18/</link>
		<comments>http://www.davidmccuskey.com/2008/11/my-first-document-scanner/#comments</comments>
		<pubDate>Thu, 27 Nov 2008 22:54:50 +0000</pubDate>
		<dc:creator>david</dc:creator>
		
		<category><![CDATA[Productivity]]></category>

		<category><![CDATA[Reviews]]></category>

		<category><![CDATA[Technology]]></category>

		<category><![CDATA[document scanner]]></category>

		<guid isPermaLink="false">http://blog.davidmccuskey.com/?p=96</guid>
		<description><![CDATA[Today I ordered a NeatScan document / receipt scanner made by NeatCo!

I&#8217;m pretty excited because I&#8217;ve always wanted one ever since the days of the Visioneer Paperport. The idea of a paperless office really appealed to me mostly due to my infatuation to keep around receipts and documents that I receive, be it electronically or [...]]]></description>
			<content:encoded><![CDATA[<p>Today I ordered a NeatScan document / receipt scanner made by NeatCo!</p>

<p>I&#8217;m pretty excited because I&#8217;ve <em>always</em> wanted one ever since the days of the Visioneer Paperport. The idea of a paperless office really appealed to me mostly due to my infatuation to keep around receipts and documents that I receive, be it electronically or on paper. Unfortunately, I&#8217;ve never figured out a method to process &amp; save any of the paperwork on an ongoing basis - it usually falls apart when I start to get too busy with life.</p>

<p>I had done a little research several months ago to see if there were any changes in the document-scanner market since the last time I checked. From that I made my <em>rough</em> list for my ultimate document-scanning setup:</p>


<ul>
<li>Small, desktop scanner</li>
<li>Ability to create <em>searchable</em> <span class="caps">PDF</span>s</li>
<li>Software to help me organize everything</li>
</ul>



<p>I started looking again because I came across two Black-Friday deals related to document scanners: <em>NeatScan to Office</em> by <span class="caps">NEAT </span>and the <em>SnapScan <span class="caps">S300M</span></em> by Fujitsu. (The deal from <span class="caps">NEAT </span>was for the PC version of the scanner, but I read on their website that they were offering the Mac software for free as long as you provided the serial number of the scanner.)</p>

<p>I found that Fujitsu&#8217;s SnapScan always had great reviews so it probably wouldn&#8217;t be a bad choice no matter what. One of the cool features it has is the ability to feed and scan multiple documents while scanning <em>both sides</em> at the same time! Very nice.</p>

<p><span class="caps">NEAT </span>released a Mac version of their software last January at MacWorld. From what I could tell from the <span class="caps">NEAT </span>website and forums, they are committed to creating a great Macintosh experience and their goal is to match the functionality of their Windows software. One of the cool features of the <span class="caps">NEAT </span>software enables you to print directly to the software (eg, print an email receipt from Amazon to the software, which will then process it with <span class="caps">OCR</span>/PDF). This could definitely be handy for me since I get a lot of electronic receipts from the things I order online.</p>

<p>Here are some of the reasons I decided on the <span class="caps">NEAT </span>scanner:</p>


<ul>
<li>It was a little cheaper than the SnapScan<br />
I wasn&#8217;t sure if I was going to appreciate a document scanner</li>
<li>The <em>included</em> software did <span class="caps">OCR </span>(important for making searchable <span class="caps">PDF</span>s)<br />
(Though during this quarter [2008Q4], Fujisu is offering a rebate to get a free copy of Readiris Pro <span class="caps">OCR </span>sofware.)</li>
<li>The included software will organize receipts and documents<br />
(I was considering purchasing Yep as my tool for organizing <span class="caps">PDF</span>s; I always have the choice if I find the <span class="caps">NEAT </span>software lacking.)</li>
</ul>



<h3>Resources</h3>


<ul>
<li><a href="http://forums.macnn.com/57/consumer-hardware-and-components/367014/neatreceipts-or-fujitsu/">MacNN Forum: NeatReceipts or Fujitsu?</a></li>
</ul>




<ul>
<li><a href="http://www.tuaw.com/2008/06/06/tuaw-review-neat-receipts-for-mac-advance-release/"><span class="caps">TUAW</span> Review: <span class="caps">NEAT</span> Receipts for Mac</a></li>
</ul>




<ul>
<li><a href="http://macmost.com/macmost-now-89-neatreceipts-review.html">MacMost Video: NeatReceipts Review</a></li>
</ul>




<ul>
<li><a href="http://www.macworld.com/article/133962/2008/06/scansnaps300m.html">Macworld Review: Fujitsu SnapScan <span class="caps">S300M</span></a></li>
</ul>




<ul>
<li><a href="http://www.fujitsu.com/us/services/computing/peripherals/scanners/scansnap/s300m.html">Fujitsu.com: SnapScan <span class="caps">S300M</span></a></li>
</ul>




<ul>
<li><a href="http://www.irislink.com/c2-532-189/OCR-Software---Product-list.aspx">Readiris Pro Website</a></li>
</ul>




<ul>
<li><a href="http://reviews.pricegrabber.com/data-fax/m/19848156/">Pricegrabber Review: Readiris Pro 11</a></li>
</ul>

<img src="http://feeds.feedburner.com/~r/davidmccuskey/~4/m-oi35i3W18" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.davidmccuskey.com/2008/11/my-first-document-scanner/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.davidmccuskey.com/2008/11/my-first-document-scanner/</feedburner:origLink></item>
	</channel>
</rss>
