Commit Graph

212 Commits

Author SHA1 Message Date
Guy Harris 6a0a56ed07 Note that -P can override -Q's suppression of packet output.
Change-Id: I38da07fb68a3b8c62e2267a06a9ba41ff80e7497
Reviewed-on: https://code.wireshark.org/review/25893
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-02-18 23:15:22 +00:00
Gerald Combs 0fa1176c22 Add `-z http_ref,tree` to the tshark man page.
Change-Id: Ia7b229fc4c42bd967ee4315543f58f6c05be5510
Reviewed-on: https://code.wireshark.org/review/25827
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-02-17 08:27:14 +00:00
Guy Harris af0f49e80d Use pcapng as the name of the file format.
At one point, I remember a discussion resulting in the official name of
the next-generation replacement for pcap format being changed to
"pcapng", with no hyphen.

Make Wireshark reflect that.

Change-Id: Ie66fb13a0fe3a8682143106dab601952e9154e2a
Reviewed-on: https://code.wireshark.org/review/25214
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-01-09 00:38:51 +00:00
Gerald Combs a65391f901 TShark: Fix color handling on Windows.
Use SetConsoleTextAttribute to reset our colors on Windows. Update the
release notes and man page.

Change-Id: I2bc309787f9c2331324503092bd1c9ae6360eb55
Reviewed-on: https://code.wireshark.org/review/25170
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-01-06 14:30:45 +00:00
Graham Bloice e4ac91091d tshark doc updates
After other changes, add info about -G help
and update output from -G dissector-tables.

Change-Id: I339d5c31a606720ef92e641e59ec5a45114321a8
Reviewed-on: https://code.wireshark.org/review/24188
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2017-10-30 19:26:13 +00:00
Christoph Wurm af09db8bd3 Tshark: Optional packet summary for Elasticsearch
Currently, the Elasticsearch output exports the packet details and,
if -x is specified, the raw hex data.

This change adds the option of exporting the packet summary as well.

The default stays the same (packet details only), but now the existing
-P switch turns on printing of the packet summary. It also turns off
printing packet details, which can be turned back on with -V to print
both, and combined with -x to print all three: summary, details and
raw hex.

The packet summary is especially useful when exploring and visualizing
the data in Kibana, e.g. by displaying the summary "Info" field/column
in a table, as in the Wireshark GUI.

Change-Id: I2030490cfdd905572397bc3d5457ba49d805a5c4
Reviewed-on: https://code.wireshark.org/review/22716
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-10-15 00:58:42 +00:00
Guy Harris 9551aca9a6 Add --print as an alias for -P, to match tcpdump.
tcpdump just got a --print option, which causes packet information to be
printed even if the raw packets are being saved to a file with -w.  We
have -P for the same purpose; make --print another name for it.

While we're at it:

	document --help and --version;

	just speak of -P/--print as causing printing even of the packet
	details, even though -V forces printing with -w, for consistency
	with how --print is documented for tcpdump;

	fix the description of -h/--help.

Change-Id: Idf650a202a09a2d1682edbd9d76123f1b1412b55
Reviewed-on: https://code.wireshark.org/review/23888
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-10-11 19:32:43 +00:00
Michael Mann 5f667694d3 Add Flow Graph functionality to TShark
Add flow graph functionality to tshark through -z option.
Output is same as ASCII format saved from GUI.

Change-Id: Iee0bfea7215858e6488b4728581be28287e9ea1a
Reviewed-on: https://code.wireshark.org/review/23652
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-09-22 04:49:48 +00:00
Ahmad Fatoum aca55a29f7 Add hardware timestamping support
pcap provides a pcap_set_tstamp_type function, which can be used to request
hardware timestamps from a supporting kernel.

This patch adds support for aforementioned function as well as two new
command line options to dumpcap, wireshark and tshark:

    --list-time-stamp-types
                             List time stamp types supported for the interface
    --time-stamp-type <type>
                             Change the interface's timestamp method

Name choice mimics those used by tcpdump(1), which already supports this
feature. However, unlike tcpdump, we provide both options unconditionally.
If Wireshark was configured without pcap_set_tstamp_type being available,
--list-time-stamp-types reports an empty list.

Change-Id: I418a4b2b84cb01949cd262aad0ad8427f5ac0652
Signed-off-by: Ahmad Fatoum <ahmad.fatoum@siemens.com>
Reviewed-on: https://code.wireshark.org/review/23113
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-08-22 07:55:26 +00:00
Sake Blok 3803e00367 Add option to use wall-clock intervals
Add the "interval" option to "-b". Each new capture starts at the
exact start of a time interval. For instance, using -b interval:3600
will start a new capture file at each whole hour.

Changed the duration option in the GUI interfaces to use the new
interval option.

Change-Id: I0180c43843f5d2f0c2f50153c9ce42ac7fa5aeae
Reviewed-on: https://code.wireshark.org/review/22428
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Sake Blok <sake.blok@SYN-bit.nl>
2017-07-03 16:41:37 +00:00
Daan De Meyer 07f576ffeb Add --no-duplicate-keys tshark option.
Adds the --no-duplicate-keys option to tshark. If -T json is specified,
this option can be specified in order to transform the duplicate keys
produced by -T json into single keys with as value a json array of all
separate values.

Specifying --no-duplicate-keys changes the function which groups node
children that is passed to write_json_proto_tree. Instead of a function
that puts each node in a separate group (proto_node_group_children_by_unique)
a function is passed that groups children that have the same json key
together (proto_node_group_children_by_json_key). This will lead to
some groups having multiple values. Groups with multiple values are
written to the output as a json array. This includes normal json keys
but also keys with the "_raw" and "_tree" suffix.

If --no-duplicate-keys is specified with an option other than "-T json"
or "-T jsonraw" or without -T an error is shown and tshark will exit.

"Export Packet Dissections -> As JSON" in the GUI is hardcoded to use
the duplicated keys format.

Fixes one regression in the output where a filtered json key (-j) with
both a value and children would not have the "_tree" suffix added to the
json key containing the children.

Includes a little code cleanup (removes one instance of code
duplication and simplifies a while loop).

Fixes a memory leak (I thought this fix was already included in the
previous refactor patch but something must have gone wrong when updating
the patch so I'm including it again in this patch).

Bug: 12958
Change-Id: I401f8fc877b5c590686567c3c44cdb832e9e7dfe
Reviewed-on: https://code.wireshark.org/review/22166
Petri-Dish: Jaap Keuter <jaap.keuter@xs4all.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-06-22 19:31:01 +00:00
Michael Mann 585d17ae7f Add support for color xml attributes in psml and pdml formats.
Bug: 6682
Change-Id: I19330d06aa3d5692503c61369c3c650d595971f5
Reviewed-on: https://code.wireshark.org/review/22077
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Stephen Donnelly <stephen.donnelly@endace.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-06-12 03:23:38 +00:00
Dave Goodell 2be411a215 tshark: add "--color" option emulating wireshark colors
With this commit, tshark will mimic the packet coloring present in the
Wireshark GUI whenever "--color" is passed.  This initial commit only
adds such support for the standard text output format.  A future commit
could potentially broaden this support to other output modes (such as
"-V" mode).

Bug: 5158
Change-Id: I59329e32475b0c67e28802e79610544d4868ea2d
Reviewed-on: https://code.wireshark.org/review/21325
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-06-11 13:36:19 +00:00
Hessam Jalali dd884611ac Auto reset epan session
Automatically resets intarnal epan session after reaching to
specified number of packets, for example
-M 1000
will reset the session every 1000 packets.

this is more like a proposal since the usage is very specific
it is useful for 24/7 live capture with dissection and sending
data directly to another application.

example:

tshark -Y "gtp" -M 100000 -T fields -e gtp.message -e gtp.teid

Change-Id: I8ee8b0380017c684120a93cb3fb43f41615a9c04
Reviewed-on: https://code.wireshark.org/review/21312
Reviewed-by: Evan Huus <eapache@gmail.com>
Petri-Dish: Evan Huus <eapache@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-05-05 00:51:58 +00:00
Guy Harris 067ef3e08a Clean up documentation and help messages for protocol enabling/disabling.
List all of --enable-protocol, --disable-protocol, --enable-heuristic,
and --disable-heuristic in the SYNOPSIS section of the man pages.

Undent after the list of taps for the -z option, so the following
options are at the same indentation as other options.

List --enable-protocol in the DESCRIPTION, above --disable-protocol.

Include --enable-protocol in the help message.

Change-Id: I680a54430789f3543b2d539fbded22b0b57f7f76
Reviewed-on: https://code.wireshark.org/review/21159
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-04-17 03:48:14 +00:00
Martin Sehnoutka 8efd42c4aa Reflect new default value of snaplen in man pages.
Default value for snaplen is defined in wiretap/wtap.h:
 #define WTAP_MAX_PACKET_SIZE    262144

and used in capture_opts.c:
    capture_opts->default_options.snaplen         =
    WTAP_MAX_PACKET_SIZE;

but help and man pages don't reflect this change.

Change-Id: I35ddf1e8b7ffd657f4e01b3fe6b4c44c9acece2b
Reviewed-on: https://code.wireshark.org/review/20738
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-03-28 16:23:59 +00:00
Jim Young e66b05fa9d tshark: Optionally delimit packet summary columns with tabs
This patch augments tshark's -T report with a "tabs" option.
When the -T tabs option is enabled an ASCII horizontal tab character
is inserted between each column of the human-readable one-line
packet summary record.

Change-Id: Id10a6e21e231eb2e52b6342ed05399db1a5fcfdf
Reviewed-on: https://code.wireshark.org/review/20537
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-03-19 13:47:41 +00:00
Peter Wu c79b5e0eb7 Update documentation with reference to $XDG_CONFIG_HOME
Since v2.1.0rc0-184-gb0b53fa593, $XDG_CONFIG_HOME/wireshark (instead of
$HOME/.wireshark) is used, clarify this in the WSUG and manuals.

Change-Id: I74a6f9b86bd8d54ee326ca83d7536e091d6da08a
Reviewed-on: https://code.wireshark.org/review/20364
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-03-03 19:29:44 +00:00
Martin Kacer cd7d159c2e json2pcap support added
Modified tshark -T json -x output
Added tshark -T jsonraw output
json2pcap.py (can be used for basic packet editing by modifying json)

The modification in tshark -T json -x and new tshark -T jsonraw output
add into  hex-data output in JSON also information on which position
each field is dissected in the original frame, what is the field length,
bitmask (for not byte aligned fields) and type. This information can be
used for latter processing. One use-case is json2pcap script which
assembles the protocol layers back together from upper to lowers layers,
which allows the basic packet modification/editing/rewriting.

Change-Id: Ibf948eb8fc7e3b0b51c12df6c3855f705a9c7925
Reviewed-on: https://code.wireshark.org/review/19990
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Dario Lombardo <lomato@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2017-02-25 19:11:01 +00:00
Jim Young 50489fd279 tshark: Add -G folders report
Add a new tshark feature to generate a folders report.  The folders report
is essentially the information presented by Wireshark's About / Folders page
in a TAB delimited format.

Change-Id: Ic4b3d332b4bdaa7e6b7aad1e9cc5dd18413aada6
Reviewed-on: https://code.wireshark.org/review/19002
Petri-Dish: Jim Young <jim.young.ws@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-12-03 12:47:05 +00:00
Moshe Kaplan 20c57cb298 Enable exporting objects with tshark
A new "--export-object <protocol>,<destdir>" option is added to tshark.

This required refactoring Export Object behavior in all GUIs to give the
export object handling to the dissector, rather than the ui layer.
Included in the refactoring was fixing some serious memory leaks in Qt
Export Object dialog, crash due to memory scope issues in GTK Export
Object dialog, and addition sorting column feature in Qt dialog (set
up by creating a widget to manage the items that were previously
leaking memory)

Bug: 9319
Ping-Bug: 13174
Change-Id: I515d7662fa1f150f672b1476716f347ec27deb9b
Reviewed-on: https://code.wireshark.org/review/18927
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-12-02 16:07:35 +00:00
Gerald Combs 8ea52e2f49 Man pages: Update -D flag text.
Refer to "Windows" instead of "Windows 2000". Add an "ip link show"
breadcrumb.

Change-Id: Ie1faa1d30b0ac63de35b0385cbb1306f08828e61
Reviewed-on: https://code.wireshark.org/review/18056
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-10-04 00:09:48 +00:00
João Valverde f8b738016e Fix manpages typo.
Change-Id: Iac747655d09c94926e51c7ea1f23375650cd6641
Ping-Bug: 12305
Reviewed-on: https://code.wireshark.org/review/16446
Reviewed-by: João Valverde <j@v6e.pt>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-07-15 01:15:15 +00:00
Martin Kacer ceae9e4d1f tshark fields filter added for other outputs
-e fields filter addded to ek|json|pdml output.

Bug: 12529
Change-Id: I1f0f8772eefceb5b71927925ce0c34af483571b9
Reviewed-on: https://code.wireshark.org/review/16193
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-06-29 08:29:16 +00:00
Martin Kacer c3f3bd7fa8 tshark JSON and Elasticsearch output fix
Fixed json and ek escape function
Fixed -j protocol filter to do exact match
Fixed -T json to correctly close json
Added -j protocol filter also to pdml output

Bug: 11754
Change-Id: I02f274e4a5a02346922b37bbe946c10340c242ea
Reviewed-on: https://code.wireshark.org/review/16034
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-06-21 16:57:59 +00:00
Martin Kacer 42b060905e tshark JSON and Elasticsearch output
Added ouput -T for json|ek
Added -j switch fo filter EK json|ek fields.
Added -x switch to work with json|ek to insert raw fields.

Bug: 11754

Change-Id: Iad5a9092b843c074b0b774d1745fa14fca09f6b7
Reviewed-on: https://code.wireshark.org/review/15869
Reviewed-by: Jaap Keuter <jaap.keuter@xs4all.nl>
Petri-Dish: Jaap Keuter <jaap.keuter@xs4all.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-06-17 06:09:29 +00:00
Jeff Morriss b2845a6ac8 tshark man page: the first TCP stream is stream 0, not 1.
This fixes the example of the -z follow option.

Also fix up some formatting in the same section.

Bug: 12383
Change-Id: Ic9b2ef5e63ab31d70f2750f9cfdcbab76cf204b6
Reviewed-on: https://code.wireshark.org/review/15667
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-06-01 04:30:50 +00:00
Gerald Combs d7cbea9428 TShark: Add a "-E bom=" option.
Add an option to print the UTF-8 BOM.

Change-Id: I3d30c67852b9b89d1548b0f957d97fd8e8741049
Reviewed-on: https://code.wireshark.org/review/15318
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jaap Keuter <jaap.keuter@xs4all.nl>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-05-11 17:30:33 +00:00
AndersBroman 505bf5945b [tshark] Document -U option and create a list of tap names when entering
an empty name "".

Change-Id: I2b8332ff6900c8a88514a25a416f342d7b696d34
Reviewed-on: https://code.wireshark.org/review/15332
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-05-11 11:27:49 +00:00
Gerald Combs ae4a912af0 TShark: Convert TTY output.
If we detect that we're writing to a TTY and that it doesn't support
UTF-8, convert our output to the current code page on UNIX/Linux or
to UTF-16LE on Windows. This helps to ensure that we don't fill users'
screens with mojibake, along with scrubbing invalid output.

Add a note about our output behavior to the TShark man page. Add a note
about the glyphs we should and shouldn't be using to utf8_entities.h.

Bug: 12393

Change-Id: I52b6dd240173b80ffb6d35b5950a46a565c97ce8
Reviewed-on: https://code.wireshark.org/review/15277
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-05-09 04:11:29 +00:00
João Valverde e005bc819c Remove synchronous DNS name resolution
Change-Id: Ie5e670b769eb0674950f3679ef511047641c2873
Reviewed-on: https://code.wireshark.org/review/14751
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-04-04 06:49:55 +00:00
Mike78 ef752689da Allow/Create an option to use "capture filter" labels defined in wireshark GUI from CLI
Move ui/filters.[ch] to filter_files.[ch] because dumpcap is using functionality.

Bug: 8091
Change-Id: I195c82fc023f97d6f331b8718c45a2d83d30faea
Reviewed-on: https://code.wireshark.org/review/5925
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-01-27 13:40:24 +00:00
Jeff Morriss cd7387d22b Add a "fieldcount" report to tshark -G to let us easily see how many fields
are registered.

Change-Id: I06f10d96916640cb9a782cae87898a5dd6c9c6e3
Reviewed-on: https://code.wireshark.org/review/10601
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-09-23 04:38:01 +00:00
Pascal Quantin 1772416170 tshark.pod: fix typo
Change-Id: Iba5f12637e0f494805f2d9aab370fb42a32c1cb9
Reviewed-on: https://code.wireshark.org/review/10335
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2015-08-31 20:12:41 +00:00
Hadriel Kaplan 190e313e9d DNS: move DNS name resolution pref to Name Resolution prefs
Move the boolean flag for using captured DNS packet info for name resolution
to the Name Resolution preferences settings, as it was rather surprising to
disable Name Resolution preferences and still have names being resolved. Also
disble them all if the '-n' command line switch is used, and re-enable it for
a 'd' character in the '-N' option.

Bug: 10337
Change-Id: Ie4d47bab0100db3360cc447cd3e446b2e39aa917
Reviewed-on: https://code.wireshark.org/review/9786
Petri-Dish: Hadriel Kaplan <hadrielk@yahoo.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Hadriel Kaplan <hadrielk@yahoo.com>
2015-07-25 17:05:01 +00:00
Michael Mann 120ed14f34 Add documentation for new enable/disable protocol and heuristic dissector options.
Change-Id: Ia31326105cf559c2196d45369270552fb78da6c7
Reviewed-on: https://code.wireshark.org/review/9692
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-07-22 07:12:28 +00:00
Gerald Combs fdb85029fd Add ServiceResponseTimeDialog.
Add ServiceResponseTimeDialog as a subclass of TapParameterDialog,
similar to StatsTreeDialog. Add initial plumbing for statistics menu
items and command line invocation.

Don't append "..." to menu item names. Don't add menu icons. In each
case this avoids repetitive UI clutter.

Change-Id: I463b95c93090160bb81d2e80b16aad389dc0bd6c
Reviewed-on: https://code.wireshark.org/review/8864
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-07-03 23:09:13 +00:00
Pascal Quantin e28339e590 tshark: add ability to display streams in EBCDIC
As requested in https://ask.wireshark.org/questions/42958/tshark-follow-tcp-stream-for-ebcdic

Change-Id: Ia8d93f59aa038bd6328adea137c92ea5a52361b5
Reviewed-on: https://code.wireshark.org/review/8844
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-06-09 04:00:01 +00:00
Jeff Morriss 2772a11bd5 Document the services file in the man pages.
Bug: 11227
Change-Id: Id9cc64820b238bd8c82a758a553e1352398ad885
Reviewed-on: https://code.wireshark.org/review/8664
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-05-28 04:10:08 +00:00
Jeff Morriss d9c13fab51 Document the subnets file in the man pages.
Text adapted from that in the WSUG documentation of the same.

Ping-Bug: 1445
Ping-Bug: 11227
Change-Id: I4d07cba437e70324d19c5ae23e44b86c47b749a8
Reviewed-on: https://code.wireshark.org/review/8662
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-05-28 04:08:06 +00:00
Gerald Combs cac102eee3 Change a lot of http:// URLs to https://.
Most of our sites are now HTTPS-only. Update URLs accordingly. Update
other URLs while we're at it. Remove or comment out dead links.

Change-Id: I7c4f323e6585d22760bb90bf28fc0faa6b893a33
Reviewed-on: https://code.wireshark.org/review/7621
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-03-10 19:30:50 +00:00
Jeff Morriss 0b0f7fa091 More emem removal.
Remove emem's 8-byte-memory-alignment configure check as well as references
to all the environment variables emem used.

Change-Id: I897aec9e9c68e064454561e7a9f066b18892ec66
Reviewed-on: https://code.wireshark.org/review/6950
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-02-06 08:11:49 +00:00
Dario Lombardo 9bbc337306 Added HPFEEDS stats_tree.
Change-Id: I256fd5395b062fa954ebd60598721323ea1d7ff1
Bug: 10875
Reviewed-on: https://code.wireshark.org/review/6713
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-01-27 13:19:20 +00:00
Dario Lombardo 696fcdba21 Added DNS statistics support
This affects both the dissector (that has been added with a tap interface and a stats generator) and the UI (to recall the stats menu).

Change-Id: I90658f7aa6707aa39bdd787a51b20fed4dbddc53
Reviewed-on: https://code.wireshark.org/review/6236
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-01-05 09:06:32 +00:00
Michael Mann 860cb393d8 tshark: Add endpoints statistics
"stat name" has been official changed to "endpoints" for all dissectors, rather than a mixture of "host"/"endpoints" based on dissector.

Change-Id: If34bcb5165b493948e784ba038ab202803a59843
Reviewed-on: https://code.wireshark.org/review/6154
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-01-02 00:02:18 +00:00
Pascal Quantin 0d414e5d7f Add ability to follow UDP stream by index
-z "follow,udp" tshark cli command now supports a stream index
It is now possible to select the UDP stream displayed in Qt GUI (like for TCP)

Change-Id: Ia367f36ea4f60db0fddb997a7e0903c09e172f2d
Reviewed-on: https://code.wireshark.org/review/6083
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-12-29 22:17:47 +00:00
Guy Harris 25f950eca9 Add tshark -G dissector-tables to dump a list of dissector tables.
That list doesn't show the entries in the dissector tables, just
information about the tables themselves.

Clean up some tshark man page issues while we're at it.

Change-Id: I70beee34110f5c0d58105944dd71105a8400f5ca
Reviewed-on: https://code.wireshark.org/review/5360
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-11-17 02:26:57 +00:00
Gerald Combs 175039128a Update the doc directory to use https://www.wireshark.org.
Change-Id: I9bfc57cb6b6ab6962b80ff58d98eb351d6f69829
Reviewed-on: https://code.wireshark.org/review/4140
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2014-09-17 00:12:26 +00:00
Jeff Morriss e0461ecd43 Indicate tshark can read (-r) from stdin and named pipes now.
(Though it works only with certain formats.)  As requested in:
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2874#c4

Change-Id: I2ce0509d8750b21ae0167d12459074ba0f9506f8
Reviewed-on: https://code.wireshark.org/review/2646
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-06-25 18:01:28 +00:00
Jeff Morriss f113306e0e More Python-bindings removal.
Change-Id: I4d82175781e65c73179f4c8e737a7900cb050bce
Reviewed-on: https://code.wireshark.org/review/2283
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
2014-06-16 23:14:05 +00:00
Hadriel Kaplan 7e423a3a1f Add read_format extension to manual pages
The -X read_format extension was added in code but in the manuals.

Change-Id: I21692120229ef531671fc3db247809ace69d23b3
Reviewed-on: https://code.wireshark.org/review/742
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-03-19 17:03:42 +00:00
Hadriel Kaplan 58fe488822 Lua: add ability for scripts loaded from command-line to be passed arguments
This change adds the ability to pass on to lua scripts loaded from the
command-line (tshark or wireshark) additional arguments supplied by the
command-line.  This will help us in our testsuites, but also might be
useful for user-created scripts.  The additional arguments are passed in
using the '-X' eXtension switch.

Change-Id: Ib94cdf1ffd194ca84692fee7816665e4ff95efbd
Reviewed-on: https://code.wireshark.org/review/156
Reviewed-by: Evan Huus <eapache@gmail.com>
Tested-by: Evan Huus <eapache@gmail.com>
2014-02-13 22:32:58 +00:00
Bill Meier 8ab9c55618 From Ville Skyttä: Spelling Fixes
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9591


svn path=/trunk/; revision=54387
2013-12-23 15:53:13 +00:00
Chris Maynard 4c19d29b7c Improve tshark command-line error help. Fixes https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9548 and adds addtional help, better formatting, sorting and some minimal documentation of the -u option to the tshark man page.
svn path=/trunk/; revision=53938
2013-12-11 16:52:40 +00:00
Chris Maynard 93f15d640c Specify SI units for the max filesize autostop condition. For now, keep the capture buffer size in IEC units, but document it as such.
#BACKPORT(1.10, 1.8(?))

svn path=/trunk/; revision=53728
2013-12-02 19:17:12 +00:00
Guy Harris 2a088c1d53 Add support for displaying dates as year and day-of-year (1-origin).
In the process, fix various man page descriptions of the -t flag,
and add support for UTC absolute times in the iousers and iostat TShark
taps.

svn path=/trunk/; revision=53114
2013-11-06 20:39:09 +00:00
Chris Maynard 63e4539229 From Ed Beroset via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9272
Add tshark -G column-formats report and document the missing ftypes, heuristic-decodes and plugins reports.

From me: Sort the reports.  Add modelines to epan/column.c.  Minor whitespace changes.

svn path=/trunk/; revision=52627
2013-10-15 18:27:35 +00:00
Michael Mann ba3e8e070a Make column "filter name" prefixed with _ws. to be the same as other "*shark application filters" created in r52462.
svn path=/trunk/; revision=52474
2013-10-09 19:43:02 +00:00
Jeff Morriss a4882cdcfe Add WIRESHARK_APPDATA description to the rawshark and tshark man pages.
svn path=/trunk/; revision=52024
2013-09-13 21:15:29 +00:00
Chris Maynard bc654875f0 Handle the 2GiB boundary case of the max filesize autostop condition properly so that we avoid overflow conditions and so that we ensure we don't capture more than 2GiB. Also, document the max filesize autostop value of 2GIB as well as indicating that it's truly GiB and not GB.
This fixes the problem reported on ask: http://ask.wireshark.org/questions/23891/wireshark-wont-run-with-multiple-capture-files

#BACKPORT(1.10) ... not sure about 1.8?

svn path=/trunk/; revision=51576
2013-08-29 18:15:13 +00:00
Chris Maynard 41f444ef87 Move the description of the -Y <displaY filter> option to maintain a proper sort.
svn path=/trunk/; revision=51238
2013-08-09 15:26:48 +00:00
Martin Kaiser 11643ecc83 add --capture-comment to tshark's manpage
fix a typo in the dumpcap manpage

svn path=/trunk/; revision=51096
2013-08-01 21:21:35 +00:00
Guy Harris a4ad9e9f74 If a core Wireshark developer repeatedly can't remember that the
argument to the -F flag for pcap format is "libpcap", not "pcap", we
have a problem.  Make it "pcap", and add a backwards-compatibility hack
to support using "libpcap" as well.

Update the man pages to refer to it as pcap as well, and fix the
capitalization of "WinPcap" (see http://www.winpcap.org) while we're at
it.

Also, refer to http://www.tcpdump.org/linktypes.html for the list of
link-layer header types for pcap and pcap-ng.

svn path=/trunk/; revision=50989
2013-07-28 21:12:07 +00:00
Jeff Morriss 36d3734dcb From Jim Young via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8906 :
This patch augments Wireshark's and tshark's augument usage reports (-? and
-t?) and the Wireshark and tshark man pages to list all available timestamp
options available for the -t option.

svn path=/trunk/; revision=50445
2013-07-08 16:25:13 +00:00
Jeff Morriss 470bd4455a 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
2013-06-05 14:08:40 +00:00
Chris Maynard 08b0f7296a If tcpdump doesn't exist, why refer to it? Omit this confusing phrase.
svn path=/trunk/; revision=49427
2013-05-20 02:21:07 +00:00
Evan Huus 7e0082988b At the suggestion of Stuart Kendrick via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8647
Improve documentation for tshark's -z io,stat somewhat so that it's clear(er)
that filters for the statistics must be associated with the -z flag and not
applied via -Y.

svn path=/trunk/; revision=49422
2013-05-19 19:49:36 +00:00
Jeff Morriss 2602490a2d From Niels de Vos via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8626 :
It is useful to see not only the minimal, maximum and average service time for
RPC procedures, but also the total time these took.


From me: add it to the man page.

svn path=/trunk/; revision=49144
2013-05-03 13:53:16 +00:00
Jörg Mayer 6c137314aa Add col. pseudo dissector to thsark manpage.
svn path=/trunk/; revision=48931
2013-04-19 16:36:52 +00:00
Chris Maynard 4ac2441d7c Coalesce "-G fields2" and "-G fields3" into "-G fields", as discussed on -dev.
See: http://www.wireshark.org/lists/wireshark-dev/201304/msg00015.html

svn path=/trunk/; revision=48753
2013-04-05 21:58:43 +00:00
Evan Huus 2fba8c0f9d Update -2, -R and -Y to behave consistently as per the concensus reached on
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8223

Mention the new -Y flag and associated changes in the release notes.

svn path=/trunk/; revision=48654
2013-03-30 15:38:03 +00:00
Evan Huus d935a280e3 From Hadriel Kaplan via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8223
Add a 2-pass display-filter flag to tshark so that reassembly and other forward-
looking dissections can be used with filters.

It's a bit of a hack, but this entire area of 2-pass analysis etc. is a giant
pile of hacks to begin with and needs cleaning up. For now just having this
feature is a big enough win.

svn path=/trunk/; revision=48589
2013-03-27 17:14:42 +00:00
Chris Maynard 63b578b182 Updated tshark man page and release notes to document the change in '-x' behavior with r45715.
svn path=/trunk/; revision=48456
2013-03-21 17:30:35 +00:00
Evan Huus 8de4b82fcd Document the wmem override environment variable in the man pages, and improve
README.wmem in a couple of places.

svn path=/trunk/; revision=48251
2013-03-11 19:17:26 +00:00
Jeff Morriss 965cb6384e Followup to r48218: remove documentation of the WIRESHARK_DEBUG_USE_SLICES environment variable.
svn path=/trunk/; revision=48249
2013-03-11 18:04:46 +00:00
Jeff Morriss 018ba4ea65 Default capture buffer size is now 2MB.
svn path=/trunk/; revision=47937
2013-02-28 13:59:47 +00:00
Chris Maynard 503cab9ff7 From Edwin Groothuis via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8353 : Document http-related '-z' statistics; also add document -z help.
From me: Don't print an error message for "-z help".

(Only "http,stat," is suitable for backport to 1.8 and 1.6)

svn path=/trunk/; revision=47763
2013-02-20 03:06:46 +00:00
Michael Mann 7f3064e6ae Add support in TShark to follow SSL streams
From QA Cafe, bug 8280 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8280)

svn path=/trunk/; revision=47372
2013-01-30 20:36:47 +00:00
Jeff Morriss 99ce4232cb As suggested in comments in sl_alloc() and sl_free(): add a new environment
variable (WIRESHARK_DEBUG_USE_SLICES) which turns off the slab allocator and uses
g_slices instead (which can themselves be turned off by setting
G_SLICE=always-malloc).

This makes debugging problems in slab-allocated memory easier to find
(hopefully including https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8197 ).


Set WIRESHARK_DEBUG_USE_SLICES when running Valgrind on *shark.


Remove unused structure member: emem_chunk_t.org.

svn path=/trunk/; revision=47110
2013-01-16 03:34:29 +00:00
Michael Mann 0bdfbe97d4 Add -Q option to TShark to force only "true" errors to stderr. No "status" messages should be included if -Q option is specified. Bug 2881 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2881)
svn path=/trunk/; revision=46627
2012-12-20 01:22:42 +00:00
Jeff Morriss 05ee001d73 Document the "-g" option to dumpcap.
Add that option to tshark, too, and document it.

The option can't be given to Wireshark because the GUI already has a "-g"
(goto packet).

svn path=/trunk/; revision=46513
2012-12-12 02:07:08 +00:00
Gerald Combs bd19dcd8bf Add an add_hosts_file routine that adds a "hosts" path to an array and
use it in tshark.c instead of read_hosts_file. This lets us use "-H"
multiple times. Make read_hosts_file static.

svn path=/trunk/; revision=46273
2012-11-29 00:32:39 +00:00
Chris Maynard b8e5c94167 List -z compare,... in the statistics documentation. Maybe someone who actually knows how to use it could elaborate?
svn path=/trunk/; revision=45769
2012-10-24 17:24:50 +00:00
Chris Maynard 26989e9d11 Inspired by http://www.wireshark.org/lists/wireshark-users/201206/msg00025.html, add support for being able to specify a numeric range as the <selector> part of tshark's -d <layer type>==<selector>,<decode-as protocol> option.
svn path=/trunk/; revision=45734
2012-10-23 00:58:38 +00:00
Jeff Morriss 8f12c9d7d7 First phase of fixing https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7380 :
Add a new name resolution option: whether or not use the configured (in the OS)
name resolver (e.g., DNS) to resolve network names.  When this option is disabled
but network name resolution is enabled then Wireshark will resolve only those
names that it can from local sources.  This includes (at least, AFAIK):

- name resolutions that Wireshark picks up on from DNS packets it decodes
- the "user hosts file" (~/.wireshark/hosts on *NIX)
- what Wireshark reads out of capture file (the PCAPNG name resolution block)

This new preference defaults to "use external resolvers" for backward
compatibility (so people turning on network name resolution will get the old
behavior).

This option can be set via Edit->Preferences and on the command line; there
remain several UIs (e.g., the "open capture file" dialog, the
View->Name Resolution menu, etc.) that don't have the new option yet.


Also expand on the "description" for the name resolution preferences: these
are used not only in the tooltips but are also written to the preferences
file.  The previous text didn't include enough context when written do the
preferences file.

svn path=/trunk/; revision=43605
2012-07-08 01:31:48 +00:00
Gerald Combs 085d21ec1c Remove what appears to be an errant vi/vim command and add a newline.
svn path=/trunk/; revision=43371
2012-06-19 15:44:10 +00:00
Jeff Morriss 406e66d3bf Fix a typo or two
svn path=/trunk/; revision=41657
2012-03-19 02:04:47 +00:00
Jeff Morriss a94c84d34f Add a new environment variable (WIRESHARK_ABORT_ON_OUT_OF_MEMORY) that
prevents OutOfMemory exceptions from being thrown.  This makes it easier
to debug such conditions.

Set this variable in test-fuzzed-cap.sh but not in fuzz-test.sh; it's nice
to see the friendly out-of-memory error message in the bug reports the
latter script generates.

svn path=/trunk/; revision=41656
2012-03-19 02:00:42 +00:00
Chris Maynard a88ab3eccf Sort the -z options.
svn path=/trunk/; revision=41560
2012-03-15 14:29:44 +00:00
Jeff Morriss 3b938cde37 Add documentation for the the tshark follow tcp/udp streams feature added
with https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6684

svn path=/trunk/; revision=41212
2012-02-27 19:05:55 +00:00
Chris Maynard 692528e2a5 Update the documentation to match the sort order. This documentation error was pointed out by Markus Amend on -users.
Reference: http://article.gmane.org/gmane.network.wireshark.user/14477

(BTW, I quickly scanned through tap-iousers.c:iousers_draw() and the sorting seems to be very inefficient.)

svn path=/trunk/; revision=40911
2012-02-07 03:20:33 +00:00
Jörg Mayer 801392d5d3 The libpcap puts pcap-filter into the misc section (which seems to be 7).
Refer to pcap-filter and mention tcpdump only as a fallback.

svn path=/trunk/; revision=40820
2012-02-03 09:07:24 +00:00
Martin Mathieson 98edb1cbb4 Add missing comments in syntax description for -z expert
svn path=/trunk/; revision=40050
2011-11-30 15:45:20 +00:00
Martin Mathieson 3b86b4d608 Change the -z args for expert item. You can now give the minimum severity level to report as well as a filter. Also, now show duplicate reports only once, and give the frequency rather than the frame number.
svn path=/trunk/; revision=40049
2011-11-30 15:41:39 +00:00
Chris Maynard 7140989018 From Michael Mann via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6377, with the tshark man page update by me: tshark -z io,stat,interval,"[SUM|MIN|MAX|AVG](field)field [and filter]" should support floating point.
svn path=/trunk/; revision=39767
2011-11-08 19:37:55 +00:00
Chris Maynard aa1199d01f Rather than complain and quit if -V is missing when -O <protocols> is used, do the user a favor and continue as if -V had been specified. Add explicit documentation of the -O <protocols> option to the man page.
svn path=/trunk/; revision=39175
2011-09-28 14:50:07 +00:00
Chris Maynard 311c5ef686 Add a new tshark option for being able to specify an alternate line separator between packets. The option chosen was "-S <separator>". The former -S option was renamed to -P, and the former -P option, which was previously undocumented, was renamed to -2. This fixes https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5342.
svn path=/trunk/; revision=39168
2011-09-27 18:32:59 +00:00
Chris Maynard cbb015b882 Fix a couple of typos and use 2 spaces consistently after a period.
svn path=/trunk/; revision=39092
2011-09-23 02:00:50 +00:00
Chris Maynard a554b48063 Trivial: Add missing <interval> in one case of tshark -z io,stat usage.
svn path=/trunk/; revision=39091
2011-09-23 01:23:42 +00:00
Martin Mathieson a0f614494b Add a tap for showing all expert items.
svn path=/trunk/; revision=39010
2011-09-15 10:30:57 +00:00