<?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>Christoffer Kjølbæk &#187; Security</title>
	<atom:link href="http://ostehamster.dk/blog/index.php/tag/security/feed/" rel="self" type="application/rss+xml" />
	<link>http://ostehamster.dk/blog</link>
	<description>I have a blog, therefore I am…</description>
	<lastBuildDate>Sun, 18 Jul 2010 12:16:40 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9-rare</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Krypter med DanIDs &#8220;Digital Signatur&#8221; i Evolution</title>
		<link>http://ostehamster.dk/blog/index.php/2010/01/31/krypter-med-danids-digital-signatur-i-evolution/</link>
		<comments>http://ostehamster.dk/blog/index.php/2010/01/31/krypter-med-danids-digital-signatur-i-evolution/#comments</comments>
		<pubDate>Sun, 31 Jan 2010 20:17:49 +0000</pubDate>
		<dc:creator>Christoffer Kjølbæk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[DanID]]></category>
		<category><![CDATA[Digital Signatur]]></category>
		<category><![CDATA[Howto]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Security]]></category>

		<guid isPermaLink="false">http://ostehamster.dk/blog/?p=664</guid>
		<description><![CDATA[Er du bruger af Evolution og har behov for at sende en krypteret mail med DanIDs "Digital Signatur", skal du først have fat i kontaktpersonens certifikat. Dette finder du på DanIDs Certificeringscenter, såfremt personen har valgt at være listet her. Når du har fundet det rette certifikat klikke du på , hvorefter du kan gemme [...]]]></description>
			<content:encoded><![CDATA[<p>Er du bruger af Evolution og har behov for at sende en krypteret mail med DanIDs "Digital Signatur", skal du først have fat i kontaktpersonens certifikat. Dette finder du på <a href="https://www.certifikat.dk/export/sites/dk.certifikat.oc/da/soegning/">DanIDs Certificeringscenter</a>, såfremt personen har valgt at være listet her. Når du har fundet det rette certifikat klikke du på <img src="http://ostehamster.dk/blog/wp-content/uploads/2010/01/download.gif" alt="download" title="download" width="16" height="16" class="alignnone size-full wp-image-665" />, hvorefter du kan gemme en .cer fil.</p>
<p>I Evolution vælger du Rediger -> Indstillinger (eller Shift-Ctrl-S) -> Certifikater -> Kontaktpersoners certifikater -> Importer hvorefter du får mulighed for at importere den hentede .cer fil.</p>
<p>Du skal naturligvis have din egen private signaturfil i Evolution.</p>
]]></content:encoded>
			<wfw:commentRss>http://ostehamster.dk/blog/index.php/2010/01/31/krypter-med-danids-digital-signatur-i-evolution/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Re-install / upgrade to Ubuntu 9.10 and keep encrypted data from previous version</title>
		<link>http://ostehamster.dk/blog/index.php/2009/11/01/re-install-upgrade-to-ubuntu-9-10-and-keep-encrypted-data-from-previous-version/</link>
		<comments>http://ostehamster.dk/blog/index.php/2009/11/01/re-install-upgrade-to-ubuntu-9-10-and-keep-encrypted-data-from-previous-version/#comments</comments>
		<pubDate>Sun, 01 Nov 2009 12:19:06 +0000</pubDate>
		<dc:creator>Christoffer Kjølbæk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Howto]]></category>
		<category><![CDATA[Karmic Koala]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Paranoia]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Ubuntu 9.10]]></category>

		<guid isPermaLink="false">http://ostehamster.dk/blog/?p=223</guid>
		<description><![CDATA[When Ubuntu first started with encrypted hard drive support, I made a LVM system inside the encrypted system. I do not like to upgrade Ubuntu from one version to another, and I do not want to copy all my data for each installation. My LVM system therefore have root, swap and home, so that home [...]]]></description>
			<content:encoded><![CDATA[<p>When Ubuntu first started with encrypted hard drive support, I made a LVM system inside the encrypted system. I do not like to upgrade Ubuntu from one version to another, and I do not want to copy all my data for each installation. My LVM system therefore have root, swap and home, so that home can survive the re-installation.</p>
<p>Unfortunately, the installer (the alternative one) do not recognise the encrypted hard drive, and is therefore not able to use it. This little guide helps you to reuse your LVM layout - and your data!</p>
<p><strong>NB: Use this guide at your own risk!</strong><br />
<span id="more-223"></span></p>
<p>Follow the installation until "Set up network", then press ctrl-alt F2 to start a console and run<br />
<code><br />
modprobe dm-crypt<br />
cryptsetup luksOpen /dev/sda5 sda5_crypt<br />
</code></p>
<p>Replace /dev/sda5 with your encrypted partition. You will now be prompted for your passphrase for the encrypted partition, after which you run<br />
<code><br />
vgscan<br />
vgchange -ay<br />
</code><br />
in order to activate the lvm volumes.</p>
<p>Press ctrl-alt f1 to get back to the installer. When asked for partition method select Manual, and your encrypted LVM volumes are now on the list. You still need to set mount points etc., and remember NOT to mark them for formatting. Continue the installation.</p>
<p>Boot into rescue with your LVM root volume as /</p>
<p>Find the unique id for this "disk" from:<br />
<code>ls -l /dev/disk/by-uuid</code></p>
<p>Insert a line like</p>
<blockquote><p>sda5_crypt /dev/disk/by-uuid/df05112c-65bf-44a2-b6d1-a740c3444b53 none luks</p></blockquote>
<p>into /etc/crypttab. Remember to use the uuid found above together with what ever name you have given the device. sda5_crypt will give a device called /dev/mapper/sda5_crypt</p>
<p>To avoid manually typing the uuid, it is possible just to do:<br />
<code>ls -l /dev/disk/by-uuid >> /etc/crypttab<br />
nano - /etc/crypttab</code></p>
<p>This will copy the entire content of "ls -l /dev/disk/by-uuid" into the bottom of /etc/crypttab, and open the file for editing with nano.</p>
<p>Run <code>update-initramfs -u</code>, reboot and you are ready to go!</p>
]]></content:encoded>
			<wfw:commentRss>http://ostehamster.dk/blog/index.php/2009/11/01/re-install-upgrade-to-ubuntu-9-10-and-keep-encrypted-data-from-previous-version/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>OpenWrt &#8211; tips &amp; tricks</title>
		<link>http://ostehamster.dk/blog/index.php/2007/04/17/openwrt-tips-tricks/</link>
		<comments>http://ostehamster.dk/blog/index.php/2007/04/17/openwrt-tips-tricks/#comments</comments>
		<pubDate>Tue, 17 Apr 2007 20:19:31 +0000</pubDate>
		<dc:creator>Christoffer Kjølbæk</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[OpenWrt]]></category>

		<guid isPermaLink="false">http://ostehamster.dk/wordpress/?p=24</guid>
		<description><![CDATA[Change SSH port from 22 to e.g. 2222
Change the last line of the file /etc/init.d/S50dropbear to:
/usr/sbin/dropbear -p 2222
]]></description>
			<content:encoded><![CDATA[<p><strong>Change SSH port from 22 to e.g. 2222</strong><br />
Change the last line of the file /etc/init.d/S50dropbear to:</p>
<blockquote><p>/usr/sbin/dropbear -p 2222</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://ostehamster.dk/blog/index.php/2007/04/17/openwrt-tips-tricks/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Encrypted home partition, using LUKS in Ubuntu Feisty Fawn</title>
		<link>http://ostehamster.dk/blog/index.php/2007/04/13/encrypted-home-partition-using-luks-in-ubunt-feisty-fawn/</link>
		<comments>http://ostehamster.dk/blog/index.php/2007/04/13/encrypted-home-partition-using-luks-in-ubunt-feisty-fawn/#comments</comments>
		<pubDate>Thu, 12 Apr 2007 23:24:41 +0000</pubDate>
		<dc:creator>Christoffer Kjølbæk</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[Feisty Fawn]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Paranoia]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://ostehamster.dk/wordpress/?p=22</guid>
		<description><![CDATA[This guide will very briefly describe how to setup an encrypted LUKS partition and mount it on log in.
Preparation
Start by installing the software needed:
sudo apt-get install libpam-mount cryptsetup
Add these line to /etc/initramfs-tools/modules
dm_mod
dm_crypt
sha256
aes_i586
and update the initrd-image with
sudo update-initramfs -u all
Making the encrypted partition
Remember to take BACKUP, because all data at /dev/sda6 will be lost!!!
Now we have [...]]]></description>
			<content:encoded><![CDATA[<p>This guide will very briefly describe how to setup an encrypted LUKS partition and mount it on log in.</p>
<p><strong>Preparation</strong><br />
Start by installing the software needed:</p>
<blockquote><p>sudo apt-get install libpam-mount cryptsetup</p></blockquote>
<p>Add these line to /etc/initramfs-tools/modules</p>
<blockquote><p>dm_mod<br />
dm_crypt<br />
sha256<br />
aes_i586</p></blockquote>
<p>and update the initrd-image with</p>
<blockquote><p>sudo update-initramfs -u all</p></blockquote>
<p><strong>Making the encrypted partition</strong><br />
<em>Remember to take BACKUP, because all data at /dev/sda6 will be lost!!!</em></p>
<p>Now we have to make the encrypted partition, in this example the devices name is /dev/sda6. First we load the needed modules</p>
<blockquote><p>sudo modprobe dm_crypt<br />
sudo modprobe sha256<br />
sudo modprobe aes_i586</p></blockquote>
<p>and the make the LUKS-partiton (use your log-in password):</p>
<blockquote><p>sudo cryptsetup luksFormat /dev/sda6</p></blockquote>
<p>Now /dev/sda6 has the LUKS format, and can be attached to /dev/mapper:</p>
<blockquote><p>sudo cryptsetup luksOpen /dev/sda6 encrypted_home</p></blockquote>
<p>And then we can make a file system on it, here ext3</p>
<blockquote><p>sudo mkfs.ext3 -j -O dir_index -m 0 -v /dev/mapper/encrypted_home</p></blockquote>
<p>Finally we can mount the partition, to see if it works</p>
<blockquote><p>sudo mount /dev/mapper/encrypted_home /mnt</p></blockquote>
<p>Unmount and close the LUKS partition:</p>
<blockquote><p>sudo umount /mnt<br />
sudo cryptsetup luksClose encrypted_home</p></blockquote>
<p><strong>Setting up pam_mount</strong><br />
Insert</p>
<blockquote><p>auth optional /lib/security/pam_mount.so use_first_pass</p></blockquote>
<p>into /etc/pam.d/common-auth</p>
<p>and</p>
<blockquote><p>session     optional      /lib/security/pam_mount.so</p></blockquote>
<p>into /etc/pam.d/common-session</p>
<p>Now create a mount point for the LUKS partition</p>
<blockquote><p>sudo mkdir /encrypted_home<br />
sudo chmod 777 /encrypted_home</p></blockquote>
<p>And add</p>
<blockquote><p>volume foo crypt - /dev/sda6 /encrypted_home cipher=aes - -</p></blockquote>
<p>into /etc/security/pam_mount.conf </p>
<p>This means that every time the user <em>foo</em> logs in, the LUKS partition will be mounted on /encrypted_home, using the password foo entered. Therefor the LUKS password has to be the same as the log in password.</p>
<p>Log out, log in and see if it works :)</p>
<p><em>This is inspirited by:<br />
<a href="http://thomasdamgaard.dk/blog/article/krypteret-swap-og-root-filsystem-med-luks-og-ubuntu">http://thomasdamgaard.dk/blog/article/krypteret-swap-og-root-filsystem-med-luks-og-ubuntu</a></em></p>
]]></content:encoded>
			<wfw:commentRss>http://ostehamster.dk/blog/index.php/2007/04/13/encrypted-home-partition-using-luks-in-ubunt-feisty-fawn/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
