{"id":594,"date":"2007-05-01T10:41:14","date_gmt":"2007-05-01T08:41:14","guid":{"rendered":"http:\/\/planetozh.com\/blog\/2007\/05\/some-fun-with-script-kiddies\/"},"modified":"2007-05-22T16:19:43","modified_gmt":"2007-05-22T14:19:43","slug":"some-fun-with-script-kiddies","status":"publish","type":"post","link":"https:\/\/planetozh.com\/blog\/2007\/05\/some-fun-with-script-kiddies\/","title":{"rendered":"Some Fun with Script Kiddies"},"content":{"rendered":"<p>One of the things you have to pay attention to when you move your website to another host is correct redirection to pages, and ensuring you&#39;re not giving 404 errors to legitimate requests. This morning I was checking my error logs and noticed a lot of pathetic attempts from <a href=\"http:\/\/en.wikipedia.org\/wiki\/Script_kiddie\">script kiddies<\/a> looking for an easy security hole to exploit :<\/p>\n<div id=\"ig-sh-1\" class=\"syntax_hilite\">\n\n\t\t<div class=\"toolbar\">\n\n\t\t<div class=\"view-different-container\">\n\t\t\t\t\t\t<a href=\"#\" class=\"view-different\">&lt; View <span>plain text<\/span> &gt;<\/a>\n\t\t\t\t\t<\/div>\n\n\t\t<div class=\"language-name\">code<\/div>\n\n\t\t\n\t\t<br clear=\"both\">\n\n\t<\/div>\n\t\n\t<div class=\"code\">\n\t\t<ol class=\"code\" style=\"font-family:monospace\"><li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">[client 212.67.208.152] File does not exist: \/home\/ozh\/planetozh.com\/\/admin\/plugins\/NP_UserSharing.php<\/div><\/li>\n<li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">(...)<\/div><\/li>\n<li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">[client 216.193.194.224] File does not exist: \/home\/ozh\/planetozh.com\/admin\/doeditconfig.php<\/div><\/li>\n<li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">(...)<\/div><\/li>\n<li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">[client 203.187.132.50] File does not exist: \/home\/ozh\/planetozh.com\/_vti_bin\/owssvr.dll<\/div><\/li>\n<li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">[client 203.187.132.50] File does not exist: \/home\/ozh\/planetozh.com\/MSOffice\/cltreq.asp<\/div><\/li>\n<\/ol>\t<\/div>\n\n<\/div>\n\n<p>The most popular attempt seems to be the <em>doeditconfig.php<\/em> one, with roughly a request every 5 minutes.<br \/>\nI honestly don&#39;t give a sh*t about those things, but why not try to have some fun with them in return ?<\/p>\n<p>First, I looked for the biggest file I could find on the internet. A <a href=\"http:\/\/mirrors.usc.edu\/pub\/linux\/distributions\/debian-cd\/current\/i386\/iso-dvd\/debian-40r0-i386-DVD-1.iso\">4.4 Gb<\/a> Debian DVD image seemed to be big enough.<\/p>\n<p>Then, time for a little mod_rewrite prank, in the <em>.htaccess<\/em> file sitting in my root I added the following lines :<\/p>\n<div id=\"ig-sh-2\" class=\"syntax_hilite\">\n\n\t\t<div class=\"toolbar\">\n\n\t\t<div class=\"view-different-container\">\n\t\t\t\t\t\t<a href=\"#\" class=\"view-different\">&lt; View <span>plain text<\/span> &gt;<\/a>\n\t\t\t\t\t<\/div>\n\n\t\t<div class=\"language-name\">code<\/div>\n\n\t\t\n\t\t<br clear=\"both\">\n\n\t<\/div>\n\t\n\t<div class=\"code\">\n\t\t<ol class=\"code\" style=\"font-family:monospace\"><li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">RewriteEngine &nbsp;on<\/div><\/li>\n<li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">RewriteBase \/<\/div><\/li>\n<li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">RewriteRule ^admin\/doeditconfig.php$ \/exit\/bigfile [L]<\/div><\/li>\n<li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">RewriteRule ^MSOffice\/cltreq.asp$ \/exit\/bigfile [L]<\/div><\/li>\n<li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">RewriteRule ^\/_vti_bin\/owssvr.dll$ \/exit\/bigfile [L]<\/div><\/li>\n<li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">RewriteRule ^\/admin\/plugins\/NP_UserSharing.php$ \/exit\/bigfile [L]<\/div><\/li>\n<li style=\"font-weight: normal;vertical-align:top\"><div style=\"font: normal normal 1em\/1.2em monospace;margin:0;padding:0;background:none;vertical-align:top\">RewriteRule ^\/phorum\/plugin\/replace\/plugin.php$ \/exit\/bigfile [L]<\/div><\/li>\n<\/ol>\t<\/div>\n\n<\/div>\n\n<p>File <em>\/exit\/bigfile<\/em> is just a log-then-redirect-to-big-DVD-iso PHP script.<\/p>\n<p>I&#39;m not sure how effective this will be : maybe script kiddie tools don&#39;t follow redirections, or look for particular header responses. But hopefully I will waste a few megabytes of some morons&#39; bandwidth :)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>One of the things you have to pay attention to when you move your website to another host is correct redirection to pages, and ensuring you&#39;re not giving 404 errors to legitimate requests. This morning I was checking my error logs and noticed a lot of pathetic attempts from script kiddies looking for an easy [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[15,56,2,206,196,194,195,61],"class_list":["post-594","post","type-post","status-publish","format-standard","hentry","tag-ahah","tag-apache","tag-code","tag-doeditconfig","tag-hax0rz","tag-htaccess","tag-mod_rewrite","tag-sux0rz"],"_links":{"self":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/posts\/594","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/comments?post=594"}],"version-history":[{"count":0,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/posts\/594\/revisions"}],"wp:attachment":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/media?parent=594"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/categories?post=594"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/tags?post=594"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}