Wireshark-commits: [Wireshark-commits] rev 28937: /trunk/epan/ /trunk/epan/dissectors/: packet-radi
Date: Fri, 03 Jul 2009 16:03:06 GMT
http://anonsvn.wireshark.org/viewvc/viewvc.cgi?view=rev&revision=28937

User: wmeier
Date: 2009/07/03 09:03 AM

Log:
 From: Tobias Witek: Fix processing of radius 'vendor specific attributes'
 
 In the RADIUS dissector, the function radius_register_avp_dissector() registers
 vendors that are not already present in the dictionary hash-table. As far as I
 can see, there are two problems with this:
 
 1. The function does not set the number of type/length octets and the has_flags
  variable for that AVP, which is required to correctly decode AVP/VSA values
 2. In some situations, the function is called _before_ radius_load_dictionary()
 is called (for example for the vendor 3GPP (ID: 10415))
 
 Therefore, all vendor entries that are created by calling
 radius_register_avp_dissector() leave their type_octets and length_octets un-initialized,
 which causes incorrect decoding.
 
 [Result: Radius dissector displays messages such as:
  "Malformed Packet: RADIUS" and "Error/Malformed: Malformed Packet(Exception occurred)"]
 
 The attached patch fixes this problem by assuming that the dictionary knows the
 'ground truth' about the type/length octet and the has_flags information and allows it to
 overwrite these values even for vendors that have already been loaded.
 
 Also: (from Bill Meier): set the type/length octet and the has_flags variables to default
 "standard" values (1,1,FALSE) in radius_register_avp_dissector().
 
 Fixes Bug #3651 (and Bug #3635).
 https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3651
 https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3635

Directory: /trunk/epan/dissectors/
  Changes    Path               Action
  +5 -0      packet-radius.c    Modified

Directory: /trunk/epan/
  Changes    Path             Action
  +7 -3      radius_dict.l    Modified