Ethereal-dev: Re: [Ethereal-dev] How to use dissector_add
Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.
Guy Harris wrote:
...so one possibility would be to make it a preference setting, as per
one of Luis Ontanon's suggestions. You'd have to pick a default port,
though - although you could make a port number of 0 mean "don't register
it", and make that the default.
Maybe I'll add a default port preference (since there's a good ALC
implementation that uses port 4001, even if that port is registered at
IANA for a different purpose).
No - you could call "dissector_add_handle()" to add it to the list of
dissectors that could be dissected based on the UDP port; it takes no
port number, so it doesn't cause any particular port to be dissected
with the dissector in question, but it does arrange that "Decode As" can
be used with a UDP port number.
Thanks. This seems to be the right way to implement a dissector of an
unspecified UDP port.
Stefano