All of lore.kernel.org
 help / color / mirror / Atom feed
From: Simon <dev@networker.co.nz>
To: netfilter@lists.netfilter.org
Subject: A replacement for rp_filter with iptables (config help needed)
Date: Thu, 30 Jun 2005 16:24:51 +1200	[thread overview]
Message-ID: <42C37413.3010504@networker.co.nz> (raw)

Hi There,

We are debian sarge with two ethernet cards.. To get eth1 (on a seperate 
subnet) working correctly, ive had to change 
/proc/sys/net/ipv4/conf/eth1/rp_filter to 0. Now i need a simple 
solution to protect against spoofing attacks on this interface... I have 
an example setup, but i want to make sure i have it correct.. can 
someone confirm for me?...

Note, this was a small script to block the mysql port on the server, but 
then enable for certain time/ip dynamically by adding/removing chains.

iptables -F
iptables -A INPUT -i lo -j ACCEPT
iptables -N MYSQL
iptables -N SPOOF
iptables -A INPUT -p tcp --dport 3306 -j MYSQL
iptables -A SPOOF -i eth1 -j SPOOF
iptables -A INPUT -p tcp --dport 3306 -j REJECT --reject-with tcp-reset

Is this correct - or have i got it ALL wrong.

Thanks

Simon


             reply	other threads:[~2005-06-30  4:24 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-06-30  4:24 Simon [this message]
2005-07-01  5:47 ` A replacement for rp_filter with iptables (config help needed) tahmeed
2005-07-01 21:55   ` John A. Sullivan III
2005-07-01 22:10     ` Jozsef Kadlecsik
2005-07-03 14:03       ` Jan Engelhardt
2005-07-04  7:39         ` Jozsef Kadlecsik

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=42C37413.3010504@networker.co.nz \
    --to=dev@networker.co.nz \
    --cc=netfilter@lists.netfilter.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.