ip ospf authentication

To specify the authentication type for an Open Shortest Path First (OSPF) interface, use the ip ospf authentication command. To remove the authentication type for an interface, use the no form of this command.

ip ospf authentication [ key-chain key-name | message-digest | null ]

no ip ospf authentication

Syntax Description

key-chain key-name
(Optional) Specifies a key chain to use for authentication. The key-name argument can be a maximum of 63 alphanumeric characters.
(Optional) Specifies that message-digest authentication is used.
(Optional) Specifies that no authentication is used. Use this keyword to override any other authentication configured for an area.

Command Default

No authentication

Command Modes

Interface configuration mode

Command History

This command was introduced.

Usage Guidelines

Use the ip ospf authentication command to configure the authentication mode for an OSPF interface. If you use this command with no keywords, use the ip ospf authentication-key command to configure the password. If you use the message-digest keyword, use the ip ospf message-digest-key command to configure the message-digest key for the interface.

The authentication that you configure on an interface overrides the authentication that you configure for the area.

This command requires the LAN Base Services license.


This example shows how to configure message-digest authentication:

switch(config)# interface ethernet 2/1
switch(config-if)# no switchport
switch(config-if)# ip ospf authentication message-digest
switch(config-if)# ip ospf message-digest-key 33 md5 0 mypassword

Related Commands

area authentication
Enables authentication for an OSPF area.
copy running-config startup-config
Saves the configuration changes to the startup configuration file.
ip ospf authentication-key
Assigns a password to be used by neighboring routers that are using the password authentication of OSPF.
ip ospf message-digest-key
Configures the OSPF MD5 message-digest key.
show ip ospf
Displays OSPF information.