aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-fc.h
diff options
context:
space:
mode:
authorJaap Keuter <jaap.keuter@xs4all.nl>2020-12-15 19:14:32 +0100
committerGuy Harris <gharris@sonic.net>2020-12-15 20:26:29 +0000
commit3f0fc1b232493815161b345368c7c41500e0153c (patch)
tree1d747b27a269e18a3f72591d2140d0c658cc9b31 /epan/dissectors/packet-fc.h
parent354a6fd0154c284b5c1b86987fde1e58cc73dbbb (diff)
FC: use ETHERTYPE_UNK when applicable, no excuses
Two interlocking problems cause the dissection of FC to fail in some cases, as shown in the capture of the related issue. The FC dissector assumes that ETHERTYPE_UNK in the data structure passed to it is coming from the MDS header dissector only, and thus that header sizes have to be taken into account. This is not / no longer the case. It always passes down ETHERTYPE_FCFT. Therefore the MDS header size checking does not apply to ETHERTYP_UNK, so is removed as condition. The other FC related dissectors were forced to setup a data structure to pass to FC for it to handle that part of the frame. Because these weren't related to ethernet, these lazily set the ethertype field in the data structure to 0. This unfortunately matches ETHERTYPE_UNK, triggering the MDS header size checking in FC, leading to this issue. With the first problem resolved, now make it explicit that unknown ethertype is indicated by ETHERTYPE_UNK, not '0'. Addresses primary part of issue #17084
Diffstat (limited to 'epan/dissectors/packet-fc.h')
-rw-r--r--epan/dissectors/packet-fc.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/epan/dissectors/packet-fc.h b/epan/dissectors/packet-fc.h
index f2e6c1cd74..553dea247a 100644
--- a/epan/dissectors/packet-fc.h
+++ b/epan/dissectors/packet-fc.h
@@ -13,6 +13,7 @@
#define __PACKET_FC_H_
#include <epan/conversation.h>
+#include <epan/etypes.h>
#include "ws_symbol_export.h"
/* R_CTL upper bits creates a classification tree */