🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: cn.comp.os.linux
Article #14326

Re: DNAT �� SNAT ����

#14326
From: madog
Date: Tue, 11 Sep 2001 03:25
41 lines
2993 bytes
������� "--sport 23" ��
����������IPTABLES�Ļ������Ӧ����ROUTER2ֻ��A������23�������Լ�23������תȥ
B

����A��ROUTER2 ������TELNET����һ����
A������1024������һ���˿�--->router2:23

�?128.1.1.1&128.1.1.2��ͬ�εģ��м���ô���и�ROUTER1����ʲô���õģ�

��Ҳ��̫����˵���˱����


--
http://madogcc.myip.org  news://madogcc.myip.org

"jkwoocn" <jkwoocn@yahoo.com> wrote in message
news:9njuf6$q9b$1@mail.cn99.com...
> ����,���繹������
>
>   ______             _______             _______            ______
>   |     |           (       )           (       )          |      |
>   |����A|-----------(Router 1)----------(Router2)----------|����B |
>   |_____|           (_______)        eth0(___)eth1         |_____ |
>   128.1.1.1                      128.1.1.2    128.2.2.2    128.2.2.3
>
> ����,����B�ܹ�ͨ������·�ɷ�������A,������Aֻ��ͨ��һ��·�ɷ��ʵ�Router2,
��
> ����Ϊ��ȫ���趨��
>
> ��Ϊ����������A��ijһ�˿��ܷ�������B, ��Router2����DNAT,��:
>
>     iptables -A PREROUTING -t nat  -i eth0  -s 128.1.1.1  -d 128.1.1.2 \
>              -p tcp --sport 23 --dport 23 -j DNAT --to 128.2.2.3
>
> ����,����A��Ȼ����������B��ͨ��,��������Ϊʲô?�Ƿ��ʱ����B��������Aʱ,
��
> ��ֱ����ԭ�е�·��,��Ӧ��Router2�������һ��SNAT����MASQUERADE?
>
>
>
>
Technical Details
Message-ID: <9nk07i$l63$1@madogcc.myip.org>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!newsfeed.google.com!sn-xit-02!supernews.com!news.tele.dk!small.news.tele.dk!195.158.233.21!news1.ebone.net!news.ebone.net!lnewspeer00.lnd.ops.eu.uu.net!emea.uu.net!newsfeed01.sul.t-online.de!t-online.de!news.cn99.com!madogcc.myip.org!not-for-mail
References: <9njuf6$q9b$1@mail.cn99.com>

Show Full Headers
Complete Article Headers
X-Google-Language: Chinese,GB
X-Google-Thread: 10b277,4fc98b59a1330052
X-Google-Attributes: gid10b277,public
X-Google-ArrivalTime: 2001-09-10 20:40:14 PST
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!newsfeed.google.com!sn-xit-02!supernews.com!news.tele.dk!small.news.tele.dk!195.158.233.21!news1.ebone.net!news.ebone.net!lnewspeer00.lnd.ops.eu.uu.net!emea.uu.net!newsfeed01.sul.t-online.de!t-online.de!news.cn99.com!madogcc.myip.org!not-for-mail
From: "madog" <no@no.no>
Newsgroups: cn.comp.os.linux
Subject: Re: DNAT �� SNAT ����
Date: Tue, 11 Sep 2001 11:25:37 +0800
Organization: madogcc.myip.org
Lines: 43
Message-ID: <9nk07i$l63$1@madogcc.myip.org>
References: <9njuf6$q9b$1@mail.cn99.com>
NNTP-Posting-Host: 61.141.206.203
X-Trace: mail.cn99.com 1000179603 28652 61.141.206.203 (11 Sep 2001 03:40:03 GMT)
X-Complaints-To: usenet@news.cn99.com
NNTP-Posting-Date: Tue, 11 Sep 2001 03:40:03 +0000 (UTC)
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000