Wireshark-dev: Re: [Wireshark-dev] general inquiry on building dissectors for wireshark-3.4.4

From: Anders Broman <anders.broman@xxxxxxxxxxxx>
Date: Thu, 8 Apr 2021 06:15:30 +0000

Hi,

If the protocol is truly described by asn1 documents there are plenty of examples in epan/dissectors/asn1/

Basically you need the asn1 description a template and a .cnf file. Are you building on Windows or Linux?

I’m not familiar with building the asn1 based dissectors on Linux. Are you going to submit the dissector back to the community

Or is it a private one? If it’s a public one we could guide you in an MR.

Best regards

Anders

 

 

From: Wireshark-dev <wireshark-dev-bounces@xxxxxxxxxxxxx> On Behalf Of Graham Bloice
Sent: den 7 april 2021 19:46
To: Developer support list for Wireshark <wireshark-dev@xxxxxxxxxxxxx>
Subject: Re: [Wireshark-dev] general inquiry on building dissectors for wireshark-3.4.4

 

 

 

On Wed, 7 Apr 2021 at 17:28, Vincent Randal <vtrandal@xxxxxxxxx> wrote:

Hello,

 

Where can I find a complete "text based" dissector example that builds with the current Wireshark cmake build method used in wireshark-3.4.4? Does that question even make sense? I fear most people reading my question won't understand what I'm after.

 

I've watched numerous YouTube videos by Graham Bloice and Richard Sharpe that describe 3 primary methods for Wireshark dissector development:

1. Text based

2. Scripting Language based

3. C based

 

In the meantime I have built wireshark-2.6.20 using the older ./autogen.sh, configure, make build method. This gives me hope I might have some success with at least 1 (one) text-based dissector example that uses that build method:

 

 

The text based dissector in my presentation was specifically WSGD which provides its own runtime via a plugin DLL.  It's a bit of a grey area if an ASN.1 dissector is text based, as the description is fed into the dissector generator asn2wrs.py and out pops a C-based dissector.

 

If I were an expert with cmake (which might be easier than I think) I would probably update the text-based examples to build using cmake. But I don't know how to do that (yet).

 

Adding a dissector with CMake is easier (I think)  as it mostly handles platform and compiler differences.  As such the page you link to (which is the old wiki, not our new shiny GitLab one, https://gitlab.com/wireshark/wireshark/-/wikis/ASN1_plugin) is woefully out of date as it doesn't describe how to do that with CMake.

 

Unfortunately I've never dealt with an asn1 based dissector, either built-in or as a plugin so can't offer advice on that.

 

 

Vincent Randal

Longmont, CO

 

--

Graham Bloice

Attachment: smime.p7s
Description: S/MIME cryptographic signature