• Welcome to Simple Machines Community Forum. Please login or sign up.
October 21, 2021, 03:40:24 PM

News:

SMF 2.1 RC4 has been released! Try it out and help us test! :) Read more.


Stop Spammer

Started by M-DVD, December 31, 2008, 07:31:43 AM

Previous topic - Next topic

snoopy_virtual

Quote from: spiros on September 28, 2017, 01:19:16 PM
I get on the top of the forum the notice "There are x members awaiting approval." all the time, and it is mostly spammers, is there any way not to have that notice there? Or even better, to have spammers rejected by default?

You cannot reject all of them by default because this mod has too many false positives.

The solution I have in all my forums is to have a couple of good questions and answers in the registration form.

And also to have installed mod httpBL together with mod StopSpammer.

El verdadero sabio es aquel que lo ve todo, lo estudia todo, lo analiza todo y molesta poco.
A true wise man is he who sees everything, studies everything, analyses everything and hardly ever annoys.

snadge

can anyone help?

iam getting spammers leaking through and I have both stop spammer and SFS and both report issues with connectivity>?  my API keys work as i just manually entered the offender

at a total loss with this one>?

thanks

snoopy_virtual

When did you installed mod StopSpammer?

Did you have the same problem since the beginning or has it just started recently?

Do you have some security questions at registration?

Do you have installed mod httpBL as well?

El verdadero sabio es aquel que lo ve todo, lo estudia todo, lo analiza todo y molesta poco.
A true wise man is he who sees everything, studies everything, analyses everything and hardly ever annoys.

Vincent Volmer

For SMF 1.0.15 I need to edit (/Sources/ManageMembers.php):

if ($context['sub_action'] == 'query' && !empty($_REQUEST['params']) && empty($_POST))
$_POST += safe_unserialize(base64_decode($_REQUEST['params']));


Into:
if ($context['sub_action'] == 'query' && empty($_POST))
{
if (!empty($_REQUEST['params']))
{
$_POST += safe_unserialize(base64_decode($_REQUEST['params']));
}
elseif ($context['browser']['is_ie'] && !empty($_SESSION['params']))
{
$_POST += $_SESSION['params'];
unset($_SESSION['params']);
}
}


But on this line I have this:
   if ($context['sub_action'] == 'query' && !empty($_REQUEST['params']) && (empty($_POST) || ((isset($_POST['spammers_checks']) || isset($_POST['spammers_report'])) && !empty($_POST['delete']))))
$_POST += safe_unserialize(base64_decode($_REQUEST['params']));


I think this is an edit from Stop Spammer.

How/what do I need to change? Could you please help with this?

Thanks!
Vincent Volmer

lurkalot

Quote from: Vincent Volmer on November 20, 2017, 01:56:55 AM
For SMF 1.0.15 I need to edit (/Sources/ManageMembers.php):

I think this is an edit from Stop Spammer.

How/what do I need to change? Could you please help with this?

Thanks!
Vincent Volmer

Ditto, I'm getting the same test failed on all my sites which are running Stop Spammer.

Kindred

untested, but seems logical



if ($context['sub_action'] == 'query' && empty($_POST)) || ((isset($_POST['spammers_checks']) || isset($_POST['spammers_report'])) && !empty($_POST['delete']))
{
if (!empty($_REQUEST['params']))
{
$_POST += safe_unserialize(base64_decode($_REQUEST['params']));
}
elseif ($context['browser']['is_ie'] && !empty($_SESSION['params']))
{
$_POST += $_SESSION['params'];
unset($_SESSION['params']);
}
}
Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Pause

Quote from: Vincent Volmer on November 20, 2017, 01:56:55 AM
For SMF 1.0.15 I need to edit (/Sources/ManageMembers.php):

You mean 2.0.15.

Quote from: Kindred on November 20, 2017, 09:41:33 AM
untested, but seems logical



if ($context['sub_action'] == 'query' && empty($_POST)) || ((isset($_POST['spammers_checks']) || isset($_POST['spammers_report'])) && !empty($_POST['delete']))
{
if (!empty($_REQUEST['params']))
{
$_POST += safe_unserialize(base64_decode($_REQUEST['params']));
}
elseif ($context['browser']['is_ie'] && !empty($_SESSION['params']))
{
$_POST += $_SESSION['params'];
unset($_SESSION['params']);
}
}


Almost, but there are some misplaced brackets that appear to stop that from working properly. Instead, the following appears to be what is needed:

if ($context['sub_action'] == 'query' && empty($_POST) || ((isset($_POST['spammers_checks']) || isset($_POST['spammers_report'])) && !empty($_POST['delete'])))
{
if (!empty($_REQUEST['params']))
{
$_POST += safe_unserialize(base64_decode($_REQUEST['params']));
}
elseif ($context['browser']['is_ie'] && !empty($_SESSION['params']))
{
$_POST += $_SESSION['params'];
unset($_SESSION['params']);
}
}
"You and me, inside that box, now." - The Doctor

Bite Fusion
Fusion Web Network
VG Fusion
Wrestling Fusion + Wrestling Fusion Forums

Vincent Volmer

Quote from: Pause on November 20, 2017, 03:34:23 PM
You mean 2.0.15.

Stupid me. Sorry about that... Yes you're right!

Thanks for your help. I'll try tomorrow!

Horme Gaming

perfect just came on to see if someone had asked this :D

HDB

I have the same issue as mentioned above with the install of the 2.0.15 patch using Stop Spammer on my forum.

I tested the Stop Spammer uninstall but didn't actually "do" the uninstall of Stop Spammer.  It looks like it would cleanly perform the uninstall. I was thinking that 2.0.15 would possibly install if I removed Stop Spammer. But I love what this mod does so much that I would hate to not be able to reinstall it after getting 2.0.15 to install.

I will wait and see what is said.

BeautifulBoy

Quote from: Pause on November 20, 2017, 03:34:23 PM

Almost, but there are some misplaced brackets that appear to stop that from working properly. Instead, the following appears to be what is needed:

if ($context['sub_action'] == 'query' && empty($_POST) || ((isset($_POST['spammers_checks']) || isset($_POST['spammers_report'])) && !empty($_POST['delete'])))
{
if (!empty($_REQUEST['params']))
{
$_POST += safe_unserialize(base64_decode($_REQUEST['params']));
}
elseif ($context['browser']['is_ie'] && !empty($_SESSION['params']))
{
$_POST += $_SESSION['params'];
unset($_SESSION['params']);
}
}


Thanks "Pause"! This edit works flawlessly... :-)

For others using this manual edit: Don't forget to edit (or check) the  required two other 2.0.15-edits in the same ManageMembers.php-file as well...

Russell G.

Quote from: Pause on November 20, 2017, 03:34:23 PM

Almost, but there are some misplaced brackets that appear to stop that from working properly. Instead, the following appears to be what is needed:

if ($context['sub_action'] == 'query' && empty($_POST) || ((isset($_POST['spammers_checks']) || isset($_POST['spammers_report'])) && !empty($_POST['delete'])))
{
if (!empty($_REQUEST['params']))
{
$_POST += safe_unserialize(base64_decode($_REQUEST['params']));
}
elseif ($context['browser']['is_ie'] && !empty($_SESSION['params']))
{
$_POST += $_SESSION['params'];
unset($_SESSION['params']);
}
}


Thanks for this, but I think there needs to be one more set of parenthesis in the first line. The code above is basically "if(a && b || c)" but it should be "if(a && (b || c))" since PHP does && operations first. Otherwise both a and b could be false but the code above would still execute if c is true. Here's a slightly modified version:

if ($context['sub_action'] == 'query' && (empty($_POST) || ((isset($_POST['spammers_checks']) || isset($_POST['spammers_report'])) && !empty($_POST['delete']))))
{
if (!empty($_REQUEST['params']))
{
$_POST += safe_unserialize(base64_decode($_REQUEST['params']));
}
elseif ($context['browser']['is_ie'] && !empty($_SESSION['params']))
{
$_POST += $_SESSION['params'];
unset($_SESSION['params']);
}
}


Thanks,
Russell

spiros

Can someone confirm which is the right version, I am a bit confused :)

Si6776

Is it just as easy to uninstall the Stop Spammer mod, then reinstall it after applying the patch?  Or would that not work?

Si6776

I've just uninstalled the Stop Spammer mod, and the 2.0.15 patch has now successfully installed, but I've run into another problem.  In my Admin panel, Members > Registration > Settings is now just a blank page.  Everything else seems to still be there.  I wanted to change the setting to Admin Approval while the Stop Spammer mod was uninstalled, but now I can't do that, so in a bit of a pickle.  I have backups of all files, but I don't know which one to restore, if indeed that would fix the problem.  Can anyone help, please?

Steve

Did you reinstall this mod?
Please do not PM me for support.

Si6776

No, I didn't.

Someone far more competent than myself has rescued the situation.  Apparently, for some reason, the Stop Spammer mod didn't uninstall cleanly, and left some debris in ManageRegistration.php, which was causing the issue.  That debris has now been removed and I have my Registration Settings page back.  :)

lurkalot

Quote from: spiros on November 21, 2017, 11:09:20 AM
Can someone confirm which is the right version, I am a bit confused :)

I'd also like to know what of the suggested fixes we are supposed to use.  Thanks.

lesmond

this is the edit you need to find and replace for SMF 2.0.15 ./Sources/ManageMembers.php

Code (find) Select
if ($context['sub_action'] == 'query' && empty($_POST))

Code (replace) Select
if ($context['sub_action'] == 'query' && (empty($_POST) || ((isset($_POST['spammers_checks']) || isset($_POST['spammers_report'])) && !empty($_POST['delete']))))

Tested on fresh SMF 2.0.15 install, no errors so far.



Free Forum Image Hosting



The only person who got all his work done by Friday was Robinson Crusoe

kitz

There appears to be confusion in this thread on how best to proceed.   

Am I correct in assuming that
- Manual update to ManageMembers.php is required...  and if so how will this affect any future SMF Updates.

It's still not clear if you are meant to uninstall Stop Spammer to proceed with the SMF patch released this week.  :(

----
Atm my forum is stuck waiting to be able to update to SMF 2.0.15 and although I have been watching this thread, it is confusing on how we are supposed to proceed next.

Would it be possible to release an updated version of StopSpammer which will fix everything and let us proceed with the SMF update?

Advertisement: