Wireshark-bugs: [Wireshark-bugs] [Bug 12687] SocketCAN dissector does not support CAN FD
Date: Thu, 25 Aug 2016 01:45:21 +0000

Comment # 41 on bug 12687 from
(In reply to Oliver Hartkopp from comment #40)
> First the pcap-canusb-linux.c can be removed from libpcap as the unit never
> reached production maturity!

OK.

> Because of my missing patch to piggyback CAN FD traffic into the existing
> pcap-can-linux.c these latest versions fall back to only handle CAN frames.
> 
> So what would be the best steps to continue?
> 
> 1. Remove pcap-canusb-linux.c

OK.

> 2. Remove pcap-can-linux.c

OK.

> 3. Let pcap-linux.c handle and provide
> 
>     DLT_CAN_SOCKETCAN_BIGENDIAN  (for ETH_P_CAN)
>     DLT_CAN_SOCKETCAN_HOSTENDIAN (for ETH_P_CAN)
> 
>     DLT_CANFD_SOCKETCAN_BIGENDIAN  (for ETH_P_CANFD) NEW! (needed??)
>     DLT_CANFD_SOCKETCAN_HOSTENDIAN (for ETH_P_CANFD) NEW!

Or how about doing a cooked capture for ARPHRD_CAN, so that the link-layer type
is DLT_LINUX_SLL, add LINUX_SLL_P_CANFD (with the same numerical value as
ETH_P_CANFD) to libpcap's pcap/sll.h and Wireshark's
epan/dissectors/packet-sll.h, add it to the byte-swapping code in libpcap's
pcap-common.c and Wireshark's wiretap/pcap-common.c, add it to the table in
epan/dissectors/packet-sll.c, and have epan/dissectors/packet-socketcan.c
register for it, as well as LINUX_SLL_P_CAN, in the "sll.ltype" dissector
table.

Then the dissector for LINUX_SLL_P_CANFD would dissect a CANFD header, and the
dissector for LINUX_SLL_P_CAN would dissect a non-CANFD header.

Then we don't need any DLT_/LINKTYPE_ values for CANFD, and might even not need
to bother with DLT_CAN_SOCKETCAN_HOSTENDIAN.


You are receiving this mail because:
  • You are watching all bug changes.