ANNOUNCEMENT: Live Wireshark University & Allegro Packets online APAC Wireshark Training Session
July 17th, 2024 | 10:00am-11:55am SGT (UTC+8) | Online

Wireshark-dev: Re: [Wireshark-dev] [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Ma

From: Anders Broman <a.broman@xxxxxxxxxxxx>
Date: Sat, 16 Apr 2011 15:44:21 +0200
Martin Mathieson skrev 2011-04-16 15:18:


On Sat, Apr 16, 2011 at 1:38 PM, Anders Broman <a.broman@xxxxxxxxxxxx> wrote:
Martin Mathieson skrev 2011-04-16 14:03:
Hi Anders,
There is already most of the ROHC profile in packet-pdcp-lte.c.  I'd been meaning to separate it out so that it could be used from other places (e.g. when I create UMTS PDCP...)

Martin
I missed that, how to proceed? I think the ROHC code should live in a separate file I have a trace
with Ethertype ROHC for instance.
Regards
Anders


ROHC should definitely be in a separate file, which I hadn't got around to doing.  My code was mostly written around 3 years ago, but to be honest hasn't been used much.

My implementation needs a few hints to decode the ROHC frame. Here are the ROHC fields in packet-pdcp-lte.h - they are what my company's decoder needs to have supplied to it.



/* RoHC settings */
83 gboolean rohc_compression;
84 unsigned short rohc_ip_version;
85 gboolean cid_inclusion_info;
86 gboolean large_cid_present;
87 enum rohc_mode mode;
88 gboolean rnd;
89 gboolean udp_checkum_present;
90 unsigned short profile;

From a very quick look, I see that your implementation is hard-wired to RTP/IPv4, and comments about maybe using preferences or conversation info to work out other fields.  My preference would be to attach info similar to the above, and let each user fill it in as they can (leaving the possibility to override with preferences).
How about in dissect_rohc() look for private data and in the private data supply a ROHC struct
similar to

#define ASN1_CTX_SIGNATURE 0x41435458  /* "ACTX" */

typedef struct _asn1_ctx_t {
  guint32 signature;
:

with the needed decoder input in that way it can be called from other places supplying the needed information
or if no struct is received use the preferences set. Some of the data can be inferred it the IR/IR-DYN packets are seen
 but that requires context tracking.

Could you supply the struct defenition, so it'll fit your data?

Regards
Anders

My very next task happens to be to configure LTE PDCP, RLC and MAC with info found in RRC, and some of these fields can be given then, whereas others are the internal state of the contexts, which is hard to know (without doing a full ROHC simulation!)...

It'd be good to merge them into one standalone dissector that I could then call from PDCP (LTE and UMTS sometime).  I noticed for example that you don't decode all of the feedback options, so maybe my implementation could help speed up the adding of some of these.

There is a screenshot of my decoder in http://wiki.wireshark.org/PDCP-LTE, but I expect I could send you a trace file later on.

Best regards,
Martin


 
On Sat, Apr 16, 2011 at 12:44 PM, <etxrab@xxxxxxxxxxxxx> wrote:
http://anonsvn.wireshark.org/viewvc/viewvc.cgi?view=rev&revision=36659

User: etxrab
Date: 2011/04/16 04:44 AM

Log:
 Add a basic ROCH dissector.
 Limitations:
 - Small CID
 - RTP profile
 - IPv4

Directory: /trunk/epan/dissectors/
 Changes    Path               Action
 +4 -3      Makefile.common    Modified
 +984 -0    packet-rohc.c      Added

___________________________________________________________________________
Sent via:    Wireshark-commits mailing list <wireshark-commits@xxxxxxxxxxxxx>
Archives:    http://www.wireshark.org/lists/wireshark-commits
Unsubscribe: https://wireshark.org/mailman/options/wireshark-commits
            mailto:wireshark-commits-request@xxxxxxxxxxxxx?subject=unsubscribe

___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev@xxxxxxxxxxxxx> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request@xxxxxxxxxxxxx?subject=unsubscribe


___________________________________________________________________________
Sent via:    Wireshark-dev mailing list <wireshark-dev@xxxxxxxxxxxxx>
Archives:    http://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
            mailto:wireshark-dev-request@xxxxxxxxxxxxx?subject=unsubscribe

___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev@xxxxxxxxxxxxx> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request@xxxxxxxxxxxxx?subject=unsubscribe