Ethereal-cvs: [Ethereal-cvs] cvs commit: ethereal reassemble.c packet-ieee80211.c reassemble.h

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Guy Harris <guy@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 17 Apr 2002 03:25:06 -0500 (CDT)
guy         2002/04/17 03:25:06 CDT

  Modified files:
    .                    reassemble.c packet-ieee80211.c 
                         reassemble.h 
  Log:
  Add a separate hash table to the reassembly code for reassembled
  packets, using the reassembly ID and the frame number of the final frame
  as the key.  There is no guarantee that reassembly IDs won't be reused,
  even when talking between the same source and destination address; if,
  once reassembly is complete, the "fragment_data" structure is moved to
  the latter hash table, this will keep reused reassembly IDs from causing
  mis-reassembly.
  
  Add a routine "fragment_add_seq_check()", which
  
  	if a fragment has the "more fragments" flag not set but is the
  	first fragment of a reassembly, treats that as a non-fragmented
  	frame, allocating a "fragment_data" structure for the reassembly
  	but not attaching any fragment to it, and adding it to a
  	reassembled packet list;
  
  	if a packet has been reassembled, removes it from the table of
  	reassemblies and moves it to the table of reassembled packets;
  
  	if the frame's been seen already, looks it up in the table of
  	reassembled packets rather than the table of reassemblies.
  
  Add reassembly support for fragmented 802.11 frames.  Use
  "fragment_add_seq_check()" to cope with the fact that some
  hardware+drivers apparently hands us reassembled frames with a non-zero
  fragment number and the "more fragments" bit clear (as if it puts the
  802.11 header of the *last* fragment onto the reassembled data).
  
  Revision  Changes    Path
  1.12      +343 -67   ethereal/reassemble.c
  1.55      +255 -34   ethereal/packet-ieee80211.c
  1.6       +38 -3     ethereal/reassemble.h