Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
Reload Flood Control Details »
Reload Flood Control
Mod Version: 1.00, by Zzed (Member) Zzed is offline
Developer Last Online: Feb 2012 I like it Show Printable Version Email this Page

This modification is in the archives.
vB Version: 2.2.x Rating: (1 vote - 5.00 average) Installs: 8
Released: 06 Sep 2002 Last Update: Never Downloads: 7
Not Supported  

This is a fairly simple hack. I implemented it a couple days ago. And realized
that it had also been requested by scotty back in June.

http://www.vbulletin.org/forum/showt...threadid=40297

This hack limits the number of http requests to 1 request per IP address
per second. It works for both registered users as well as guests. If a users
hits the refresh button more than once per second he will be taken to the
error screen. The hack actually terminates the loading process of the page
in the early stages and prevents the server load from going up. I have
tried the refresh flood with and without this hack. And without the hack
I got the server load to go from 0.7 to about 25 with about 30 people logged
on. With the hack in place, the same refresh flood caused the load to go as high
as 1.2.

This hack requires you to create a new template. And it modifies 2 source
files: global.php and showthread.php.

In admin CP add the following template: error_floodreload
Add the following text to the template:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

In global.php
Look for the following code:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Add this code directly above it:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

In showthread.php
Look for the following code:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace it with

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

In showthread.php
Look for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace it with:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

The reason for the 1 second sleeps is to prevent the error screen from popping up when
the user clicks on the goto newest or goto last post arrows in the forum display.
Those 2 calls end up making a second recursive call to showthread.php which ends up
being within the same 1 second interval of the click itself. This way you are fooling
the flood control so that it wont catch the back to back requests.

Download Now

Only licensed members can download files, Click Here for more information.

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Comments
  #2  
Old 06 Sep 2002, 11:20
Logician's Avatar
Logician Logician is offline
 
Join Date: Nov 2001
it's a very good idea and a must have hack especially for people having bandwidth problems. IMO it also fixes the gap someone could exploit by sending too many page requests for a long time and thus making your server busy all the times. It wouldnt be a problem for manual sending but a malicious hacker could always code a script to make it automatically and increase your server load dramatically. So great fix..

One minor issue though: it would prevent users open a few pages at the same time when they come to the site. For example when they make a search, they cant anymore open a few threads at the same time by clicking "Open in new browser windows" link. (which I do a lot!). Of course this is not related to you it's the nature of the hack but maybe setting the second to 0.5 instead of 1 may be a little help for these users...
__________________
Logician's Blog | WebTemplates for vb 4.x : VB Integrated Content Management System
Reply With Quote
  #3  
Old 06 Sep 2002, 11:24
Zzed's Avatar
Zzed Zzed is offline
 
Join Date: Feb 2002
Real name: Edwin
Thank you for your kind words.

We do suffer from high loads on our server.

You can actually load multiple pages. I do that all the time. I am willing to bet you money that opening the subsequent windows will take longer than a one second interval.
Reply With Quote
  #4  
Old 06 Sep 2002, 14:30
The Ghost's Avatar
The Ghost The Ghost is offline
 
Join Date: Feb 2002
Very Great Hack, I have a lot of peoples which refreshs only to kill my board.......

thx
Reply With Quote
  #5  
Old 06 Sep 2002, 14:32
MarkB's Avatar
MarkB MarkB is offline
 
Join Date: Oct 2001
Has it affected bandwidth at all?
Reply With Quote
  #6  
Old 06 Sep 2002, 15:22
The Ghost's Avatar
The Ghost The Ghost is offline
 
Join Date: Feb 2002
Well, I've installed your great Hack, but if I now press the "F5" Key (Refresh) ever and ever I don't see the Antiflood Message....

I've Tryed it very often......
Reply With Quote
  #7  
Old 06 Sep 2002, 16:27
Zzed's Avatar
Zzed Zzed is offline
 
Join Date: Feb 2002
Real name: Edwin
MarkB, it will prevent the server load from going up.

The Ghost, can you double check your installation steps and make sure you haven't left anything out?
Reply With Quote
  #8  
Old 06 Sep 2002, 19:22
Neo's Avatar
Neo Neo is offline
 
Join Date: Oct 2001
Real name: Dan
Nice.
Reply With Quote
  #9  
Old 07 Sep 2002, 01:35
The Ghost's Avatar
The Ghost The Ghost is offline
 
Join Date: Feb 2002
Hi,

I checked it all again and again step by step, but I think it doesn't work for me
Reply With Quote
  #10  
Old 07 Sep 2002, 11:24
Zzed's Avatar
Zzed Zzed is offline
 
Join Date: Feb 2002
Real name: Edwin
Can you Email me a copy of your global.php?

edwink@seebeyond.com
Reply With Quote
  #11  
Old 07 Sep 2002, 16:42
rapsearch's Avatar
rapsearch rapsearch is offline
 
Join Date: Aug 2002
added it but when i try it out... i don't see the text message??.. the screen pops up.. but not with the line from the template??

I did add it....
__________________
RapSearch.Com (VB!)
KillaMail.Com - Free Email
Sporttoolbars.com - Free Sport Toolbars
Reply With Quote
  #12  
Old 07 Sep 2002, 17:50
Rapdis's Avatar
Rapdis Rapdis is offline
 
Join Date: Mar 2002
i added it all... i dont see it either.... please advise, by the way, im using 12 gb and only 450 members, i got a big problem sumwhere and need help.
Reply With Quote
  #13  
Old 07 Sep 2002, 23:44
Zzed's Avatar
Zzed Zzed is offline
 
Join Date: Feb 2002
Real name: Edwin
Ok, I updated the instructions and the attachment.

I needed to obtain the proper templateset, replacementset, and style id's in order for the error screen to load properly for those of you who have been having trouble with it.

I replaced

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

with

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

I apologize for your inconvenience.
Reply With Quote
  #14  
Old 11 Sep 2002, 13:12
rapsearch's Avatar
rapsearch rapsearch is offline
 
Join Date: Aug 2002
did what you suggested but still got the same screen??

see attachment.....
Attached Images
File Type: gif floodcontrol.gif (4.2 KB, 61 views)
__________________
RapSearch.Com (VB!)
KillaMail.Com - Free Email
Sporttoolbars.com - Free Sport Toolbars
Reply With Quote
  #15  
Old 15 Nov 2002, 00:22
GeorgeofCS's Avatar
GeorgeofCS GeorgeofCS is offline
 
Join Date: Oct 2001
Is there any way to make this hack affect just non registered members?
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 03:31.

Layout Options | Width: Wide Color: