aboutsummaryrefslogtreecommitdiff
path: root/wireshark/pictochat.lua
diff options
context:
space:
mode:
Diffstat (limited to 'wireshark/pictochat.lua')
-rw-r--r--wireshark/pictochat.lua17
1 files changed, 10 insertions, 7 deletions
diff --git a/wireshark/pictochat.lua b/wireshark/pictochat.lua
index 13a2722..ff09783 100644
--- a/wireshark/pictochat.lua
+++ b/wireshark/pictochat.lua
@@ -13,7 +13,8 @@ pc.fields.resend = ProtoField.uint16("pictochat.resend", "Resend", base.DEC, {
pc.fields.length = ProtoField.uint16("pictochat.length", "Message length")
pc.fields.host = ProtoField.ether("pictochat.host", "Room host")
pc.fields.src = ProtoField.ether("pictochat.src", "Source")
-pc.fields.dst = ProtoField.ether("pictochat.dst", "dstination")
+pc.fields.dst = ProtoField.ether("pictochat.dst", "Destination")
+
pc.fields.content_offset = ProtoField.uint16("pictochat.content_offset", "Content offset")
pc.fields.content = ProtoField.bytes("pictochat.content", "Content")
pc.fields.sequence = ProtoField.uint16("pictochat.sequence", "Packet sequence")
@@ -36,9 +37,15 @@ function pc.dissector(buffer, pinfo, tree)
pc_tree:add_le(pc.fields.msg_type, buffer(0x00, 2))
pc_tree:add_le(pc.fields.resend, buffer(0x02, 2))
pc_tree:add_le(pc.fields.length, buffer(0x0a, 2))
- pc_tree:add_le(pc.fields.host, buffer(0x10, 6))
+ pc_tree:add_le(pc.fields.dst, buffer(0x10, 6))
pc_tree:add_le(pc.fields.src, buffer(0x16, 6))
- pc_tree:add_le(pc.fields.dst, buffer(0x1c, 6))
+ pc_tree:add_le(pc.fields.host, buffer(0x1c, 6))
+
+ pinfo.cols.protocol = pc.name
+ pinfo.cols.src = tostring(pc_src_field())
+ pinfo.cols.dst = tostring(pc_dst_field())
+ pinfo.cols.info = pc_msg_type_field().display .. ", " .. pc_resend_field().display
+
pc_tree:add_le(pc.fields.unknown, buffer(0x22, 2))
pc_tree:add_le(pc.fields.unknown, buffer(0x24, 2))
@@ -56,10 +63,6 @@ function pc.dissector(buffer, pinfo, tree)
pc_tree:add(pc.fields.unknown, buffer(0x04, 4))
end
- pinfo.cols.protocol = pc.name
- pinfo.cols.src = tostring(pc_src_field())
- pinfo.cols.dst = tostring(pc_dst_field())
- pinfo.cols.info = pc_msg_type_field().display .. ", " .. pc_resend_field().display
end