• Downloading from our site will require you to have a paid membership. Upgrade to a Premium Membership from 10$ a month today!

    Dont forget read our Rules! Also anyone caught Sharing this content will be banned. By using this site you are agreeing to our rules so read them. Saying I did not know is simply not an excuse! You have been warned.

Một code anti DDOS đơn giản nhưng hiểu quả

Admin

Well-Known Member
Staff member
Administrator
PHP:
<?php 
session_start(); 
$limit = 1; // thoi gian (s) han che giua hai lan truy cap 
$delay = 2; // thoi gian (s) phai cho de load trang 
$last = ($_SESSION['time'] == NULL) ? 0 : $_SESSION['time']; 
$_SESSION['time'] = time(); 
if ( $limit >= (time() - $last) ) { 
   echo '   <html> 
         <head> 
         <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> 
         <meta http-equiv="Refresh" Content="'.$delay.'; url='.$_SERVER["REQUEST_URI"].'"> 
         </head> 
         <title>:: Loading ... ::</title> 
Loading..............
         </html>'; 
   exit(0); 
} 
?>
 
Đây

<?php
session_start();
$limit = 1; // thoi gian (s) han che giua hai lan truy cap
$delay = 2; // thoi gian (s) phai cho de load trang
$last = ($_SESSION['time'] == NULL) ? 0 : $_SESSION['time'];
$_SESSION['time'] = time();
if ( $limit >= (time() - $last) ) {
echo ' <html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Refresh" Content="'.$delay.'; url='.$_SERVER["REQUEST_URI"].'">
</head>
<title>:: Loading ... ::</title>
Loading..............
</html>';
exit(0);
}
?>
 
Đầu index.php em nhé...
 
Up top phải cái top này không anh admin nếu phải anh chỉ em chi tiết tí nhá anh biết em rồi đó
 
...Cái này cũng đc...

----------> Bổ sung bài viết lúc 22:42 <----------> Bài viết trước lúc 22:42 <----------

Em xem kỹ chủ đề tương tự nhé
 
Nếu được anh chỉ em pass vào chỗ nào cụ thể nha anh :khakha
 
Em paste vào chỗ nào muốn chống ddos nhé

----------> Bổ sung bài viết lúc 12:21 <----------> Bài viết trước lúc 12:20 <----------

Anh khuyên em dùng cái này Anti ddos bằng htaccess
 

Facebook Comments

Similar threads

New posts New threads New resources

Back
Top