root
Well-Known Member
- Joined
- Dec 31, 2012
- Messages
- 1,153
- Reaction score
- 71
- Points
- 48
I. Yêu Cầu
1. Cấu hình PPPoE
2. Cấu hình VPN Client to Site
3. Client
- Mô hình triển khai
- Yêu cầu:
- Cấu hình PPPoE cho Router Cisco 892 thay thế cho Modem nhà mạng
- Cấu hình VPN client-to-site trên Router Cisco 892
1. Cấu hình PPPoE
- Với Router 892 của Cisco hỗ trợ 3 port WAN
- 2 port GigabitEthernet 8 và GigabitEthernet 9
- 1 port SPF
- Và có thêm 8 port LAN ở layer 2 từ GigabitEthernet 0 đến GigabitEthernet 7
- Sau đây là cấu hình Router 892 mình đã config pppoe cho nó
// Đưa interface G1 vào VLAN 10 interface GigabitEthernet0 switchport access vlan 10 spanning-tree portfast no ip address ! interface GigabitEthernet1 no ip address ! interface GigabitEthernet2 no ip address ! interface GigabitEthernet3 no ip address ! interface GigabitEthernet4 no ip address ! interface GigabitEthernet5 no ip address ! interface GigabitEthernet6 no ip address ! interface GigabitEthernet7 no ip address ! // Cấu hình pppoe trên interface G8 interface GigabitEthernet8 no ip address ip nat outside ip virtual-reassembly in ip tcp adjust-mss 1452 duplex auto speed auto pppoe enable group global pppoe-client dial-pool-number 1 ! interface GigabitEthernet9 no ip address shutdown duplex auto speed auto ! interface Vlan1 no ip address ! // Đặt IP cho VLAN 10. Vì các port còn lại của Router 892 đều là port layer 2 nên chúng ta cần cấu hình inter-VLAN cho Router 892 interface Vlan10 ip address 192.168.10.254 255.255.255.0 ip nat inside ip virtual-reassembly in ! // Cấu hình PPPoE, chứng thực giữa Router 892 và ISP, đặt IP tĩnh cho cổng Dialer 1 interface Dialer1 ip address 16.18.18.65 255.255.255.252 ip nat outside ip virtual-reassembly in encapsulation ppp dialer pool 1 dialer-group 1 ppp chap hostname svuit ppp chap password 0 svuit.vn ppp pap sent-username svuit password 0 svuit.vn no cdp enable ! ip forward-protocol nd no ip http server no ip http secure-server ! ! ip nat inside source static 192.168.10.5 16.18.18.66 // NAT overload cho interface Dialer1 ip nat inside source list 1 interface Dialer1 overload // Default Router qua cổng Dialer 1 ip route 0.0.0.0 0.0.0.0 Dialer1 ! ! access-list 1 permit any |
2. Cấu hình VPN Client to Site
- Việc cấu hình VPN client to site tương tự như các bài lab trước. Các bạn có thể tham khảo thêm trên forum. Dưới đây là cách mình config VPN client to site cho Router 892 của Cisco
// Pharse 1 R1(config)#crypto isakmp policy 10 R1(config-isakmp)#encryption 3des R1(config-isakmp)#authentication pre-share R1(config-isakmp)#hash md5 R1(config-isakmp)#group 2 R1(config-isakmp)#exit / Pharse 2 R1(config)#crypto ipsec transform-set MYSET esp-3des esp-md5-hmac R1(config)#crypto dynamic-map DYNAMIC_MAP 10 R1(config-crypto-map)#set transform-set MYSET R1(config)#crypto map CLIENT-MAP client authentication list userauthen R1(config)#crypto map CLIENT-MAP isakmp authorization list groupauthor R1(config)#crypto map CLIENT-MAP client configuration address respond R1(config)#crypto map CLIENT-MAP 10 ipsec-isakmp dynamic DYNAMIC_MAP R1(config)#ip local pool IP-POOL 10.10.10.1 10.10.10.10 R1(config)#ip access-list extended ACL-VPN R1(config-ext-nacl)#permit ip 192.168.10.0 0.0.0.255 10.10.10.0 0.0.0.255 R1(config-ext-nacl)#exit R1(config)#crypto isakmp client configuration group VPN-CLIENT R1(config-isakmp-group)#key svuit R1(config-isakmp-group)#dns 8.8.8.8 R1(config-isakmp-group)#domain svuit.vn R1(config-isakmp-group)#pool IP-POOL R1(config-isakmp-group)#acl ACL-VPN R1(config)#username svuit password svuit.com // Khác với ASA, VPN trên Router phải áp trên Dialer1 R1(config)#interface Dialer1 R1(config-if)#crypto map CLIENT-MAP |
3. Client
- Client thực hiện truy cập VPN về Router 892 thành công