<?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:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>AnyHosting</title>
	
	<link>http://anyhosting.com/blog</link>
	<description>It's all about the web</description>
	<lastBuildDate>Sun, 18 Oct 2009 01:41:28 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" href="http://feeds.feedburner.com/Anyhosting" type="application/rss+xml" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com" /><item>
		<title>monitoring ubuntu web servers with nagios3</title>
		<link>http://feedproxy.google.com/~r/Anyhosting/~3/b0wCz02XEvo/</link>
		<comments>http://anyhosting.com/blog/2009/10/17/monitoring-ubuntu-web-servers-with-nagios3/#comments</comments>
		<pubDate>Sun, 18 Oct 2009 01:41:28 +0000</pubDate>
		<dc:creator>rhelmer</dc:creator>
				<category><![CDATA[monitoring]]></category>
		<category><![CDATA[web hosting]]></category>

		<guid isPermaLink="false">http://anyhosting.com/blog/?p=114</guid>
		<description><![CDATA[I have chosen Nagios to keep track of the anyhosting.com network. There are many alternatives (some I have explored and some not yet), what I like about Nagios:

I&#8217;ve been using it for a long time; familiarity
very simple/powerful plugin system
tons of users, so lots of examples and plugins already available

Nagios version 3 is provided in the [...]]]></description>
			<content:encoded><![CDATA[<p>I have chosen <a href="http://nagios.org">Nagios</a> to keep track of the <a href="http://anyhosting.com">anyhosting.com</a> network. There are <a href="http://www.zabbix.com/">many</a> <a href="http://mmonit.com/monit/">alternatives</a> (some I have explored and some not yet), what I like about Nagios:</p>
<ul>
<li>I&#8217;ve been using it for a long time; familiarity</li>
<li>very simple/powerful plugin system</li>
<li>tons of users, so lots of examples and plugins already available</li>
</ul>
<p>Nagios version 3 is provided in the Ubuntu repositories, and is quite simple to install:</p>
<blockquote><p>root@admin:~# apt-get install nagios3</p></blockquote>
<p>The default config comes set up to monitor a set of services on localhost; I don&#8217;t really like the default Ubuntu/Debian setup of having one config file per host/service/etc, so on the master I&#8217;ve replaced the config file structure:</p>
<blockquote><p>root@admin:/etc/nagios3/conf.d# cd /etc/nagios3/conf.d/<br />
root@admin:/etc/nagios3/conf.d# ls<br />
contacts.cfg  extinfo.cfg  groups.cfg  hosts.cfg  services.cfg  timeperiods.cfg</p></blockquote>
<p>groups.conf contains the set of server types that I care about:</p>
<blockquote><p># A list of your web servers<br />
define hostgroup {<br />
hostgroup_name  http-servers<br />
alias           HTTP servers<br />
members         localhost<br />
}</p>
<p># A list of your mysql servers<br />
define hostgroup {<br />
hostgroup_name  mysql-servers<br />
alias           MySQL servers<br />
}</p>
<p># A list of your VHosts<br />
define hostgroup {<br />
hostgroup_name  http-vhosts<br />
alias           Virtual Host HTTP servers<br />
}</p></blockquote>
<p>Note that the &#8220;http-servers&#8221; can define &#8220;members&#8221; (localhost in this case), however in general I do not add members in this file but instead in the hosts.cfg:</p>
<blockquote><p>define host {<br />
host_name   anyhosting1<br />
address     1.2.3.4<br />
use         generic-host<br />
hostgroups  http-servers<br />
}</p>
<p>define host {<br />
host_name   example.com<br />
address     1.2.3.4<br />
use         generic-host<br />
hostgroups  http-vhosts<br />
}</p></blockquote>
<p>Note the &#8220;hostgroups&#8221; line; anyhosting1 is the physical server (this monitor is really checking on the <a href="http://anyhosting.com/blog/2009/10/01/secure-shared-web-hosting-on-ubuntu-server-part-1/">reverse proxy</a>), and example.com is a vhost (which is really proxying to a user running Apache for the &#8220;example.com&#8221; domain). These two checks make sure that the whole system is working and proxying correctly.</p>
<p>Finally, services.cfg brings it all together by defining which groups should run which services:</p>
<blockquote><p># check that web services are running<br />
define service {<br />
hostgroup_name                  http-servers<br />
service_description             HTTP<br />
check_command                   check_http<br />
use                             generic-service<br />
notification_interval           0 ; set &gt; 0 if you want to be renotified<br />
}<br />
define service {<br />
hostgroup_name                  http-vhosts<br />
service_description             Virtual Host HTTP<br />
check_command                   check_httpname<br />
use                             generic-service<br />
notification_interval           0 ; set &gt; 0 if you want to be renotified<br />
}</p></blockquote>
<p>The Ubuntu nagios-plugins package (which by default is installed along with the nagios3 package) contains plugins that can intelligently check MySQL databases, disk space, load average, etc. By default these only work on the local machine, but these can be made to run on remote machines by installing the nagios-nrpe-server package. I will cover this further in a future blog post.</p>
<blockquote>
<blockquote>
<blockquote></blockquote>
</blockquote>
</blockquote>

<p><a href="http://feedads.g.doubleclick.net/~a/Q5zLBSrppeS2JUZZq1V9pjQDLVk/0/da"><img src="http://feedads.g.doubleclick.net/~a/Q5zLBSrppeS2JUZZq1V9pjQDLVk/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/Q5zLBSrppeS2JUZZq1V9pjQDLVk/1/da"><img src="http://feedads.g.doubleclick.net/~a/Q5zLBSrppeS2JUZZq1V9pjQDLVk/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/Anyhosting/~4/b0wCz02XEvo" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://anyhosting.com/blog/2009/10/17/monitoring-ubuntu-web-servers-with-nagios3/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://anyhosting.com/blog/2009/10/17/monitoring-ubuntu-web-servers-with-nagios3/</feedburner:origLink></item>
		<item>
		<title>national cybersecurity awareness month</title>
		<link>http://feedproxy.google.com/~r/Anyhosting/~3/07bovRxRcJA/</link>
		<comments>http://anyhosting.com/blog/2009/10/12/national-cybersecurity-awareness-month/#comments</comments>
		<pubDate>Tue, 13 Oct 2009 03:53:10 +0000</pubDate>
		<dc:creator>rhelmer</dc:creator>
				<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://anyhosting.com/blog/?p=107</guid>
		<description><![CDATA[Apparently it is &#8220;National Cybersecurity Awareness Month&#8221; in the US.
Computer crime is rampant and quite profitable. Websites have long been defaced for fun or viruses and worms released to cause disruptions.  Now there&#8217;s an incentive for criminals to avoid detection, to add your machines to a botnet for hire, or hide spam and ad links [...]]]></description>
			<content:encoded><![CDATA[<p>Apparently it is &#8220;<a href="http://www.whitehouse.gov/the_press_office/Presidential-Proclamation-National-Cybersecurity-Awareness-Month/">National Cybersecurity Awareness Month</a>&#8221; in the US.</p>
<p><a href="http://en.wikipedia.org/wiki/Computer_crime">Computer crime</a> is rampant and quite profitable. Websites have long been <a href="http://en.wikipedia.org/wiki/Website_defacement">defaced</a> for fun or viruses and worms released to cause <a href="http://archives.cnn.com/2000/TECH/computing/05/04/iloveyou.01/">disruptions</a>.  Now there&#8217;s an incentive for criminals to avoid detection, to add your machines to a <a href="http://en.wikipedia.org/wiki/Botnet">botnet</a> for hire, or <a href="http://wordpress.org/development/2009/09/keep-wordpress-secure/">hide spam and ad links in your Wordpress blog</a>.</p>
<p>This is why it&#8217;s super critical to us as at AnyHosting to focus on <a href="http://anyhosting.com/blog/category/security/">security</a>, and follow best practices like secure backups, regular audits, intrusion detection, automatic updates, etc.</p>

<p><a href="http://feedads.g.doubleclick.net/~a/cXWEm1KzOp_DjVS0UUy5fCrlYTE/0/da"><img src="http://feedads.g.doubleclick.net/~a/cXWEm1KzOp_DjVS0UUy5fCrlYTE/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/cXWEm1KzOp_DjVS0UUy5fCrlYTE/1/da"><img src="http://feedads.g.doubleclick.net/~a/cXWEm1KzOp_DjVS0UUy5fCrlYTE/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/Anyhosting/~4/07bovRxRcJA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://anyhosting.com/blog/2009/10/12/national-cybersecurity-awareness-month/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://anyhosting.com/blog/2009/10/12/national-cybersecurity-awareness-month/</feedburner:origLink></item>
		<item>
		<title>centralized logging with syslog-ng</title>
		<link>http://feedproxy.google.com/~r/Anyhosting/~3/SCinILVPz4w/</link>
		<comments>http://anyhosting.com/blog/2009/10/06/centralized-logging-with-syslog-ng/#comments</comments>
		<pubDate>Tue, 06 Oct 2009 22:29:14 +0000</pubDate>
		<dc:creator>rhelmer</dc:creator>
				<category><![CDATA[monitoring]]></category>
		<category><![CDATA[sysadmin]]></category>

		<guid isPermaLink="false">http://anyhosting.com/blog/?p=100</guid>
		<description><![CDATA[Just wanted to point out another excellent post from the Blog O&#8217; Matty on centralized logging with syslog-ng.
I actually helped to set up real-time web analysis with syslog-ng (using TCP) and a slightly hacked webalizer (it was ignoring multiple hits happening on the same second) from a FreeBSD/Apache web farm ~10 years ago, and have [...]]]></description>
			<content:encoded><![CDATA[<p>Just wanted to point out another excellent post from the <a href="http://prefetch.net/blog">Blog O&#8217; Matty</a> on <a href="http://prefetch.net/blog/index.php/2009/10/05/slides-from-syslog-ng-presentation/">centralized logging with syslog-ng</a>.</p>
<p>I actually helped to set up real-time web analysis with syslog-ng (using TCP) and a slightly hacked webalizer (it was ignoring multiple hits happening on the same second) from a FreeBSD/Apache web farm ~10 years ago, and have been looking into it again for my current logging needs.</p>
<p>His blog has <a href="http://prefetch.net/blog/index.php/2009/09/30/how-the-linux-oom-killer-works/">consistently</a> <a href="http://prefetch.net/blog/index.php/2009/08/25/securing-linux-file-systems-that-dont-contain-executables/">awesome</a> <a href="http://prefetch.net/blog/index.php/2009/06/15/migrating-kvm-hosts-with-virsh/">posts</a> (if you&#8217;re interested in systems administration), and as your doctor I highly suggest that you <a href="http://prefetch.net/blog/index.php/feed/">subscribe</a>.</p>

<p><a href="http://feedads.g.doubleclick.net/~a/CHLCiNMYmg4vYZt6pRMQXgKGj8c/0/da"><img src="http://feedads.g.doubleclick.net/~a/CHLCiNMYmg4vYZt6pRMQXgKGj8c/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/CHLCiNMYmg4vYZt6pRMQXgKGj8c/1/da"><img src="http://feedads.g.doubleclick.net/~a/CHLCiNMYmg4vYZt6pRMQXgKGj8c/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/Anyhosting/~4/SCinILVPz4w" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://anyhosting.com/blog/2009/10/06/centralized-logging-with-syslog-ng/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://anyhosting.com/blog/2009/10/06/centralized-logging-with-syslog-ng/</feedburner:origLink></item>
		<item>
		<title>Secure shared web hosting on Ubuntu Server, part 3</title>
		<link>http://feedproxy.google.com/~r/Anyhosting/~3/Ga3UA-VxdF8/</link>
		<comments>http://anyhosting.com/blog/2009/10/04/secure-shared-web-hosting-on-ubuntu-server-part-3/#comments</comments>
		<pubDate>Sun, 04 Oct 2009 07:26:29 +0000</pubDate>
		<dc:creator>rhelmer</dc:creator>
				<category><![CDATA[security]]></category>
		<category><![CDATA[web hosting]]></category>

		<guid isPermaLink="false">http://anyhosting.com/blog/?p=87</guid>
		<description><![CDATA[In this third and final installment, we&#8217;ll look at alternatives and future directions for shared web hosting on Ubuntu Server (go back in time to part 1 and part 2 in case you missed them).
Our original goal was to provide websites for multiple users on one host, keeping them compartmentalized from each other, and to [...]]]></description>
			<content:encoded><![CDATA[<p>In this third and final installment, we&#8217;ll look at alternatives and future directions for shared web hosting on Ubuntu Server (go back in time to <a href="http://anyhosting.com/blog/2009/10/03/secure-shared-web-hosting-on-ubuntu-server-part-1/">part 1</a> and <a href="http://anyhosting.com/blog/2009/10/03/secure-shared-web-hosting-on-ubuntu-server-part-2/">part 2</a> in case you missed them).</p>
<p>Our original goal was to provide websites for multiple users on one host, keeping them compartmentalized from each other, and to restrict break-ins. We chose to do reverse proxying using Apache, with separate Apache instances for each user, using mod_chroot.</p>
<p>Pros:</p>
<ul>
<li>user cannot see or read/write other users files, even on the same shared server, or use any system resources not explicitly provided in the chroot.</li>
<li>mod_chroot is way less work than building a full chroot jail, and is potentially safer since you don&#8217;t have to provide system libraries or binaries, reducing your attack surface</li>
</ul>
<p>Cons:</p>
<ul>
<li>multiple Apache instances consume more memory, and need special configuration and startup scripts</li>
<li>it is possible to <a href="http://kerneltrap.org/Linux/Abusing_chroot">break out of a chroot</a>. It is especially easy if the attacker can somehow get elevated to root (e.g. local security exploit)</li>
</ul>
<p>Further investigation:</p>
<ul>
<li> apache-mpm-itk &#8211; This runs Apache child processes as a separate user per vhost. Cannot be combined with mod_chroot, unfortunately, and has some serious drawbacks (see the section on <a href="http://mpm-itk.sesse.net/">Quirks and Warnings</a>).</li>
</ul>
<ul>
<li><a href="http://en.wikipedia.org/wiki/Solaris_Containers">solaris containers</a>, <a href="http://en.wikipedia.org/wiki/FreeBSD_jail">freebsd jail</a>, <a href="http://en.wikipedia.org/wiki/Linux-VServer">linux vserver</a> &#8211; These are real jails; less overhead than <a href="http://en.wikipedia.org/wiki/Virtual_machine">Virtual Machines</a>, but provide more protection than a chroot. These tend to be significantly more complex to set up than something like mod_chroot, but are by design a lot harder to escape than a chroot.</li>
</ul>
<p>There are some other interesting security-related modules such as <a href="http://www.zdziarski.com/projects/mod_evasive/">mod_evasive</a> that I am checking into further, which may mitigate some of the &#8220;cons&#8221; above.</p>
<p>Hopefully this will be useful to someone, however <a href="http://www.schneier.com/book-sandl-pref.html">security is a process, not a product</a>, and you should not rely solely on something like mod_chroot, but it can be a useful tool as part of an overall strategy that includes monitoring, intrusion detection, and regular security updates.</p>

<p><a href="http://feedads.g.doubleclick.net/~a/t-IfbjC0NBCrXC5sQf0H1uP5XGQ/0/da"><img src="http://feedads.g.doubleclick.net/~a/t-IfbjC0NBCrXC5sQf0H1uP5XGQ/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/t-IfbjC0NBCrXC5sQf0H1uP5XGQ/1/da"><img src="http://feedads.g.doubleclick.net/~a/t-IfbjC0NBCrXC5sQf0H1uP5XGQ/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/Anyhosting/~4/Ga3UA-VxdF8" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://anyhosting.com/blog/2009/10/04/secure-shared-web-hosting-on-ubuntu-server-part-3/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://anyhosting.com/blog/2009/10/04/secure-shared-web-hosting-on-ubuntu-server-part-3/</feedburner:origLink></item>
		<item>
		<title>Secure shared web hosting on Ubuntu Server, part 2</title>
		<link>http://feedproxy.google.com/~r/Anyhosting/~3/MqaArm3VmO8/</link>
		<comments>http://anyhosting.com/blog/2009/10/03/secure-shared-web-hosting-on-ubuntu-server-part-2/#comments</comments>
		<pubDate>Sat, 03 Oct 2009 14:10:13 +0000</pubDate>
		<dc:creator>rhelmer</dc:creator>
				<category><![CDATA[security]]></category>
		<category><![CDATA[web hosting]]></category>

		<guid isPermaLink="false">http://anyhosting.com/blog/?p=70</guid>
		<description><![CDATA[Continuing from part 1, here are the nuts and bolts:
Ubuntu 8.10 Server
root@theo:~# apt-get install apache2 libapache2-mod-chroot
For each domain, create a virtual host config like /etc/apache2/sites-available/example.com:
&#60;VirtualHost *:80&#62;
ServerAdmin webmaster@example.com
ServerName example.com
ServerAlias www.example.com
ProxyPass / http://localhost:8080/
ProxyPassReverse / http://localhost:8080/
&#60;Proxy *&#62;
  Allow from all
&#60;/Proxy&#62;
ErrorLog /var/www/example.com/logs/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog /var/www/example.com/logs/access.log combined
&#60;/VirtualHost&#62;
This will be [...]]]></description>
			<content:encoded><![CDATA[<p>Continuing from <a href="http://anyhosting.com/blog/2009/10/01/secure-shared-web-hosting-on-ubuntu-server-part-1/">part 1</a>, here are the nuts and bolts:</p>
<p>Ubuntu 8.10 Server</p>
<pre>root@theo:~# apt-get install apache2 libapache2-mod-chroot</pre>
<p>For each domain, create a virtual host config like /etc/apache2/sites-available/example.com:</p>
<pre>&lt;VirtualHost *:80&gt;
ServerAdmin webmaster@example.com
ServerName example.com
ServerAlias www.example.com</pre>
<pre>ProxyPass / http://localhost:8080/
ProxyPassReverse / http://localhost:8080/</pre>
<pre>&lt;Proxy *&gt;
  Allow from all
&lt;/Proxy&gt;</pre>
<pre>ErrorLog /var/www/example.com/logs/error.log</pre>
<pre># Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn</pre>
<pre>CustomLog /var/www/example.com/logs/access.log combined</pre>
<pre>&lt;/VirtualHost&gt;</pre>
<p>This will be used by the Apache proxy, which is the normal system apache2 running as the default &#8220;www-data&#8221; user. This proxy handles name-based virtual hosts, and proxies the requests to a second process, running at localhost on port 8080.</p>
<p>Note that the logs are configured here and not in the user&#8217;s Apache process, for two reasons:</p>
<ol>
<li>keep logs pristine in the event of a break-in on a user site (for example via a buggy or malicious PHP script)</li>
<li>single system-wide log file analysis process instead of per-user</li>
</ol>
<p>Next, create a user account for each domain:</p>
<pre>root@theo:~# mkdir /var/www/example.com
root@theo:~# cd /var/www/example.com/
root@theo:/var/www/example.com# useradd -d /var/www/example.com/htdocs example.com
root@theo:/var/www/example.com# mkdir htdocs logs conf
root@theo:/var/www/example.com# chown www-data:www-data logs
root@theo:/var/www/example.com# chown example.com:example.com htdocs/</pre>
<p>Create the following in /var/www/example.com/conf/apache2.conf:</p>
<pre>ServerRoot "/var/www/example.com/"
RequestHeader set Host example.com
LockFile /var/www/example.com/conf/accept.lock
PidFile /conf/apache2.pid
Timeout 300
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 15
User example.com
Group example.com
AccessFileName .htaccess
&lt;Files ~ "^\.ht"&gt;
  Order allow,deny
  Deny from all
&lt;/Files&gt;

DefaultType text/plain
HostnameLookups Off
ErrorLog /var/www/example.com/conf/error.log
LogLevel warn
LoadFile /lib/libnss_dns.so.2
LoadModule chroot_module /usr/lib/apache2/modules/mod_chroot.so
Include /etc/apache2/mods-enabled/*.load
Include /etc/apache2/mods-enabled/*.conf
Listen 8080
DocumentRoot /htdocs
ChrootDir /var/www/example.com/</pre>
<p>Start up the user Apache process:</p>
<pre>
<pre>root@theo:~# apache2 -f /var/www/example.com/conf/apache2.conf -k start</pre>
</pre>
<p>Everything should now work, but you may notice some problems with PHP or CGI scripts. Generally this means that you will need to make parts of the system available in the chroot; however making copies takes up a lot of space and can quickly get out of date, which is a security risk.</p>
<p>One workaround is to provide needed directories using the &#8220;mount -o bind&#8221; option, which will remount an existing, mounted part of the file hierarchy somewhere else. For example, this will provide all of &#8220;/usr&#8221; inside the chroot:</p>
<pre>root@theo:~# mkdir /usr /var/www/example.com/usr
root@theo:~# mount -o bind,ro /usr /var/www/example.com/usr</pre>
<p>PHP sessions require /tmp to exist inside the chroot; there is no benefit to sharing this one, an empty directory is fine.</p>
<p>That&#8217;s pretty much it! Testing, getting startup right etc. is left as an exercise for the reader, since we&#8217;re venturing a bit out of the standard Ubuntu Apache setup. Entries in /etc/fstab and creating an init script to handle user Apache processes is probably the best way to go.</p>
<p>In part 3 we&#8217;ll cover take a more general look at the pros and cons to this setup, as well as possible future directions.</p>
<p><em>EDIT 2009-Oct-03 2:25 PM Pacific &#8211; create dir before cding into it; add read-only (ro) option to usr mount; override &#8220;host&#8221; header in user Apache process</em></p>
<p><em>EDIT 2009-Oct-05 4:41 PM Pacific &#8211; load resolver library and install caching proxy dns server, needed by popular wordpress anti-spam plugin Akismet<br />
</em></p>

<p><a href="http://feedads.g.doubleclick.net/~a/lNQrJc9GKKoe5ir_TRK7gJlekoI/0/da"><img src="http://feedads.g.doubleclick.net/~a/lNQrJc9GKKoe5ir_TRK7gJlekoI/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/lNQrJc9GKKoe5ir_TRK7gJlekoI/1/da"><img src="http://feedads.g.doubleclick.net/~a/lNQrJc9GKKoe5ir_TRK7gJlekoI/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/Anyhosting/~4/MqaArm3VmO8" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://anyhosting.com/blog/2009/10/03/secure-shared-web-hosting-on-ubuntu-server-part-2/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://anyhosting.com/blog/2009/10/03/secure-shared-web-hosting-on-ubuntu-server-part-2/</feedburner:origLink></item>
		<item>
		<title>Secure shared web hosting on Ubuntu Server, part 1</title>
		<link>http://feedproxy.google.com/~r/Anyhosting/~3/YL_wdQREZqA/</link>
		<comments>http://anyhosting.com/blog/2009/10/01/secure-shared-web-hosting-on-ubuntu-server-part-1/#comments</comments>
		<pubDate>Fri, 02 Oct 2009 01:51:07 +0000</pubDate>
		<dc:creator>rhelmer</dc:creator>
				<category><![CDATA[security]]></category>
		<category><![CDATA[web hosting]]></category>

		<guid isPermaLink="false">http://anyhosting.com/blog/?p=63</guid>
		<description><![CDATA[We&#8217;ve gone over securing a shared hosting setup briefly in the past, but I have made some improvements and simplifications that I&#8217;d like to share. This is part 1 of 3, an introduction to secure shared web hosting on Ubuntu Server.
At AnyHosting we want to have multiple users on one shared server, but  protect [...]]]></description>
			<content:encoded><![CDATA[<p>We&#8217;ve gone over securing a shared hosting setup briefly <a href="http://anyhosting.com/blog/2008/01/14/web-hosting-with-ubuntu-server/">in the past</a>, but I have made some improvements and simplifications that I&#8217;d like to share. This is part 1 of 3, an introduction to secure shared web hosting on Ubuntu Server.</p>
<p>At AnyHosting we want to have multiple users on one shared server, but  protect them from reading or writing each other&#8217;s files (whether  accidental or intentional) and also limit damage caused by a break-in  via a poorly configured PHP script or CGI, or even an Apache exploit.</p>
<p>The solution here is to have each customer run their own Apache process, and do <a href="http://en.wikipedia.org/wiki/Virtual_hosting#Name-based">name-based virtual hosting</a> and forwarding via a <a href="http://en.wikipedia.org/wiki/Reverse_proxy">reverse proxy</a>. The proxy is currently Apache but we are also considering more scalable alternatives such as <a href="http://en.wikipedia.org/wiki/Nginx">nginx</a>. An important thing to note here is that the proxy could be on a separate machine and also combine <a href="http://en.wikipedia.org/wiki/Load_balancing_%28computing%29">load-balancing</a> into the mix, so it provides a lot of flexibility.</p>
<p>The <a href="http://www.faqs.org/docs/securing/chap29sec254.html">classic way to chroot Apache</a> (or any server process) is to copy the server process and all of it&#8217;s dependencies into the chroot jail, which makes keeping the files up to date not just a depressing chore but also a serious security hazard. Also it&#8217;s a ton of work to get right, especially if you want to support server-side scripting like PHP, since it depends on lots of system files and libraries.</p>
<p>Enter <a href="http://core.segfault.pl/~hobbit/mod_chroot/">mod_chroot</a>. This Apache module runs in the user&#8217;s process, and does the chroot system call after opening all the files it needs. The only caveats I&#8217;ve found (besides the ones on the mod_chroot <a href="http://core.segfault.pl/~hobbit/mod_chroot/caveats.html">caveats page</a>) are some files that the Ubuntu PHP install assumes it can reach (such as the MySQL server socket, timezone info, and random number generator). I will cover this in more detail in part 2.</p>

<p><a href="http://feedads.g.doubleclick.net/~a/LxZA3rKNzvRuLjb2j5dub50B5O0/0/da"><img src="http://feedads.g.doubleclick.net/~a/LxZA3rKNzvRuLjb2j5dub50B5O0/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/LxZA3rKNzvRuLjb2j5dub50B5O0/1/da"><img src="http://feedads.g.doubleclick.net/~a/LxZA3rKNzvRuLjb2j5dub50B5O0/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/Anyhosting/~4/YL_wdQREZqA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://anyhosting.com/blog/2009/10/01/secure-shared-web-hosting-on-ubuntu-server-part-1/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<feedburner:origLink>http://anyhosting.com/blog/2009/10/01/secure-shared-web-hosting-on-ubuntu-server-part-1/</feedburner:origLink></item>
		<item>
		<title>AnyHosting launched!</title>
		<link>http://feedproxy.google.com/~r/Anyhosting/~3/GEFKOuX_tVo/</link>
		<comments>http://anyhosting.com/blog/2009/10/01/anyhosting-launched/#comments</comments>
		<pubDate>Thu, 01 Oct 2009 05:25:04 +0000</pubDate>
		<dc:creator>rhelmer</dc:creator>
				<category><![CDATA[web hosting]]></category>

		<guid isPermaLink="false">http://anyhosting.com/blog/?p=58</guid>
		<description><![CDATA[I&#8217;ve just pushed a new front page to anyhosting.com with more details.
If you&#8217;re looking for simple, secure and affordable web hosting, check it out!
I&#8217;m also working on a series of blog posts and articles about the new setup (reverse proxy, mod_chroot, on ubuntu server).
]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve just pushed a new front page to <a href="http://anyhosting.com">anyhosting.com</a> with more details.</p>
<p>If you&#8217;re looking for simple, secure and affordable web hosting, check it out!</p>
<p>I&#8217;m also working on a series of blog posts and articles about the new setup (reverse proxy, mod_chroot, on ubuntu server).</p>

<p><a href="http://feedads.g.doubleclick.net/~a/AXHlTduyen6bRplt7Bh0eEZIqjg/0/da"><img src="http://feedads.g.doubleclick.net/~a/AXHlTduyen6bRplt7Bh0eEZIqjg/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/AXHlTduyen6bRplt7Bh0eEZIqjg/1/da"><img src="http://feedads.g.doubleclick.net/~a/AXHlTduyen6bRplt7Bh0eEZIqjg/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/Anyhosting/~4/GEFKOuX_tVo" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://anyhosting.com/blog/2009/10/01/anyhosting-launched/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://anyhosting.com/blog/2009/10/01/anyhosting-launched/</feedburner:origLink></item>
		<item>
		<title>web hosting control panels</title>
		<link>http://feedproxy.google.com/~r/Anyhosting/~3/hssYpaw9k4E/</link>
		<comments>http://anyhosting.com/blog/2009/06/18/web-hosting-control-panels/#comments</comments>
		<pubDate>Thu, 18 Jun 2009 22:43:58 +0000</pubDate>
		<dc:creator>rhelmer</dc:creator>
				<category><![CDATA[web hosting]]></category>

		<guid isPermaLink="false">http://anyhosting.com/blog/?p=55</guid>
		<description><![CDATA[I&#8217;ve been shopping around for virtual web hosting control panels. At this point, I am interested only in providing end-users things like file management, basic database administration, pre-defined package mangement.
They seem to fall into three broad categories:

expensive proprietary packages
free open-source packages
custom software developed by hosting companies

The leader in #1 seems to be cPanel. I am [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been shopping around for virtual web hosting control panels. At this point, I am interested only in providing end-users things like file management, basic database administration, pre-defined package mangement.</p>
<p>They seem to fall into three broad categories:</p>
<ol>
<li>expensive proprietary packages</li>
<li>free open-source packages</li>
<li>custom software developed by hosting companies</li>
</ol>
<p>The leader in #1 seems to be <a href="http://www.cpanel.net/">cPanel</a>. I am not at all impressed with their <a href="http://www.cpanel.net/products/cpanelwhm/try-demo.html">demo</a>, it looks very cluttered to me and I really want something simple, easy and aesthetically pleasing.</p>
<p>I have checked out all of the <a href="http://en.wikipedia.org/wiki/Control_panel_%28web_hosting%29#Free_and_open_source_software_-_FOSS">free/open-source web hosting control panels that Wikipedia lists</a>, and I am also very displeased with the UI, and the code doesn&#8217;t look very easy to jump into to me. There seems to be a lot of custom code (I&#8217;d be happiest with something based on <a href="http://www.djangoproject.com/">Django</a>, but the PHP ones could at least use <a href="http://cakephp.org/">Cake</a>). This makes me a little worried on the security aspect (XSS, SQL injection, etc.). Most of these code bases seem to be very old and not necessarily very active.</p>
<p>So is #3 the way to go? I&#8217;ve seen and heard about lots of great hosting control panels that only exist behind close doors, is this the big differentiator for modern hosting companies?</p>

<p><a href="http://feedads.g.doubleclick.net/~a/itzrnaXb1TDkuUoyAYMeuBlLf2U/0/da"><img src="http://feedads.g.doubleclick.net/~a/itzrnaXb1TDkuUoyAYMeuBlLf2U/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/itzrnaXb1TDkuUoyAYMeuBlLf2U/1/da"><img src="http://feedads.g.doubleclick.net/~a/itzrnaXb1TDkuUoyAYMeuBlLf2U/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/Anyhosting/~4/hssYpaw9k4E" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://anyhosting.com/blog/2009/06/18/web-hosting-control-panels/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://anyhosting.com/blog/2009/06/18/web-hosting-control-panels/</feedburner:origLink></item>
		<item>
		<title>offline mobile Gmail</title>
		<link>http://feedproxy.google.com/~r/Anyhosting/~3/YRLnLRxj084/</link>
		<comments>http://anyhosting.com/blog/2009/02/20/offline-mobile-gmail/#comments</comments>
		<pubDate>Fri, 20 Feb 2009 20:33:28 +0000</pubDate>
		<dc:creator>rhelmer</dc:creator>
				<category><![CDATA[cloud computing]]></category>
		<category><![CDATA[web browsers]]></category>

		<guid isPermaLink="false">http://anyhosting.com/blog/?p=51</guid>
		<description><![CDATA[Mobile Gmail will soon be using nex-gen (HTML5) browser standards to make network reliability not matter:

]]></description>
			<content:encoded><![CDATA[<p>Mobile Gmail will soon be using nex-gen (HTML5) browser standards to make network reliability <a href="http://anyhosting.com/blog/2008/02/23/cloud-computing-reliability-will-not-matter/">not matter</a>:</p>
<p><object width="480" height="295" data="http://www.youtube.com/v/VmjxmOtNZCk&amp;hl=en&amp;fs=1" type="application/x-shockwave-flash"><param name="allowFullScreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://www.youtube.com/v/VmjxmOtNZCk&amp;hl=en&amp;fs=1" /><param name="allowfullscreen" value="true" /></object></p>

<p><a href="http://feedads.g.doubleclick.net/~a/Doimj2egbn3MYgasJ7_js_t5JDg/0/da"><img src="http://feedads.g.doubleclick.net/~a/Doimj2egbn3MYgasJ7_js_t5JDg/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/Doimj2egbn3MYgasJ7_js_t5JDg/1/da"><img src="http://feedads.g.doubleclick.net/~a/Doimj2egbn3MYgasJ7_js_t5JDg/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/Anyhosting/~4/YRLnLRxj084" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://anyhosting.com/blog/2009/02/20/offline-mobile-gmail/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://anyhosting.com/blog/2009/02/20/offline-mobile-gmail/</feedburner:origLink></item>
		<item>
		<title>Google Chrome on Mac screenshots</title>
		<link>http://feedproxy.google.com/~r/Anyhosting/~3/jHxFtOPHjZs/</link>
		<comments>http://anyhosting.com/blog/2009/02/14/google-chrome-on-mac-screenshots/#comments</comments>
		<pubDate>Sat, 14 Feb 2009 04:43:46 +0000</pubDate>
		<dc:creator>rhelmer</dc:creator>
				<category><![CDATA[web browsers]]></category>

		<guid isPermaLink="false">http://anyhosting.com/blog/?p=44</guid>
		<description><![CDATA[Very early screenshots of Google Chrome running on Mac. Via pinkerton&#8217;s blog:


]]></description>
			<content:encoded><![CDATA[<p>Very early screenshots of Google Chrome running on Mac. Via pinkerton&#8217;s <a href="http://weblogs.mozillazine.org/pinkerton/archives/019848.html">blog</a>:</p>
<p><a href="http://homepage.mac.com/mikepinkerton/FirstChromePageEver.png"><img class="alignnone" title="First Mac Google Chrome screenshot" src="http://homepage.mac.com/mikepinkerton/FirstChromePageEver.png" alt="" width="262" height="219" /></a></p>
<p><a href="http://homepage.mac.com/avidrissman/extimgs/st.png"><img class="alignnone" title="Sad Google Mac Screenshot" src="http://homepage.mac.com/avidrissman/extimgs/st.png" alt="" width="288" height="245" /></a></p>

<p><a href="http://feedads.g.doubleclick.net/~a/lVEkBNGl5HZngmoTTn2hwESrgYk/0/da"><img src="http://feedads.g.doubleclick.net/~a/lVEkBNGl5HZngmoTTn2hwESrgYk/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/lVEkBNGl5HZngmoTTn2hwESrgYk/1/da"><img src="http://feedads.g.doubleclick.net/~a/lVEkBNGl5HZngmoTTn2hwESrgYk/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/Anyhosting/~4/jHxFtOPHjZs" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://anyhosting.com/blog/2009/02/14/google-chrome-on-mac-screenshots/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://anyhosting.com/blog/2009/02/14/google-chrome-on-mac-screenshots/</feedburner:origLink></item>
	</channel>
</rss>
