aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-teredo.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2015-07-12 20:40:31 -0400
committerMichael Mann <mmann78@netscape.net>2015-07-17 17:12:22 +0000
commit21e5a950ade6a20260b63b5f5c055c52ac07b599 (patch)
tree417e76e5a3082c2431ce0f5c6d88cbf7701e0489 /epan/dissectors/packet-teredo.c
parent5bd6c4aff21dbc8a7ebf31c5d1510fcedf66d875 (diff)
Remove all preferences related to enabling/disabling heuristic dissectors.
The preferences are still supported for backwards compatibility, but the heuristic_protos file has final say on the "preference" to enable/disable a heuristic dissector. Also add parameter to heur_dissector_add() for the "default" enable/disable of a heuristic dissector. With this parameter, a few more (presumably weak) heuristic dissectors have been "registered" but of course default to being disabled. Change-Id: I51bebb2146ef3fbb8418d4f5c7f2cb2b58003a22 Reviewed-on: https://code.wireshark.org/review/9610 Petri-Dish: Michael Mann <mmann78@netscape.net> Reviewed-by: Roland Knall <rknall@gmail.com> Reviewed-by: Hadriel Kaplan <hadrielk@yahoo.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/packet-teredo.c')
-rw-r--r--epan/dissectors/packet-teredo.c14
1 files changed, 2 insertions, 12 deletions
diff --git a/epan/dissectors/packet-teredo.c b/epan/dissectors/packet-teredo.c
index 657e811ded..091a38bb76 100644
--- a/epan/dissectors/packet-teredo.c
+++ b/epan/dissectors/packet-teredo.c
@@ -72,9 +72,6 @@ static dissector_table_t teredo_dissector_table;
/*static heur_dissector_list_t heur_subdissector_list;*/
static dissector_handle_t data_handle;
-static gboolean global_teredo_heur = FALSE;
-
-
static int
parse_teredo_auth(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
int offset, e_teredohdr *teredoh)
@@ -257,9 +254,6 @@ dissect_teredo_heur(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *d
guint16 val;
int offset = 0;
- if (!global_teredo_heur)
- return FALSE;
-
if (tvb_captured_length_remaining(tvb, offset) < 40)
return FALSE;
@@ -397,11 +391,7 @@ proto_register_teredo(void)
teredo_module = prefs_register_protocol(proto_teredo, NULL);
- prefs_register_bool_preference(teredo_module, "heuristic_teredo",
- "Try to decode UDP packets as Teredo IPv6",
- "Check this to decode IPv6 traffic between Teredo clients and "
- "relays",
- &global_teredo_heur);
+ prefs_register_obsolete_preference(teredo_module, "heuristic_teredo");
}
@@ -415,7 +405,7 @@ proto_reg_handoff_teredo(void)
teredo_tap = register_tap("teredo");
dissector_add_uint("udp.port", UDP_PORT_TEREDO, teredo_handle);
- heur_dissector_add("udp", dissect_teredo_heur, "Teredo over UDP", "teredo_udp", proto_teredo);
+ heur_dissector_add("udp", dissect_teredo_heur, "Teredo over UDP", "teredo_udp", proto_teredo, HEURISTIC_DISABLE);
}
/*