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

Wireshark-dev: Re: [Wireshark-dev] Handling malformed packet exceptions from within ASN.1 disse

From: Anders Broman <anders.broman@xxxxxxxxxxxx>
Date: Tue, 3 Nov 2020 07:56:17 +0000
Hi,
I think a TRY CATCH block is the thing to use. Grep for CTACH and I think you will find a bunch of examples.
Regards
Anders

-----Original Message-----
From: Wireshark-dev <wireshark-dev-bounces@xxxxxxxxxxxxx> On Behalf Of Richard Sharpe
Sent: den 3 november 2020 00:26
To: Developer support list for Wireshark <wireshark-dev@xxxxxxxxxxxxx>
Subject: [Wireshark-dev] Handling malformed packet exceptions from within ASN.1 dissectors

Hi folks,

I am using some of the existing ASN.1 dissectors from within the
ieee802.11 dissector, and in some cases the frame is malformed in the
ASN.1 portion.

However, since it is within an IE where I know the length of the element, I would like to regain control and add an Expert Info and then keep dissecting.

How can I handle this?

--
Regards,
Richard Sharpe
(何以解憂?唯有杜康。--曹操)(传说杜康是酒的发明者)
___________________________________________________________________________
Sent via:    Wireshark-dev mailing list <wireshark-dev@xxxxxxxxxxxxx>
Archives:    https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
             mailto:wireshark-dev-request@xxxxxxxxxxxxx?subject=unsubscribe

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