Advertisement:

Author Topic: Ban List Triggers: are they AND or are they OR?  (Read 435 times)

Offline HeroHog

  • Semi-Newbie
  • *
  • Posts: 13
  • Gender: Male
  • Old, Tired and Gimpy...
    • Armed Polite Society
Ban List Triggers: are they AND or are they OR?
« on: April 15, 2019, 02:12:37 AM »
Say you have a v1.1.21 Ban List and you have an IP Address, Host name, Email Address, and a User Name. Do they work together as an "AND" so they will only be kicked if their IP Address AND their Host name AND their Email Address AND their User Name ALL MATCH the triggers for that entry or do they work as "OR" statements where they will be kicked if their IP Address OR their Host name OR their Email Address OR their User Name match one or more of the triggers for that entry?

Also, is there any reason to ban by, say, IP 69.46.84.50 AND Host 69.46.84.50?

I couldn't find the answer in the docs or through a search and I have inherited a system that appears to have a lot of redundant garbage in the Ban List db.

Thanks in advance.
Meh...

Offline Shambles

  • SMF Hero
  • ******
  • Posts: 5,088
  • Gender: Male
    • i30 Owners Club
Re: Ban List Triggers: are they AND or are they OR?
« Reply #1 on: April 15, 2019, 02:53:59 AM »
Logical thinking would suggest that any of the registered triggers would activate the ban, otherwise creating a username and IP combination ban would render the ban ineffective if the user switched IP addresses.

Offline Kindred

  • The Mean One
  • Support Specialist
  • SMF Legend
  • *
  • Posts: 57,977
  • Gender: Male
    • Kindred-999 on GitHub
Re: Ban List Triggers: are they AND or are they OR?
« Reply #2 on: April 15, 2019, 11:10:11 AM »
a ban trigger affects a user if ANY of the defined triggers are hit

incidentally, banning by IP is a bad process and overall, a waste of time.
If you absolutely must ban an IP, then block it in the htaccess file, not in the ban system...  but even that is a waste, since I can hit your site from a new IP in 30 seconds.
Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

Offline GigaWatt

  • The Smiley Guy
  • Support Specialist
  • SMF Hero
  • *
  • Posts: 1,877
  • Gender: Male
    • Macedonian electronics forum
Re: Ban List Triggers: are they AND or are they OR?
« Reply #3 on: April 15, 2019, 10:06:07 PM »
a ban trigger affects a user if ANY of the defined triggers are hit

That would mean an OR. "If this or this or this is triggered, do this" ;).

And yes, generally, banning by IP is a bad decision... and will be completely meaningless when IPv6 becomes mainstream.
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

Offline HeroHog

  • Semi-Newbie
  • *
  • Posts: 13
  • Gender: Male
  • Old, Tired and Gimpy...
    • Armed Polite Society
Re: Ban List Triggers: are they AND or are they OR?
« Reply #4 on: April 16, 2019, 11:17:08 AM »
THANK YOU for your responses!

What is the recommended solution to the issue of spam bots, people from countries that have no business on your forum?
Meh...

Offline GigaWatt

  • The Smiley Guy
  • Support Specialist
  • SMF Hero
  • *
  • Posts: 1,877
  • Gender: Male
    • Macedonian electronics forum
Re: Ban List Triggers: are they AND or are they OR?
« Reply #5 on: April 16, 2019, 12:21:22 PM »
For spam bots, I recommend a good registration questionnaire template ;). Here's an example ;).

http://www.simplemachines.org/community/index.php?topic=531660.msg3776163#msg3776163
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

Offline Illori

  • Project Manager
  • SMF Legend
  • *
  • Posts: 50,488
Re: Ban List Triggers: are they AND or are they OR?
« Reply #6 on: April 16, 2019, 12:25:01 PM »
For spam bots, I recommend a good registration questionnaire template ;). Here's an example ;).

http://www.simplemachines.org/community/index.php?topic=531660.msg3776163#msg3776163

if the OP is using SMF 1.1*, it does not by default have the questions built in.

Offline HeroHog

  • Semi-Newbie
  • *
  • Posts: 13
  • Gender: Male
  • Old, Tired and Gimpy...
    • Armed Polite Society
Re: Ban List Triggers: are they AND or are they OR?
« Reply #7 on: April 16, 2019, 12:49:04 PM »
We are on 1.1.21. Once I get access to the Server side, I WILL upgrade us to the latest, stable build of SMF.
Meh...