Εργαστήριο Σχεδίασης Δικτύων Υπολογιστών ΘΕΩΡΙΑ 9 ου ΕΡΓΑΣΤΗΡΙΟΥ Σύνδεση WAN Ενθυλάκωση HDLC και PPP
Εξάσκηση στο σπίτι
Άσκηση- ενθυλάκωση PPP Υλοποιείστε την παραπάνω συνδεσμολογία Διαμορφώστε τους δρομολογητές με τα παρακάτω interfaces: *ΣΗΜΕΙΩΣΗ: Στον δρομολογητή 2811A (σχήμα και πίνακας) όπου 0/0/0 και 0/1/1 interfaces εννοούμε 0/0 και 0/1 αντίστοιχα Επιβάλετε δρομολόγηση OSPF 2621A(config)#router ospf 100 2621A(config-router)#network 172.16.20.2 0.0.0.0 area 0 2621A(config-router)#network 172.16.40.0 0.0.0.255 area 0 2621A(config-router)#ctrl+z 2621B(config)#router ospf 101 2621B(config-router)#network 172.16.30.2 0.0.0.0 area 0 2621B(config-router)#network 172.0.0.0 0.255.255.255 area 0 2621B(config-router)#ctrl+z 2811A(config)#router ospf 102 2811A(config-router)#network 172.16.10.1 0.0.0.0 area 0 2811A(config-router)#network 172.16.20.1 0.0.0.0 area 0 2811A(config-router)#network 172.16.30.1 0.0.0.0 area 0 2811A(config-router)#ctrl+z Ορίστε στις σειριακές WAN συνδέσεις (interfaces) router ενθυλάκωση PPP 2811A>enable 2811A#config t 2811A(config)#interface serial 0/0 2811A(config-if)#encapsulation ppp
2811A(config-if)#interface serial 0/1 2811A(config-if)#encapsulation ppp 2811A(config-if)#ctrl+z 2811A# 2621B>enable 2621B#config t 2621B(config)#interface serial 0/0 2621B(config-if)#encapsulation ppp 2621B(config-if)#ctrl+z 2621B# 2621A>enable 2621A#config t 2621A(config)#interface serial 0/0 2621A(config-if)#encapsulation ppp 2621A(config-if)#ctrl+z 2621A# Επιβεβαιώστε τη δρομολόγηση με show ip route: 2621A#show ip route [output cut] 172.16.0.0/16 is variably subnetted, 6 subnets, 2 masks O 172.16.30.0/24 [110/74] via 172.16.20.1, 22:22:18, Serial0/0 C 172.16.20.1/32 is directly connected, Serial0/0 C 172.16.40.0/24 is directly connected, FastEthernet0/0 O 172.16.50.0/24 [110/74] via 172.16.20.1, 22:22:18, Serial0/0 C 172.16.20.0/24 is directly connected, Serial0/0 O 172.16.10.0/24 [110/74] via 172.16.20.1, 22:22:18, Serial0/0 2621A# 2621B#show ip route [output cut] 172.16.0.0/16 is variably subnetted, 6 subnets, 2 masks C 172.16.30.1/32 is directly connected, Serial0/0 C 172.16.30.0/24 is directly connected, Serial0/0 O 172.16.40.0/24 [110/74] via 172.16.30.1, 22:22:18, Serial0/0 C 172.16.50.0/24 is directly connected, FastEthernet0/0 O 172.16.20.0/24 [110/74] via 172.16.30.1, 22:22:18, Serial0/0 O 172.16.10.0/24 [110/74] via 172.16.30.1, 22:22:18, Serial0/0 2621B# 2811A#show ip route [output cut] 172.16.0.0/16 is variably subnetted, 7 subnets, 2 masks C 172.16.30.2/32 is directly connected, Serial0/0 C 172.16.30.0/24 is directly connected, Serial0/0 O 172.16.40.0/24 [110/74] via 172.16.20.2, 22:22:18, Serial0/1 C 172.16.20.2/32 is directly connected, Serial0/1
O 172.16.50.0/24 [110/74] via 172.16.30.2, 22:22:18, Serial0/0 C 172.16.20.0/24 is directly connected, Serial0/1 C 172.16.10.0/24 is directly connected, FastEthernet0/0 2811A# Επιβεβαιώστε τη ενθυλάκωση PPP με show interface: 2811A#show interface s0/0 Serial0/0 is up, line protocol is up Hardware is GT96K Serial Description: connection to 2621B Internet address is 172.16.30.1/24 MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec, reliablility 255/255, txload 1/255, rxload 1/255 Encapsulation PPP, loopback not set [output cut] 2811A#show interface s0/1 Serial0/1 is up, line protocol is up Hardware is GT96K Serial Description: connection to 2621A Internet address is 172.16.20.1/24 MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec, reliablility 255/255, txload 1/255, rxload 1/255 Encapsulation PPP, loopback not set *ΣΗΜΕΙΩΣΗ: μπορείτε ομοίως να επιβάλετε ενθυλάκωση HDLC Επιβάλετε CHAP αυθεντικοποίηση σε κάθε δρομολογητή Είναι εφικτή η αυθεντικοποίηση PPP για την παρεμπόδιση ανεπιθύμητων χρηστών να συνδεθούν στο δίκτυο. Μολονότι χρησιμοποιείται για dial-up συνδέσεις, εντούτοις μπορεί να χρησιμοποιηθεί και σε σειριακά interfaces. Παρακάτω θα διευθετήσουμε αυθεντικοποίηση PPP σε όλα τα σειριακά interfaces των δρομολογητών με χρήση του πρωτοκόλλου CHAP. Challenge Authentication Protocol (CHAP) χρησιμοποιείται κατά την εκκίνηση μίας σύνδεσης, και την τσεκάρει περιοδικά για να διασφαλίσει την ασφαλή επικοινωνία του router με τους ίδιους και όχι άλλους host. Μετά το πέραν της αρχικής φάσης ο τοπικός router στέλνει αίτημα σε απόμακρο κόμβο. Ο τελευταίος στέλνει πίσω μία τιμή υπολογισμένη από μία συνάρτηση ονομαζόμενη MD5. Ο τοπικός router τσεκάρει να δει αν ταιριάζει η τιμή αυτή με αυτή που διαφυλάτει. Αν δεν ταιριάζει τότε τερματίζει τη σύνδεση. Για την υλοποίηση αυθεντικοποίησης PPP, πρώτα ορίζουμε hostname στον τοπικό router. Στη συνέχεια ορίζουμε username και password για τον απόμακρο κόμβο (router) που συνδέεται με τον αρχικό router. Για παράδειγμα αν είμαστε συνδεδεμένοι με τον 2621A router και θέλουμε να επιβάλουμε αυθεντικοποίηση, ορίζουμε κατά τα γνωστά hostname και στη συνέχεια δημιουργούμε username ως το hostname του router που θα συνδεθούμε πχ το 2811A για τον router 2811A.
Επιπλέον τα password για όλους τους routers θα πρέπει να είναι τα ίδια. Επιβεβαιώνονται με την εντολή show run. Αυτή τη διαδικασία την επιβάλουμε για όλες τις συνδέσεις. 2621A#config t 2621A(config)#username 2811A password cisco 2621A(config)#interface serial 0/0 2621A(config-if)#ppp authentication chap 2621A(config-if)#ctrl+z 2621A# 2621B#config t 2621B(config)#username 2811A password cisco 2621B(config)#interface serial 0/0 2621B(config-if)#ppp authentication chap 2621B(config-if)#ctrl+z 2621B# 2811A#config t 2811A(config)#username 2621A password cisco 2811A(config)#username 2621B password cisco 2811A(config)#interface serial 0/0 2811A(config-if)#ppp authentication chap 2811A(config)#interface serial 0/1 2811A(config-if)#ppp authentication chap 2811A(config-if)#ctrl+z Επιβεβαιώστε ξανά τη δρομολόγηση με show ip route και την ενθυλάκωση PPP με show interface: 2811A#show interface s0/0 Serial0/0 is up, line protocol is up Hardware is GT96K Serial Description: connection to 2621B Internet address is 172.16.30.1/24 MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec, reliablility 255/255, txload 1/255, rxload 1/255 Encapsulation PPP, loopback not set Keepalive set (10) Last input 00:00:02, output 00:00:06, output hang never Last clearing of "show interface" counters 02:41:59 Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0 Queueing strategy: weighted fair Output queue: 0/1000/64/0 (size/max total/threshold/drops) Conversations 0/1/256 (active/max active/max total) Reserved Conversations 0/0 (allocated/max allocated) Available Bandwidth 1158 kilobits/sec 5 minute input rate 0 bits/sec, 0 packets/sec 5 minute output rate 0 bits/sec, 0 packets/sec 1645 packets input, 100265 bytes, 0 no buffer
Received 1139 broadcasts, 0 runts, 0 giants, 0 throttles 0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort 1662 packets output, 105842 bytes, 0 underruns 0 output errors, 0 collisions, 3 interface resets 0 output buffer failures, 0 output buffers swapped out 2 carrier transitions DCD=up DSR=up DTR=up RTS=up CTS=up 2811A# 2811A#show interface s0/1 Serial0/1 is up, line protocol is up Hardware is GT96K Serial Description: connection to 2621A Internet address is 172.16.20.1/24 MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec, reliablility 255/255, txload 1/255, rxload 1/255 Encapsulation PPP, loopback not set Keepalive set (10) Last input 00:00:02, output 00:00:06, output hang never Last clearing of "show interface" counters 02:41:59 Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0 Queueing strategy: weighted fair Output queue: 0/1000/64/0 (size/max total/threshold/drops) Conversations 0/1/256 (active/max active/max total) Reserved Conversations 0/0 (allocated/max allocated) Available Bandwidth 1158 kilobits/sec 5 minute input rate 0 bits/sec, 0 packets/sec 5 minute output rate 0 bits/sec, 0 packets/sec 1645 packets input, 100265 bytes, 0 no buffer Received 1139 broadcasts, 0 runts, 0 giants, 0 throttles 0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort 1662 packets output, 105842 bytes, 0 underruns 0 output errors, 0 collisions, 3 interface resets 0 output buffer failures, 0 output buffers swapped out 2 carrier transitions DCD=up DSR=up DTR=up RTS=up CTS=up