Ethereal-dev: [Ethereal-dev] [bug report] Small error in packet-afs.c

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

From: Loic Tortay <tortay@xxxxxxxxxxx>
Date: Wed, 12 Jun 2002 19:19:49 +0200
There seems to be a small error in "packet-afs.c", in function
"dissect_kauth_request", around line 1115 ("case 23: /* getticket */").

The data part of the AFS authentication request (hf_afs_kauth_data) is
displayed as a string whilst declared as a binary array in
"packet-afs-register-info.h".

The message displayed while trying to examine such a packet is:
** ERROR **: file <...>/ethereal-0.9.4/epan/proto.c: line 1216
  (proto_tree_add_string): assertion failed: (hfinfo->type == FT_STRING)

The patch is really simple stupid (look 6 lines above in the source):

--- packet-afs.c.orig   Sat May 11 18:23:26 2002
+++ packet-afs.c        Wed Jun 12 18:20:29 2002
@@ -1115,7 +1115,7 @@
                case 23: /* getticket */
                        OUT_UINT(hf_afs_kauth_kvno);
                        OUT_RXString(hf_afs_kauth_domain);
-                       OUT_RXString(hf_afs_kauth_data);
+                       OUT_BYTES_ALL(hf_afs_kauth_data);
                        OUT_RXString(hf_afs_kauth_princ);
                        OUT_RXString(hf_afs_kauth_realm);
                        break;


Loïc.