From: Philip Craig <philipc@snapgear.com>
To: Mikko Alutoin <mikko.alutoin@vtt.fi>
Cc: netfilter@lists.netfilter.org
Subject: Re: Transparent proxying using REDIRECT
Date: Thu, 17 Jul 2003 17:35:49 +1000 [thread overview]
Message-ID: <3F1651D5.5060708@snapgear.com> (raw)
In-Reply-To: <4.2.2.20030717085400.00cb6ac0@vttmail.vtt.fi>
Mikko Alutoin wrote:
> How does the proxy get to know the original destination IP address and
> port? By looking into the HTTP-request, perhaps? If so, what if the
> application protocol (some other than HTTP) does not contain the
> destination URL?
Use SO_ORIGINAL_DST, for example:
getsockopt(fd, SOL_IP, SO_ORIGINAL_DST, &dst_addr, &addrlen);
--
Philip Craig - philipc@snapgear.com - http://www.SnapGear.com
SnapGear - Custom Embedded Solutions and Security Appliances
prev parent reply other threads:[~2003-07-17 7:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-07-17 6:24 Transparent proxying using REDIRECT Mikko Alutoin
2003-07-17 5:28 ` Arthur Meyer
2003-07-17 7:22 ` Cedric Blancher
2003-07-17 7:35 ` Philip Craig [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=3F1651D5.5060708@snapgear.com \
--to=philipc@snapgear.com \
--cc=mikko.alutoin@vtt.fi \
--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.