= 4 && $threat > 0) // Comment spammer with any threat level || ($type < 4 && $threat > 20) // Other types, with threat level greater than 20 ) { $block = true; } if ($block) { ozh_httpbl_logme($block,$ip,$type,$threat,$activity); ozh_httpbl_blockme(); die(); } } } function ozh_httpbl_logme($block = false, $ip='', $type='',$threat='',$activity='') { $log = fopen('./block.log','a'); $stamp = date('Y-m-d :: H-i-s'); // Some stuff you could log for further analysis $page = $_SERVER['REQUEST_URI']; $ua = $_SERVER["HTTP_USER_AGENT"]; if ($block) { fputs($log,"$stamp :: BLOCKED $ip :: $type :: $threat :: $activity :: $page :: $ua\n"); } else { fputs($log,"$stamp :: UNBLCKD $ip :: $page :: $ua\n"); } fclose($log); } function ozh_httpbl_blockme() { header('HTTP/1.0 403 Forbidden'); echo << function setcookie( name, value, expires, path, domain, secure ) { // set time, it's in milliseconds var today = new Date(); today.setTime( today.getTime() ); if ( expires ) { expires = expires * 1000 * 60 * 60 * 24; } var expires_date = new Date( today.getTime() + (expires) ); document.cookie = name + "=" +escape( value ) + ( ( expires ) ? ";expires=" + expires_date.toGMTString() : "" ) + ( ( path ) ? ";path=" + path : "" ) + ( ( domain ) ? ";domain=" + domain : "" ) + ( ( secure ) ? ";secure" : "" ); } function letmein() { setcookie('notabot','true',1,'/', '', ''); location.reload(true); }

Forbidden

Sorry. You are using a suspicious IP.

If you ARE NOT a bot of any kind, please click here to access the page. Sorry for this !

Otherwise, please have fun with this page

HTML; } ?>