ANNOUNCEMENT: Live Wireshark University & Allegro Packets online APAC Wireshark Training Session
April 17th, 2024 | 14:30-16:00 SGT (UTC+8) | Online

Wireshark-dev: Re: [Wireshark-dev] What type should I use for 12 byte field in my dissector??

From: Guy Harris <guy@xxxxxxxxxxxx>
Date: Thu, 6 May 2010 19:08:09 -0700
On May 6, 2010, at 7:02 PM, Craig Bumpstead wrote:

> What data type can I use when the proprietary protocol says that the field is 12 bytes (96 Bit)????

FT_BYTES.  There *is* no 12-byte integral data type in Wireshark, so there *is* no FT_UINT?? that you can use to display it as a 96-bit integer.

Or don't use proto_tree_add_item(), but, instead, fetch it by hand, convert it to an nstime_t (seconds since January 1, 1970, 00:00:00 UTC, and nanoseconds), and add it as an FT_ABSOLUTE_TIME, if that conversion is possible.