From: Jason Opperisano <opie@817west.com>
To: netfilter@lists.netfilter.org
Subject: Re: Transparent Proxy to a Remote Squid Box
Date: Fri, 19 Nov 2004 12:11:02 -0500 [thread overview]
Message-ID: <20041119171102.GA20751@bender.817west.com> (raw)
In-Reply-To: <419E1644.1030903@phreaker.net>
On Fri, Nov 19, 2004 at 11:50:28PM +0800, ro0ot wrote:
> I am running the below scripts for "Transparent Proxy to a Remote Squid
> Box": -
>
> $IPTABLES -t nat -A PREROUTING -i $cusif -s ! $squid_box -p tcp --dport
> 80 -j DNAT --to $squid_box:3128
> $IPTABLES -t nat -A POSTROUTING -o $cusif -s $cus_net -d $squid_box -j
> SNAT --to $cus_ip
> $IPTABLES -A FORWARD -s $eastin_i001 -d $squid_box -i $cusif -o $cusif
> -p tcp --dport 3128 -j ACCEPT
>
> If the daemon dies, I need to remove the above three lines. How can I
> monitor the Squid daemon from the firewall?
i do not see how this is at all relevant to a netfilter mailing list.
that being said--there are infinite ways for you to do this--the 10
second response is:
setup shared SSH keys between the firewall and the squid box.
on the firewall, run a cron job that checks for the squid process on the
remote machine:
---begin script---
alive=`ssh $SQUIDHOST "if pgrep squid > /dev/null; then echo 1;else echo 0;
fi"`
if [ $alive -eq 0 ]; then
iptables -D [ ... ]
fi
---end script---
since this is completely OT--i'm not really looking for comments on the
lameness of the above... :-D
-j
--
"Ah, good ol' trustworthy beer. My love for you will never die."
--The Simpsons
prev parent reply other threads:[~2004-11-19 17:11 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-11-19 15:50 Transparent Proxy to a Remote Squid Box ro0ot
2004-11-19 17:11 ` Jason Opperisano [this message]
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=20041119171102.GA20751@bender.817west.com \
--to=opie@817west.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox