Configuring OSPF interface authentication

Configure authentication on the interface. Only one method of authentication can be active on an interface at a time. If one method is already configured on an interface, configuring an alternative method on the same interface automatically overwrites the first method used.

Prerequisites

You must be in the interface configuration context, as indicated by the switch(config-if)# prompt.

Procedure
  1. Set the authentication type that will be used for authentication with the neighbor router using the following command. For command details, see ip ospf authentication.

    ip ospf authentication {message-digest | simple-text | null}

    For example, the following command set the authentication type to simple-text.
    switch(config-if)# ip ospf authentication simple-text
  2. For simple-text authentication, set the password using the following command. For command details, see ip ospf authentication-key.

    ip ospf authentication-key <password>

    For example:
    switch(config-if)# ip ospf authentication-key secure
  3. For MD5 authentication, set the password using the following command. For command details, see ip ospf message-digest-key md5.

    ip ospf message-digest-key {Key ID 1-255} md5 {ciphertext | plaintext} <key>

    For example:
    switch(config-if)# ip ospf message-digest-key 1 md5 ciphertext 100