From 8dfaa8fa7c97cd1372a0a233b83fbc7945447b75 Mon Sep 17 00:00:00 2001 From: Uli Heilmeier Date: Fri, 5 Oct 2018 08:54:55 +0200 Subject: [PATCH] *shark: Update help and manpage for name resolving Add 'v' option for VLAN ID resolving and get rid of deprecated 'C' option. Bug: 14826 Change-Id: I63104f4a465d251048693ad02882ea7eb2c4d926 Reviewed-on: https://code.wireshark.org/review/30029 Petri-Dish: Anders Broman Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman --- doc/rawshark.pod | 2 ++ doc/tshark.pod | 2 ++ doc/wireshark.pod.template | 2 ++ docbook/wsug_src/WSUG_chapter_customize.asciidoc | 3 ++- docbook/wsug_src/rawshark-h.txt | 2 +- docbook/wsug_src/tshark-h.txt | 2 +- epan/prefs.c | 4 ---- rawshark.c | 2 +- test/suite_clopts.py | 4 ++-- tshark.c | 2 +- ui/commandline.c | 2 +- ui/dissect_opts.c | 3 ++- 12 files changed, 17 insertions(+), 13 deletions(-) diff --git a/doc/rawshark.pod b/doc/rawshark.pod index be6caee9f3..8f1044541a 100644 --- a/doc/rawshark.pod +++ b/doc/rawshark.pod @@ -183,6 +183,8 @@ B to enable transport-layer port number resolution B to enable resolution from captured DNS packets +B to enable VLAN IDs to names resolution + =item -o EpreferenceE:EvalueE Set a preference value, overriding the default value and any value read diff --git a/doc/tshark.pod b/doc/tshark.pod index 263332bf46..8aff736265 100644 --- a/doc/tshark.pod +++ b/doc/tshark.pod @@ -676,6 +676,8 @@ resolution B to enable transport-layer port number resolution +B to enable VLAN IDs to names resolution + =item -o EpreferenceE:EvalueE Set a preference value, overriding the default value and any value read diff --git a/doc/wireshark.pod.template b/doc/wireshark.pod.template index a25ea65b92..c45581fc30 100644 --- a/doc/wireshark.pod.template +++ b/doc/wireshark.pod.template @@ -499,6 +499,8 @@ B to enable transport-layer port number resolution B to enable resolution from captured DNS packets +B to enable VLAN IDs to names resolution + =item -o Epreference/recent settingE Set a preference or recent value, overriding the default value and any value diff --git a/docbook/wsug_src/WSUG_chapter_customize.asciidoc b/docbook/wsug_src/WSUG_chapter_customize.asciidoc index 67afafc27f..a7411c46fa 100644 --- a/docbook/wsug_src/WSUG_chapter_customize.asciidoc +++ b/docbook/wsug_src/WSUG_chapter_customize.asciidoc @@ -76,7 +76,7 @@ Input file: Processing: -R packet filter in Wireshark display filter syntax -n disable all name resolutions (def: all enabled) - -N enable specific name resolution(s): "mnNtCd" + -N enable specific name resolution(s): "mnNtdv" -d ==, ... "Decode As”, see the man page for details Example: tcp.port==8888,http @@ -295,6 +295,7 @@ argument is a string that may contain the letters `m` to enable MAC address resolution, `n` to enable network address resolution, and `t` to enable transport-layer port number resolution. This overrides `-n` if both `-N` and `-n` are present. The letter `d` enables resolution from captured DNS packets. +The letter `v` enables resolution from VLAN IDs to names. -o :: diff --git a/docbook/wsug_src/rawshark-h.txt b/docbook/wsug_src/rawshark-h.txt index 39aeec0ef3..7de64ec7ed 100644 --- a/docbook/wsug_src/rawshark-h.txt +++ b/docbook/wsug_src/rawshark-h.txt @@ -13,7 +13,7 @@ Processing: -F field to display -m virtual memory limit, in bytes -n disable all name resolution (def: all enabled) - -N enable specific name resolution(s): "mnNtd" + -N enable specific name resolution(s): "mnNtdv" -p use the system's packet header format (which may have 64-bit timestamps) -R packet filter in Wireshark display filter syntax diff --git a/docbook/wsug_src/tshark-h.txt b/docbook/wsug_src/tshark-h.txt index 9eaccda966..ffe12b9973 100644 --- a/docbook/wsug_src/tshark-h.txt +++ b/docbook/wsug_src/tshark-h.txt @@ -38,7 +38,7 @@ Processing: -Y packet displaY filter in Wireshark display filter syntax -n disable all name resolutions (def: all enabled) - -N enable specific name resolution(s): "mnNtCd" + -N enable specific name resolution(s): "mnNtdv" -d ==, ... "Decode As", see the man page for details Example: tcp.port==8888,http diff --git a/epan/prefs.c b/epan/prefs.c index 34c05d3075..d732eb2046 100644 --- a/epan/prefs.c +++ b/epan/prefs.c @@ -4932,10 +4932,6 @@ string_to_name_resolve(const char *string, e_addr_resolve *name_resolve) case 't': name_resolve->transport_name = TRUE; break; - case 'C': - /* DEPRECATED */ - /* name_resolve->concurrent_dns */ - break; case 'd': name_resolve->dns_pkt_addr_resolution = TRUE; break; diff --git a/rawshark.c b/rawshark.c index 61875c1472..29cb2ba801 100644 --- a/rawshark.c +++ b/rawshark.c @@ -190,7 +190,7 @@ print_usage(FILE *output) fprintf(output, " -m virtual memory limit, in bytes\n"); #endif fprintf(output, " -n disable all name resolution (def: all enabled)\n"); - fprintf(output, " -N enable specific name resolution(s): \"mnNtd\"\n"); + fprintf(output, " -N enable specific name resolution(s): \"mnNtdv\"\n"); fprintf(output, " -p use the system's packet header format\n"); fprintf(output, " (which may have 64-bit timestamps)\n"); fprintf(output, " -R packet filter in Wireshark display filter syntax\n"); diff --git a/test/suite_clopts.py b/test/suite_clopts.py index 194abc8473..02cfd97f68 100644 --- a/test/suite_clopts.py +++ b/test/suite_clopts.py @@ -153,8 +153,8 @@ class case_tshark_name_resolution_clopts(subprocesstest.SubprocessTestCase): def test_tshark_valid_name_resolution(self): if not config.canCapture(): self.skipTest('Test requires capture privileges and an interface.') - # $TSHARK -N mntC -a duration:1 > ./testout.txt 2>&1 - self.assertRun((config.cmd_tshark, '-N', 'mntC', '-a', 'duration: 1')) + # $TSHARK -N mnNtdv -a duration:1 > ./testout.txt 2>&1 + self.assertRun((config.cmd_tshark, '-N', 'mnNtdv', '-a', 'duration: 1')) # XXX Add invalid name resolution. diff --git a/tshark.c b/tshark.c index a152c2b191..2d84153611 100644 --- a/tshark.c +++ b/tshark.c @@ -370,7 +370,7 @@ print_usage(FILE *output) fprintf(output, " -Y packet displaY filter in Wireshark display filter\n"); fprintf(output, " syntax\n"); fprintf(output, " -n disable all name resolutions (def: all enabled)\n"); - fprintf(output, " -N enable specific name resolution(s): \"mnNtCd\"\n"); + fprintf(output, " -N enable specific name resolution(s): \"mnNtdv\"\n"); fprintf(output, " -d %s ...\n", DECODE_AS_ARG_TEMPLATE); fprintf(output, " \"Decode As\", see the man page for details\n"); fprintf(output, " Example: tcp.port==8888,http\n"); diff --git a/ui/commandline.c b/ui/commandline.c index 6a26be334e..7c0768a0b5 100644 --- a/ui/commandline.c +++ b/ui/commandline.c @@ -123,7 +123,7 @@ commandline_print_usage(gboolean for_help_option) { fprintf(output, "Processing:\n"); fprintf(output, " -R packet filter in Wireshark display filter syntax\n"); fprintf(output, " -n disable all name resolutions (def: all enabled)\n"); - fprintf(output, " -N enable specific name resolution(s): \"mnNtd\"\n"); + fprintf(output, " -N enable specific name resolution(s): \"mnNtdv\"\n"); fprintf(output, " -d %s ...\n", DECODE_AS_ARG_TEMPLATE); fprintf(output, " \"Decode As\", see the man page for details\n"); fprintf(output, " Example: tcp.port==8888,http\n"); diff --git a/ui/dissect_opts.c b/ui/dissect_opts.c index 77e7b589c4..c6aa77165c 100644 --- a/ui/dissect_opts.c +++ b/ui/dissect_opts.c @@ -79,7 +79,8 @@ dissect_opts_handle_opt(int opt, char *optarg_str_p) "\t'n' to enable network address resolution\n" "\t'N' to enable using external resolvers (e.g., DNS)\n" "\t for network address resolution\n" - "\t't' to enable transport-layer port number resolution"); + "\t't' to enable transport-layer port number resolution\n" + "\t'v' to enable VLAN IDs to names resolution"); return FALSE; } break;