<?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>jsha/README &#187; Uncategorized</title>
	<atom:link href="http://jacob.hoffman-andrews.com/README/index.php/category/uncategorized/feed/" rel="self" type="application/rss+xml" />
	<link>http://jacob.hoffman-andrews.com/README</link>
	<description>a blog by Jacob Hoffman-Andrews</description>
	<lastBuildDate>Fri, 26 Mar 2010 20:47:41 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Rendered my first OSM image!</title>
		<link>http://jacob.hoffman-andrews.com/README/index.php/2010/03/26/rendered-my-first-osm-image/</link>
		<comments>http://jacob.hoffman-andrews.com/README/index.php/2010/03/26/rendered-my-first-osm-image/#comments</comments>
		<pubDate>Fri, 26 Mar 2010 20:47:41 +0000</pubDate>
		<dc:creator>jsha</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://jacob.hoffman-andrews.com/README/?p=73</guid>
		<description><![CDATA[I&#8217;ve been playing around with OpenStreetMaps recently.  I downloaded a subset of the world data set covering San Francisco by using this tool: http://78.46.81.38/.  I loaded the data into a local PostGIS database with osm2pgsql.  Then I spent a couple hours installing the prerequisites for Mapnik and building Mapnik itself, which was the hardest [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been playing around with OpenStreetMaps recently.  I downloaded a subset of the world data set covering San Francisco by using this tool: <a href="http://78.46.81.38/">http://78.46.81.38/</a>.  I loaded the data into a local PostGIS database with <a href="http://wiki.openstreetmap.org/wiki/Osm2pgsql">osm2pgsql</a>.  Then I spent a couple hours installing the prerequisites for <a href="http://wiki.openstreetmap.org/wiki/Mapnik">Mapnik</a> and building Mapnik itself, which was the hardest part but still very doable.  Once Mapnik was installed, I was able to use the generate_image.py script to generate a quick map of SF.  Next step is to learn how to build tiles for slippy maps, and then how to customize them.</p>
<p><a href="http://jacob.hoffman-andrews.com/osm/first-sf-render.png"><img class="alignnone" src="http://jacob.hoffman-andrews.com/osm/first-sf-render-thumb.png" alt="" width="400" height="400" /></a></p>
<p>The process was mostly easy and rewarding.  One funny quirk: osm2pgsql can&#8217;t do password authentication to the database, so it&#8217;s most convenient to use a passwordless account.  Mapnik, on the other hand, appears to choke if it is given an empty password string, so you need to add a password to the account once you get to the Mapnik stage.</p>
]]></content:encoded>
			<wfw:commentRss>http://jacob.hoffman-andrews.com/README/index.php/2010/03/26/rendered-my-first-osm-image/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>HOWTO Encrypt an existing home directory on Ubuntu Karmic Koala</title>
		<link>http://jacob.hoffman-andrews.com/README/index.php/2009/12/08/howto-encrypt-an-existing-home-directory-on-ubuntu-karmic-koala/</link>
		<comments>http://jacob.hoffman-andrews.com/README/index.php/2009/12/08/howto-encrypt-an-existing-home-directory-on-ubuntu-karmic-koala/#comments</comments>
		<pubDate>Wed, 09 Dec 2009 06:44:55 +0000</pubDate>
		<dc:creator>jsha</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://jacob.hoffman-andrews.com/README/?p=51</guid>
		<description><![CDATA[
.instructions {
margin: 1em;
background-color: #f4f4f4;
}

Karmic Koala, the latest release of Ubuntu, made it really easy for new installs to use encryption for  home directories.  However, for users who upgraded from previous releases (Jaunty Jackalope, Intrepid Ibex, etc), the process to encrypt an existing home directory is not so obvious.  Here&#8217;s one way to do it.
You&#8217;ll [...]]]></description>
			<content:encoded><![CDATA[<style>
.instructions {
margin: 1em;
background-color: #f4f4f4;
}
</style>
<p><a href="https://wiki.ubuntu.com/KarmicKoala">Karmic Koala</a>, the latest release of Ubuntu, made it really easy for new installs to use encryption for  home directories.  However, for users who upgraded from previous releases (Jaunty Jackalope, Intrepid Ibex, etc), the process to encrypt an existing home directory is not so obvious.  Here&#8217;s one way to do it.</p>
<p>You&#8217;ll need enough free space for two copies of your entire home directory.  If you don&#8217;t have that, first move your existing home directory onto external media, and modify these instructions as appropriate.</p>
<p>First, log out of your normal account, which we&#8217;ll term <strong>myrealusername</strong>.  Login as root.  Create a new, temporary user, using the &#8211;encrypt-home flag to adduser.  Use the same password as your current user account.</p>
<div class=instructions># adduser &#8211;encrypt-home tmpuser<br />
************************************************************************<br />
YOU SHOULD RECORD YOUR MOUNT PASSPHRASE AND STORE IT IN A SAFE LOCATION.<br />
ecryptfs-unwrap-passphrase ~/.ecryptfs/wrapped-passphrase<br />
THIS WILL BE REQUIRED IF YOU NEED TO RECOVER YOUR DATA AT A LATER TIME.<br />
************************************************************************</p>
<p>Done configuring.</p>
<p>Enter new UNIX password: <strong>USE YOUR EXISTING PASSWORD</strong><br />
Retype new UNIX password:<br />
No password supplied<br />
Enter new UNIX password:<br />
Retype new UNIX password:<br />
passwd: password updated successfully<br />
Changing the user information for tmpuser<br />
Enter the new value, or press ENTER for the default<br />
Full Name []:<br />
Room Number []:<br />
Work Phone []:<br />
Home Phone []:<br />
Other []:<br />
Is the information correct? [Y/n]
</div>
<p>When you ran &#8216;adduser&#8217;, it created two important directories: /home/.ecryptfs/tmpuser/.Private and /home/.ecryptfs/tmpuser/.ecryptfs.  These are both symlinked into a skeleton home directory at /home/tmpuser.  I say skeleton here, because the directory so created is only ever visible when &#8216;tmpuser&#8217; is logged out.  Once &#8216;tmpuser&#8217; is logged in, the contents of /home/.ecryptfs/tmpuser/.Private are decrypted and mounted <em>on top of</em> /home/tmpuser.  We want the same thing to happen for <strong>myrealusername</strong>.  Before we put the skeleton directory in place, however, we want to move your existing, unencrypted home aside.  That way when you log in with an encrypted home it isn&#8217;t hidden and we&#8217;re able to copy files into your new, encrypted home.</p>
<div class=instructions># mv /home/<strong>myrealusername</strong> /home/<strong>myrealusername</strong>.orig
</div>
<p>Now you want to copy these skeleton files to /home/.ecryptfs/<strong>myrealusername</strong> and change the ownership:</p>
<div class=instructions># REALUSER=<strong>myrealusername</strong><br />
# cd /home<br />
# mkdir -m 0700 $REALUSER<br />
# cp -r .ecryptfs/tmpuser .ecryptfs/$REALUSER<br />
# chown -R $REALUSER.$REALUSER .ecryptfs/$REALUSER $REALUSER<br />
# ln -s /home/.ecryptfs/$REALUSER/.* $REALUSER/
</div>
<p>You also need to edit a mount description file which still refers to &#8216;tmpuser&#8217;:</p>
<div class=instructions># sed -i s/tmpuser/$REALUSER/ .ecryptfs/$REALUSER/.ecryptfs/Private.mnt
</div>
<p>Just for good measure we&#8217;ll copy the two informational symlinks from the skeleton directory.  These are handy because if they show up when you&#8217;re logged in, you know something went wrong and you&#8217;re not accessing your encrypted home dir.</p>
<div class=instructions># cp tmpuser/* $REALUSER/<br />
# chown $REALUSER.$REALUSER $REALUSER/*
</div>
<p>At this point, you&#8217;re ready to log in as <strong>myrealusername</strong>.  Go ahead.  I&#8217;ll wait.</p>
<p>Got it?  You should have a mostly empty home directory.  If you have a file named Access-Your-Private-Data.desktop, something went wrong.</p>
<p>If all&#8217;s well, copy your original home directory into the new, encrypted home directory.  It&#8217;s best to do this as root, on the off chance you have some files in your home dir which you don&#8217;t own, but want to preserve exactly.  You may be tempted to do this as an &#8216;mv&#8217; if you&#8217;re low on disk space.  That should work just the same, but it won&#8217;t actually unlink the original until *everything* is copied, meaning you still need enough space for two copies of your home dir.  In a pinch you could move one subdirectory at a time, which means you don&#8217;t need as much spare space.</p>
<p>Note the trailing slashes on the rsync &#8211; those are important.</p>
<div class=instructions><strong>myrealusername</strong>$ su<br />
# rsync -av /home/<strong>myrealusername</strong>.orig/ /home/<strong>myrealusername</strong>/
</div>
<p>Bingo!  Your home directory is now encrypted.  Once you&#8217;re satisfied that everything is there, don&#8217;t forget to remove your original, unencrypted home.  To be tidy you may want to delete the &#8216;tmpuser&#8217; account too.</p>
<div class=instructions># rm -rf /home/<strong>myrealusername</strong>.orig<br />
# userdel -r tmpuser
</div>
]]></content:encoded>
			<wfw:commentRss>http://jacob.hoffman-andrews.com/README/index.php/2009/12/08/howto-encrypt-an-existing-home-directory-on-ubuntu-karmic-koala/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>JavaScript compiler roundup</title>
		<link>http://jacob.hoffman-andrews.com/README/index.php/2008/09/22/javascript-compiler-roundup/</link>
		<comments>http://jacob.hoffman-andrews.com/README/index.php/2008/09/22/javascript-compiler-roundup/#comments</comments>
		<pubDate>Mon, 22 Sep 2008 17:22:00 +0000</pubDate>
		<dc:creator>jsha</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://jacob.hoffman-andrews.com/README/?p=14</guid>
		<description><![CDATA[I&#8217;m looking to start compiling JavaScript for a personal project, so I did a quick roundup of freely available JS compilers / obfuscators / minifiers.
Dojo Shrinksafe &#8211; http://dojotoolkit.org/docs/shrinksafe
YUI Compressor &#8211; http://www.julienlecomte.net/yuicompressor/
JavaScript Obfuscator by Stunnix &#8211; http://www.stunnix.com/prod/jo/
JSMin &#8211; http://www.crockford.com/javascript/jsmin.html
Packer- http://dean.edwards.name/packer/
So far I&#8217;ve tried Shrinksafe and YUI Compressor.  I couldn&#8217;t get Shrinksafe to produce any output, even [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m looking to start compiling JavaScript for a personal project, so I did a quick roundup of freely available JS compilers / obfuscators / minifiers.</p>
<p>Dojo Shrinksafe &#8211; http://dojotoolkit.org/docs/shrinksafe</p>
<p>YUI Compressor &#8211; http://www.julienlecomte.net/yuicompressor/</p>
<p>JavaScript Obfuscator by Stunnix &#8211; http://www.stunnix.com/prod/jo/</p>
<p>JSMin &#8211; http://www.crockford.com/javascript/jsmin.html</p>
<p>Packer- http://dean.edwards.name/packer/</p>
<p>So far I&#8217;ve tried Shrinksafe and YUI Compressor.  I couldn&#8217;t get Shrinksafe to produce any output, even though it seemed to be parsing my JS since it threw errors when I had something wrong.</p>
<p>YUI compressor ran on my input JS and produced output, but it had a couple of problems.  Backslash-escaped strings get unescaped from the output.  For instance,</p>
<pre>alert("two \n lines");

Becomes:

alert("two
 lines");

Also, it seemed to have trouble with "else if (...) {" constructs, turning them into "else{if(...){".</pre>
]]></content:encoded>
			<wfw:commentRss>http://jacob.hoffman-andrews.com/README/index.php/2008/09/22/javascript-compiler-roundup/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
