dpkt icon indicating copy to clipboard operation
dpkt copied to clipboard

please calculate the length of BGP-4 BGP packets automatically

Open kbandla opened this issue 9 years ago • 0 comments

From [email protected] on August 04, 2010 23:15:16

The length of BGP objects is not automatically calculated (the 'len' field'). Please calculate the length automatically when encoding a BGP object.

As a workaround, I have to calculate the length manually this way:

msg = ... msg_with_headers = dpkt.bgp.BGP(len=dpkt.bgp.BGP.hdr_len + len(msg), type=msg_type) msg_with_headers.data = msg

Original issue: http://code.google.com/p/dpkt/issues/detail?id=44

kbandla avatar Jun 04 '15 01:06 kbandla