All of lore.kernel.org
 help / color / mirror / Atom feed
From: dmorris <dmorris@neogenen.com>
To: netfilter-devel@lists.netfilter.org
Subject: Transparent proxy non-local bind conflict.
Date: 07 Apr 2003 12:09:49 -0700	[thread overview]
Message-ID: <1049742595.401.41.camel@timmy> (raw)

Hello all,

I'm writing a transparent proxy app, which uses the non-local binding
patch and friends here:
http://www.neogenen.com/patches/netcap.kernel-2.5.66.040303.patch

Here's the typical setup:
[box A] <----------> [box T] <--------> [box B]

Here's a step by step play.
A makes a connection to B, which T uses redirect to direct to the
transparent proxy app.
T then gets the original (dest,port) and origal (src,port) binds the
socket to the original (src,port) and makes a connection to the original
(dst,port).

And here's the problem I'm having:
The second connection (t->b) fails. T sends a syn to B,
B replies with a syn/ack (to who it thinks is A, but is actually T)
but T rejects with a RST.

The reason for this, I suspect, is that there are two connections (a->t
and b->t) with the exact same 5-tuple (protocol, src, dst, src-port,
dst-port), and so ip_conntrack kills the second connection. 
(I must have ip_conntrack to do the redirection)
So does anyone have any ideas how I can break ip_conntrack to handle 
both connections, or perhaps ignore the second one?

thanks,
-dirk 
 

-- 
//* */   dmorris   (* www.neogenen.com *)
main(){int _=0;for(;_!=1687193639&&putchar(" \
dn\nc@oge.m"[abs(_%11)]);_=(_*42913)+115127);}

                 reply	other threads:[~2003-04-07 19:09 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=1049742595.401.41.camel@timmy \
    --to=dmorris@neogenen.com \
    --cc=netfilter-devel@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.