The Assimilation Project
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Layout of CDP Packets

CDP is the Cisco Discovery Protocol - which we receive and interpret, but don't send. More...

Collaboration diagram for Layout of CDP Packets:

Modules

 CDP: Offsets of initial non-TLV items in a CDP packet.
 The initial items are a checksum, protocol version, and the time to live of the packet.
 
 CDP: Sizes of the type and length portion of a CDP TLV entry.
 Offsets of things that occur at the beginning of each TLV entry.
 
 CDP: Known values for TLV types
 
 CDP: Capability (CDP_TLV_CAPS) mask bits.
 The TLV type CDP_TLV_CAPS value is a field with a set of bits defining the capabilities which a given switch or router might implement.
 

Detailed Description

CDP is the Cisco Discovery Protocol - which we receive and interpret, but don't send.

CDP packets consist of a 4-byte initial header, followed by any number of Type/Length/Value (TLV) sections. A CDP packet should never exceed 1500 bytes, because they are restricted to single ethernet-level frames. The initial header portion (after ethernet and SNAP headers) is laid out as shown below:

+-------------------—+---------------------—+------------—+
| CDP Protocol Version | CDP Time To Live (TTL) | CDP Checksum  |
|       1 byte         |        1 byte          |    2 bytes    |
+-------------------—+---------------------—+------------—+