if($cfg_anquan_cc == 'Y'){ //php防CC攻擊 在3秒內(nèi)連續(xù)刷新頁面5次以上將指向本機(jī) http://dedecms51.com/404.htm $P_S_T = $t_array[0] + $t_array[1]; $timest amp = time(); session_start(); $ll_nowtime = $timestamp ; if (session_is_registered('ll_lasttime')){ $ll_lasttime = $_SESSION['ll_lasttime']; $ll_times = $_SESSION['ll_times'] + 1; $_SESSION['ll_times'] = $ll_times; }else{ $ll_lasttime = $ll_nowtime; $ll_times = 1; $_SESSION['ll_times'] = $ll_times; $_SESSION['ll_lasttime'] = $ll_lasttime; } if (($ll_nowtime - $ll_lasttime)<3){ if ($ll_times>=5){ header(sprintf("Location: %s",'http://www.copyie.com/404.htm')); exit; } }else{ $ll_times = 0; $_SESSION['ll_lasttime'] = $ll_nowtime; $_SESSION['ll_times'] = $ll_times; } } |
版權(quán)聲明: 本站資源均來自互聯(lián)網(wǎng)或會員發(fā)布,如果侵犯了您的權(quán)益請與我們聯(lián)系,我們將在24小時(shí)內(nèi)刪除!謝謝!
轉(zhuǎn)載請注明: 怎么樣防止針對織夢dede源碼網(wǎng)站的DDos攻擊?