MyBB Community Forums

Full Version: ban a hostname!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello! I'm looking for a way to ban a hostname temporarily. We have this member that keeps spamming, attacking, threatening, and going after people. It's a tedious process to ban every IP to her telecom in her country. Heck, her country is so uncommon that we'd just like to ban the Telecom.

For example when she visits her IP is ###.##.###.## and her telecom is: ###.##.###.##.telecom.net

How can I ban *.telecom.net? I would like a plugin to do this ban!
I probably can't make a plugin to do this (seems a bit out of my league), but for at least some kind of measure, what about using your .htaccess to remove them? (It's probably not as neat/clean, but it should work.)

Try adding:
RewriteEngine On
RewriteCond %{HTTP_HOST} ^telecom\.com$
RewriteRule .* - [F]

Or even just
deny from telecom.com
(Provided you already have a .htaccess in your root folder... which if you have MyBB you likely already do.)

Either way though make sure reverse DNS lookup in your configuration files is enabled because otherwise neither will work properly. (It'd likely need to be enabled for a plugin to use anyway...)

Also, as an aside, I'm not sure how server intensive these are so I wouldn't recommend using them permanently or for a lot of hostnames. But where it's for just one it shouldn't be too bad. Still, test it anyway just in case.


Though as another alternative you could always skip banning hosts and just ban the entire country via .htaccess and be done with it... Use this site to get the IPs in a list to copy/paste to your .htaccess.
Though you may want to add a comment line just so you can easy remove these blocks in case you need to.