diff options
author | Uwe Girlich <Uwe.Girlich@philosys.de> | 2000-08-14 11:36:04 +0000 |
---|---|---|
committer | Uwe Girlich <Uwe.Girlich@philosys.de> | 2000-08-14 11:36:04 +0000 |
commit | c6097bf6844db5a033cef96e64406eedd6a0b997 (patch) | |
tree | abffe6d9456bffa54afba6f671b4e8bf07ab343d | |
parent | 364ec7fa0535398c16f9a14ba3cb392b08461123 (diff) | |
download | wireshark-c6097bf6844db5a033cef96e64406eedd6a0b997.tar.gz |
Reversed the latest changes for protocol enable/disable in RPC sub-dissectors.
The RPC layer itself handles all this stuff.
svn path=/trunk/; revision=2271
-rw-r--r-- | packet-bootparams.c | 17 | ||||
-rw-r--r-- | packet-mount.c | 42 | ||||
-rw-r--r-- | packet-nlm.c | 17 | ||||
-rw-r--r-- | packet-portmap.c | 35 |
4 files changed, 5 insertions, 106 deletions
diff --git a/packet-bootparams.c b/packet-bootparams.c index 93b687a94d..e912feec56 100644 --- a/packet-bootparams.c +++ b/packet-bootparams.c @@ -1,7 +1,7 @@ /* packet-bootparams.c * Routines for bootparams dissection * - * $Id: packet-bootparams.c,v 1.12 2000/08/13 14:08:04 deniel Exp $ + * $Id: packet-bootparams.c,v 1.13 2000/08/14 11:36:03 girlich Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@zing.org> @@ -58,9 +58,6 @@ int dissect_bp_address(const u_char *pd, int offset, frame_data *fd, guint32 type; guint32 ipaddr; - if (!proto_is_protocol_enabled(proto_bootparams)) - return offset; - /* get the address type */ if ( !BYTES_ARE_IN_FRAME(offset, 1)) return offset; type = pntohl(&pd[offset]); /* type of address */ @@ -92,9 +89,6 @@ ZZZZZZZZZZZZZZZZZZZ Check type: int dissect_getfile_call(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - if (!proto_is_protocol_enabled(proto_bootparams)) - return offset; - if ( tree ) { offset = dissect_rpc_string(pd,offset,fd,tree,hf_bootparams_host,NULL); @@ -108,9 +102,6 @@ int dissect_getfile_call(const u_char *pd, int offset, frame_data *fd, int dissect_getfile_reply(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - if (!proto_is_protocol_enabled(proto_bootparams)) - return offset; - if ( tree ) { offset = dissect_rpc_string(pd,offset,fd,tree,hf_bootparams_host,NULL); @@ -125,9 +116,6 @@ int dissect_getfile_reply(const u_char *pd, int offset, frame_data *fd, int dissect_whoami_call(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - if (!proto_is_protocol_enabled(proto_bootparams)) - return offset; - if ( tree ) { offset = dissect_bp_address(pd,offset,fd,tree,hf_bootparams_hostaddr); @@ -140,9 +128,6 @@ int dissect_whoami_call(const u_char *pd, int offset, frame_data *fd, int dissect_whoami_reply(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - if (!proto_is_protocol_enabled(proto_bootparams)) - return offset; - if ( tree ) { offset = dissect_rpc_string(pd,offset,fd,tree,hf_bootparams_host,NULL); diff --git a/packet-mount.c b/packet-mount.c index 7a5596ab17..8915de0fba 100644 --- a/packet-mount.c +++ b/packet-mount.c @@ -1,7 +1,7 @@ /* packet-mount.c * Routines for mount dissection * - * $Id: packet-mount.c,v 1.16 2000/08/13 14:08:29 deniel Exp $ + * $Id: packet-mount.c,v 1.17 2000/08/14 11:36:03 girlich Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@zing.org> @@ -83,9 +83,6 @@ dissect_fhstatus(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { guint32 status; - if (!proto_is_protocol_enabled(proto_mount)) - return offset; - if (!BYTES_ARE_IN_FRAME(offset,4)) return offset; status = EXTRACT_UINT(pd, offset+0); if (tree) { @@ -110,10 +107,6 @@ static int dissect_mount_dirpath_call(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - - if (!proto_is_protocol_enabled(proto_mount)) - return offset; - if ( tree ) { offset = dissect_rpc_string(pd,offset,fd,tree,hf_mount_path,NULL); @@ -128,10 +121,6 @@ static int dissect_mount_mnt_reply(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - - if (!proto_is_protocol_enabled(proto_mount)) - return offset; - offset = dissect_fhstatus(pd, offset, fd, tree); return offset; @@ -149,9 +138,6 @@ dissect_mountlist(const u_char *pd, int offset, frame_data *fd, proto_tree *tree char* hostname; char* directory; - if (!proto_is_protocol_enabled(proto_mount)) - return offset; - if (tree) { mountlist_item = proto_tree_add_item(tree, hf_mount_mountlist, NullTVB, offset+0, END_OF_FRAME, FALSE); @@ -181,10 +167,6 @@ static int dissect_mount_dump_reply(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - - if (!proto_is_protocol_enabled(proto_mount)) - return offset; - offset = dissect_rpc_list(pd,offset,fd,tree,dissect_mountlist); return offset; @@ -196,10 +178,6 @@ dissect_mount_dump_reply(const u_char *pd, int offset, frame_data *fd, static int dissect_group(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - - if (!proto_is_protocol_enabled(proto_mount)) - return offset; - offset = dissect_rpc_string(pd, offset, fd, tree, hf_mount_groups_group,NULL); return offset; @@ -219,9 +197,6 @@ dissect_exportlist(const u_char *pd, int offset, frame_data *fd, proto_tree *tre proto_item* groups_tree = NULL; char* directory; - if (!proto_is_protocol_enabled(proto_mount)) - return offset; - if (tree) { exportlist_item = proto_tree_add_item(tree, hf_mount_exportlist, NullTVB, offset+0, END_OF_FRAME, FALSE); @@ -266,10 +241,6 @@ static int dissect_mount_export_reply(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - - if (!proto_is_protocol_enabled(proto_mount)) - return offset; - offset = dissect_rpc_list(pd,offset,fd,tree,dissect_exportlist); return offset; @@ -347,9 +318,6 @@ dissect_mount_pathconf_reply(const u_char *pd, int offset, frame_data *fd, proto_item *ti; proto_tree *mask_tree; - if (!proto_is_protocol_enabled(proto_mount)) - return offset; - /* * Extract the mask first, so we know which other fields the * server was able to return to us. @@ -538,9 +506,6 @@ dissect_mountstat3(const u_char *pd, int offset, frame_data *fd, proto_tree *tre { guint32 mountstat3; - if (!proto_is_protocol_enabled(proto_mount)) - return offset; - if (!BYTES_ARE_IN_FRAME(offset,4)) return offset; mountstat3 = EXTRACT_UINT(pd, offset+0); @@ -563,10 +528,7 @@ dissect_mount3_mnt_reply(const u_char *pd, int offset, frame_data *fd, guint32 auth_flavors; guint32 auth_flavor; guint32 auth_flavor_i; - - if (!proto_is_protocol_enabled(proto_mount)) - return offset; - + offset = dissect_mountstat3(pd, offset, fd, tree, hf_mount_status, &status); switch (status) { case 0: diff --git a/packet-nlm.c b/packet-nlm.c index 6eb3c43e69..b9d204d2a9 100644 --- a/packet-nlm.c +++ b/packet-nlm.c @@ -1,7 +1,7 @@ /* packet-nlm.c * Routines for nlm dissection * - * $Id: packet-nlm.c,v 1.8 2000/08/13 14:08:33 deniel Exp $ + * $Id: packet-nlm.c,v 1.9 2000/08/14 11:36:02 girlich Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@zing.org> @@ -105,9 +105,6 @@ dissect_nlm_lock(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int versio tvb_compat(tvb, &pd, &compat_offset); - if (!proto_is_protocol_enabled(proto_nlm)) - return offset; - if (tree) { lock_item = proto_tree_add_item(tree, hf_nlm_lock, tvb, offset, tvb_length_remaining(tvb, offset), FALSE); @@ -151,9 +148,6 @@ dissect_nlm1_lock_call(const u_char* pd, int offset, frame_data* fd, proto_tree* #endif int noffset; - if (!proto_is_protocol_enabled(proto_nlm)) - return tvb_raw_offset(tvb); - noffset = dissect_rpc_data_tvb(tvb, pinfo, tree, hf_nlm_cookie, 0); noffset = dissect_rpc_bool_tvb(tvb, pinfo, tree, hf_nlm_block, noffset); noffset = dissect_rpc_bool_tvb(tvb, pinfo, tree, hf_nlm_exclusive, noffset); @@ -177,9 +171,6 @@ dissect_nlm1_unlock_call(const u_char* pd, int offset, frame_data* fd, proto_tre #endif int noffset; - if (!proto_is_protocol_enabled(proto_nlm)) - return tvb_raw_offset(tvb); - noffset = dissect_rpc_data_tvb(tvb, pinfo, tree, hf_nlm_cookie, 0); noffset = dissect_nlm_lock(tvb, pinfo, tree, 1, noffset); return tvb_raw_offset(tvb) + noffset; @@ -199,9 +190,6 @@ dissect_nlm1_gen_reply(const u_char* pd, int offset, frame_data* fd, proto_tree* #endif int noffset; - if (!proto_is_protocol_enabled(proto_nlm)) - return tvb_raw_offset(tvb); - noffset = dissect_rpc_data_tvb(tvb, pinfo, tree, hf_nlm_cookie, 0); noffset = dissect_rpc_uint32_tvb(tvb, pinfo, tree, hf_nlm_state, noffset); return tvb_raw_offset(tvb) + noffset; @@ -310,9 +298,6 @@ dissect_nlm4_test_call(const u_char* pd, int offset, frame_data* fd, proto_tree* #endif int noffset; - if (!proto_is_protocol_enabled(proto_nlm)) - return tvb_raw_offset(tvb); - noffset = dissect_rpc_data_tvb(tvb, pinfo, tree, hf_nlm_cookie, 0); dissect_rpc_bool_tvb(tvb, pinfo, tree, hf_nlm_exclusive, noffset); noffset += 4; diff --git a/packet-portmap.c b/packet-portmap.c index d256bd9124..125f43a1b9 100644 --- a/packet-portmap.c +++ b/packet-portmap.c @@ -1,7 +1,7 @@ /* packet-portmap.c * Routines for portmap dissection * - * $Id: packet-portmap.c,v 1.18 2000/08/13 14:07:55 deniel Exp $ + * $Id: packet-portmap.c,v 1.19 2000/08/14 11:36:04 girlich Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@zing.org> @@ -65,10 +65,6 @@ int dissect_getport_call(const u_char *pd, int offset, frame_data *fd, { guint32 proto; guint32 prog; - - if (!proto_is_protocol_enabled(proto_portmap)) - return offset; - if ( !BYTES_ARE_IN_FRAME(offset, 16)) return offset; if ( tree ) @@ -94,9 +90,6 @@ int dissect_getport_call(const u_char *pd, int offset, frame_data *fd, int dissect_getport_reply(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - if (!proto_is_protocol_enabled(proto_portmap)) - return offset; - if ( !BYTES_ARE_IN_FRAME(offset, 4)) return offset; if ( tree ) { @@ -112,10 +105,6 @@ int dissect_set_call(const u_char *pd, int offset, frame_data *fd, { guint32 proto; guint32 prog; - - if (!proto_is_protocol_enabled(proto_portmap)) - return offset; - if ( !BYTES_ARE_IN_FRAME(offset, 16)) return offset; if ( tree ) @@ -144,10 +133,6 @@ int dissect_unset_call(const u_char *pd, int offset, frame_data *fd, { guint32 proto; guint32 prog; - - if (!proto_is_protocol_enabled(proto_portmap)) - return offset; - if ( !BYTES_ARE_IN_FRAME(offset, 16)) return offset; if ( tree ) @@ -173,9 +158,6 @@ int dissect_unset_call(const u_char *pd, int offset, frame_data *fd, int dissect_set_reply(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - if (!proto_is_protocol_enabled(proto_portmap)) - return offset; - if ( tree ) { if ( !BYTES_ARE_IN_FRAME(offset, 4)) return offset; @@ -193,9 +175,6 @@ dissect_dump_entry(const u_char* pd, int offset, frame_data* fd, proto_tree* tre int prog, version, proto, port; proto_item *ti, *subtree; - if (!proto_is_protocol_enabled(proto_portmap)) - return offset; - if ( ! BYTES_ARE_IN_FRAME(offset, 16) ) { if ( tree ) @@ -232,9 +211,6 @@ dissect_dump_entry(const u_char* pd, int offset, frame_data* fd, proto_tree* tre int dissect_dump_reply(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - if (!proto_is_protocol_enabled(proto_portmap)) - return offset; - offset = dissect_rpc_list(pd, offset, fd, tree, dissect_dump_entry); return offset; } @@ -320,9 +296,6 @@ dissect_rpcb(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) int dissect_rpcb3_getaddr_call(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - if (!proto_is_protocol_enabled(proto_portmap)) - return offset; - offset = dissect_rpcb(pd, offset, fd, tree); return offset; @@ -333,9 +306,6 @@ int dissect_rpcb3_getaddr_call(const u_char *pd, int offset, frame_data *fd, int dissect_rpcb3_getaddr_reply(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - if (!proto_is_protocol_enabled(proto_portmap)) - return offset; - offset = dissect_rpc_string(pd, offset, fd, tree, hf_portmap_uaddr,NULL); return offset; @@ -346,9 +316,6 @@ int dissect_rpcb3_getaddr_reply(const u_char *pd, int offset, frame_data *fd, int dissect_rpcb3_dump_reply(const u_char *pd, int offset, frame_data *fd, proto_tree *tree) { - if (!proto_is_protocol_enabled(proto_portmap)) - return offset; - offset = dissect_rpc_list(pd, offset, fd, tree, dissect_rpcb); return offset; } |