Đây là phiên bản Lite của tường lửa trên forum mà Shacker đang dùng. Nó tương thích với hầu hết tất cả các loại forum và website (php) nên bên cạnh vBulletin, bạn có thể áp dụng nó cho nhiều hệ thống php khác nhau.
Mẫu
i - Chuẩn bị
Bạn tải bộ style và images của Firewall theo attachment Shacker đã đính kèm bên dưới. Password là
delynie.silveryhat.com
+ Sau khi tải xong bạn giải nén và upload lên đường dẫn chính của forum, ví dụ:
-
[Bạn phải là thành viên mới thấy được link. ]
hoặc
-
[Bạn phải là thành viên mới thấy được link. ]
+ Tùy vào vị trí bạn cài đặt forum của mình, của Shacker là
[Bạn phải là thành viên mới thấy được link. ]
Vậy là phần chuẩn bị đã hoàn tất.
i - Cài đặt
Mở tập tin global.php, tìm:
thêm vào sau đó
PHP Code:
session_start (); $URL_OF_FORUM = 'http://www.silveryhat.com' ; $TEN_COOKIE = 'dnp_firewall' ; if ( strstr ( $HTTP_SERVER_VARS [ 'HTTP_USER_AGENT' ] , 'Googlebot' )|| strstr ( $HTTP_SERVER_VARS [ 'HTTP_USER_AGENT' ] , 'msnbot' )|| strstr ( $HTTP_SERVER_VARS [ 'HTTP_USER_AGENT' ] , 'slurp' )) {} else{ if( file_exists ( $firewall ) ){ require_once( $firewall );} if(( strpos ( $_SERVER [ 'HTTP_REFERER' ], $URL_OF_FORUM ) !== 0 ) || ( strpos ( $_SERVER [ 'HTTP_REFERER' ], $URL_OF_FORUM ) !== 0 ) || ( strpos ( $_SERVER [ 'HTTP_REFERER' ], $URL_OF_FORUM ) !== 0 ) ) { if (empty( $HTTP_SESSION_VARS [ '{$TEN_COOKIE}' ])) { if (!empty( $HTTP_POST_VARS [ '{$TEN_COOKIE}' ])) { session_register ( '{$TEN_COOKIE}' ); $HTTP_SESSION_VARS [ '{$TEN_COOKIE}' ]= 'myforum_protection' ; header ( "location: " . $_SERVER [ 'REQUEST_URI' ]); exit(); } $sform = '<!DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd> <html xmlns=http://www.w3.org/1999/xhtml> <head> <meta http-equiv=Content-Type content=text/html; charset=utf-8 /> <meta name="keywords" content="silvery hat hacker, delynie, ngoc diem, hack mod cho forum, invisionfree, phpbb2, vbb, vbulletin, ipb, web design, hack mod, modification, shacker, dnp, sh, mu bac" /> <meta name="description" content="Vietnamese American\'s Community, Website Development, Forum, Hack Mod, Shacker, Silvery Hat Hacker, DnP" /> <title>Protection Gate Lite v0.4 by Silvery Hat Hacker</title> <link href=dnp_style.php rel=stylesheet type=text/css /> <script language=JavaScript><!-- //Anti-right click for all broswers by Shacker © 2006 //Redistributed for Vn communities by delynie.silveryhat.com var message="";function clickIE() {if (document.all) {(message);return false;}}function clickNS(e) {if (document.layers||(document.getElementById&&!document.all)) {if (e.which==2||e.which==3) {(message);return false;}}}if (document.layers) {document.captureEvents(Event.MOUSEDOWN);document.onmousedown=clickNS;}else{document.onmouseup=clickNS;document.oncontextmenu=clickIE;document.onselectstart=clickIE}document.oncontextmenu=new Function("return false") // --> </script> </head> <body background="img/clean_orange_crystalxp_1600.jpg"> <table border=0 height=600 width=100%> <tr><td align=center valign=middle> <table width=468 class="table" align="center" border="0" cellpadding="0" cellspacing="0"> <tr><td height=25 width=35 class="tcat" colspan="0" align=center valign="middle"><img src="img/internet.gif"></td> <td class="tcat" colspan="0" align=left width=318><STRONG>Forum Protection Gate Lite v0.4</STRONG></td> <td class="tcat" colspan="0" align=center width=115> </td></tr> <tr><td colspan=3 height="25" id=Des align=center><strong style="color:#000066"> Press the button below to access to the forum</strong> </td> <tr><td colspan=3 align=center bgcolor=#F7F7F7 class="vienall" style=filter:Alpha(Opacity:90);cursor:default><img src="img/home.jpg" border=0 title="Firewall Layout Designed by Silvery Hat Hacker"/> </td></tr> <form name=sercform method=POST action=' . $_SERVER [ 'REQUEST_URI' ]. '> <tr><td height=25 colspan=3 align=center class="tbottom"> <input type=submit value="Enter" size=6 style=cursor:pointer name=shfirewall class=button></td></tr></form> </table></div></td></tr> <tr><td align=right><a href="http://delynie.silveryhat.com" target=_blank>Silvery Hat Hacker</a> © 2007<BR>DnP Community</td></tr> <tr><td align=right><a href="img/direction.jpg" target="_blank"><b>Can\'t access the forum because of Zone Alarm?</b></s></td></tr> </table> </body></html> ' ; echo $sform ; exit(); } } }
Bạn lưu ý 2 biến ở đầu đoạn mã trên
PHP Code:
$URL_OF_FORUM = 'http://www.silveryhat.com' ; $TEN_COOKIE = 'dnp_firewall' ;
Hãy thay đổi lại cho thích hợp với diễn đàn bạn. Sau đó save và upload tập tin global.php lên host.
Nếu gặp lỗi, chỉ vào dc khi có www hoặc không có www thì làm theo bước sau. Tìm:
PHP Code:
$URL_OF_FORUM = 'http://www.silveryhat.com' ;
Thay =:
PHP Code:
$URL_OF_FORUM = 'silveryhat.com' ;
Tìm:
PHP Code:
if(( strpos ( $_SERVER [ 'HTTP_REFERER' ], $URL_OF_FORUM ) !== 0 ) || ( strpos ( $_SERVER [ 'HTTP_REFERER' ], $URL_OF_FORUM ) !== 0 ) || ( strpos ( $_SERVER [ 'HTTP_REFERER' ], $URL_OF_FORUM ) !== 0 ) )
Thay =
PHP Code:
if(( strpos ( $_SERVER [ 'HTTP_REFERER' ], $URL_OF_FORUM ) !== 7 ) && ( strpos ( $_SERVER [ 'HTTP_REFERER' ], $URL_OF_FORUM ) !== 11 ) )
Xong xuôi, Forum bạn đã được bảo vệ bởi Firewall Protection Gateway Lite v0.4
Test thử MTv Forum thì bít KQ
[right][i]Nguồn: www.forum.mtv4vn.net[/i][/right]