PPP or Point-to-Point Protocol is a type of Layer 2 protocol (Data-link layer) used mainly for WAN. PPP features two methods of authentication PAP (Password Authentication Protocol) and CHAP (Challenge Handshake Authentication Protocol) a c0nnection is established between two peers only after authentication succeeds. PAP sends the password in cleartext for authentication so CHAP is preferred and will be discussed in this article. PPP encapsulation is possible only over a serial link. This article will showcase two different topologies first with two routers and second with three routers.
Topology 1
The first topology will have just two routers connected directly with a serial cable. Both the routers should have different hostnames.
Router 1
Hostname: R1
Serial 2/0 (DTE): 10.0.0.1/30
Router 2
Hostname: R2
Serial 2/0 (DCE): 10.0.0.2/30
Common Password: ppppwd123
On both the routers enable debugging of PPP negotiation so that you can see the connectivity process.
Router#debug ppp negotiation
PPP negotiation debugging is on
Configuring the first router
Router>enable
Router#configure terminal
Router(config)#hostname R1
R1(config)#username R2 password ppppwd123
R1(config)#interface Serial 2/0
R1(config-if)#encapsulation ppp
R1(config-if)#ppp authentication chap
R1(config-if)#ip address 10.0.0.1 255.255.255.252
R1(config-if)#no shutdown
Configuring the second router
Router>enable
Router#configure terminal
Router(config)#hostname R2
R2(config)#username R1 password ppppwd123
R2(config)#interface Serial 2/0
R2(config-if)#encapsulation ppp
R2(config-if)#ppp authentication chap
R2(config-if)#clock rate 64000
R2(config-if)#ip address 10.0.0.2 255.255.255.252
R2(config-if)#no shutdown
Since the DCE end of the cable is connected to the second router a clock rate has to be set. Also note that the following
Hostname of first router = Username of the second router
Hostname of the second router = Username of the first router
After the “no shutdown” command is enabled on the second router you should see the following
Serial2/0 PPP: Using default call direction
Serial2/0 PPP: Treating connection as a dedicated line
Serial2/0 PPP: Phase is ESTABLISHING, Active Open
Serial2/0 LCP: State is Open
Serial2/0 PPP: Phase is AUTHENTICATING
Serial2/0 IPCP: O CONFREQ [Closed] id 1 len 10
Serial2/0 IPCP: I CONFACK [Closed] id 1 len 10
Serial2/0 IPCP: O CONFREQ [Closed] id 1 len 10
Serial2/0 IPCP: I CONFACK [REQsent] id 1 len 10
Serial2/0 LCP: State is Open
Serial2/0 PPP: Phase is AUTHENTICATING
Serial2/0 IPCP: O CONFREQ [Closed] id 1 len 10
Serial2/0 IPCP: I CONFREQ [Closed] id 1 len 10
Serial2/0 IPCP: O CONFACK [Closed] id 1 len 10
Serial2/0 IPCP: I CONFACK [Closed] id 1 len 10
Serial2/0 IPCP: O CONFREQ [Closed] id 1 len 10
Serial2/0 IPCP: I CONFREQ [REQsent] id 1 len 10
Serial2/0 IPCP: O CONFACK [REQsent] id 1 len 10
Serial2/0 IPCP: I CONFACK [REQsent] id 1 len 10
Serial2/0 PPP: Phase is FORWARDING, Attempting Forward
Serial2/0 Phase is ESTABLISHING, Finish LCP
Serial2/0 Phase is UP
You should now be able to ping both the routers from each other.
Topology 2
In the second topology we will add a third router and connect it to R2’s Serial 3/0 interface.
Router 2
Serial 3/0 (DCE): 10.0.0.5/30
Router 3
Hostname: R3
Serial 3/0 (DTE): 10.0.0.6/30
Common password: newLink123
We need to add one more username/password combination in R2 and configure its interface.
R2(config)#username R3 password newLink123
R2(config)#interface Serial 3/0
R2(config-if)#encapsulation ppp
R2(config-if)#ppp authentication chap
R2(config-if)#clock rate 64000
R2(config-if)#ip address 10.0.0.5 255.255.255.252
R2(config-if)#no shutdown
Configuring third router
Router>enable
Router#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#hostname R3
R3(config)#username R2 password newLink123
R3(config)#interface Serial 3/0
R3(config-if)#encapsulation ppp
R3(config-if)#ppp authentication chap
R3(config-if)#ip address 10.0.0.6 255.255.255.252
R3(config-if)#no shutdown
For R1 and R3 to communicate with each other routing has to be configured on both. Since R2 is directly connected with both we don’t have to configure routing on it. For this article I will use static routing.
R1(config)#ip route 10.0.0.4 255.255.255.252 10.0.0.2
R3(config)#ip route 10.0.0.0 255.255.255.252 10.0.0.5
Leave a Reply