Wireshark mailing list archives
Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c
From: Martin Mathieson <martin.r.mathieson () googlemail com>
Date: Sat, 16 Apr 2011 15:07:01 +0100
On Sat, Apr 16, 2011 at 2:44 PM, Anders Broman <a.broman () bredband net>wrote:
Martin Mathieson skrev 2011-04-16 15:18: On Sat, Apr 16, 2011 at 1:38 PM, Anders Broman <a.broman () bredband net>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 AndersROHC 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
I haven't really looked into how easy it'd be to track the context and work out some of the ROHC fields. Yes, the above is what is currently done with PDCP-LTE. The pdcp_lte_info struct has information for both the PDCP frame and the ROHC frame, and the ROHC part was what I pasted into my earlier message in this thread. What I'd need to do is split them - fill in the PDCP half, and if there was ROHC present, fill that in and attach it to the PDCP frame. One MAC frame may contain many PDCP/ROHC frames, but rather than attach an array of structs (as I think UMTS RLC does), I just attach one struct and keep overwriting the contents just before the decoder is called. LTE MAC and RLC also already do the same thing with structs for the context they need in order to decode. They either get the info from the log file format (in my case) or parsed from special headers that precede the PDU (see the UDP heuristic formats, but special ethertypes have also been used for MAC). The first step is probably to work out if all of these context fields are really needed, and work out how you can start off by hard-coding them when your ethertype is seen, or maybe from some signalling that sets up the ROHC conversation. Martin
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, MartinOn Sat, Apr 16, 2011 at 12:44 PM, <etxrab () wireshark org> 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 () wireshark org> Archives: http://www.wireshark.org/lists/wireshark-commits Unsubscribe: https://wireshark.org/mailman/options/wireshark-commits mailto:wireshark-commits-request () wireshark org ?subject=unsubscribe___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev () wireshark org> <wireshark-dev () wireshark org> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request () wireshark org?subject=unsubscribe <wireshark-dev-request () wireshark org?subject=unsubscribe> ___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev () wireshark org> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request () wireshark org ?subject=unsubscribe___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev () wireshark org> <wireshark-dev () wireshark org> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request () wireshark org?subject=unsubscribe <wireshark-dev-request () wireshark org?subject=unsubscribe> ___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev () wireshark org> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request () wireshark org?subject=unsubscribe
___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev () wireshark org> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request () wireshark org?subject=unsubscribe
Current thread:
- Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c Martin Mathieson (Apr 16)
- Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c Martin Mathieson (Apr 16)
- Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c Anders Broman (Apr 16)
- Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c Martin Mathieson (Apr 16)
- Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c Anders Broman (Apr 16)
- Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c Martin Mathieson (Apr 16)
- Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c Martin Mathieson (Apr 16)
- <Possible follow-ups>
- Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c Stephen Fisher (Apr 19)
- Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c Guy Harris (Apr 19)
- Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c Martin Mathieson (Apr 19)
- Re: [Wireshark-commits] rev 36659: / /trunk/epan/dissectors/: Makefile.common packet-rohc.c Guy Harris (Apr 19)