Ethereal-dev: Re: [Ethereal-dev] Fields and protocols relationships

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

From: Guy Harris <gharris@xxxxxxxxx>
Date: Sun, 02 Jan 2005 15:08:03 -0800
Stefano Pettini wrote:

Ok. This means that I can't let the user choose the dissectors for a stack of 2 protocol over UDP.

Not without adding new code to the "Decode As" dialog.

The problem is it's difficult, for dissector A, to understand what's the upper layer protocol.

It *HAS* to understand, in some sense, what the upper layer protocol is - otherwise it can't call the dissector for that protocol!

It doesn't have to be able to determine that from the contents of the packet, although if it can, that's obviously preferable. If it has to be done by the user, then it has to be done by the user - but, even in that case, it has to set something that dissector A uses to determine what protocol dissector to call.