<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: Building a secure web server with CentOS 5, part 1</title>
	<atom:link href="http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/</link>
	<description>Enterprise Technologies</description>
	<lastBuildDate>Sun, 05 Feb 2012 18:34:01 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: TonyRiver</title>
		<link>http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/comment-page-1/#comment-4767</link>
		<dc:creator>TonyRiver</dc:creator>
		<pubDate>Thu, 29 Dec 2011 10:15:01 +0000</pubDate>
		<guid isPermaLink="false">http://wp.rayheffer.com/?p=36#comment-4767</guid>
		<description>Thanks. I’ve been wondering how to change the default home directory for a while now. Glad I found this to explain how.
Your comment is awaiting moderation.</description>
		<content:encoded><![CDATA[<p>Thanks. I’ve been wondering how to change the default home directory for a while now. Glad I found this to explain how.<br />
Your comment is awaiting moderation.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dave</title>
		<link>http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/comment-page-1/#comment-4063</link>
		<dc:creator>Dave</dc:creator>
		<pubDate>Thu, 27 Oct 2011 19:49:31 +0000</pubDate>
		<guid isPermaLink="false">http://wp.rayheffer.com/?p=36#comment-4063</guid>
		<description>Hi Ray,

Glad you took my comments as intended and didn&#039;t think I was flaming you.

You are 100% correct in stating that &quot;phpMyAdmin isn’t alone in having security vulnerabilities&quot;.  In Fact, phpMyAdmin has a good track record in resolving all security threats reported to/by US-CERT.

The reason for my comments regarding phpMyAdmin and others was &lt;b&gt;because&lt;/b&gt; your article targeted novices.  This is also why I strongly recommend disabling networking.  A novice should learn the intricacies of GRANTS and MySQL administration in general before deploying and administrating a tool intended to make it easy for them shoot off a toe.  Hopefully, anyone intending to administrate a DBMS is comfortable with some SQL, if not, this is the ideal time to learn some, and better to do so locally than through a web interface which will abstract away the SQL layer.

As regards Yum and other such tools...  I wouldn&#039;t trust any; RedHat or otherwise.  Source builds are the only way to install &quot;secure&quot; software... but in fairness to your efforts, that may not be a &quot;novice&quot; topic.

The reason to remove networking on the DBMS is not so much a fear of a threat originating from the network layer, but more of a concern regarding a novice administrator who may make mistakes in configuration while learning (and inadvertently exposing himself to something hostile on the network layer).

Good luck with your site!

D</description>
		<content:encoded><![CDATA[<p>Hi Ray,</p>
<p>Glad you took my comments as intended and didn&#8217;t think I was flaming you.</p>
<p>You are 100% correct in stating that &#8220;phpMyAdmin isn’t alone in having security vulnerabilities&#8221;.  In Fact, phpMyAdmin has a good track record in resolving all security threats reported to/by US-CERT.</p>
<p>The reason for my comments regarding phpMyAdmin and others was <b>because</b> your article targeted novices.  This is also why I strongly recommend disabling networking.  A novice should learn the intricacies of GRANTS and MySQL administration in general before deploying and administrating a tool intended to make it easy for them shoot off a toe.  Hopefully, anyone intending to administrate a DBMS is comfortable with some SQL, if not, this is the ideal time to learn some, and better to do so locally than through a web interface which will abstract away the SQL layer.</p>
<p>As regards Yum and other such tools&#8230;  I wouldn&#8217;t trust any; RedHat or otherwise.  Source builds are the only way to install &#8220;secure&#8221; software&#8230; but in fairness to your efforts, that may not be a &#8220;novice&#8221; topic.</p>
<p>The reason to remove networking on the DBMS is not so much a fear of a threat originating from the network layer, but more of a concern regarding a novice administrator who may make mistakes in configuration while learning (and inadvertently exposing himself to something hostile on the network layer).</p>
<p>Good luck with your site!</p>
<p>D</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ray Heffer</title>
		<link>http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/comment-page-1/#comment-4059</link>
		<dc:creator>Ray Heffer</dc:creator>
		<pubDate>Thu, 27 Oct 2011 17:58:16 +0000</pubDate>
		<guid isPermaLink="false">http://wp.rayheffer.com/?p=36#comment-4059</guid>
		<description>Hi Dave,

Thanks for your comments, feedback is always welcome! I agree with your observations for the most part, but remember that my guide is aimed at the newbie or intermediate Linux user and someone that wants to host their own LAMP server. Anyway, here are my views...

phpMyAdmin: phpMyAdmin isn&#039;t alone in having security vulnerabilities. Wordpress, Apache, MySQL all have them, the list goes on. My recommendation is to use Yum (more on that in a moment) and keep everything up to date. In 8 years my LAMP servers have never had a security vulnerability compromised as a result of using phpMyAdmin. But a lazy administrator may do if it&#039;s not kept up to date, good passwords, etc... as with any other service.

Turning off unwanted daemons: My guide does already state that CentOS should be installed using the &#039;custom&#039; setting, and removing everything from the list. Still, when you do this daemons such as CUPS are still present (you can&#039;t remove this at install time). Surely it&#039;s good to know how to list these running services and learn how to disable them.

Yum: I know exactly where my software and updates come from... the CentOS Project repositories and it&#039;s very closely aligned to the RHEL repositories. In fact you can&#039;t always get the latest versions of software unless they&#039;re approved by CentOS and fully tested (PHP is a good example). I wouldn&#039;t recommend that people use repositories like utterramblings unless they know what they are doing and it&#039;s not for an enterprise production LAMP server. For example, &lt;a href=&quot;http://bit.ly/uB82e4&quot; rel=&quot;nofollow&quot;&gt;Read this&lt;/a&gt;, I won&#039;t start quoting from their FAQ but I trust it no less than the RHEL repositories.

MySQL: I&#039;ve not done this so I will test when I get time. I don&#039;t think having networking enabled for MySQL is a high security risk though given IPTABLES is running and my guide states the use of TCP Wrappers. &lt;a href=&quot;http://dev.mysql.com/doc/refman/5.0/en/security-against-attack.html&quot; rel=&quot;nofollow&quot;&gt;http://dev.mysql.com/doc/refman/5.0/en/security-against-attack.html&lt;/a&gt;

VSFTP: I&#039;m not trying to secure the transport layer otherwise SSH is also a great option and one I use myself. I&#039;m aiming this guide at novice to moderate users of Linux that want a web server up and running (LAMP).

Apache: Great tips here especially not using * in the virtualhost section.

It&#039;s good to get others views on this as it&#039;s a popular topic on my website, despite being over 5 years old now!

Ray</description>
		<content:encoded><![CDATA[<p>Hi Dave,</p>
<p>Thanks for your comments, feedback is always welcome! I agree with your observations for the most part, but remember that my guide is aimed at the newbie or intermediate Linux user and someone that wants to host their own LAMP server. Anyway, here are my views&#8230;</p>
<p>phpMyAdmin: phpMyAdmin isn&#8217;t alone in having security vulnerabilities. WordPress, Apache, MySQL all have them, the list goes on. My recommendation is to use Yum (more on that in a moment) and keep everything up to date. In 8 years my LAMP servers have never had a security vulnerability compromised as a result of using phpMyAdmin. But a lazy administrator may do if it&#8217;s not kept up to date, good passwords, etc&#8230; as with any other service.</p>
<p>Turning off unwanted daemons: My guide does already state that CentOS should be installed using the &#8216;custom&#8217; setting, and removing everything from the list. Still, when you do this daemons such as CUPS are still present (you can&#8217;t remove this at install time). Surely it&#8217;s good to know how to list these running services and learn how to disable them.</p>
<p>Yum: I know exactly where my software and updates come from&#8230; the CentOS Project repositories and it&#8217;s very closely aligned to the RHEL repositories. In fact you can&#8217;t always get the latest versions of software unless they&#8217;re approved by CentOS and fully tested (PHP is a good example). I wouldn&#8217;t recommend that people use repositories like utterramblings unless they know what they are doing and it&#8217;s not for an enterprise production LAMP server. For example, <a href="http://bit.ly/uB82e4"  onclick="pageTracker._trackPageview('/outgoing/bit.ly/uB82e4?referer=');">Read this</a>, I won&#8217;t start quoting from their FAQ but I trust it no less than the RHEL repositories.</p>
<p>MySQL: I&#8217;ve not done this so I will test when I get time. I don&#8217;t think having networking enabled for MySQL is a high security risk though given IPTABLES is running and my guide states the use of TCP Wrappers. <a href="http://dev.mysql.com/doc/refman/5.0/en/security-against-attack.html"  onclick="pageTracker._trackPageview('/outgoing/dev.mysql.com/doc/refman/5.0/en/security-against-attack.html?referer=');">http://dev.mysql.com/doc/refman/5.0/en/security-against-attack.html</a></p>
<p>VSFTP: I&#8217;m not trying to secure the transport layer otherwise SSH is also a great option and one I use myself. I&#8217;m aiming this guide at novice to moderate users of Linux that want a web server up and running (LAMP).</p>
<p>Apache: Great tips here especially not using * in the virtualhost section.</p>
<p>It&#8217;s good to get others views on this as it&#8217;s a popular topic on my website, despite being over 5 years old now!</p>
<p>Ray</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dave</title>
		<link>http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/comment-page-1/#comment-4056</link>
		<dc:creator>Dave</dc:creator>
		<pubDate>Thu, 27 Oct 2011 12:10:01 +0000</pubDate>
		<guid isPermaLink="false">http://wp.rayheffer.com/?p=36#comment-4056</guid>
		<description>I was searching for a few things and stumbled upon your site.  Your intentions seem good so I thought I&#039;d offer up a couple comments which might help from the &quot;secure&quot; point of view.

phpMyAdmin :  I&#039;d avoid this like the plague; it has had a million-and-one security flaws over the years and even if you got it cleaned up completely, it&#039;s a vector of choice into your system.  Meaning attackers will be constantly looking to use it as a way into you system.  One look at your logs will show you that bots are scanning for it&#039;s presence.

Turning off un-needed daemons : why install them to begin with?  It serves no purpose to install potential vulnerabilities if all your going to do is turn it off.  Since you&#039;re starting with a fresh OS build, deselect all software you don&#039;t need.  This narrows your attack surface and offers the added bonus of conserving resources.

Yum : as soon as you type that into your console you&#039;ve lost any sense of security.  You have no idea where that software has come from, who packaged it, nor how it was built.  remember the great redhat gcc 2.96 issue?  They grabbed a developers snapshot of gcc (without gnu&#039;s knowledge) and used it to build all their rpms for their redhat 8 release.  Over the next six months people everywhere were discovering corrupt tables in their mysql implementations with no way to recover.  The issue was eventually traced back to redhat&#039;s rpms.  If you didn&#039;t build it, don&#039;t trust it! (secure is the goal, right?).  This gives you the added bonus of letting you remove pieces of the software that you don&#039;t need, narrowing the attack surface.  Not going to offer CGI access?  Don&#039;t even even compile in CGI capabilities.

MySQL : remove its networking capabilities and force it to work over unix domain sockets.  When you run &quot;netstat -an &#124; grep LISTEN&quot;, you should NOT see 3306 as a bound port.  The DBMS is for the local hosting user&#039;s, they don&#039;t need to access the daemon from outside of the environment; and now, attackers can&#039;t either.

VSFTP : is not very secure at all.  Your already supporting sshd, why not offer SFTP access?  You don&#039;t need to add any extra software, you just need to enable it and add a couple rules to your firewall.  Now you&#039;ll have end-to-end encryption, again, narrowing your attack surface.

Apache conf : turn off tokens (set to prod), don&#039;t use * in the virtualhost; it&#039;s a rare thing when you really want all sites gloaming onto all adapters.  More often then not you&#039;ll want to restrict each container to a specific IP.

I hope you founf something helpful or useful in that.</description>
		<content:encoded><![CDATA[<p>I was searching for a few things and stumbled upon your site.  Your intentions seem good so I thought I&#8217;d offer up a couple comments which might help from the &#8220;secure&#8221; point of view.</p>
<p>phpMyAdmin :  I&#8217;d avoid this like the plague; it has had a million-and-one security flaws over the years and even if you got it cleaned up completely, it&#8217;s a vector of choice into your system.  Meaning attackers will be constantly looking to use it as a way into you system.  One look at your logs will show you that bots are scanning for it&#8217;s presence.</p>
<p>Turning off un-needed daemons : why install them to begin with?  It serves no purpose to install potential vulnerabilities if all your going to do is turn it off.  Since you&#8217;re starting with a fresh OS build, deselect all software you don&#8217;t need.  This narrows your attack surface and offers the added bonus of conserving resources.</p>
<p>Yum : as soon as you type that into your console you&#8217;ve lost any sense of security.  You have no idea where that software has come from, who packaged it, nor how it was built.  remember the great redhat gcc 2.96 issue?  They grabbed a developers snapshot of gcc (without gnu&#8217;s knowledge) and used it to build all their rpms for their redhat 8 release.  Over the next six months people everywhere were discovering corrupt tables in their mysql implementations with no way to recover.  The issue was eventually traced back to redhat&#8217;s rpms.  If you didn&#8217;t build it, don&#8217;t trust it! (secure is the goal, right?).  This gives you the added bonus of letting you remove pieces of the software that you don&#8217;t need, narrowing the attack surface.  Not going to offer CGI access?  Don&#8217;t even even compile in CGI capabilities.</p>
<p>MySQL : remove its networking capabilities and force it to work over unix domain sockets.  When you run &#8220;netstat -an | grep LISTEN&#8221;, you should NOT see 3306 as a bound port.  The DBMS is for the local hosting user&#8217;s, they don&#8217;t need to access the daemon from outside of the environment; and now, attackers can&#8217;t either.</p>
<p>VSFTP : is not very secure at all.  Your already supporting sshd, why not offer SFTP access?  You don&#8217;t need to add any extra software, you just need to enable it and add a couple rules to your firewall.  Now you&#8217;ll have end-to-end encryption, again, narrowing your attack surface.</p>
<p>Apache conf : turn off tokens (set to prod), don&#8217;t use * in the virtualhost; it&#8217;s a rare thing when you really want all sites gloaming onto all adapters.  More often then not you&#8217;ll want to restrict each container to a specific IP.</p>
<p>I hope you founf something helpful or useful in that.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ray Heffer</title>
		<link>http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/comment-page-1/#comment-3605</link>
		<dc:creator>Ray Heffer</dc:creator>
		<pubDate>Thu, 22 Sep 2011 08:41:30 +0000</pubDate>
		<guid isPermaLink="false">http://wp.rayheffer.com/?p=36#comment-3605</guid>
		<description>I think what the other post meant was they block port 80 outbound on non-established connections. In other words, http traffic that originates from your home connection. This prevents people running their own servers, but I&#039;m not sure which ISP&#039;s do this.

You only need port 80 inbound to your home for browsing.</description>
		<content:encoded><![CDATA[<p>I think what the other post meant was they block port 80 outbound on non-established connections. In other words, http traffic that originates from your home connection. This prevents people running their own servers, but I&#8217;m not sure which ISP&#8217;s do this.</p>
<p>You only need port 80 inbound to your home for browsing.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Frank Hooper</title>
		<link>http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/comment-page-1/#comment-3601</link>
		<dc:creator>Frank Hooper</dc:creator>
		<pubDate>Thu, 22 Sep 2011 00:33:33 +0000</pubDate>
		<guid isPermaLink="false">http://wp.rayheffer.com/?p=36#comment-3601</guid>
		<description>They block port 80, eh?  Hummm.  So you can&#039;t browse either?  LOL.</description>
		<content:encoded><![CDATA[<p>They block port 80, eh?  Hummm.  So you can&#8217;t browse either?  LOL.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ray Heffer</title>
		<link>http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/comment-page-1/#comment-3415</link>
		<dc:creator>Ray Heffer</dc:creator>
		<pubDate>Fri, 12 Aug 2011 08:27:05 +0000</pubDate>
		<guid isPermaLink="false">http://wp.rayheffer.com/?p=36#comment-3415</guid>
		<description>I&#039;m glad you found my site useful! :)</description>
		<content:encoded><![CDATA[<p>I&#8217;m glad you found my site useful! <img src='http://www.rayheffer.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tim D</title>
		<link>http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/comment-page-1/#comment-3412</link>
		<dc:creator>Tim D</dc:creator>
		<pubDate>Fri, 12 Aug 2011 03:32:06 +0000</pubDate>
		<guid isPermaLink="false">http://wp.rayheffer.com/?p=36#comment-3412</guid>
		<description>I am SO excited to have found your site.  I have been working on a new kickbutt cloud server for about 10 days straight.  I kept having to reimage it (centOS 5) b/c I kept screwing something up.  I tried imaging w/ plesk and w/ cpanel.  I hated cpanel whm and I ran into issues w/ plesk as it contained modified versions of php (no mcrypt which is required by magento!).  So I am now down bare CentOS install and going to use webmin and virtualmin.  Wish I would have found this 10 days ago.  Sure would have saved me alot of time!!!  Thank you :)</description>
		<content:encoded><![CDATA[<p>I am SO excited to have found your site.  I have been working on a new kickbutt cloud server for about 10 days straight.  I kept having to reimage it (centOS 5) b/c I kept screwing something up.  I tried imaging w/ plesk and w/ cpanel.  I hated cpanel whm and I ran into issues w/ plesk as it contained modified versions of php (no mcrypt which is required by magento!).  So I am now down bare CentOS install and going to use webmin and virtualmin.  Wish I would have found this 10 days ago.  Sure would have saved me alot of time!!!  Thank you <img src='http://www.rayheffer.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Damien</title>
		<link>http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/comment-page-1/#comment-947</link>
		<dc:creator>Damien</dc:creator>
		<pubDate>Thu, 09 Dec 2010 13:55:18 +0000</pubDate>
		<guid isPermaLink="false">http://wp.rayheffer.com/?p=36#comment-947</guid>
		<description>The list option for the chkconfig is used with 2 dashes in my case:
 #chkconfig --list&#124;grep on

Btw, I don&#039;t know all of the daemons you suggest to disable. Maybe I need some of them, or maybe some others can be turn off. Do you have a reference somewhere which will give us more information about those daemons ?</description>
		<content:encoded><![CDATA[<p>The list option for the chkconfig is used with 2 dashes in my case:<br />
 #chkconfig &#8211;list|grep on</p>
<p>Btw, I don&#8217;t know all of the daemons you suggest to disable. Maybe I need some of them, or maybe some others can be turn off. Do you have a reference somewhere which will give us more information about those daemons ?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ray Heffer</title>
		<link>http://www.rayheffer.com/36/building-a-secure-web-server-with-centos-5-part-1/comment-page-1/#comment-704</link>
		<dc:creator>Ray Heffer</dc:creator>
		<pubDate>Sat, 13 Nov 2010 18:14:48 +0000</pubDate>
		<guid isPermaLink="false">http://wp.rayheffer.com/?p=36#comment-704</guid>
		<description>I&#039;d strongly recommend using a virtual server with a provider like &lt;a href=&quot;http://www.linode.com/?r=6af02fe4285827f3bb09d52875f71dfa026d21f1&quot; rel=&quot;nofollow&quot;&gt;Linode&lt;/a&gt;, they don&#039;t block any ports and it&#039;s perfect for doing your own web hosting.</description>
		<content:encoded><![CDATA[<p>I&#8217;d strongly recommend using a virtual server with a provider like <a href="http://www.linode.com/?r=6af02fe4285827f3bb09d52875f71dfa026d21f1"  onclick="pageTracker._trackPageview('/outgoing/www.linode.com/?r=6af02fe4285827f3bb09d52875f71dfa026d21f1&amp;referer=');">Linode</a>, they don&#8217;t block any ports and it&#8217;s perfect for doing your own web hosting.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
<!-- WP Super Cache is installed but broken. The path to wp-cache-phase1.php in wp-content/advanced-cache.php must be fixed! -->
