Ask Your Question
0

protofield.new error in lua dissector

asked 2018-08-02 06:21:14 +0000

BMWE gravatar image

updated 2019-01-30 17:25:55 +0000

cmaynard gravatar image

Hello,

I have some PCs with different version of wireshark (all are of version 1.x).

On my own PC, the dissector is working fine.

On the lab PC, I'm getting error on the f.fieldname = ProtoField.new("name", "description", ftypes.UINT16) line:

bad argument #3 to 'new' (ProtoField_new: Unsupported ProtoField field type)

I'd be glad to have some assistance what is the issue.

edit retag flag offensive close merge delete

Comments

I don't know what the problem is, but all 1.x versions of Wireshark have gone End of Life. If possible, I would recommend that you upgrade to one of the supported versions of Wireshark and see if that resolves your problem.

cmaynard gravatar imagecmaynard ( 2018-08-02 06:34:15 +0000 )edit

This is little bit problematic

BMWE gravatar imageBMWE ( 2018-08-02 06:35:55 +0000 )edit

On your own PC you have a different (1.x) version of Wireshark then in the lab? Is it a problem on all Wireshark installation in the lab? The Lua interface has had an overhaul in the 1.x era, so you'll have to dig up that relevant Lua API for the lab machine to work with.

Jaap gravatar imageJaap ( 2018-08-02 09:54:00 +0000 )edit

I've tried few PC's in the lab. I think that all of them has the same issue.

BMWE gravatar imageBMWE ( 2018-08-02 13:50:31 +0000 )edit

Unless you start comparing version numbers there's little to go on....

Jaap gravatar imageJaap ( 2018-08-02 14:01:15 +0000 )edit

2 Answers

Sort by ยป oldest newest most voted
0

answered 2018-08-21 10:34:27 +0000

BMWE gravatar image

eventually I'm using ftypes.BYTES which solves the issue.

edit flag offensive delete link more
0

answered 2018-08-02 14:16:34 +0000

cmaynard gravatar image

I don't know which specific version(s) of Wireshark your lab PC's are running, but the old way prior to version 1.8 should be to omit the ftypes. prefix, like so:

f.fieldname = ProtoField.new("name", "description", UINT16)

Compare how ftenums[] is declared between version 1.6 and version 1.8.

If you can't update your lab PC's to the latest stable version, then you might want to consider at least updating them to the latest 1.X version possible. Reference the End of Life planning table on the Wireshark LifeCycle wiki page for some guidelines that may help decide which version is likely possible in your case.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2018-08-02 06:21:14 +0000

Seen: 586 times

Last updated: Aug 21 '18