All of lore.kernel.org
 help / color / mirror / Atom feed
From: /dev/rob0 <rob0@gmx.co.uk>
To: netfilter@vger.kernel.org
Subject: Re: Proxy Filter iptable Settings
Date: Sat, 30 Apr 2011 14:24:11 -0500	[thread overview]
Message-ID: <20110430192411.GQ2976@cardinal> (raw)
In-Reply-To: <1304190535.2488.13.camel@andybev>

On Sat, Apr 30, 2011 at 08:08:55PM +0100, Andrew Beverley wrote:
> On Sat, 2011-04-30 at 13:23 -0500, Mike Hendrie wrote:
> > Now to lock it down? I should just create rules to block ports?
> 
> Well it depends how paranoid you are. You might just want to block 
> new incoming connections to the local network:
> 
> iptables -P FORWARD DROP
> iptables -A FORWARD -i $ext_IF -o $int_IF \
> 	-m state --state ESTABLISHED,RELATED -j ACCEPT
> iptables -A FORWARD -i $int_IF -o $ext_IF -j ACCEPT
> 
> You'd probably also want to drop all incoming connections to the 
> server apart from your web server:
> 
> iptables -A INPUT -p tcp --dport 80 -i $ext_IF -j ACCEPT
> iptables -A INPUT -i $ext_IF -j DROP
> 
> As Rob says though, you're probably best going through a few basic
> tutorials first - you'll be up to speed in no time. Also check out
> iptables-save and iptables-restore.
> 
> Let's hope I haven't made any more mistakes that Rob is going to 
> spot :)

Hehe ... well ... I would suggest that you look at the enhanced 
feature set of -m conntrack --ctstate vs. -m state --state. That's 
not a mistake, though; that is preference. :)
-- 
    Offlist mail to this address is discarded unless
    "/dev/rob0" or "not-spam" is in Subject: header

  reply	other threads:[~2011-04-30 19:24 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-27  3:07 Proxy Filter iptable Settings Mike Hendrie
2011-04-27  6:16 ` Andrew Beverley
2011-04-27 11:26   ` Mike Hendrie
2011-04-27 12:17     ` Vigneswaran R
2011-04-27 12:45       ` Mike Hendrie
2011-04-27 13:18         ` Vigneswaran R
2011-04-27 13:41           ` Mike Hendrie
2011-04-27 17:24             ` Andrew Beverley
2011-04-28  6:36             ` Vigneswaran R
2011-04-28 21:43               ` Mike Hendrie
2011-04-29  9:16                 ` Vigneswaran R
2011-04-30  8:02                 ` Andrew Beverley
2011-04-30 16:50                   ` /dev/rob0
2011-04-30 17:47                     ` Mike Hendrie
2011-04-30 18:02                       ` Andrew Beverley
2011-04-30 18:23                         ` Mike Hendrie
2011-04-30 19:08                           ` Andrew Beverley
2011-04-30 19:24                             ` /dev/rob0 [this message]
2011-05-03 17:23                               ` Mike Hendrie
2011-04-30 18:04                       ` Jan Engelhardt
2011-04-30 18:28                       ` /dev/rob0
2011-04-27 16:46         ` Mike Hendrie

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=20110430192411.GQ2976@cardinal \
    --to=rob0@gmx.co.uk \
    --cc=netfilter@vger.kernel.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.