How to Create a code against DDOS
Thứ Hai, 26 tháng 5, 2014
First
need to determine that the method by the anti-DDOS server language like
PHP, ASP, Java, C # ... will bring efficiency is not very high, because
most of the languages installed on the server mentioned above require
a resource (resource) to handle large server commands. CuaSoTinHoc
limited use method is quite simple DDOS not use the PHP language and is
not required to own the website server with root privileges.
The way we use simply by combining configuration file. Htaccess on hosting and a small fragment javascipt. ------------------------- - Configuration file. Htaccess - ------------------------- Options
+ FollowSymlinksRewriteEngine onRewriteCond% {HTTP_REFERER}! ^ Http
(s)? :/ / (Www \.)? Your_web_site.com [NC] RewriteRule ^ (. *). (Php |
html | asp | htm) antiddos.htm [ NC] ------------------------- The
codes on the system to help handle the links are introduced (referer)
from cuasotinhoc.com, which means when a link is typed directly from the
browser or from a DDOS program or from a different domain, the system
system will not handle any more conventional way that will bring about a
specific processing site, which is here antiddos.htm page. Field 1: mean serial path. Field 2: turn on the engine to service records identifying referer. Field 3: referer from cuasotinhoc.com regulations. Field 4: put the file antiddos.htm law. ---------------------------- - Configuration file antiddos.htm - ---------------------------- In antiddos.htm file we'll use a little JavaScript to production line: var = this.document.URL currUrl; newUrl var = currUrl.replace ('#', '?') var re = / CODE / var chk = re.test (currUrl); if (chk == 1) { this.document.write
("class='story_text'> align='center'> <a
href='"+newUrl+"&' target='_self'> [Click here to view the
contents] </ a> </ div>" ); } else { this.document.write
("class='story_text'> align='center'> <a href='"+newUrl+"?'
target='_self'> [Click here to view the contents] </ a> </
div>" ); } So
to configure. Htaccess and javascript as restrictions on our most
common programs Flash DDOS attacks on MySQL, and with the way system
resources are used very little, because the language. htaccess file on
the server and language fragment is large javacript on. =============================================== It
remains to be confirmed that this method is only temporary, and there
are errors, as evidenced by the ability to quick edit Firefox unusable
by the "effects" of the referer. 2 immediate need to develop problem: 1. Doing so real server activity referer function effectively. To us from adding useless characters like "?", "&" To the new link. 2. Necessary to study a DDOS against other methods without having to take out a full page antiddos.htm offensive.
All comments [ 0 ]
Your comments