<?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>Autarchy of the Private Cave &#187; dewlance</title> <atom:link href="https://bogdan.org.ua/tags/dewlance/feed" rel="self" type="application/rss+xml" /><link>https://bogdan.org.ua</link> <description>Tiny bits of bioinformatics, [web-]programming etc</description> <lastBuildDate>Wed, 28 Dec 2022 16:09:04 +0000</lastBuildDate> <language>en-US</language> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>https://wordpress.org/?v=3.8.27</generator> <item><title>Blatant dewlance.com SEO, thrustvps, and HEAD attacks</title><link>https://bogdan.org.ua/2010/11/06/blatant-dewlance-seo-thrustvps-and-head-attacks.html</link> <comments>https://bogdan.org.ua/2010/11/06/blatant-dewlance-seo-thrustvps-and-head-attacks.html#comments</comments> <pubDate>Sat, 06 Nov 2010 02:42:35 +0000</pubDate> <dc:creator><![CDATA[Bogdan]]></dc:creator> <category><![CDATA[Misc]]></category> <category><![CDATA[Web]]></category> <category><![CDATA[attack]]></category> <category><![CDATA[blatant]]></category> <category><![CDATA[cheap]]></category> <category><![CDATA[dewlance]]></category> <category><![CDATA[HEAD]]></category> <category><![CDATA[IP]]></category> <category><![CDATA[poor]]></category> <category><![CDATA[SEO]]></category> <category><![CDATA[thrustvps]]></category> <category><![CDATA[ugly]]></category> <guid
isPermaLink="false">http://bogdan.org.ua/?p=1189</guid> <description><![CDATA[Update 4: there are claims that these HEAD-attacks were coming from a malicious dewlance.com customer, and have nothing to do with dewlance itself. Noticing weird narrow spikes in server load graph, I decided to investigate the most recent one &#8211; at 03:50 GMT+2 on Nov. 6, 2010. The reason was simple: someone issued a few [&#8230;]]]></description> <content:encoded><![CDATA[<p><ins
datetime="2010-11-11T10:55:10+00:00">Update 4: there are <a
href="http://bogdan.org.ua/2010/11/06/blatant-dewlance-seo-thrustvps-and-head-attacks.html#comment-120235">claims</a> that these HEAD-attacks were coming from a malicious dewlance.com customer, and have nothing to do with dewlance itself.</ins></p><p>Noticing weird narrow spikes in server load graph, I decided to investigate the most recent one &#8211; at 03:50 GMT+2 on Nov. 6, 2010.</p><p>The reason was simple: someone issued a few hundred HEAD-requests over a 30 second period to a PHP-based web-application.</p><p>All the requests were coming from IP <strong>109.169.59.139</strong>, which belongs to the IP range of thrustvps.com:</p><blockquote><p> inetnum:        109.169.58.0 &#8211; 109.169.59.255<br
/> netname:        ThrustVPS_1<br
/> descr:          Thrust::VPS<br
/> country:        US<br
/> admin-c:        RF5058-RIPE<br
/> tech-c:         RF5058-RIPE<br
/> status:         ASSIGNED PA<br
/> mnt-by:         RAPIDSWITCH-MNT</p></blockquote><p>However, it is the <em>referrer</em> string which is more interesting: in all those requests, decorated with varying UserAgents and even operating systems, there was only one referrer &#8211; www.dewlance.com.</p><p>Initially I thought that was a test of a new DoS attack &#8211; really, who would issue dozens of HEAD requests to the same page over a few seconds? However, after seeing that &#8220;referrer&#8221; string, I now think this is a cheap, blatant, poor and ugly <abbr="search engine optimization">SEO</abbr> performed by dewlance. It relies on some sites displaying a box of &#8216;recent visitors&#8217;, sometimes including their referrer URL as a &#8220;page where this visitor came from&#8221; &#8211; this would give dewlance.com some free link-love. Or maybe dewlance.com expects administrators to investigate log files, notice that referrer string, and happily order some services from dewlance? No way <img
src="https://bogdan.org.ua/wp-includes/images/smilies/icon_smile.gif" alt=":)" class="wp-smiley" /></p><p>I&#8217;ll file a complaint with thrustvps if I see that kind of misbehaviour again. All that started on Nov. 4, so there&#8217;s still hope people behind this dumb SEO implementation will get fired.</p><p><ins
datetime="2010-11-07T19:40:02+00:00">Update 1</ins>: they do this every 4 hours since November 4, 2010 (Thursday). This results in loads up to 22, with ~50 apache processes struggling for a few CPU cores:<br
/> <span
id="more-1189"></span><br
/> <a
href="http://bogdan.org.ua/wp-content/uploads/2010/11/dewlance-head.png"><img
src="http://bogdan.org.ua/wp-content/uploads/2010/11/dewlance-head-500x130.png" alt="" title="load graph, dewlance spikes every 4 hours" width="500" height="130" class="alignleft size-medium wp-image-1195" /></a><br
/> <a
href="http://bogdan.org.ua/wp-content/uploads/2010/11/loads.png"><img
src="http://bogdan.org.ua/wp-content/uploads/2010/11/loads-500x53.png" alt="" title="loads" width="500" height="53" class="alignleft size-medium wp-image-1196" /></a></p><p><ins
datetime="2010-11-08T15:30:02+00:00">Update 2</ins>: some 20 hours after sending report to abuse at thrustvps.com nothing has changed &#8211; still a bunch of HEAD requests every 4 hours. I have written a fail2ban filter+rule to ban anything issuing more than about 1 HEAD request per second. If that rule works as expected &#8211; I&#8217;ll publish it here.</p><p><ins
datetime="2010-11-09T16:46:14+00:00">Update 3</ins>: the last HEAD request referring to dewlance occurred at 12:23 GMT on November 8, 2010. I have no idea if that was my complaint, or if that &#8220;experiment&#8221; just ended naturally.</p><p>I have been testing fail2ban rule for false-positives, and it now seems OK. However, I haven&#8217;t tested for true positives &#8211; I do not know if it will actually block extra HEAD requests (it should).</p><p>Put the fragment below into your /etc/fail2ban/jail.local (edit logpath to match your apache logs):</p><blockquote><p> [head-dos]<br
/> enabled = true<br
/> port    = http,https<br
/> filter  = head-dos<br
/> logpath = /var/log/apache2/other_vhosts_access.log<br
/> maxretry = 8<br
/> findtime = 6<br
/> #ban for 25 hours<br
/> bantime = 90000<br
/> action = %(action_mwl)s</p></blockquote><p>I recommend leaving action as specified for a few weeks to see if you aren&#8217;t blocking legitimate requests.</p><p>Also paste the fragment below into /etc/fail2ban/filter.d/head-dos.conf:</p><blockquote><p> # Fail2Ban configuration file<br
/> #<br
/> # Author: bogdan.org.ua<br
/> #</p><p>[Definition]</p><p># Option:  failregex<br
/> # Note: this regex matches *any* HEAD requests; together with a maxretry=8 and findtime=6 (for example)<br
/> # this rule should ban anything issuing more than ~1 HEAD request per second.<br
/> #<br
/> # sample matching entry:<br
/> # bogdan.org.ua:80 109.169.59.139 &#8211; - [07/Nov/2010:04:38:33 +0200] &#8220;HEAD /2009/10/27/search-and-replace-in-a-mysql-table.html HTTP/1.0&#8243; 200 &#8211; &#8220;http://www.dewlance.com&#8221; &#8220;Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/532.2 (KHTML, like Gecko) Chrome/4.0.221.7 Safari/532.2&#8243;<br
/> #</p><p>failregex = ^[^ ]+ <HOST> -.*&#8221;HEAD /.*$</p><p># Option:  ignoreregex<br
/> # Notes.:  regex to ignore. If this regex matches, the line is ignored.<br
/> # Values:  TEXT<br
/> #<br
/> ignoreregex =</p></blockquote><p><ins
datetime="2010-12-09T08:46:22+00:00">Update:</ins> this rule does work. There were a few false-positives over 2 weeks of testing, so you may need to tune number of requests and time period. After the initial HEAD attacks I&#8217;ve seen there were more of these, with other referrer strings &#8211; but always a website URL.</p><p>Please comment to report improvements/enhancements and problems you&#8217;ve encountered with this rule.</p><p><a
class="a2a_button_citeulike" href="https://www.addtoany.com/add_to/citeulike?linkurl=https%3A%2F%2Fbogdan.org.ua%2F2010%2F11%2F06%2Fblatant-dewlance-seo-thrustvps-and-head-attacks.html&amp;linkname=Blatant%20dewlance.com%20SEO%2C%20thrustvps%2C%20and%20HEAD%20attacks" title="CiteULike" rel="nofollow noopener" target="_blank"></a><a
class="a2a_button_pocket" href="https://www.addtoany.com/add_to/pocket?linkurl=https%3A%2F%2Fbogdan.org.ua%2F2010%2F11%2F06%2Fblatant-dewlance-seo-thrustvps-and-head-attacks.html&amp;linkname=Blatant%20dewlance.com%20SEO%2C%20thrustvps%2C%20and%20HEAD%20attacks" title="Pocket" rel="nofollow noopener" target="_blank"></a><a
class="a2a_button_kindle_it" href="https://www.addtoany.com/add_to/kindle_it?linkurl=https%3A%2F%2Fbogdan.org.ua%2F2010%2F11%2F06%2Fblatant-dewlance-seo-thrustvps-and-head-attacks.html&amp;linkname=Blatant%20dewlance.com%20SEO%2C%20thrustvps%2C%20and%20HEAD%20attacks" title="Kindle It" rel="nofollow noopener" target="_blank"></a><a
class="a2a_button_evernote" href="https://www.addtoany.com/add_to/evernote?linkurl=https%3A%2F%2Fbogdan.org.ua%2F2010%2F11%2F06%2Fblatant-dewlance-seo-thrustvps-and-head-attacks.html&amp;linkname=Blatant%20dewlance.com%20SEO%2C%20thrustvps%2C%20and%20HEAD%20attacks" title="Evernote" rel="nofollow noopener" target="_blank"></a><a
class="a2a_button_pinterest" href="https://www.addtoany.com/add_to/pinterest?linkurl=https%3A%2F%2Fbogdan.org.ua%2F2010%2F11%2F06%2Fblatant-dewlance-seo-thrustvps-and-head-attacks.html&amp;linkname=Blatant%20dewlance.com%20SEO%2C%20thrustvps%2C%20and%20HEAD%20attacks" title="Pinterest" rel="nofollow noopener" target="_blank"></a><a
class="a2a_dd addtoany_share_save addtoany_share" href="https://www.addtoany.com/share#url=https%3A%2F%2Fbogdan.org.ua%2F2010%2F11%2F06%2Fblatant-dewlance-seo-thrustvps-and-head-attacks.html&#038;title=Blatant%20dewlance.com%20SEO%2C%20thrustvps%2C%20and%20HEAD%20attacks" data-a2a-url="https://bogdan.org.ua/2010/11/06/blatant-dewlance-seo-thrustvps-and-head-attacks.html" data-a2a-title="Blatant dewlance.com SEO, thrustvps, and HEAD attacks"><img
src="https://static.addtoany.com/buttons/share_save_120_16.png" alt="Share"></a></p>]]></content:encoded> <wfw:commentRss>https://bogdan.org.ua/2010/11/06/blatant-dewlance-seo-thrustvps-and-head-attacks.html/feed</wfw:commentRss> <slash:comments>8</slash:comments> </item> </channel> </rss>