All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Usuário do Sistema" <maiconlp@ig.com.br>
To: Pandu Poluan <pandu@poluan.info>
Cc: Mail List - Netfilter <netfilter@vger.kernel.org>
Subject: Re: Access Interfaces Wan
Date: Fri, 30 Sep 2011 15:25:18 -0300	[thread overview]
Message-ID: <CAMTjHrwM65DpLDsxy43K_AzUUA2TCivFbM_a5y6Z3mZ38uxcdA@mail.gmail.com> (raw)
In-Reply-To: <CAA2qdGXKDB13HGx3spq2NqqFEB5WfncMBqUVeCvd0D5QH1bRaw@mail.gmail.com>

Maybe been a problem inside of the firewall but I need sure that my
rules are right.



thanks





Em 30 de setembro de 2011 12:58, Pandu Poluan <pandu@poluan.info> escreveu:
>
> On Sep 30, 2011 8:52 PM, "Usuário do Sistema" <maiconlp@ig.com.br> wrote:
>>
>> Hello everyone,
>>
>>
>> I'm needing that my inside network accesses some IPs which are in the
>> my firewall wan interfaces. for exemplo, in the firewall there is the
>> IP 200.247.222.1 on the wan interface. those has a destination NAT to
>> a inside network machine for FTP protocol. so from Internet to
>> ftp://200.247.222.1 it's Working! but from my inside network to
>> ftp://200.247.222.1 isn't Working.
>>
>> I've done some rules as follow:
>>
>>
>> iptables -t nat -I PREROUTING -s 128.2.0.0/24 -d 200.247.222.1 -p tcp
>> --dport 21 -j DNAT --to-destination  128.2.8.214
>>
>> iptables -t nat -I POSTROUTING -s 128.2.0.0/24 -d 200.247.222.1 -o
>> bond0 -j SNAT --to-source 128.2.7.16
>>
>
> I'm betting that this is the problem. After the packet has undergone DNAT in
> PREROUTING, the destination is no longer 200.247.222.1 but 128.2.8.214, so
> the SNAT rule isn't triggered.
>
>> iptables -I FORWARD -s 128.2.0.0/24 -d 200.247.222.1 -j ACCEPT
>>
>
> Also add a rule to ACCEPT packets from 128.2.0.0 destined to 128.2.0.0.
>
> Rgds,
>

      parent reply	other threads:[~2011-09-30 18:25 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-30 13:52 Access Interfaces Wan Usuário do Sistema
2011-09-30 14:02 ` Paulo Ricardo Bruck
2011-09-30 14:51   ` Usuário do Sistema
2011-09-30 15:29     ` Usuário do Sistema
     [not found] ` <CAA2qdGXKDB13HGx3spq2NqqFEB5WfncMBqUVeCvd0D5QH1bRaw@mail.gmail.com>
2011-09-30 18:25   ` Usuário do Sistema [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=CAMTjHrwM65DpLDsxy43K_AzUUA2TCivFbM_a5y6Z3mZ38uxcdA@mail.gmail.com \
    --to=maiconlp@ig.com.br \
    --cc=netfilter@vger.kernel.org \
    --cc=pandu@poluan.info \
    /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.