Hi, I have create a protocol between UDP and RTP, so the packet I want to capture with wireshark looks like this : ( IP, UDP, [my protocol], RTP ) I have written a lua file to include decoding of my protocol. After I decode my protocol I want to call a dissector to decode the RTP part. The problem is that it thinks it should start reading RTP after the UDP packet, and not after my protocol (which is 20 bytes ) Here is the code :
So the problem is that the RTP packets thinks the first bytes after UDP are RTP, but those are my protocol bytes. How can I tell the dissector that RTP should start dissecting AFTER my protocol? Thank you in advance asked 07 Nov ‘12, 01:03 harkap |
3 Answers:
Eh, let's see. Maybe even easier, you could go with:
answered 08 Nov '12, 07:53 Jaap ♦ |
The last few lines of your code should be:
You might consider consolidating into one line:
Also, check out another similar question. answered 08 Nov '12, 21:53 helloworld |
Use tvb:range(20) to create a sub-TVB, starting from byte 20 of the buffer you get. answered 07 Nov '12, 03:59 Jaap ♦ Could you please provide an code example on how to do this? (07 Nov '12, 06:31) harkap |
Hi,
Thank you very much that works great!
Another question : is there an rtp mux dissector?
Another question : Is there an dissectortable for UDP source port?
I cannot find the answer to that simple question, generally, WHAT types of dissectors and dissetortables EXISTS that i can use in the code?
Thank you!
I converted your "answer" to a comment as that's how this site works, and chose the one from @helloworld as it's the highest rated.
If an answer solves your problem please accept it for the benefit of other users by clicking the checkmark icon next to the answer. Please read the FAQ to find out how this site works.
As for your new questions, you should start new questions for those as they'll be lost in the comments to an answer.