Zbblock

ZBBLOCK 을 아십니까?

자체적으로 서버를 구축하여 사용하는 경우 스팸봇의 여러 공격에 적절히 대응하기가 어렵다. 최근 도쿠위키구글 페이지랭크 (Pagerank)를 올리기 위한 공격 (register → login → edit) 이 계속 오고 있어서 검색 중 알아낸 것임.

디도스 (D-DOS) 공격을 알기쉽게 말하면..공격을 막을 수는 없으나, 그외의 다양한 스팸을 해결할 수 있고, 악성IP주소를 자동으로 공유하며 차단하기 때문에 더욱 도움이 된다. FIXME

  • Stopping MySQL/msSQL tampering / blind injection.
  • Stopping Site Defacement.
  • Stopping PHP script exploits.
  • Stopping Remote File Include (RFI) exploits.
  • Stopping directory traversal attacks. ( …/../../../../../../../../proc/self/environ%00 type stuff)
  • Blocking known bad IP addresses, and hostnames from accessing your site. Sure that can be done by .htaccess, but .htaccess is incredibly slow, and processor intensive, especially when checking hostnames, as it has to re-poll the server variable every time it wants to do a check.
  • Stopping known bad user agents (many skript kiddies can't get around this).
  • Deterring content theft and keyword scraping. Many of the functions above will work in concert with this goal.
  • Stopping registrations and logins from known insecure networks and known spammers (via remote DB lookup), but allow non-registered read only access (TOR and known spammers).
  • Stopping HTTP_REFERER Spam.
  • Impeding some Cross Site Scripting (XSS) attacks.
  • Stopping most forum spam (via remote DB lookup).
  • 유료 호스팅의 경우 관리자가 알아서 이런 기능을 사용하고 있을 지도 모릅니다.

설치

간단한 과정으로 설치 후 사용할 수 있다.

  1. 일단 내려 받은 뒤, 본인 웹사이트의 /zbblock 폴더에 풀어 넣다.
  2. 이제 웹브라우져로 /본인사이트주소/zbblock/setup.php를 실행함.
  3. ZBblock의 위치를 스스로 알 수 있도록 지정해 주는데 2번이나 7번이 권장된다. 클릭함.
  4. 이제 <?php include('yourdirectory/zbblock/zbblock.php'); ?> php 문구를 보여주는데 이것을 방어하고자 하는 php파일의 맨 처음에 넣으면 된다. 도쿠위키의 경우 doku.php의 최상단에 넣다.
  5. 끝.

특별한 설정은 필요없으나 세밀한 설정을 원하면 동봉된 영문 설명문서를 참조하라.

확인

yourdirectory/zbblock/vault/killed_log.txt 를 보면 차단한 내역이 나온다.

#: 151 @: Mon, 22 Apr 2013 16:44:32 +0900 Running: 0.4.10a1
Host: ks313370.kimsufi.com
IP: 188.165.228.9
Score: 1
Violation count: 1 
Why blocked: kimsufi, forum spambots (HN-0006). 
Query: 
Referer: 
User Agent: 
Reconstructed URL: http://  /

#: 152 @: Mon, 22 Apr 2013 16:46:21 +0900 Running: 0.4.10a1
Host: 216.172.139.106
IP: 216.172.139.106
Score: 1
Violation count: 1 
Why blocked: No registrations, or logins, from hosts listed as hostile on http://www.stopforumspam.com/ (local). 
Query: id=tech/&do=login
Referer: http://mine.vaslor.net/tech/picking_no-hassle_secrets_of_mountain_climbing
User Agent: Mozilla/5.0 (Windows NT 6.0) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/13.0.782.112 Safari/535.1
Reconstructed URL: http:// mine.vaslor.net /tech/?do=login

참고

누구나 수정할 수 있다. 위키 사용법 참고하라.