aboutsummaryrefslogtreecommitdiffstats
path: root/packet-udp.c
AgeCommit message (Collapse)AuthorFilesLines
1999-11-17Heikki Vatiainen's SAP (Session Announcement Protocol) dissector.Guy Harris1-1/+3
Rename the dissector for the Netware SAP protocol to "dissect_ipxsap()", so as to keep its name from colliding with that of the dissector for the Session Announcement Protocol. svn path=/trunk/; revision=1046
1999-11-16Replace the ETT_ "enum" members, declared in "packet.h", withGuy Harris1-9/+14
dynamically-assigned "ett_" integer values, assigned by "proto_register_subtree_array()"; this: obviates the need to update "packet.h" whenever you add a new subtree type - you only have to add a call to "proto_register_subtree_array()" to a "register" routine and an array of pointers to "ett_", if they're not already there, and add a pointer to the new "ett_" variable to the array, if they are there; would allow run-time-loaded dissectors to allocate subtree types when they're loaded. svn path=/trunk/; revision=1043
1999-11-14Move the test to see if something looks like an ONC RPC request or replyGuy Harris1-49/+6
into "dissect_rpc()" itself; it returns TRUE if it is, FALSE if it isn't. svn path=/trunk/; revision=1030
1999-10-29Uwe Girlich's ONC RPC and NFS dissectors.Guy Harris1-1/+50
svn path=/trunk/; revision=945
1999-10-24Kojak's ICQ dissector.Guy Harris1-2/+5
svn path=/trunk/; revision=919
1999-10-22Generalize the "ip_src" and "ip_dst" members of the "packet_info"Guy Harris1-27/+20
structure to "dl_src"/"dl_dst", "net_src"/"net_dst", and "src"/"dst" addresses, where an address is an address type, an address length in bytes, and a pointer to that many bytes. "dl_{src,dst}" are the link-layer source/destination; "net_{src,dst}" are the network-layer source/destination; "{src,dst}" are the source/destination from the highest of those two layers that we have in the packet. Add a port type to "packet_info" as well, specifying whether it's a TCP or UDP port. Don't set the address and port columns in the dissector functions; just set the address and port members of the "packet_info" structure. Set the columns in "fill_in_columns()"; this means that if we're showing COL_{DEF,RES,UNRES}_SRC" or "COL_{DEF,RES,UNRES}_DST", we only generate the string from "src" or "dst", we don't generate a string for the link-layer address and then overwrite it with a string for the network-layer address (generating those strings costs CPU). Add support for "conversations", where a "conversation" is (at present) a source and destination address and a source and destination port. (In the future, we may support "conversations" above the transport layer, e.g. a TFTP conversation, where the first packet goes from the client to the TFTP server port, but the reply comes back from a different port, and all subsequent packets go between the client address/port and the server address/new port, or an NFS conversation, which might include lock manager, status monitor, and mount packets, as well as NFS packets.) Currently, all we support is a call that takes the source and destination address/port pairs, looks them up in a hash table, and: if nothing is found, creates a new entry in the hash table, and assigns it a unique 32-bit conversation ID, and returns that conversation ID; if an entry is found, returns its conversation ID. Use that in the SMB and AFS code to keep track of individual SMB or AFS conversations. We need to match up requests and replies, as, for certain replies, the operation code for the request to which it's a reply doesn't show up in the reply - you have to find the request with a matching transaction ID. Transaction IDs are per-conversation, so the hash table for requests should include a conversation ID and transaction ID as the key. This allows SMB and AFS decoders to handle IPv4 or IPv6 addresses transparently (and should allow the SMB decoder to handle NetBIOS atop other protocols as well, if the source and destination address and port values in the "packet_info" structure are set appropriately). In the "Follow TCP Connection" code, check to make sure that the addresses are IPv4 addressses; ultimately, that code should be changed to use the conversation code instead, which will let it handle IPv6 transparently. svn path=/trunk/; revision=909
1999-10-20Added Nathan's patch for AFS and RX dissection.Gilbert Ramirez1-1/+8
svn path=/trunk/; revision=894
1999-10-15Nathan Neulinger's patch to set "pi.srcport" and "pi.dstport".Guy Harris1-1/+4
svn path=/trunk/; revision=844
1999-10-14Nathan Neulinger's NTP dissector.Guy Harris1-1/+4
svn path=/trunk/; revision=828
1999-10-12Jun-ichiro itojun Hagino's changes for IPv6 extension header decodingGuy Harris1-2/+5
and RIPng decoding. svn path=/trunk/; revision=818
1999-10-12New proto_tree header_field_info stuff. Header_field_infos now containGilbert Ramirez1-6/+11
the base for numbers to be displayed in, bitmasks for bitfields, and blurbs (which are one or two sentences describing the field). proto_tree_add*() routines now automatically handle bitfields. You tell it which header field you are adding, and just pass it the value of the entire field, and the proto_tree routines will do the masking and shifting for you. This means that bitfields are more naturally filtered via dfilter now. Added Phil Techau's support for signed integers in dfilters/proto_tree. Added the beginning of the SNA dissector. It's not complete, but I'm committing it now because it has example after example of how to use bitfields with the new header_field_info struct and proto_tree routines. It was the impetus to change how header_field_info works. svn path=/trunk/; revision=815
1999-10-02Check for truncated header.Laurent Deniel1-2/+6
svn path=/trunk/; revision=752
1999-09-14Peter Torvals' Internet Cache Protocol dissector.Guy Harris1-2/+4
svn path=/trunk/; revision=677
1999-08-18Declare the "packet_info" structure "pi" in "packet.h", rather than in aGuy Harris1-7/+2
bunch of source files. Replace the "payload" field of a "packet_info" structure with "len" and "captured_len" fields, which contain the total packet length and total captured packet length (including all headers) at the current protocol layer (i.e., if a given layer has a length field, and that length field says its shorter than the length we got from the capture, reduce the "pi.len" and "pi.captured_len" values appropriately). Those fields can be used in the future if we add checks to make sure a field we're extracting from a packet doesn't go past the end of the packet, or past the captured part of the packet. Get rid of the additional payload argument to some dissection functions; use "pi.captured_len - offset" instead. Have the END_OF_FRAME macro use "pi.captured_len" rather than "fd->cap_len", so that "dissect the rest of the frame" becomes "dissect the rest of the packet", and doesn't dissect end-of-frame padding such as padding added to make an Ethernet frame 60 or more octets long. (We might want to rename it END_OF_PACKET; if we ever want to label the end-of-frame padding for the benefit of people curious what that extra gunk is, we could have a separate END_OF_FRAME macro that uses "fd->cap_len".) svn path=/trunk/; revision=506
1999-08-05"packet-udp.c" and "packet-x25.c" both have global variables namedGuy Harris1-2/+2
"hash_table", but each of them is used only in the file in question; make them static, so that they don't collide. svn path=/trunk/; revision=440
1999-07-22Converted UDP fields to new proto_tree functions.Gilbert Ramirez1-8/+46
svn path=/trunk/; revision=376
1999-07-08Added Johan's RADIUS dissector, finally. I modified it to fit in with theGilbert Ramirez1-1/+10
new proto_tree routines. I also removed the check for lex and yacc from wiretap's configure script. The IP dissector now uses proto_register_field_array(). svn path=/trunk/; revision=348
1999-07-07Created a new protocol tree implementation and a new display filterGilbert Ramirez1-8/+7
mechanism that is built into ethereal. Wiretap is now used to read all file formats. Libpcap is used only for capturing. svn path=/trunk/; revision=342
1999-06-25When checking to see if a packet is of a given type by checking theGuy Harris1-25/+14
source and destination port numbers, check both port numbers against the specified port, rather than checking the lower of the two port numbers against the specified port, just in case you happen to either have 1) the port number for that type being high enough that you can get client sockets using it or 2) client sockets using it for some other reason. svn path=/trunk/; revision=333
1999-06-11Added PPPoE, PPTP, GRE, and ISAKMP dissectors.Gilbert Ramirez1-1/+5
svn path=/trunk/; revision=303
1999-05-12Added Didier Jorand's dissect_snmp routine. This is only compiled inGilbert Ramirez1-1/+7
if you have the UCD or CMU SNMP library available. If you have the SNMP library but do not with to have SNMP support, use the ./configure --disable-snmp option. Otherwise 'configure' finds the SNMP library and uses it. svn path=/trunk/; revision=281
1999-05-10Decode SMB requests inside NetBIOS Datagram Service packets.Guy Harris1-2/+7
svn path=/trunk/; revision=269
1999-03-23Removed all references to gtk objects from packet*.[ch] files. They nowGilbert Ramirez1-19/+38
reference the protocol tree with struct proto_tree and struct proto_item objects. That way, the packet decoding source code file can be used with non-gtk packet decoders, like a curses-based ethereal, e.g. I also re-arranged some of the information in packet.h to more appropriate places (like other packet-*.[ch] files). svn path=/trunk/; revision=223
1999-03-01Small fixes for alignment, and #include for gtk+-1.1.x/glib-1.1.xGilbert Ramirez1-1/+2
svn path=/trunk/; revision=197
1999-02-15Added Richard Sharpe's TFTP support.Guy Harris1-8/+127
svn path=/trunk/; revision=190
1998-12-29* Added Joerg Mayer's Vines patchGerald Combs1-1/+5
* Added Joerg to the AUTHORS file * Added Guy's bitfield decode patch * Fixed time output svn path=/trunk/; revision=142
1998-12-21Changed port print formats to unsigned, added raw port number to tree output.Gerald Combs1-6/+8
svn path=/trunk/; revision=132
1998-11-20Added NetBIOS Datagram (over UDP) support.Gilbert Ramirez1-1/+4
svn path=/trunk/; revision=113
1998-11-17* Fixes for TCP and UDP port number display.Gerald Combs1-2/+10
svn path=/trunk/; revision=98
1998-11-17* Added column formatting functionality.Gerald Combs1-5/+5
* Added check_col(), add_col_str() and add_col_fmt() to replace references to ft->win_info. * Added column prefs handling code. svn path=/trunk/; revision=97
1998-10-14Don't assume the UDP header is always properly aligned (sometimes itGuy Harris1-7/+8
isn't). svn path=/trunk/; revision=54
1998-10-14Added preliminary support for NetBIOS Name Services over IPX and UDP. NoteGilbert Ramirez1-1/+4
that these are two very different implementations of NetBIOS name services and at the protocol level are not similar. I have put the UDP protocol in packet-nbns.c, since it will be a very big module. I have all of rfc 1002 to read and implement. I am planning on putting many different NetBIOS over IPX functions in packet-nbipx.c, however, since there is no RFC or published standard. I have to hack the protocol, and as such, I do not expect it to be as full-featured as the IP-world equivalents. svn path=/trunk/; revision=50
1998-09-27Merged in a _huge_ patch from Guy Harris. It adds a time stap column,Gerald Combs1-4/+4
generalizes the column printing code, adds a "frame" tree item to the tree view, and fixes a bunch of miscellaneous coding bugs. svn path=/trunk/; revision=31
1998-09-21IPX over IP (rfc 1234) added. Very trivial.Gilbert Ramirez1-1/+4
svn path=/trunk/; revision=20
1998-09-16Added ID tags to the beginning of each source file.Gerald Combs1-0/+2
svn path=/trunk/; revision=7
1998-09-16Initial revisionGerald Combs1-0/+92
svn path=/trunk/; revision=2