This is our old Q&A Site. Please post any new questions and answers at ask.wireshark.org.

For example, if you have the postdissector example, and append the following:

do
    local f_newfield1 = Field.new("http.newfield1")
end

It fails to start up with the following error:

tshark: Lua: Error during loading:
 [string "/home/alastair/.wireshark/plugins/http_extr..."]:38: bad argument #1 to 'new' (Field_new: a field with this name must exist)

.. even though the field was defined previously as a ProtoField.

Is this a bug or feature or something else?

asked 04 Mar '14, 08:51

randomphrase's gravatar image

randomphrase
21225
accept rate: 0%


What version are you running?

The ability to use a Field extractor (i.e., to call Field.new()) of a field created by your script was only possible relatively recently - as a fix in bug 3513, back in October. I think that means you have to be running Wireshark version 1.11 at least. (I think 1.10 was cut before then, so it won't have this because the bug wasn't critical) I could be wrong though - it might have gotten backported into 1.10 at some point.

permanent link

answered 04 Mar '14, 09:25

Hadriel's gravatar image

Hadriel
2.7k2939
accept rate: 18%

Just checked - no it's not in 1.10, you need to go to 1.11.2, which you can get on the downloads page.

(04 Mar '14, 09:33) Hadriel

Yep that was the problem - Thanks for the timely answer!

(04 Mar '14, 12:05) randomphrase
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×431
×34
×24

question asked: 04 Mar '14, 08:51

question was seen: 1,337 times

last updated: 04 Mar '14, 12:05

p​o​w​e​r​e​d by O​S​Q​A