<?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>American Butifarra &#187; Apache</title> <atom:link href="http://claude.betancourt.us/tag/apache/feed/" rel="self" type="application/rss+xml" /><link>http://claude.betancourt.us</link> <description>Claude Betancourt&#039;s Personal Blog</description> <lastBuildDate>Fri, 16 Dec 2011 02:43:25 +0000</lastBuildDate> <language>en</language> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.3.1</generator> <item><title>Stop &#8216;Apache Killer&#8217; in its tracks</title><link>http://claude.betancourt.us/stop-apache-killer-in-its-tracks/</link> <comments>http://claude.betancourt.us/stop-apache-killer-in-its-tracks/#comments</comments> <pubDate>Thu, 25 Aug 2011 03:47:44 +0000</pubDate> <dc:creator>Claude</dc:creator> <category><![CDATA[How-To]]></category> <category><![CDATA[Platform]]></category> <category><![CDATA[Security]]></category> <category><![CDATA[Apache]]></category> <category><![CDATA[Rewrite]]></category><guid isPermaLink="false">http://claude.betancourt.us/?p=861</guid> <description><![CDATA[Protect your Apache server from the latest vulnerability exploit with a simple rule. <a href="http://claude.betancourt.us/stop-apache-killer-in-its-tracks/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description> <content:encoded><![CDATA[<p>As you may have heard, a new Apache attack tool was released on Friday. The tool, named Apache Killer, is able to create a denial-of-service attack by overloading the web server with partial requests for content. As the web server attempts to fulfill the requests it begins to run out of and memory and it crashes. The problem is exacerbated when larger files are requested (PDFs, zips, etc.) as the server must fulfill the entire request while it attempts to deliver just a portion of it.</p><h3>Testing &#8216;Apache Killer&#8217;</h3><p>I ran the tool to attack this server as well as my employer&#8217;s load balanced array of servers. It is clear that only those servers running an older version of Apache (i.e. 1.3) and those not protected by a firewall are at risk.</p><p>My underpowered virtual private server crashed just a few seconds after the attack began. The tool revealed that my employer&#8217;s web sites did not appear to be vulnerable.</p><h3>Is there a solution?</h3><p>While a solution from Apache.org has not been published, some of the contributors have identified the issue and are working on a patch. In the meantime, you can add the following rule to your virtual site definitions, if you own your sever, or <code>.htaccess</code> file if you&#8217;re in a shared-hosting environment.</p><pre class="brush: plain; title: ; notranslate">
&lt;IfModule mod_rewrite.c&gt;
RewriteEngine On
RewriteCond %{REQUEST_METHOD} ^(HEAD|GET) [NC]
RewriteCond %{HTTP:Range} ([0-9]*-[0-9]*)(\s*,\s*[0-9]*-[0-9]*)+
RewriteRule .* - [F]
&lt;/IfModule&gt;
</pre><p>The preceding rule blocks &#8220;<a href="http://seclists.org/fulldisclosure/2011/Aug/241">get and head requests with multiple ranges in the Range HTTP header</a>.&#8221;</p><p>After applying this rule, feel free to attempt to kill your server, it will not crash. You should inspect your traffic logs to verify the incoming traffic is denied access with an HTTP status of 403, or forbidden.</p><p>Dirk-Willem van Gulik from <a href="http://mail-archives.apache.org/mod_mbox/httpd-announce/201108.mbox/%3C20110824161640.122D387DD@minotaur.apache.org%3E">Apache published this workaround</a> for versions 2.0 and 2.2:</p><pre class="brush: plain; title: ; notranslate">
&lt;IfModule mod_setenvif.c&gt;
# Drop the Range header when more than 5 ranges.
# CVE-2011-3192
SetEnvIf Range (,.*?){5,} bad-range=1
RequestHeader unset Range env=bad-range

# optional logging.
CustomLog logs/range-CVE-2011-3192.log common env=bad-range
&lt;/IfModule&gt;
</pre>]]></content:encoded> <wfw:commentRss>http://claude.betancourt.us/stop-apache-killer-in-its-tracks/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Upgrade and Secure WordPress</title><link>http://claude.betancourt.us/upgrade-and-secure-wordpress-dont-wait-for-heart-surgery/</link> <comments>http://claude.betancourt.us/upgrade-and-secure-wordpress-dont-wait-for-heart-surgery/#comments</comments> <pubDate>Sun, 06 Sep 2009 20:01:49 +0000</pubDate> <dc:creator>Claude</dc:creator> <category><![CDATA[Security]]></category> <category><![CDATA[WordPress]]></category> <category><![CDATA[Apache]]></category> <category><![CDATA[htaccess]]></category> <category><![CDATA[IIS]]></category> <category><![CDATA[Wordpress]]></category> <category><![CDATA[Worm]]></category><guid isPermaLink="false">http://claude.betancourt.us/?p=671</guid> <description><![CDATA[There is a worm making its way around old, unpatched versions of WordPress. Here's how to avoid getting infected. <a href="http://claude.betancourt.us/upgrade-and-secure-wordpress-dont-wait-for-heart-surgery/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description> <content:encoded><![CDATA[<p><span class="drop_cap">M</span>att Mullenweg <a href="http://wordpress.org/development/2009/09/keep-wordpress-secure/">reported the following</a>:</p><blockquote><p>Right now there is a worm making its way around old, unpatched versions of WordPress. This particular worm, like many before it, is clever: it registers a user, uses a security bug (fixed earlier in the year) to allow evaluated code to be executed through the permalink structure, makes itself an admin, then uses JavaScript to hide itself when you look at users page, attempts to clean up after itself, then goes quiet so you never notice while it inserts hidden spam and malware into your old posts.</p></blockquote><p>Here are two quick steps to avoid unnecessary risks:</p><h3>Turn off user registration</h3><p>This one is simple. Just log in to your administrator screen and visit the &#8220;General Settings&#8221; screen (listed under Settings) and make sure the checkbox labeled &#8220;Anyone can register&#8221; is not checked.</p><h3>Block access to your blog&#8217;s admin area</h3><p>This can be accomplished with simple authentication.</p><p>If your site runs on Apache, you can create an <strong>.htaccess</strong> file in your <code>/wp-admin/</code> directory to require authentication before the page is displayed. <a href="http://spiralbound.net/2005/08/03/quick-and-easy-apache-password-protection">This post</a> provides the necessary steps.</p> ]]></content:encoded> <wfw:commentRss>http://claude.betancourt.us/upgrade-and-secure-wordpress-dont-wait-for-heart-surgery/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Force a URL to Use HTTPS</title><link>http://claude.betancourt.us/how-to-force-a-url-to-use-https/</link> <comments>http://claude.betancourt.us/how-to-force-a-url-to-use-https/#comments</comments> <pubDate>Sat, 28 Feb 2009 03:02:55 +0000</pubDate> <dc:creator>Claude</dc:creator> <category><![CDATA[How-To]]></category> <category><![CDATA[Protocol]]></category> <category><![CDATA[Security]]></category> <category><![CDATA[Apache]]></category> <category><![CDATA[ColdFusion]]></category> <category><![CDATA[IIS]]></category> <category><![CDATA[MachII]]></category> <category><![CDATA[plugin]]></category> <category><![CDATA[Rewrite]]></category><guid isPermaLink="false">http://claude.betancourt.us/?p=385</guid> <description><![CDATA[Site owners sometimes need to make sure secure connections are used. They can do this quickly with this Apache rule. <a href="http://claude.betancourt.us/how-to-force-a-url-to-use-https/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description> <content:encoded><![CDATA[<p><span class="drop_cap">T</span>oday I came across some old ColdFusion <span class="amp">&#038;</span> Mach-II (1.0) code where a plugin was used to force HTTPS. I assume the original developer decided to go with this solution because the target environment was Windows and Internet Information Server.</p><p>The task becomes a lot easier under Apache. So I threw away the plugin code and added the following rule to the Apache configuration:</p><pre class="brush: xml; title: ; notranslate">
&lt;directory &quot;/public_html/mysite.com&quot;&gt;
RewriteEngine on
RewriteCond %{HTTPS} !=on
RewriteRule ^(.*) https://%{HTTP_HOST}/$1	[R,L]
&lt;/directory&gt;
</pre><p class="alert">The directive above can be placed inside a <span class="amp">VirtualHost</span> or <span class="amp">Directory</span> directives, but this usually requires access to the Apache server configuration, which is not typically possible in a shared hosting environment &#8212; in that case, the rule can be added to the <span class="amp">.htaccess</span> file.</p><p>Alternatively we could have used the <a href="http://httpd.apache.org/docs/2.2/mod/mod_ssl.html#sslrequiressl">SSLRequireSSL Apache (2.x) directive</a>, but this would only block access to the non HTTPS address. In our case we want to automatically redirect the users instead of displaying an error message.</p> ]]></content:encoded> <wfw:commentRss>http://claude.betancourt.us/how-to-force-a-url-to-use-https/feed/</wfw:commentRss> <slash:comments>2</slash:comments> </item> </channel> </rss>
<!-- Served from: claude.betancourt.us @ 2012-02-07 14:39:10 by W3 Total Cache -->
