Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

Website and Server Administration Forum


You are currently viewing our Website and Server Administration Forum as a guest. Please register to participate.
Login



Reply
Using geoip with iptables
Old 09-07-2010, 06:26 AM Using geoip with iptables
Junior Talker

Posts: 1
Trades: 0
Hi, I have a dedicated web server in the US and it is receiving a lot of bogus requests from China, Brazil, Turkey.

From the log I see they are trying to brute force dovecot.

I host a website on this server, so I need dovecot just to read the emails customers send to me. This means I'm the only user of dovecot.

I thought to use geoip with iptables to ban all accesses to dovecot from countries other than mine.

I'm no expert of iptables and googling I found that it is possible to use it with geoip to specify which countries to ban. What i want, however, is to allow only accesses from my country. This way I don't need to add new rules to iptables every time a new ip from a non banned country attacks me.

From what I understand, iptables uses the -j DROP switch to send matching packets to hell. What i want is to send non matching patterns to hell.

This way I use -m geoip --src-c my_country_code and I need to drop all packets from countries that are not my own.
pabloski is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Reply     « Reply to Using geoip with iptables
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.08104 seconds with 12 queries