日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

[实战]HM-Router configuration for TP ROOM

發布時間:2025/3/21 编程问答 22 豆豆
生活随笔 收集整理的這篇文章主要介紹了 [实战]HM-Router configuration for TP ROOM 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

HM-Router configuration for TP

目標: 讓外網可以訪問FTP server [10.1.1.2] /Telnet(這里為了方便測試,使用telnet),中間跨了2個 Router

++++CNSO-TP01 configuration +++++

conf t

service timestamps debug datetime localtime show-timezone msec

service timestamps log datetime localtime show-timezone msec

service password-encryption

service sequence-numbers

service tcp-keepalives-in

service tcp-keepalives-out

no ip http server

no ip http secure-server

no service config

no logging console

no logging monitor

password encryption aes

key config-key password-encrypt?xxxxx

ip domain name hm.com

ip name-server 8.8.8.8 8.8.8.4

hostname CNSO-TP01

ip cef

ip multicast-routing

!

!

crypto key generate rsa

1024

!

!

!

ip ssh version 2

ip ssh authentication-retries 3

!

!

!

username xxxx priv 15 password 0 xxxx

enable secret 0 xxxxx

line vty 0 4

transport input all

exec-timeout 15 0

logging synchronous

login local

exit

banner exec #

*****************************************************************

*UNAUTHORIZED ACCESS TO THIS DEVICE IS PROHIBITED *

*You must have explicit, authorized permission to access or *

*configure this device. Unauthorized attempts and actions to *

*access or use this system may result in civil and/or criminal *

*penalties.All activities performed on this device are logged *

*and monitored. *

*****************************************************************#

!

!

!

interface f0/0

description *** TP WAN INTERFACE ***

ip address 12.1.1.2 255.255.255.0

no shut

exit

interface Vlan 1

description *** LAN INTERFACE ***

ip address 192.168.1.1 255.255.255.0

no shut

exit

!

!

Service DHCP

ip dhcp pool HM-CN

network 192.168.1.0 255.255.255.0

default-router 192.168.1.1

netbios-node-type h-node

dns-server 8.8.8.8 8.8.4.4

domain-name hm.com

lease 3

exit

ip dhcp excluded-address 192.168.1.1 192.168.1.10

!

!

ip route 0.0.0.0 0.0.0.0 f0/0 12.1.1.1

access-list 1 permit 192.168.1.0 0.0.0.255

ip nat inside source list 1 interface f0/0 overload

ip nat inside source static tcp 192.168.1.11 23 int f0/0 23

!

!

interface f0/0

ip nat outside

no cdp enable

no shut

exit

interface Vlan 1

ip nat inside

cdp ena

no shut

exit

!

試驗結果:

在外面可以telnet R4

CNSO-TP01#sh ip nat translations

Pro Inside global Inside local Outside local Outside global

tcp 12.1.1.2:23 192.168.1.11:23 15.1.1.5:24113 15.1.1.5:24113

tcp 12.1.1.2:23 192.168.1.11:23 15.1.1.5:40245 15.1.1.5:40245

tcp 12.1.1.2:23 192.168.1.11:23 --- ---

=======以上模擬測試是否能進CNSO-TP01 router=================

CNSO-TP01(config)#ip route 10.1.1.0 255.255.255.0 vlan 1

CNSO-TP01(config)#no ip nat inside source static tcp 192.168.1.11?23 int f0/0 23

CNSO-TP01(config)#ip nat inside source static tcp 192.168.1.10?23 int f0/0 23

CT(config)#int f0/1

CT(config-if)#ip nat outside

CT(config-if)#int f0/0

CT(config-if)#ip nat inside

CT(config-if)#exit

CT(config)#access-list 1 permit 10.1.1.0 0.0.0.255

CT(config)#ip nat inside source list 1 interface f0/1 overload

CT(config)#ip nat inside source static tcp 10.1.1.2 23 int f0/1 23

測試成功如下:

CNSO-TP01#sh ip nat translations

Pro Inside global Inside local Outside local Outside global

tcp 12.1.1.2:23 192.168.1.10:23 15.1.1.5:26987 15.1.1.5:26987

tcp 12.1.1.2:23 192.168.1.10:23 --- ---

CT#sh ip nat translations

Pro Inside global Inside local Outside local Outside global

icmp 192.168.1.10:3 10.1.1.2:3 192.168.1.1:3 192.168.1.1:3

tcp 192.168.1.10:23 10.1.1.2:23 15.1.1.5:26987 15.1.1.5:26987

tcp 192.168.1.10:23 10.1.1.2:23 --- ---

總結:學要致用!


本文轉自 bilinyee博客,原文鏈接: ??http://blog.51cto.com/ericfu/1748980? ? ?如需轉載請自行聯系原作者

總結

以上是生活随笔為你收集整理的[实战]HM-Router configuration for TP ROOM的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。