Class: PacketGen::Header::OSPFv2::DbDescription
- Defined in:
- lib/packetgen/header/ospfv2/db_description.rb
Overview
This class handles OSPFv2 DB description packets payload. The DB description payload has the following format:
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Interface MTU | Options |0|0|0|0|0|I|M|MS
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| DD sequence number |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| |
+- -+
| |
+- An LSA Header -+
| |
+- -+
| |
+- -+
| |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| ... |
A DB description payload is composed of:
-
a 16-bit #mtu field (
BinStruct::Int16
), -
a 8-bit #options field (
BinStruct::Int8
), -
a 8-bit #flags field (
BinStruct::Int8
). Supported flags are: -
a 32-bit #sequence_number field (
BinStruct::Int32
), -
and an array of LSAHeaders (#lsas, ArrayOfLSA).
Instance Attribute Summary collapse
-
#dc_opt ⇒ Integer
This bit describes the router’s handling of demand circuits.
- #dn_opt ⇒ Integer
-
#e_opt ⇒ Integer
This bit describes the way AS-external-LSAs are flooded.
- #flags ⇒ Integer
-
#i_flag ⇒ Integer
Init bit.
-
#l_opt ⇒ Integer
This specifies if a LLS Data block is present.
-
#lsas ⇒ ArrayOfLSAHeader
Array of LSA headers.
-
#m_flag ⇒ Integer
More bit.
-
#mc_opt ⇒ Integer
This bit describes whether IP multicast datagrams are forwarded.
-
#ms_flag ⇒ Integer
Master/Slave bit.
- #mt_opt ⇒ Integer
-
#mtu ⇒ Integer
16-bit interface MTU.
-
#n_opt ⇒ Integer
This bit specifies if NSSA is supported.
- #o_opt ⇒ Integer
-
#options ⇒ Integer
8-bit options field.
-
#sequence_number ⇒ Integer
(also: #seqnum)
32-bit DD sequence number, used to sequence the collection of Database Description Packets.
Method Summary
Methods inherited from Base
bind, calculate_and_set_length, #header_id, inherited, #initialize, #ip_header, #ll_header
Methods included from PacketGen::Headerable
#added_to_packet, included, #method_name, #packet, #packet=, #parse?, #protocol_name, #read, #to_s
Constructor Details
This class inherits a constructor from PacketGen::Header::Base
Instance Attribute Details
#dc_opt ⇒ Integer
This bit describes the router’s handling of demand circuits.
70 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 70 OSPFv2.(self) |
#dn_opt ⇒ Integer
70 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 70 OSPFv2.(self) |
#e_opt ⇒ Integer
This bit describes the way AS-external-LSAs are flooded.
70 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 70 OSPFv2.(self) |
#flags ⇒ Integer
84 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 84 define_bit_attr :flags, zero: 5, i_flag: 1, m_flag: 1, ms_flag: 1 |
#i_flag ⇒ Integer
Init bit
84 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 84 define_bit_attr :flags, zero: 5, i_flag: 1, m_flag: 1, ms_flag: 1 |
#l_opt ⇒ Integer
This specifies if a LLS Data block is present.
70 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 70 OSPFv2.(self) |
#lsas ⇒ ArrayOfLSAHeader
Array of LSA headers
97 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 97 define_attr :lsas, ArrayOfLSA, builder: ->(_h, t) { t.new(only_headers: true) } |
#m_flag ⇒ Integer
More bit
84 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 84 define_bit_attr :flags, zero: 5, i_flag: 1, m_flag: 1, ms_flag: 1 |
#mc_opt ⇒ Integer
This bit describes whether IP multicast datagrams are forwarded.
70 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 70 OSPFv2.(self) |
#ms_flag ⇒ Integer
Master/Slave bit
84 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 84 define_bit_attr :flags, zero: 5, i_flag: 1, m_flag: 1, ms_flag: 1 |
#mt_opt ⇒ Integer
70 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 70 OSPFv2.(self) |
#mtu ⇒ Integer
16-bit interface MTU
67 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 67 define_attr :mtu, BinStruct::Int16 |
#n_opt ⇒ Integer
This bit specifies if NSSA is supported.
70 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 70 OSPFv2.(self) |
#o_opt ⇒ Integer
70 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 70 OSPFv2.(self) |
#options ⇒ Integer
70 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 70 OSPFv2.(self) |
#sequence_number ⇒ Integer Also known as: seqnum
32-bit DD sequence number, used to sequence the collection of Database Description Packets.
90 |
# File 'lib/packetgen/header/ospfv2/db_description.rb', line 90 define_attr :sequence_number, BinStruct::Int32 |