配IP
[R1-Serial3/0/0]ip address 192.168.1.1 24
[R2-Serial3/0/0]ip address 192.168.1.2 24
使用ppp协议
[R2]int Mp-group 0/0/0
[R3]int Mp-group 0/0/0
[R2-Serial4/0/0]ppp mp Mp-group 0/0/0
[R2-Serial4/0/1]ppp mp Mp-group 0/0/0
[R3-Serial4/0/0]ppp mp Mp-group 0/0/0
[R3-Serial4/0/0]ppp mp Mp-group 0/0/0
[R2-Mp-group0/0/0]ip address 192.168.2.1 24
[R3-Mp-group0/0/0]ip address 192.168.2.2 24
3.单向验证
[R2-aaa]
[R2-aaa]local-user xxx password cipher 12345
[R2-aaa]local-user xxx service-type ppp
[R2]int s3/0/0
[R2-Serial3/0/0]ppp authentication-mode chap
[R1-Serial3/0/0]ppp chap user xxx
[R1-Serial3/0/0]ppp chap password cipher 12345
验证
[R1]ping 192.168.1.2
PING 192.168.1.2: 56 data bytes, press CTRL_C to break
Reply from 192.168.1.2: bytes=56 Sequence=1 ttl=255 time=110 ms
Reply from 192.168.1.2: bytes=56 Sequence=2 ttl=255 time=30 ms
Reply from 192.168.1.2: bytes=56 Sequence=3 ttl=255 time=20 ms
Reply from 192.168.1.2: bytes=56 Sequence=4 ttl=255 time=20 ms
Reply from 192.168.1.2: bytes=56 Sequence=5 ttl=255 time=30 ms
--- 192.168.1.2 ping statistics ---
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 20/42/110 ms
- 双向验证
11111111111111111
[R2]aaa
[R2-aaa]local-user xxx password cipher 12345
[R2-aaa]local-user xxx service-type ppp
[R2-Serial4/0/0]ppp authentication-mode chap
[R2-Serial4/0/1]ppp authentication-mode chap
[R3-Serial4/0/0]ppp chap user xxx
[R3-Serial4/0/0]ppp chap password cipher 12345
[R3-Serial4/0/1]ppp chap user xxx
[R3-Serial4/0/1]ppp chap password cipher 12345
2222222222222222
[R3]aaa
[R3-aaa]local-user xxx password cipher 12345
[R3-aaa]local-user xxx service-type ppp
[R3-Serial4/0/0]ppp authentication-mode chap
[R3-Serial4/0/1]ppp authentication-mode chap
[R2]int s4/0/0
[R2-Serial4/0/0]ppp chap user xxx
[R2-Serial4/0/0]int s4/0/1
[R2-Serial4/0/1]ppp chap user xxx
双方用户密码一直可以不敲密码