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

Ethereal-dev: RE: [Ethereal-dev] Help With Plug-in Dissector

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

From: Sahil Kumar <Sahil.Kumar@xxxxxxxxxxx>
Date: Wed, 15 Jun 2005 09:56:50 -0500
Hi Gilbert,

I had another quick question. I am trying to register one of my
protocols over a protocol that I had built. I am not sure how to do
this. I have tried to do it the same way as 

    PROTO2_handle = find_dissector("PROTO2");
    dissector_add("PROTO1", PROTO1_PROTO2, PROTO1_handle);

And I defined the value of PROTO1_PROTO2 as the required hex. value, but
still it is not dissecting the second protocol.

I would appreciate if you could guide me on how to associate the packet
type field of PROTO1 with calling PROTO2.

Thanks!

Best Regards,
Sahil

 

-----Original Message-----
From: ethereal-dev-bounces@xxxxxxxxxxxx
[mailto:ethereal-dev-bounces@xxxxxxxxxxxx] On Behalf Of Gilbert Ramirez
Sent: Thursday, June 09, 2005 3:22 PM
To: Ethereal development
Subject: Re: [Ethereal-dev] Help With Plug-in Dissector

Your dissector needs to register itself to the "ethertype" dissector
call. Look at how packet-ipx.c does it:

    ipx_handle = find_dissector("ipx");
    dissector_add("ethertype", ETHERTYPE_IPX, ipx_handle);

In this case, ETHERTYPE_IPX is defined as 0x8137 in etypes.h in the
top-level directory of the Ethereal source code.

--gilbert

On 6/9/05, Sahil Kumar <Sahil.Kumar@xxxxxxxxxxx> wrote:
>  
> Hi,
>   
> I really need some help here. I am building a protocol that is 
> currently seen in ethereal as  "Type: unknown (0x0606)" . I am pretty 
> sure my plug-in dissector is almost complete and correct. The issue 
> that I am unable to figure out is why is my protocol not being 
> identified by Ethernet II. I am sure I am missing something small 
> here. I would truly appreciate it if you could let me know where am I
missing something out.
> More precisely, how do I make Ethernet II know that the Type 0x0606 is

> my protocol!!
> Thanks a ton. 
>   
> Best Regards,
> Sahil
>  
> -----------------------------------------------------------
> -----
>  Visit our Internet site at http://www.reuters.com
>  
>  To find out more about Reuters Products and Services visit 
> http://www.reuters.com/productinfo
>  
>  Any views expressed in this message are those of the individual  
> sender, except where the sender specifically states them to be  the 
> views of Reuters Ltd.
>  
> _______________________________________________
> Ethereal-dev mailing list
> Ethereal-dev@xxxxxxxxxxxx
> http://www.ethereal.com/mailman/listinfo/ethereal-dev
> 
> 
>

_______________________________________________
Ethereal-dev mailing list
Ethereal-dev@xxxxxxxxxxxx
http://www.ethereal.com/mailman/listinfo/ethereal-dev


------------------------------------------------------- ---------
        Visit our Internet site at http://www.reuters.com

To find out more about Reuters Products and Services visit http://www.reuters.com/productinfo 

Any views expressed in this message are those of  the  individual
sender,  except  where  the sender specifically states them to be
the views of Reuters Ltd.