🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: DNAT �� SNAT ����

#14332
From: jkwoocn
Date: Tue, 11 Sep 2001 08:10
92 lines
5102 bytes
ʵ�������Router2�Ҳ��õ�linux�汾��Astaro Security Linux 1.811 ,���е�����
������WEB������е�.����B����һTelnet Server,����Router2ʹ����A�ܷ���B,��A��
��B��Telnet Serverʱ,���ܾ�.���Կ϶�����B�ϵ�Ȩ������,Ҳ������������.ǰ��˵
��ֻ��һ������,�ؼ�������֪��DNAT��SNAT�Dz������Ӧ��,����DNAT�Dz��Ǿͱ���ͬ
ʱҲҪ����Ӧ��SNAT

���иղ��Ǹ�����:���ڲ���--destination-port�е�destinationָ��������A����
Router2��������B
(��ݴ�A��B)? Ϊʲô��˵��"�����Լ�23������"?

лл��Ļش�

"madog" <no@no.no> wrote in message news:9nk9pl$mpf$1@madogcc.myip.org...
>
> "jkwoocn" <jkwoocn@yahoo.com> wrote in message
> news:9nk7a9$35s$1@mail.cn99.com...
> > ������A��IPΪ192.168.1.1
>
> ����ô˵�ľ�������һ����û����ʵ�������������Ŀ�أ�
>
> > ���ڲ���--destination-port�е�destinationָ��������A����Router2��������
B?
>
> destination
>
> > ʹ������������������
>
> ��ʾ��ʲô����һ��Could not open a connection to host: Connect failed ?
>
> >     iptables -A PREROUTING -t nat  -i eth0  -s 192.168.1.1  -d 128.1.1.2
\
> >              -p tcp --dport 23 -j DNAT --to 128.2.2.3
>
> #iptables -t nat -L
>
> �ѽ����������һ��
>
>
>
> >
> > "madog" <no@no.no> wrote in message
news:9nk07i$l63$1@madogcc.myip.org...
> > > ������� "--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         |_____ |
> > > >   192.168.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: <9nkgq2$99k$1@mail.cn99.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!sn-xit-03!supernews.com!newsswitch.lcs.mit.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!news.cn99.com!not-for-mail
References: <9njuf6$q9b$1@mail.cn99.com> <9nk07i$l63$1@madogcc.myip.org> <9nk7a9$35s$1@mail.cn99.com> <9nk9pl$mpf$1@madogcc.myip.org>

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-11 01:08:37 PST
Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!sn-xit-03!supernews.com!newsswitch.lcs.mit.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!news.cn99.com!not-for-mail
From: "jkwoocn" <jkwoocn@yahoo.com>
Newsgroups: cn.comp.os.linux
Subject: Re: DNAT �� SNAT ����
Date: Tue, 11 Sep 2001 16:10:29 +0800
Organization: Bentium Ltd. (CN99)
Lines: 94
Message-ID: <9nkgq2$99k$1@mail.cn99.com>
References: <9njuf6$q9b$1@mail.cn99.com> <9nk07i$l63$1@madogcc.myip.org> <9nk7a9$35s$1@mail.cn99.com> <9nk9pl$mpf$1@madogcc.myip.org>
NNTP-Posting-Host: 61.170.136.115
X-Trace: mail.cn99.com 1000195714 9524 61.170.136.115 (11 Sep 2001 08:08:34 GMT)
X-Complaints-To: usenet@news.cn99.com
NNTP-Posting-Date: Tue, 11 Sep 2001 08:08:34 +0000 (UTC)
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.00.2919.6600
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6600