All of lore.kernel.org
 help / color / mirror / Atom feed
From: "kenn murrah" <kenn@thebytebusiness.com>
To: Cedric Blancher <blancher@cartel-securite.fr>
Cc: netfilter@lists.netfilter.org
Subject: Re: newbie question about port blocking
Date: Thu, 17 Apr 2003 15:06:41 -0500	[thread overview]
Message-ID: <001901c3051c$dc8a4c20$2d64a8c0@murrahboy> (raw)
In-Reply-To: 1050591911.740.36.camel@elendil.intranet.cartel-securite.net

well, i DID try this idea from Cedric ..
----- Original Message -----
From: "Cedric Blancher" <blancher@cartel-securite.fr>

Le jeu 17/04/2003 à 16:33, kenn murrah a écrit :
> BTW, i *AM* using squid, and my iptables already includes:
> iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j
> REDIRECT --to-port 3128
> so, will the setup you describe be the only thing i need to add in order
to
> block non-http ports?

You can also set FROWARD chain policy to DROP :

iptables -P FORWARD DROP

This way, everything is denied, unless you use HTTP proxy.



as well as THIS idea from Kim:

> Rules should be:
> $ iptables -t filter -A INPUT -i lo -j ACCEPT
> $ iptables -t filter -A INPUT -p tcp --dport 80 -j ACCEPT
> $ iptables -t filter -A INPUT -j DROP
> $ iptables -t filter -A FORWARD -p tcp --dport 80 -j ACCEPT
> $ iptables -t filter -A FORWARD -j DROP


but both of them resulted in my not being about to access HTTP, either ...
what am I doing wrong here?  Thanks again to both Cedric and Kim ... can you
or anybody else spot what I'm doing wrong ???

all replies appreciated.

Kenn





  reply	other threads:[~2003-04-17 20:06 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-04-17 13:49 newbie question about port blocking kenn murrah
2003-04-17 14:22 ` Kim Jensen
2003-04-17 14:33   ` kenn murrah
2003-04-17 15:05     ` Cedric Blancher
2003-04-17 20:06       ` kenn murrah [this message]
2003-04-17 14:37   ` Kim Jensen

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='001901c3051c$dc8a4c20$2d64a8c0@murrahboy' \
    --to=kenn@thebytebusiness.com \
    --cc=blancher@cartel-securite.fr \
    --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.