Huge thanks to our Platinum Members Endace and LiveAction,
and our Silver Member Veeam, for supporting the Wireshark Foundation and project.

Wireshark-dev: Re: [Wireshark-dev] Malformed packets in CORBA protocol plugin

From: Guy Harris <guy@xxxxxxxxxxxx>
Date: Wed, 13 Dec 2006 10:23:55 -0800
Andy.Ling@xxxxxxxxxxx wrote:

Can anyone see any problem with this?

1) as indicated in my earlier mail, it won't throw an exception if you have a bad packet that should have a request body but doesn't.

2) if you ignore that, it should be tvb_reported_length_remaining(), because tvb_length_remaining() gives the amount of *captured* data, not the amount of *actual* data, and you want to throw an exception if the capture was cut short by a snapshot length and that meant that the request body was present on the wire but wasn't in the capture.