Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local http_headers_proto = Proto("http_extra", "Extra analysis of the HTTP protocol");
- http_headers_proto.fields.hdr_len = ProtoField.uint32("http.hdr_len", "HTTP Header length (bytes)")
- http_headers_proto.fields.request_headers = ProtoField.string("http.request_headers", "HTTP Request Headers")
- http_headers_proto.fields.response_headers = ProtoField.string("http.response_headers", "HTTP Request Headers")
- local tcp_dissector_table = DissectorTable.get("tcp.port")
- local original_http_dissector = tcp_dissector_table:get_dissector(80)
- function http_headers_proto.dissector(tvb, pinfo, treeitem)
- original_http_dissector:call(tvb, pinfo, treeitem)
- -- ...
- end
- tcp_dissector_table:add(80, http_headers_proto)
- local http_response_headers = Field.new("http.response_headers")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement