Ethereal-dev: Re: [Ethereal-dev] Ethernet FCS questions

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Ulf Lamping <ulf.lamping@xxxxxx>
Date: Wed, 28 Sep 2005 23:21:37 +0200
Guy Harris wrote:

Ulf Lamping wrote:

In the protocol PN-RT (directly on top of Ethernet), the last four
user bytes contains some protocol status values. There's no length field
to indicate at which offset the status is,


So are all PN-RT packets > 46 bytes long, so that there's no padding? Or does it have some other way to indicate whether there's Ethernet padding?

Yes, the data is at least 46 bytes long. Two bytes FrameId, the user data (padded to at least 40bytes) and then the 4 byte status.


so I'll have to take the end of the tvb


...after checking to make sure that tvb_length(tvb) == tvb_reported_length(tvb), i.e. that the status wasn't cut off by the snapshot length.

Hmmm, I still don't 100% understand the reported length. To quote the README.developer (identical in README.tvbuff):

"    reported_length is the number of bytes that the current protocol
   says should be in the payload. A reported_length of -1 says that
   the protocol doesn't say anything about the size of its payload."

It might be possible to improve this sentence :-)

Regards, ULFL