Wireshark-bugs: [Wireshark-bugs] [Bug 9896] Lua dissector tcp packet reassemble not working on W
Comment # 6
on bug 9896
from Hadriel Kaplan
Also, I don't believe returning the missing number of bytes does anything.
See bug 9851.
Just setting the pinfo.desegment_offset and pinfo.desegment_len appropriately
is all you can do.
Your script looks a little odd because it tries to do a partial dissection -
i.e., it tries to pick up where it left off last time, instead of starting from
buffer offset 0 each time, and just setting desegment_len to what more it
needs.
from README.developer:
If the dissector discovers that the end of the tvbuff does /not/ coincide with
the end of a PDU, (ie, there is half of a PDU at the end of the tvbuff), it can
indicate this to the parent dissector, by updating the pinfo struct. The
desegment_offset field is the offset in the tvbuff at which the dissector will
continue processing when next called. The desegment_len field should contain
the estimated number of additional bytes required for completing the PDU. Next
time your dissect_PROTO is called, it will be passed a tvbuff composed of the
end of the data from the previous tvbuff together with desegment_len more
bytes.
You are receiving this mail because:
- You are watching all bug changes.