Print Page | Close Window

Admin/Mods Unable to Block IPs

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Forums
Forum Description: Support forum for Web Wiz Forums application.
URL: https://forums.webwiz.net/forum_posts.asp?TID=16978
Printed Date: 16 April 2026 at 2:22am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Admin/Mods Unable to Block IPs
Posted By: Ali Bilgrami
Subject: Admin/Mods Unable to Block IPs
Date Posted: 21 October 2005 at 6:06am
hi
im running 7.92 with a couple of 7.95 modifications on SQL 2000 server. now the problem we are facing from some time is that we are unable to stop members from posting or coming with IP Blocking. we tried blocking ranges but to no avail...what can be wrong?



Replies:
Posted By: javi712
Date Posted: 21 October 2005 at 10:09am
I noticed this also on an Access Database. I would block their IP Address, yet they were still able to continue posting as if nothing.


Posted By: JJLatWebWiz
Date Posted: 21 October 2005 at 7:05pm
This could be caused by the banned IP bug: http://forums.webwiz.net/forum_posts.asp?TID=16121 - http://forums.webwiz.net/forum_posts.asp?TID=16121

Try that change and see if the IP blocking works as it should.

-------------
p.s. I'm not affiliated with Web Wiz Guide in any way. I'm just an average Web Wiz user repaying my debt for the use of their fine forum by trying to help other Web Wiz Guide users.


Posted By: Scotty32
Date Posted: 23 October 2005 at 7:50am
this might be a silly question, but are your users IPs the same?
as they might have a dynamic ip, or posting from a new location

many of my users ips change often, eg AOL users

if it IS a IP Blocking problem, you could try de-activating their account, i believe this adds a block so they cant reactive there account

i my self set up a group called "Banned" and turned forum permissions off for this group, now i can put people in this group and they cant post

could try this is the IP Blocking isnt working


-------------
S2H.co.uk - http://www.s2h.co.uk/wwf/" rel="nofollow - WebWiz Mods and Skins

For support on my mods + skins, please use http://www.s2h.co.uk/forum/" rel="nofollow - my forum .


Posted By: Ali Bilgrami
Date Posted: 24 October 2005 at 9:37am
Scotty_32, i have such a group named "Failed!" LOL but u see some ppl are just stupid, they come again n again with new ids Confused that is why email or ip blocking is important and yes i have checked the IPS they are the same. that is why i am worried


Posted By: Ali Bilgrami
Date Posted: 24 October 2005 at 11:46am
Thanks JJLatWebWiz your solution did work fine and solved my problem :) Clap
although there was   and a variable typo that i removed. Smile
 
here is JJLatWebWiz Code for the IP Baning Problem in WWF V 7.92 And V 7.95
it is to be replaced in ../functions/functions_common.asp....
 

 
'******************************************
'****        Banned IP's             *****
'************************** ****************
Private Function bannedIP()

     'Declare variables
     Dim rsIPAddr
     Dim strCheckIPAddress
     Dim strUserIPAddress
     Dim blnIPMatched
     
     'Intilise variable
     blnIPMatched = False
     
     'Get the users IP
     strUserIPAddress = getIP()

     'Intialise the ADO recordset object
     Set rsIPAddr = Server.CreateObject("ADODB.Recordset")

     'Get any banned IP address from the database
     'Initalise the strSQL variable with an SQL statement to query the database to count the number of topics in the forums
     If strDatabaseType = "SQLServer" Then
          strSQL = "EXECUTE " & strDbProc & "BannedIPs"
     Else
        strSQL = "SELECT " & strDbTable & "BanList.IP FROM " & strDbTable & "BanList WHERE " & strDbTable & "BanList.IP Is Not Null;"
     End If

     'Query the database
     rsIPAddr.Open strSQL, adoCon

     'Loop through the IP address and check 'em out
     Do while NOT rsIPAddr.EOF and NOT blnIPMatched                 'Get the IP address to check from the recordset           strCheckIPAddress = rsIPAddr("IP")               'See if we need to check the IP range or just one IP address           'If the last character is a * then this is a wildcard range to be checked           If Right(strCheckIPAddress, 1) = "*" Then                 &n bsp;           'Remove the wildcard charcter form the IP                strCheckIP Address = Replace(strCheckIPAddress, "*", "", 1, -1, 1)
               
            'See if whats left of the IP matches
               I f strCheckIPAddress = Mid(strUserIPAddress, 1, Len(strCheckIPAddress)) Then blnIPMatched = True
                &nbs p;        
          'Else check the IP address metches     
          E lse
               'Else check to see if the IP address match
               If strCheckIPAddress = strUserIPAddress Then blnIPMatched = True
          
        End If

          'Move to the next record
          rsIPAddr.MoveNext
    Loop

     'Clean up
     rsIPAddr.Close
     Set rsIPAddr = Nothing

     'Return the function
     bannedIP = blnIPMatched
End Function
 
 
strCheckIP Address = strCheckIPAddress in line 40 of this code under the heading of "'Remove the wildcard charcter form the IP"
 
and delete the &nbs p; in line 44 under the heading " 'See if whats left of the IP matches"
 Smile
great work man .... Clap


Posted By: JJLatWebWiz
Date Posted: 24 October 2005 at 12:20pm
I corrected that variable. I don't know how that got there. But, the credit for http://forums.webwiz.net/forum_posts.asp?TID=12385#74540 - the solid fix goes to sfd19. I just posted the complete function to make the fix easier.

-------------
p.s. I'm not affiliated with Web Wiz Guide in any way. I'm just an average Web Wiz user repaying my debt for the use of their fine forum by trying to help other Web Wiz Guide users.


Posted By: Ali Bilgrami
Date Posted: 25 October 2005 at 1:51am
In that case thanks to sfd19 as well Smile



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net