Bug 2515 - Byte tags cause a crash when calling Packet->AddAtEnd() for large packets.
Byte tags cause a crash when calling Packet->AddAtEnd() for large packets.
Status: RESOLVED DUPLICATE of bug 2069
Product: ns-3
Classification: Unclassified
Component: network
ns-3-dev
All All
: P5 critical
Assigned To: ns-bugs
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2016-10-04 09:44 UTC by l.salameh
Modified: 2016-10-04 10:55 UTC (History)
1 user (show)

See Also:


Attachments
Patch for byte tag list (861 bytes, patch)
2016-10-04 09:46 UTC, l.salameh
Details | Diff
Byte tag list fix. (576 bytes, patch)
2016-10-04 09:47 UTC, l.salameh
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description l.salameh 2016-10-04 09:44:27 UTC
I encountered this bug when running a TCP experiment where I had added Byte Tags to my packets. On recovering from a large slew of drops, a large amount of packets are available to be read by the Application layer, and TcpRxBuffer aggregates them into one large packet. But Packet->AddAtEnd() throws an assertion failure due to the byte tags.


The problem is the 16 bit used size in ByteTagList, which wraps around for large packets and causes an assertion failure in TagBuffer::ReadU8.

See patch for fix (namely changing uint16_t to uint32_t).
Comment 1 l.salameh 2016-10-04 09:46:01 UTC
Created attachment 2604 [details]
Patch for byte tag list
Comment 2 l.salameh 2016-10-04 09:47:16 UTC
Created attachment 2605 [details]
Byte tag list fix.
Comment 3 l.salameh 2016-10-04 10:55:34 UTC
Whoops I guess this is a duplicate of Bug #2069 which has been fixed in ns-3-dev already.

*** This bug has been marked as a duplicate of bug 2069 ***