Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation

Example: Configuring Simple Authentication for OSPFv2 Exchanges

This example shows how to enable simple authentication for OSPFv2 exchanges.

Requirements

Before you begin:

Overview

Simple authentication uses a plain-text password that is included in the transmitted packet. The receiving routing device uses an authentication key (password) to verify the packet. Plain-text passwords are not encrypted and might be subject to packet interception. This method is the least secure and should only be used if network security is not your goal.

You can configure only one simple authentication key (password) on the routing device. The simple key can be from 1 through 8 characters and can include ASCII strings. If you include spaces, enclose all characters in quotation marks (“ “).

In this example, you specify OSPFv2 interface so-0/1/0 in area 0.0.0.0, set the authentication type to simple-password, and define the key as PssWd4.

Configuration

CLI Quick Configuration

To quickly configure simple authentication, copy the following command, removing any line breaks, and then paste the command into the CLI. You must configure all routing devices within the area with the same authentication and corresponding password.

[edit]set protocols ospf area 0.0.0.0 interface so-0/1/0 authentication simple-password PssWd4

Step-by-Step Procedure

To enable simple authentication for OSPFv2 exchanges:

  1. Create an OSPF area.
    [edit]user@host# edit protocols ospf area 0.0.0.0
  2. Specify the interface.
    [edit protocols ospf area 0.0.0.0]user@host# edit interface so-0/1/0
  3. Set the authentication type and the password.
    [edit protocols ospf area 0.0.0.0 interface so-0/1/0.0]user@host# set authentication simple-password PssWd4
  4. If you are done configuring the device, commit the configuration.
    [edit protocols ospf area 0.0.0.0 interface so-0/1/0.0]user@host# commit

    Note: Repeat this entire configuration on all peer OSPFv2 routing devices in the area.

Results

Confirm your configuration by entering the show protocols ospf command. If the output does not display the intended configuration, repeat the instructions in this example to correct the configuration.

Note: After you configure the password, you do not see the password itself. The output displays the encrypted form of the password you configured.

user@host# show protocols ospf area 0.0.0.0 {interface so-0/1/0.0 {authentication {simple-password "$9$-3dY4ZUHm5FevX-db2g"; ## SECRET-DATA}}}

Verification

Confirm that the configuration is working properly.

Verifying the Configured Authentication Method

Purpose

Verify that the authentication method for sending and receiving OSPF protocol packets is configured. The Authentication Type field displays Password when configured for simple authentication.

Action

From operational mode, enter the show ospf interface and the show ospf overview commands.

Published: 2012-12-08