Stop Forum Spam

BUG: Stop Forum Spam 1.1.7 - Stop Forum Spam

BUG: Stop Forum Spam 1.1.7

by M.O.B. » Mon Nov 13, 2017 3:01 pm

Not 100% sure, but I think there is a bug with this version or at least the setting:

Code: Select all

Allow if Stop Forum Spam is down:
Should registration/posting go through if the stop forum spam website is down
If STOP FORUM SPAM (SFS) is down, we have the option to either allow or not the registration to succeed. I have it set to NO, so they will have to wait and later try again. I believe that is how it works, right?

Well, viewing my admin logs, it seems that when SFS is down, right away that user's IP address is also being banned after it was logged in the ADMIN LOGs that SFS was down during registration, since I do have that option also enabled, that it should ban IP addresses if the account is found on SFS database.

See this example on my ADMIN LOGS:

Code: Select all

Anonymous 	XX.XXX.XXX.XX Sun Nov 12, 2017 10:10 am 	Banned IP for reason “Found in the Stop Forum Spam database”
» XX.XXX.XXX.XX 	
Anonymous 	XX.XXX.XXX.XX 	Sun Nov 12, 2017 10:10 am 	Stop Forum Spam was down during a registration or a forum post
Plus then I check the USER LOGS to see if there is any info about that block, and there is no report about that. What am I referring to? When you got in the USER LOGs and you see a report like this:

Code: Select all

Stop Forum Spam triggered:
Username: (some username)
IP: xx.xxx.xx.x
Email: (some email address)
How I found this bug? Well, I got a member report this issue to us via support, so this is why I am thinking this is what is happening. Plus when I verify if that IP address is listed at SFS, I don't get any hits.

Let me know if you want me to PM you the IP's in question, since this happened a few times during the time SFS was down temporarily?

Question: how long do they have to wait when SFS is down?
Do they get temporarily banned? Does the BAN duration we set dictate this waiting time? What if we put "PERMEMENT" BAN on that IP address?
Last edited by M.O.B. on Tue Nov 14, 2017 1:38 am
Image
User avatar
M.O.B.
Registered User
Posts: 899
Joined: Tue Jan 04, 2005 1:07 am
Location: San Diego CA USA
Contact:

Re: BUG: Stop Forum Spam 1.1.7

by RMcGirr83 » Mon Nov 13, 2017 5:14 pm

M.O.B. wrote:Not 100% sure, but I think there is a bug with this version or at least the setting:

Code: Select all

Allow if Stop Forum Spam is down:
Should registration/posting go through if the stop forum spam website is down
If STOP FORUM SPAM (SFS) is down, we have the option to either allow or not the registration to succeed. I have it set to NO, so they will have to wait and later try again. I believe that is how it works, right?
Yes
Well, viewing my admin logs, it seems that when SFS is down, right away that user's IP address is also being banned after the it was logged in the ADMIN LOGs that SFS was down during registration, since I do have that option also enabled, that it should ban IP addresses if the account is found on SFS database.
Yep quite correct. To fix that you need to find lines 139 and 212 in the main_listener file and change them from what they are to this

Code: Select all

if ($this->config['sfs_ban_ip'] && $check != 'sfs_down')
In times of change, learners inherit the earth, while the learned find themselves beautifully equipped to deal with a world that no longer exists - Eric Hoffer
Former Modifications/Extensions Team Member | My extensions
Appreciate the extensions/mods/support then buy me a beer
All requests for support via PM will be ignored
User avatar
RMcGirr83
Recognised Extension Developer
Posts: 20926
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr
Contact:

Re: BUG: Stop Forum Spam 1.1.7

by M.O.B. » Tue Nov 14, 2017 1:39 am

Just to clarify? What does that line code do for me?

What I want is for the users IP to not be banned if SFS is down.
Image
User avatar
M.O.B.
Registered User
Posts: 899
Joined: Tue Jan 04, 2005 1:07 am
Location: San Diego CA USA
Contact:

Re: BUG: Stop Forum Spam 1.1.7

by RMcGirr83 » Tue Nov 14, 2017 10:47 am

That's exactly what it does.
In times of change, learners inherit the earth, while the learned find themselves beautifully equipped to deal with a world that no longer exists - Eric Hoffer
Former Modifications/Extensions Team Member | My extensions
Appreciate the extensions/mods/support then buy me a beer
All requests for support via PM will be ignored
User avatar
RMcGirr83
Recognised Extension Developer
Posts: 20926
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr
Contact:

Re: BUG: Stop Forum Spam 1.1.7

by M.O.B. » Sat Nov 25, 2017 2:18 am

I don't know if I should start a new topic, but I found a new bug in SFS v1.17

It seems if we choose the options (see below), it doesn't seem to add the banned IP to the Ban IP list in the ACP. Like it doesn't ban them anymore by IP address.

Code: Select all

Ban IP: Yes
Length of ban: Permanent
Log a message: Yes
It was working before with a previous extension version. Could it be broken I wonder? I am using phpBB 3.1.11.

Or did the above edit you asked to do to fix another bug caused this malfunction, I wonder? -- UPDATE: I think the above edit you asked me to do, perhaps broke that, since it was working just prior to those code changes. :(

I already tried disabling the extension and deleting the data and reinstall the plugin.

I also now opted for a YEAR to see if that is also broken? I will report in a few days, as I have one site that I get daily log when it blocks someone. :)

Edit:

Okay, setting it to a YEAR also didn't help. Now I am going to revert the changes I made earlier to: main_listener.php to see if it fixes this issue?
Image
User avatar
M.O.B.
Registered User
Posts: 899
Joined: Tue Jan 04, 2005 1:07 am
Location: San Diego CA USA
Contact:

Re: BUG: Stop Forum Spam 1.1.7

by M.O.B. » Sat Nov 25, 2017 10:20 pm

UPDATE:

I removed the changes to main_listener.php and now the IPs are being banned again and being added to the ACP ban IP list. So that was the issue, the fix you offered above for the first bug became the problem that caused the 2nd bug.

Hopefully you can offer another solution?
Image
User avatar
M.O.B.
Registered User
Posts: 899
Joined: Tue Jan 04, 2005 1:07 am
Location: San Diego CA USA
Contact:

Re: BUG: Stop Forum Spam 1.1.7

by RMcGirr83 » Thu Dec 07, 2017 5:10 pm

In times of change, learners inherit the earth, while the learned find themselves beautifully equipped to deal with a world that no longer exists - Eric Hoffer
Former Modifications/Extensions Team Member | My extensions
Appreciate the extensions/mods/support then buy me a beer
All requests for support via PM will be ignored
User avatar
RMcGirr83
Recognised Extension Developer
Posts: 20926
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr
Contact:

Re: BUG: Stop Forum Spam 1.1.7

by RMcGirr83 » Tue Dec 12, 2017 5:10 pm

M.O.B. wrote:UPDATE:

I removed the changes to main_listener.php and now the IPs are being banned again and being added to the ACP ban IP list. So that was the issue, the fix you offered above for the first bug became the problem that caused the 2nd bug.

Hopefully you can offer another solution?
In times of change, learners inherit the earth, while the learned find themselves beautifully equipped to deal with a world that no longer exists - Eric Hoffer
Former Modifications/Extensions Team Member | My extensions
Appreciate the extensions/mods/support then buy me a beer
All requests for support via PM will be ignored
User avatar
RMcGirr83
Recognised Extension Developer
Posts: 20926
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr
Contact:

Re: BUG: Stop Forum Spam 1.1.7

by RMcGirr83 » Tue Dec 19, 2017 1:12 pm

This should now be fixed.
In times of change, learners inherit the earth, while the learned find themselves beautifully equipped to deal with a world that no longer exists - Eric Hoffer
Former Modifications/Extensions Team Member | My extensions
Appreciate the extensions/mods/support then buy me a beer
All requests for support via PM will be ignored
User avatar
RMcGirr83
Recognised Extension Developer
Posts: 20926
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr
Contact:

Re: BUG: Stop Forum Spam 1.1.7

by M.O.B. » Sun Dec 24, 2017 6:34 am

Sorry that I never came back... I never got any notifications. For some odd reason I don't get any from the extensions forum section. :(

I'm about to update to v1.1.8, so I figure the fix is in there?
Image
User avatar
M.O.B.
Registered User
Posts: 899
Joined: Tue Jan 04, 2005 1:07 am
Location: San Diego CA USA
Contact:

Re: BUG: Stop Forum Spam 1.1.7

by RMcGirr83 » Sun Dec 24, 2017 11:19 am

Yes the fix is in the latest version
In times of change, learners inherit the earth, while the learned find themselves beautifully equipped to deal with a world that no longer exists - Eric Hoffer
Former Modifications/Extensions Team Member | My extensions
Appreciate the extensions/mods/support then buy me a beer
All requests for support via PM will be ignored
User avatar
RMcGirr83
Recognised Extension Developer
Posts: 20926
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr
Contact: