Ethereal-dev: Re: [Ethereal-dev] dissecting PDU with variable length

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

From: Jaap Keuter <jaap.keuter@xxxxxxxxx>
Date: Thu, 12 Jan 2006 16:13:07 +0100 (CET)
Hi,

Lets see:

	2B std info
	2B encoding count
		8B struct
		4B encoding type
		?B encoded data
		8B struct
		4B encoding type
		?B encoded data
		... repeat 'encoding count' times

So how do you know you've reached the end of the encoded data, so where
the new encoding block begins? Is it defined by the encoding type, or
derived from the decoded data?

Thanx,
Jaap

On Thu, 12 Jan 2006, [iso-8859-1] Lars D?rner wrote:

> Hello
>
> I want to dissect a PDU that is build like this :
>
> 2* 1 Byte standard information
> 1* 2 Byte number of encodings
>
> then there is following for each Encoding:
>
> header :  	8 Byte Struct
> 		4 Byte  kind of encoding
>
> After that there has an automat do be started for encoding the unknown!!!
> number of Bytes requesting
> Byte for Byte till he reached the end of the Data.
>
> The number of Data is different for each encoding.
>
> The Protocol is running on TCP.
>
> I have no idea how to realize that. I need a description or an example
> especially of the functions
> I have to use.
>
> Thx
>
> _______________________________________________
> Ethereal-dev mailing list
> Ethereal-dev@xxxxxxxxxxxx
> http://www.ethereal.com/mailman/listinfo/ethereal-dev
>