aboutsummaryrefslogtreecommitdiffstats
path: root/tap-smbstat.c
diff options
context:
space:
mode:
authorgerald <gerald@f5534014-38df-0310-8fa8-9805f1628bb7>2005-04-16 21:54:32 +0000
committergerald <gerald@f5534014-38df-0310-8fa8-9805f1628bb7>2005-04-16 21:54:32 +0000
commitf28c4f91866d5b15074da29e09759c74e53a74c2 (patch)
tree6c5bfed8fc78f85ff40462f798d09689464b18d9 /tap-smbstat.c
parent920b60a82830b9ea9014458d91cff034e86ee499 (diff)
Add an extra_info_type field to smb_extra_info_t so that we can make
sure we're not referencing a fid when we think we're referencing an smb_nt_transact_info_t pointer. (A fuzzed capture I have triggers this behavior). git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@14107 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'tap-smbstat.c')
-rw-r--r--tap-smbstat.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tap-smbstat.c b/tap-smbstat.c
index 1b0b487c7d..6fa63e01d3 100644
--- a/tap-smbstat.c
+++ b/tap-smbstat.c
@@ -67,14 +67,14 @@ smbstat_packet(void *pss, packet_info *pinfo, epan_dissect_t *edt _U_, const voi
return 0;
}
- if(si->cmd==0xA0){
+ if(si->cmd==0xA0 && si->sip->extra_info_type == SMB_EI_NTI){
smb_nt_transact_info_t *sti=(smb_nt_transact_info_t *)si->sip->extra_info;
/*nt transaction*/
if(sti){
sp=&(ss->nt_trans[sti->subcmd]);
}
- } else if(si->cmd==0x32){
+ } else if(si->cmd==0x32 && si->sip->extra_info_type == SMB_EI_T2I){
smb_transact2_info_t *st2i=(smb_transact2_info_t *)si->sip->extra_info;
/*transaction2*/