Search code examples
lte

How to know a received packet is a TM, UM or AM RLC packet?


I'm writing a dissector in wireshark for parse received packets. As we know there three types of RLC packet, that are TM, UM and AM RLC PDU. But how could I know the type of received packet?


Solution

  • There is an LTE RLC dissector in the official sources, see: - https://code.wireshark.org/review/gitweb?p=wireshark.git;a=blob;f=epan/dissectors/packet-rlc-lte.c - https://code.wireshark.org/review/gitweb?p=wireshark.git;a=blob;f=epan/dissectors/packet-rlc-lte.h

    There are several pieces of information, including the RLC mode, that are not contained in the frame and must be told to the dissector in order for it to decode the PDU properly. In the header file, see struct rlc_lte_info.

    It is then up to the calling dissector, e.g. the LTE MAC dissector, to correctly fill in this context information before calling the RLC dissector.