From 470bd4455a17a3d4e3ad1694fd64376720a768a9 Mon Sep 17 00:00:00 2001 From: Jeff Morriss Date: Wed, 5 Jun 2013 14:08:40 +0000 Subject: Add a new environment variable to cause abort()s if we add too many items to the tree (to separate this case from the generic DISSECTOR_BUG case). Enable this environment variable when fuzz testing. Enable the 3rd (without tree but with a read filter) check (added in r49643) when testing capture files but not when fuzz testing--not sure if we want to add even more to the fuzzbot's work load now (OTOH I've been running it for a while and it hasn't buried me in bugs). svn path=/trunk/; revision=49784 --- doc/rawshark.pod | 12 ++++++++++++ doc/tshark.pod | 12 ++++++++++++ doc/wireshark.pod.template | 12 ++++++++++++ 3 files changed, 36 insertions(+) (limited to 'doc') diff --git a/doc/rawshark.pod b/doc/rawshark.pod index 5500cd2476..da425a0dbf 100644 --- a/doc/rawshark.pod +++ b/doc/rawshark.pod @@ -484,6 +484,18 @@ your environment is configured correctly, generate a core dump file. This can be useful to developers attempting to troubleshoot a problem with a protocol dissector. +=item WIRESHARK_ABORT_ON_TOO_MANY_ITEMS + +If this environment variable is set, B will call abort(3) +if a dissector tries to add too many items to a tree (generally this +is an indication of the dissector not breaking out of a loop soon enough). +abort(3) will cause the program to exit abnormally; if you are running +B in a debugger, it should halt in the debugger and allow +inspection of the process, and, if you are not running it in a debugger, +it will, on some OSes, assuming your environment is configured correctly, +generate a core dump file. This can be useful to developers attempting to +troubleshoot a problem with a protocol dissector. + =item WIRESHARK_EP_VERIFY_POINTERS This environment variable, if set, causes certain uses of pointers to be diff --git a/doc/tshark.pod b/doc/tshark.pod index 44d488a4ae..3e7b0d15cd 100644 --- a/doc/tshark.pod +++ b/doc/tshark.pod @@ -1642,6 +1642,18 @@ your environment is configured correctly, generate a core dump file. This can be useful to developers attempting to troubleshoot a problem with a protocol dissector. +=item WIRESHARK_ABORT_ON_TOO_MANY_ITEMS + +If this environment variable is set, B will call abort(3) +if a dissector tries to add too many items to a tree (generally this +is an indication of the dissector not breaking out of a loop soon enough). +abort(3) will cause the program to exit abnormally; if you are running +B in a debugger, it should halt in the debugger and allow +inspection of the process, and, if you are not running it in a debugger, +it will, on some OSes, assuming your environment is configured correctly, +generate a core dump file. This can be useful to developers attempting to +troubleshoot a problem with a protocol dissector. + =item WIRESHARK_EP_VERIFY_POINTERS This environment variable, if present, causes certain uses of pointers to be diff --git a/doc/wireshark.pod.template b/doc/wireshark.pod.template index 44afe294f1..3bc15cd3ad 100644 --- a/doc/wireshark.pod.template +++ b/doc/wireshark.pod.template @@ -2790,6 +2790,18 @@ your environment is configured correctly, generate a core dump file. This can be useful to developers attempting to troubleshoot a problem with a protocol dissector. +=item WIRESHARK_ABORT_ON_TOO_MANY_ITEMS + +If this environment variable is set, B will call abort(3) +if a dissector tries to add too many items to a tree (generally this +is an indication of the dissector not breaking out of a loop soon enough). +abort(3) will cause the program to exit abnormally; if you are running +B in a debugger, it should halt in the debugger and allow +inspection of the process, and, if you are not running it in a debugger, +it will, on some OSes, assuming your environment is configured correctly, +generate a core dump file. This can be useful to developers attempting to +troubleshoot a problem with a protocol dissector. + =item WIRESHARK_EP_VERIFY_POINTERS This environment variable, if set, causes certain uses of pointers to be -- cgit v1.2.3