Linux Netfilter discussions
 help / color / mirror / Atom feed
From: "Rob Sterenborg" <rob@sterenborg.info>
To: 'Tarak Ranjan' <tarak.ranjan@liqwidkrystal.com>,
	netfilter@vger.kernel.org
Subject: RE: Direct Internet Connection For Client
Date: Tue, 13 Nov 2007 09:13:14 +0100	[thread overview]
Message-ID: <000901c825cd$09c13700$1d43a500$@info> (raw)
In-Reply-To: <4739525D.70205@liqwidkrystal.com>

> Hi list,
>            i have installed proxy and gateway in the same system.
> How
> can  stop "Direct Connection" in web browser for internet for the
> clients(proxy). i have redirect 80 port to 8080. then also direct
> connection is happening from the clients. what sort of iptables
> rules
> i've to implement in my gateway firewall , that every time users
> should
> pass through proxy(8080). No Direct Connection........

When your clients can still connect when you redirect port 80 to 8080
then your redirection doesn't work.
This may be because packets hit another rule before the redirection. Or
maybe you are redirecting to localhost which, (last time I tried) is not
possible.

If I'm correct you've posted this question before and when I looked
through that script I didn't have much trust in it. If you really want
good advice, post your ruleset (and perhaps routing table). Otherwise,
simply blocking internet access is done like this:

$ipt -A FORWARD -s <net_lan> -p tcp --dport 80 \
  -j REJECT --reject-with tcp-reset

The actual place where you want to insert the rule depends on the script
you're currently using. This will do nothing if packets are already
accepted by a previous rule.


Grts,
Rob



  parent reply	other threads:[~2007-11-13  8:13 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-13  7:29 Direct Internet Connection For Client Tarak Ranjan
2007-11-13  8:04 ` Покотиленко Костик
2007-11-13  8:13 ` Rob Sterenborg [this message]
2007-11-13 11:46   ` Tarak Ranjan

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='000901c825cd$09c13700$1d43a500$@info' \
    --to=rob@sterenborg.info \
    --cc=netfilter@vger.kernel.org \
    --cc=tarak.ranjan@liqwidkrystal.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox