Cisco – Does OSPF use a packet checksum using MD5

ciscoospfrouting

When we configure OSPF routers with MD5 authentication, a message digest is created, which is the combination of a pre-defined message-digest-key which has been run through the MD5 algorithm; that must be the same between routers of an area, for example:

  • message-digest-key = cisco
  • md5("cisco") = "dfeaf10390e560aea745ccba53e044ed"

My Question

  • What part of the packet is checksummed by this MD5 hash?
  • Does OSPF check the whole packet? or what exactly?

Please include your references.

Best Answer

From the RFC:

            (c) The MD5 authentication algorithm is run over the
                concatenation of the OSPF packet, secret key, pad
                and length fields, producing a 16 byte message
                digest (see [Ref17]).