ip ospf authentication を使わずにOSPF認証設定



条件
・R1-SW1 間でOSPF認証(clear-text password)を設定しなさい。
・ip ospf authentication を使ってはいけません。


OSPF認証で検証したやつでエリア認証を使えばできるものですね。
簡単なので、検証なしでざっとやりましょ。
下記の状態からスタート。

R1
interface Loopback0
 ip address 1.1.1.1 255.255.255.255
!
interface Serial1/0
 ip address 192.168.0.1 255.255.255.0
!
router ospf 1
 network 192.168.0.0 0.0.0.255 area 0
 network 1.1.1.1 0.0.0.0 area 0

SW1
interface Loopback0
 ip address 2.2.2.2 255.255.255.255
!
interface Serial1/0
 ip address 192.168.0.2 255.255.255.0
!
router ospf 1
 network 192.168.0.0 0.0.0.255 area 0
 network 2.2.2.2 0.0.0.0 area 0

これで普通にneighborがはられている状態から、認証を設定しますが、とりあえずインターフェース認証の場合、

R1
s1/0
ip ospf authentication
ip ospf authentication-key cisco

R2
s1/0
ip ospf authentication
ip ospf authentication-key cisco

ってやりますね。
でも今回は ip ospf authentication を使ってはいけないので、

R1
s1/0
ip ospf authentication-key cisco
router ospf 1
area 0 authentication

R2
s1/0
ip ospf authentication-key cisco
router ospf 1
area 0 authentication

で、正解ですね。ちなみにmd5のエリア認証をしたい場合は、

R1
s1/0
ip ospf message-digest-key 10 md5 cisco
router ospf 1
area 0 authentication message-digest

R2
s1/0
ip ospf message-digest-key 10 md5 cisco
router ospf 1
area 0 authentication message-digest

です。終了ー
更新日時 2012/7/22