Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Calling CRC functions from Lua

Does Wireshark provide an API for CRC calculations from Lua dissectors? I see Wireshark has many CRC functions in C; can they be called from Lua?

If they can't be called from Lua, are there good Lua bindings available for CRC calculations? I've managed to build luagcrypt to call libgcrypt, and I am using that to do CRC-32. But libgcrypt doesn't have 16-bit CRCs such as CRC-CCITT.

Calling CRC functions from Lua

Does Wireshark provide an API for CRC calculations from Lua dissectors? I see Wireshark has many CRC functions in C; can they be called from Lua?

If they can't be called from Lua, are there good Lua bindings available for CRC calculations? calculations?

I've managed to build luagcrypt to call libgcrypt, and I am using that to do CRC-32. fast CRC-32 calculations. But libgcrypt doesn't have 16-bit CRCs such as CRC-CCITT.CRC-CCITT. I found GitHub youlu-cn/luacrc16, but that doesn't support Lua 5.2.x which is in Wireshark 2.6.1.