Advertisement:

Author Topic: [MOD][PENDING] Spam Blocker - Anti-spam modification to restrict or limit access  (Read 89044 times)

Offline Suki

  • Customizer
  • SMF Super Hero
  • *
  • Posts: 15,088
  • Kaizoku Jotei
    • MissAllSunday on GitHub
    • SMF mods
Yes, most of it are personal preferences, personal preferences that helps reducing support requests.
Quote
When searching for a line of code I like to include the preceding tabs (the whole line if you will) and I will always continue to do that.

Until another mod modifies the exact same line before yours and replaces the tabs with dots or simply doesn't put the tabs back or even the exact number of tabs, making your edit to fail and naturally, the user will blame you, not the other mod author.

It is a really simple change and believe me, it will save you a few headaches when giving support.

Quote
but neglected to change it.  I think something was changed regarding the hooks in 2.1 and you are correct this won't work with it as I believe I tested that some time ago. Still, this version description claims SMF 2.0.X compatibility and what is described to this mod's users is correct.

What it claims to do and what it actually does are different things, over performing to what was claimed is just as bad as been unable to perform what is claimed. This comes from experience dealing with support, users generally don't wait until mod authors adjust their mods to be compatible with the new version, they just install them, it is preferable to not be able to install the mod (in a normal way) than give them the ability to install a mod that just won't work with their version.

Again, a simple change can made the difference between you been happily enjoying a cold one and watching the sunset or been fed up and angry in front of your computer, choice is yours of course, I'm just offering my experience and nothing more.

Quote
The db queries are tabbed out nicely and I do not understand the issue you speak of.

Subs-SpamBlocker, Subs-SpamBlockerAdmin, SpamBlockerAdmin  has queries on a single line and none of them uses the casting array.  Sometime ago casting all values was mandatory, I don't know whats the policy these days.

Regardless of personal preferences, code should be easy to read by humans, after all, thats the primary role for all languages.

Your license doesn't allow re-distribution, can you please add a simple note in the mod's page indicating you give SMF and SM  written consent to re-distribute your work.
Look at them. They're just asking for it. Maybe the human race deserves to be wiped out.

Offline Chen Zhen

  • Sophist Member
  • *****
  • Posts: 1,028
  • Gender: Male
  • If you're going through hell, keep going!
    • Underdog-01 on GitHub
    • WebDev.ca

Suki,

  I take everything you said into consideration and will make the changes later tonight. May I also add that I realize you were correct about the tabbing of the MYSQL whereas I do not know why I did not do it properly before. I suppose as I do more and more projects my coding habits improve and atm tabbing things properly comes natural. Thank you again for looking at the mod and giving me the feedback I need.

Arantor,

  I also thank you for your feedback and experience.

Regards.

 

Offline Chen Zhen

  • Sophist Member
  • *****
  • Posts: 1,028
  • Gender: Male
  • If you're going through hell, keep going!
    • Underdog-01 on GitHub
    • WebDev.ca

Mod has been updated.

Spam Blocker_v1.0-RC1.7

Changes:
+ added link in Admin->Members to redirect to Lookup template
! fixed source code for post filtering
! adjusted copyright to allow Simple Machines to distribute the modification from SMF download site
! fixed tabs for all mysql queries
! fixed install to only work for SMF 2.0.X series
! reorganized install files into appropriate folders (same as SMF defaults)
! used casting array in smcFunc functions where applicable
! removed all empty whitespaces at end of lines in every file



Offline Chen Zhen

  • Sophist Member
  • *****
  • Posts: 1,028
  • Gender: Male
  • If you're going through hell, keep going!
    • Underdog-01 on GitHub
    • WebDev.ca

I fixed the ones I missed in the admin sources file with RC1.71 ... my apologies.

Offline phill104

  • Semi-Newbie
  • *
  • Posts: 13
Many thanks for the update and feature inclusion. Spam is an ever increasing problem and while there are many great tools out there some just don't hit the mark. Some work but require far too much admin intervention and when you have a big forum like ours that at times is getting 500+ spam registrations per day the work load is just silly. This seems to work well and hopefully keeps the users happy by not having to jump through hoops to simply register.

Offline Suki

  • Customizer
  • SMF Super Hero
  • *
  • Posts: 15,088
  • Kaizoku Jotei
    • MissAllSunday on GitHub
    • SMF mods

Mod has been updated.

Spam Blocker_v1.0-RC1.7

Changes:
+ added link in Admin->Members to redirect to Lookup template
! fixed source code for post filtering
! adjusted copyright to allow Simple Machines to distribute the modification from SMF download site
! fixed tabs for all mysql queries
! fixed install to only work for SMF 2.0.X series
! reorganized install files into appropriate folders (same as SMF defaults)
! used casting array in smcFunc functions where applicable
! removed all empty whitespaces at end of lines in every file




Thnks :)

On my part theres nothing more to edit or change, there might be bugs but thats only natural and they will only arise after some production usage. Guess just have to wait for the cust team. Good luck :)
Look at them. They're just asking for it. Maybe the human race deserves to be wiped out.

Offline Chen Zhen

  • Sophist Member
  • *****
  • Posts: 1,028
  • Gender: Male
  • If you're going through hell, keep going!
    • Underdog-01 on GitHub
    • WebDev.ca

Suki,

  Thank you for unveiling your expertise.



  I added a blacklist link as one of the admin nav button children for the RC1.71 but didn't realize it loads my language file after that particular hook. I edited in a load language file command for that hook to fix that issue in RC1.72 (and for the mod site 1.0 copy).

Offline phill104

  • Semi-Newbie
  • *
  • Posts: 13
How are you getting on with this mod? We've been using it for a while and it ended up overloading our DB as the ban list ended up so large queries to it were taking so long. We emptied the ban list and stopped the mod from adding to it in the short term.

Offline Chen Zhen

  • Sophist Member
  • *****
  • Posts: 1,028
  • Gender: Male
  • If you're going through hell, keep going!
    • Underdog-01 on GitHub
    • WebDev.ca
phill104,

  Although it allows an option to permanently ban any flagged IP's, it is best to set it to ie. a 1, 2 or 3 day ban whereas it will delete ban entries it added within that time frame.  You can also leave it set to not ban an ip address as you have stated which should work just fine as it cache's flagged ip's for 1 hour.
 
Regards.