php forum
php mysql forum
php mysql smarty
 
Topic Options
#312620 - 01/11/07 12:34 PM Dynamic banning
arentzen Offline
Newbie

Registered: 10/05/06
Posts: 19
Loc: Denmark

   Dynamic banning to Del.icio.us Add to del.icio.us
  Digg Dynamic banning Digg it
Hej
Im running threads 6.0.1, and im looking for a way to use dynamic banning or IP block range. I can only ban a full Ip address; the Ip block range feature with % and _ doesnt work.
_________________________
Peter Arentzen
trosfrihed.dk

Top
#312629 - 01/11/07 06:21 PM Re: Dynamic banning [Re: arentzen]
AllenAyres Administrator Offline
I type Like navaho

Registered: 03/10/00
Posts: 25432
Loc: Texas
Hey Peter, is it not possible to upgrade? There are a large number of security holes in the older stuff that aren't going to be fixed, would seem like ip banning would be the least of your concerns smile

Barring that, I would just compare the ip banning code blocks from your version and 6.5.5.
_________________________
- Allen wavey
- What Drives You?

Top
#312643 - 01/12/07 07:14 AM Re: Dynamic banning [Re: AllenAyres]
arentzen Offline
Newbie

Registered: 10/05/06
Posts: 19
Loc: Denmark
Dear Allen
I will upgrade at some time. But I wont upgrade just because the platform has to be new. I still got around 20-25% users using 56k modems, so the platform may not become too heavy to upload. I had spend time closing security holes and made ehancements. I have only been hacked 1 time since we started up in 2002.

Anyway. Last week I opened some of my forums for anonymous posting, and I must realize the world is full of spammers, but I have decided to fight em', so this night I have made a little, but very effective programcode, which can ban Ip ranges. I have uploaded it into my ubbt.inc.php file right after check_ban function. Here it is:
Php Code:

//##########################################################
//Ny ban - af Arentzen
//##########################################################
		// Adresser der skal bannes.
			   $omraade = array('0'=>'148.233',
							  '1'=>'201.20',
					   '2'=>'149.9',
					   '3'=>'201.20',
					   '4'=>'165.228',	
					   '5'=>'201.',
										'6'=>'212.168.34',	
					'7'=>'222.',
					'8'=>'59.93',
					'9'=>'59.94',
					'10'=>'59.95',
					'11'=>'203.144',
					'12'=>'212.138',
					'13'=>'221.208',
					'14'=>'218.',

					);
	
		// Check IP adressen.
		foreach($omraade as $liste){
			if(strstr($_SERVER['REMOTE_ADDR'], $liste)){
				$html = new html;
				$html -> not_right("{$ubbt_lang['YOU_BANNED']}: $Reason", $Cat);
				exit();
			}
		} 


Beware! If banning e.g only the number '222',every user with 222 somewhere in their ip adress will be banned, so use this code with care.
_________________________
Peter Arentzen
trosfrihed.dk

Top
#312644 - 01/12/07 07:42 AM Re: Dynamic banning [Re: arentzen]
Gizmo Administrator Offline
Wizard

Registered: 01/10/00
Posts: 5123
Loc: Portland, OR, USA
I use something that provides similar functionality on my site; i generally just use it for blocking spambots, but could be added to theubb with an include.

One thing to give thought to with an upgrade; UBB.Threads 7.1 comes with a captcha system for both Registration and Guest Posting; which would make "fly by posting" by automated tools pretty much thwarted.
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design Owner

Top


Moderator:  Ian_W 
Who's Online
0 Registered (), 41 Guests and 9 Spiders online.
Key: Admin, Global Mod, Mod
Shout Box

Latest Posts
Blogs, love em or hate em?
by AllenAyres
10/07/08 02:05 PM
What do you use to edit the files
by Ian_W
10/05/08 03:33 PM
BeyondCompare v3.00
by Ian_W
10/05/08 03:32 PM
Glossy Black Theme with Image Reflection
by Gizmo
10/05/08 02:17 PM
ShareThis
by Gizmo
09/28/08 05:06 AM
[7.3] Viewing MySQL logfiles made easier
by AllenAyres
09/27/08 09:57 PM
Looking for a simple upload script
by Murphdog
09/26/08 08:45 PM
New Mods
[7.3] Viewing MySQL logfiles made easier
by blaaskaak
09/24/08 05:39 PM
[7.3] Language file checker
by blaaskaak
09/09/08 12:56 AM
[7.3.1] add search to showmembers page
by blaaskaak
09/07/08 04:50 AM
Multiple Identity Detector
by
12/30/06 06:39 PM
Newest Members
pisa666, ghengis317, NitroX, Dogan, EliYah-
13345 Registered Users
Top Posters Last 30 Days
AllenAyres 13
blaaskaak 9
tackaberry 7
FREAK1 6
Gizmo 4
Mike L_dup1 4
Chris Bale 4

 

 

 
fusionbb message board php hacks