<?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>wiretrip</title>
	<atom:link href="http://www.wiretrip.org/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.wiretrip.org</link>
	<description></description>
	<lastBuildDate>Sun, 01 Aug 2010 17:26:02 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Restricting access to IPMI modules on public IP&#8217;s</title>
		<link>http://www.wiretrip.org/2010/08/01/restricting-access-to-ipmi-modules-on-public-ips/</link>
		<comments>http://www.wiretrip.org/2010/08/01/restricting-access-to-ipmi-modules-on-public-ips/#comments</comments>
		<pubDate>Sun, 01 Aug 2010 17:26:02 +0000</pubDate>
		<dc:creator>rvdm</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.wiretrip.org/?p=22</guid>
		<description><![CDATA[IPMI modules are a great way to get full control over a remote server, without buying extra remote console / remote power hardware. You can take over the entire server, do KVM or serial over IP, and it&#8217;s even possible to mount ISO&#8217;s on a local workstation, and boot the server off it. The problem [...]]]></description>
			<content:encoded><![CDATA[<p>IPMI modules are a great way to get full control over a remote server, without buying extra remote console / remote power hardware. You can take over the entire server, do KVM or serial over IP, and it&#8217;s even possible to mount ISO&#8217;s on a local workstation, and boot the server off it.<br />
The problem is, IPMI modules should only be accessible from a management network that is not publicly reachable.</p>
<p>Recently I wanted to place my server in a (shared) co-location facility, unable to use a private network for the IPMI module in my supermicro server. The original plan was to use a local iptables firewall on the IPMI module itself, as it runs an ARM linux implementation. Unfortunately the iptables install included with the firmware is severely broken, and can&#8217;t be used:</p>
<p><code># iptables -I INPUT -p tcp -s x.x.x.x -j ACCEPT<br />
iptables v1.2.11: Couldn't load target `standard':/lib/iptables/libipt_standard.so: cannot open shared object file: No such file or directory</p>
<p>Try `iptables -h' or 'iptables --help' for more information.<br />
# </code></p>
<p>Crosscompiling iptables is an option, but would also mean extensive modification of the flash image, as there is no (easy) way to transfer files to the BMC, and flash storage space is limited.</p>
<p>The customized linux install also doesn&#8217;t allow for safe shutdown of unneeded services, and this would still expose the module to the internet. <a href="http://serverfault.com/questions/17521/securing-a-supermicro-ipmi-bmc">This</a> post at serverfault shows that I&#8217;m not the only one looking for a solution for this.</p>
<p>In the end, a friend (thanks mtp!) came up with a simple solution to at least limit access to the public IPMI IP &#8211; simply removing the default gateway, and setting routes to some static IP&#8217;s that are allowed to connect. In combination with a small enough netmask, this is secure enough for my purposes.</p>
<!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a><strong><em>Bookmark It</em></strong></a>
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http%3A%2F%2Fwww.wiretrip.org%2F2010%2F08%2F01%2Frestricting-access-to-ipmi-modules-on-public-ips%2F&amp;title=Restricting+access+to+IPMI+modules+on+public+IP%26%238217%3Bs" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.wiretrip.org%2F2010%2F08%2F01%2Frestricting-access-to-ipmi-modules-on-public-ips%2F&amp;title=Restricting+access+to+IPMI+modules+on+public+IP%26%238217%3Bs" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.wiretrip.org%2F2010%2F08%2F01%2Frestricting-access-to-ipmi-modules-on-public-ips%2F" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fwww.wiretrip.org%2F2010%2F08%2F01%2Frestricting-access-to-ipmi-modules-on-public-ips%2F&amp;title=Restricting+access+to+IPMI+modules+on+public+IP%26%238217%3Bs" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.wiretrip.org%2F2010%2F08%2F01%2Frestricting-access-to-ipmi-modules-on-public-ips%2F&amp;title=Restricting+access+to+IPMI+modules+on+public+IP%26%238217%3Bs" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fwww.wiretrip.org%2F2010%2F08%2F01%2Frestricting-access-to-ipmi-modules-on-public-ips%2F&amp;title=Restricting+access+to+IPMI+modules+on+public+IP%26%238217%3Bs" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http%3A%2F%2Fwww.wiretrip.org%2F2010%2F08%2F01%2Frestricting-access-to-ipmi-modules-on-public-ips%2F" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+Restricting+access+to+IPMI+modules+on+public+IP%26%238217%3Bs+@+http%3A%2F%2Fwww.wiretrip.org%2F2010%2F08%2F01%2Frestricting-access-to-ipmi-modules-on-public-ips%2F" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
]]></content:encoded>
			<wfw:commentRss>http://www.wiretrip.org/2010/08/01/restricting-access-to-ipmi-modules-on-public-ips/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>dm-crypt benchmarks</title>
		<link>http://www.wiretrip.org/2009/05/24/dm-crypt-benchmarks/</link>
		<comments>http://www.wiretrip.org/2009/05/24/dm-crypt-benchmarks/#comments</comments>
		<pubDate>Sun, 24 May 2009 19:34:04 +0000</pubDate>
		<dc:creator>rvdm</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[cipher]]></category>
		<category><![CDATA[dm-crypt]]></category>

		<guid isPermaLink="false">http://www.wiretrip.org/?p=3</guid>
		<description><![CDATA[I finally got around to re-installing my new server. This machine will be my secondary co-located box, serving as secondary DNS, MX, and as a machine to experiment with. As I don&#8217;t want to risk downtime on more important services, I&#8217;ll be running KVM virtual machines, so I won&#8217;t make a mess of the services [...]]]></description>
			<content:encoded><![CDATA[<p>I finally got around to re-installing my new server. This machine will be my secondary co-located box, serving as secondary DNS, MX, and as a machine to experiment with. As I don&#8217;t want to risk downtime on more important services, I&#8217;ll be running KVM virtual machines, so I won&#8217;t make a mess of the services I want to keep running at all time.</p>
<p>The new box is quite fast, running on a core i7 CPU, with 12Gb of RAM and 4 1.5Tb disks in raid10,f2 &#8211; so i thought it would be nice to spend some of that power on encrypting the volume groups my virtual machines will be running on.  Before moving it to the datacenter, I&#8217;m playing around with it, and ran some benchmarks on dm-crypt, to get a feeling about the performance loss. Oh, and I&#8217;m running Ubuntu Jaunty.</p>
<p>First I ran a benchmark on a 500Gb encrypted volume. The disks have been configured in linux software raid10,f2, using a 256Kb chunk size. I used cryptsetup on the md device, to create an encrypted dm-crypt device, attached it, and marked it as a physical volume for LVM. I&#8217;ve left out the output from the commands.</p>
<pre>root@cipher:~# cryptsetup luksFormat /dev/md3 -c aes -s 256 -h sha256
root@cipher:~# cryptsetup luksOpen /dev/md3 crypted
root@cipher:~# pvcreate /dev/mapper/crypted</pre>
<p>After this, I created a volume group using the freshly created pv, and activated a 500Gb logical volume, created an xfs filesystem and mounted it:</p>
<pre>root@cipher:~# vgcreate crypted_vg /dev/mapper/crypted
root@cipher:~# lvcreate -n test_lv -L500G crypted_vg
root@cipher:~# mkfs.xfs /dev/crypted_vg/test_lv
root@cipher:~# mount /dev/crypted_vg/test_lv /mnt/</pre>
<p>On the mounted filesystem, I ran bonnie++ to benchmark performance of dm-crypt. During the benchmark cpu load of 6 of the 8 cores were mostly at 0. The two remaining cores were taking up 80%+ load, by the bonnie++ and the kcryptd processes:</p>
<pre>root@cipher:~# bonnie++ -d . -s 24000 -u rvdm:rvdm
Version 1.03c       ------Sequential Output------ --Sequential Input- --Random-
                    -Per Chr- --Block-- -Rewrite- -Per Chr- --Block-- --Seeks--
Machine        Size K/sec %CP K/sec %CP K/sec %CP K/sec %CP K/sec %CP  /sec %CP
cipher       24000M 73629  97 62418   6 40186   5 55728  79 98903   9 477.3   1
                    ------Sequential Create------ --------Random Create--------
                    -Create-- --Read--- -Delete-- -Create-- --Read--- -Delete--
              files  /sec %CP  /sec %CP  /sec %CP  /sec %CP  /sec %CP  /sec %CP
                 16  1516   5 +++++ +++   990   2  1193   3 +++++ +++   866   2
cipher,24000M,73629,97,62418,6,40186,5,55728,79,98903,9,477.3,1,16,1516,5,+++++,+++,990,2,1193,3,+++++,+++,866,2</pre>
<p>What&#8217;s missing in the output above are the commands to create a directory for bonnie to work in, and to make it writable for the right user.</p>
<p>After the benchmark, I wiped the LV, VG and PV, killed the dm-crypt mapping with cryptsetup, and was left with a new usable md device. To keep the tests as similar as possible, I&#8217;ve created a new vg, containing the entire md device. After creating a new 500Gb LV, mounting and xfs-ing it, I ran the second benchmark:</p>
<pre>root@cipher:~# bonnie++ -d . -s 24000 -u rvdm:rvdm
Version 1.03c       ------Sequential Output------ --Sequential Input- --Random-
                    -Per Chr- --Block-- -Rewrite- -Per Chr- --Block-- --Seeks--
Machine        Size K/sec %CP K/sec %CP K/sec %CP K/sec %CP K/sec %CP  /sec %CP
cipher       24000M 82330  98 157554  17 55584   8 67361  82 226305  22 595.0   1
                    ------Sequential Create------ --------Random Create--------
                    -Create-- --Read--- -Delete-- -Create-- --Read--- -Delete--
              files  /sec %CP  /sec %CP  /sec %CP  /sec %CP  /sec %CP  /sec %CP
                 16  1154   2 +++++ +++   925   2  1241   3 +++++ +++  1186 3
cipher,24000M,82330,98,157554,17,55584,8,67361,82,226305,22,595.0,1,16,1154,2,+++++,+++,925,2,1241,3,+++++,+++,1186,3</pre>
<p>It&#8217;s clear from the output that the overhead from using dm-crypt is quite big; up to 100% in some cases. Also, CPU usage increases significantly. I will be using dm-crypt for crypting some of the virtual machines, but I&#8217;ll be sure to only use it when it&#8217;s worth the performance penalty..</p>
<p><em>Note: I realise the bonnie++ output gets chopped off. To be honest, I&#8217;m too lazy to fix that <img src='http://www.wiretrip.org/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </em></p>
<!-- Social Bookmarks BEGIN -->
<div class="social_bookmark">
<a><strong><em>Bookmark It</em></strong></a>
<br />
<div class="d">
<br />
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http%3A%2F%2Fwww.wiretrip.org%2F2009%2F05%2F24%2Fdm-crypt-benchmarks%2F&amp;title=dm-crypt+benchmarks" rel="nofollow" title="Add to&nbsp;Del.icio.us"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/delicious.png" title="Add to&nbsp;Del.icio.us" alt="Add to&nbsp;Del.icio.us" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fwww.wiretrip.org%2F2009%2F05%2F24%2Fdm-crypt-benchmarks%2F&amp;title=dm-crypt+benchmarks" rel="nofollow" title="Add to&nbsp;digg"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/digg.png" title="Add to&nbsp;digg" alt="Add to&nbsp;digg" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.wiretrip.org%2F2009%2F05%2F24%2Fdm-crypt-benchmarks%2F" rel="nofollow" title="Add to&nbsp;Facebook"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/facebook.png" title="Add to&nbsp;Facebook" alt="Add to&nbsp;Facebook" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fwww.wiretrip.org%2F2009%2F05%2F24%2Fdm-crypt-benchmarks%2F&amp;title=dm-crypt+benchmarks" rel="nofollow" title="Add to&nbsp;Google Bookmarks"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/google.png" title="Add to&nbsp;Google Bookmarks" alt="Add to&nbsp;Google Bookmarks" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://reddit.com/submit?url=http%3A%2F%2Fwww.wiretrip.org%2F2009%2F05%2F24%2Fdm-crypt-benchmarks%2F&amp;title=dm-crypt+benchmarks" rel="nofollow" title="Add to&nbsp;reddit"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/reddit.png" title="Add to&nbsp;reddit" alt="Add to&nbsp;reddit" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fwww.wiretrip.org%2F2009%2F05%2F24%2Fdm-crypt-benchmarks%2F&amp;title=dm-crypt+benchmarks" rel="nofollow" title="Add to&nbsp;Stumble Upon"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/stumbleupon.png" title="Add to&nbsp;Stumble Upon" alt="Add to&nbsp;Stumble Upon" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http%3A%2F%2Fwww.wiretrip.org%2F2009%2F05%2F24%2Fdm-crypt-benchmarks%2F" rel="nofollow" title="Add to&nbsp;Technorati"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/technorati.png" title="Add to&nbsp;Technorati" alt="Add to&nbsp;Technorati" /></a>
<a onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home/?status=Check+out+dm-crypt+benchmarks+@+http%3A%2F%2Fwww.wiretrip.org%2F2009%2F05%2F24%2Fdm-crypt-benchmarks%2F" rel="nofollow" title="Add to&nbsp;Twitter"><img class="social_img" src="http://www.wiretrip.org/wp-content/plugins/social-bookmarks/images/twitter.png" title="Add to&nbsp;Twitter" alt="Add to&nbsp;Twitter" /></a>
<br />
</div>
</div>
<!-- Social Bookmarks END -->
]]></content:encoded>
			<wfw:commentRss>http://www.wiretrip.org/2009/05/24/dm-crypt-benchmarks/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
