All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marian Stagarescu <marian@ti.com>
To: Ciaran Deignan <ciaran.deignan@netcelo.com>,
	netfilter-devel@lists.netfilter.org
Cc: Matthieu Marc <matthieu.marc@netcelo.com>
Subject: Re: snat and ICMP question
Date: Tue, 8 Oct 2002 15:00:06 -0400	[thread overview]
Message-ID: <200210081500.06505.marian@ti.com> (raw)
In-Reply-To: <3DA30D48.3EA0E56E@netcelo.com>

> I'm using the following configuration
>
> iptables -t mangle -A PREROUTING --in-interface ipsec+ \
>                         -j MARK --set-mark 1
> iptables -t nat -A POSTROUTING -m mark --mark 1 \
>                                 -j MASQUERADE

i think that the icmp packet is not marked hence not masqueraded 
(it is locally generated by the ip stack (above ipsec anyways) hence
does not follow rule 1 mangle above).

is this your config ?

      
                    SNAT
             ------------------->
ipsec-interface         public_interface-------WEB-SERVER
     mtu 1400             mtu 1500
                                       |               1500
                                       |         <-------------      
                                       |                       
        ICMP frag required     |
        (OUTPUT) ------------+

> However the IPsec tunnel had an MTU of 1400, slightly less
> than the ethernet packet. When a user requests a large
> web page (for example), the web server send big packets,
> and an ICMP error is generated by the NAT-ing node. However
> the ICMP packet contains the real destination address, not
> the address of the NAT device... The web server ignores the
> ICMP error, which is normal.
>
> I'm using iptables v1.2.7a with a 2.4.17 kernel. I haven't
> tried anding any additional patches.
>
> Has anybody previously encountered this sort of problem?
> How can I tell iptables to NAT inside ICMP packets that are
> generated locally but that concern connections coming
> from the tunnel? I suppose it would work if I just
> masquraded everything going through any interface,
> but that seems a bit drastic...
>
> Thanks for any pointers,
> Ciaran

  reply	other threads:[~2002-10-08 19:00 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-10-08 16:52 snat and ICMP question Ciaran Deignan
2002-10-08 19:00 ` Marian Stagarescu [this message]
2002-10-09 10:11   ` Ciaran Deignan
2002-10-09 11:16     ` Ciaran Deignan
2002-10-09 13:34       ` Marian Stagarescu
2002-10-10 10:23         ` Ciaran Deignan
2002-10-10 10:41           ` Balazs Scheidler
  -- strict thread matches above, loose matches on Subject: below --
2002-10-03 10:20 Ciaran Deignan
2002-10-03 12:36 ` Ciaran Deignan

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=200210081500.06505.marian@ti.com \
    --to=marian@ti.com \
    --cc=ciaran.deignan@netcelo.com \
    --cc=matthieu.marc@netcelo.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.