1TSHARK(1)               The Wireshark Network Analyzer               TSHARK(1)
2
3
4

NAME

6       tshark - Dump and analyze network traffic
7

SYNOPSIS

9       tshark [ -2 ] [ -a <capture autostop condition> ] ...
10       [ -b <capture ring buffer option>] ...  [ -B <capture buffer size> ]
11       [ -c <capture packet count> ] [ -C <configuration profile> ]
12       [ -d <layer type>==<selector>,<decode-as protocol> ] [ -D ]
13       [ -e <field> ] [ -E <field print option> ] [ -f <capture filter> ]
14       [ -F <file format> ] [ -g ] [ -h ] [ -H <input hosts file> ]
15       [ -i <capture interface>|- ] [ -I ] [ -K <keytab> ] [ -l ] [ -L ]
16       [ -n ] [ -N <name resolving flags> ] [ -o <preference setting> ] ...
17       [ -O <protocols> ] [ -p ] [ -P ] [ -q ] [ -Q ] [ -r <infile> ]
18       [ -R <Read filter> ] [ -Y <displaY filter> ] [ -s <capture snaplen> ]
19       [ -S <separator> ] [ -t a|ad|d|dd|e|r|u|ud ]
20       [ -T pdml|psml|ps|text|fields ] [ -v ] [ -V ] [ -w <outfile>|- ]
21       [ -W <file format option>] [ -x ] [ -X <eXtension option>]
22       [ -y <capture link type> ] [ -z <statistics> ] [ <capture filter> ]
23
24       tshark -G [fields|protocols|values|decodes|defaultprefs|currentprefs]
25

DESCRIPTION

27       TShark is a network protocol analyzer.  It lets you capture packet data
28       from a live network, or read packets from a previously saved capture
29       file, either printing a decoded form of those packets to the standard
30       output or writing the packets to a file.  TShark's native capture file
31       format is pcap format, which is also the format used by tcpdump and
32       various other tools.
33
34       Without any options set, TShark will work much like tcpdump.  It will
35       use the pcap library to capture traffic from the first available
36       network interface and displays a summary line on stdout for each
37       received packet.
38
39       TShark is able to detect, read and write the same capture files that
40       are supported by Wireshark.  The input file doesn't need a specific
41       filename extension; the file format and an optional gzip compression
42       will be automatically detected.  Near the beginning of the DESCRIPTION
43       section of wireshark(1) or
44       <http://www.wireshark.org/docs/man-pages/wireshark.html> is a detailed
45       description of the way Wireshark handles this, which is the same way
46       Tshark handles this.
47
48       Compressed file support uses (and therefore requires) the zlib library.
49       If the zlib library is not present, TShark will compile, but will be
50       unable to read compressed files.
51
52       If the -w option is not specified, TShark writes to the standard output
53       the text of a decoded form of the packets it captures or reads.  If the
54       -w option is specified, TShark writes to the file specified by that
55       option the raw data of the packets, along with the packets' time
56       stamps.
57
58       When writing a decoded form of packets, TShark writes, by default, a
59       summary line containing the fields specified by the preferences file
60       (which are also the fields displayed in the packet list pane in
61       Wireshark), although if it's writing packets as it captures them,
62       rather than writing packets from a saved capture file, it won't show
63       the "frame number" field.  If the -V option is specified, it writes
64       instead a view of the details of the packet, showing all the fields of
65       all protocols in the packet.  If the -O option is specified, it will
66       only show the full protocols specified.  Use the output of "tshark -G
67       protocols" to find the abbreviations of the protocols you can specify.
68
69       If you want to write the decoded form of packets to a file, run TShark
70       without the -w option, and redirect its standard output to the file (do
71       not use the -w option).
72
73       When writing packets to a file, TShark, by default, writes the file in
74       pcap format, and writes all of the packets it sees to the output file.
75       The -F option can be used to specify the format in which to write the
76       file.  This list of available file formats is displayed by the -F flag
77       without a value.  However, you can't specify a file format for a live
78       capture.
79
80       Read filters in TShark, which allow you to select which packets are to
81       be decoded or written to a file, are very powerful; more fields are
82       filterable in TShark than in other protocol analyzers, and the syntax
83       you can use to create your filters is richer.  As TShark progresses,
84       expect more and more protocol fields to be allowed in read filters.
85
86       Packet capturing is performed with the pcap library.  The capture
87       filter syntax follows the rules of the pcap library.  This syntax is
88       different from the read filter syntax.  A read filter can also be
89       specified when capturing, and only packets that pass the read filter
90       will be displayed or saved to the output file; note, however, that
91       capture filters are much more efficient than read filters, and it may
92       be more difficult for TShark to keep up with a busy network if a read
93       filter is specified for a live capture.
94
95       A capture or read filter can either be specified with the -f or -R
96       option, respectively, in which case the entire filter expression must
97       be specified as a single argument (which means that if it contains
98       spaces, it must be quoted), or can be specified with command-line
99       arguments after the option arguments, in which case all the arguments
100       after the filter arguments are treated as a filter expression.  Capture
101       filters are supported only when doing a live capture; read filters are
102       supported when doing a live capture and when reading a capture file,
103       but require TShark to do more work when filtering, so you might be more
104       likely to lose packets under heavy load if you're using a read filter.
105       If the filter is specified with command-line arguments after the option
106       arguments, it's a capture filter if a capture is being done (i.e., if
107       no -r option was specified) and a read filter if a capture file is
108       being read (i.e., if a -r option was specified).
109
110       The -G option is a special mode that simply causes Tshark to dump one
111       of several types of internal glossaries and then exit.
112

OPTIONS

114       -2  Perform a two-pass analysis. This causes tshark to buffer output
115           until the entire first pass is done, but allows it to fill in
116           fields that require future knowledge, such as 'response in frame #'
117           fields. Also permits reassembly frame dependencies to be calculated
118           correctly.
119
120       -a  <capture autostop condition>
121           Specify a criterion that specifies when TShark is to stop writing
122           to a capture file.  The criterion is of the form test:value, where
123           test is one of:
124
125           duration:value Stop writing to a capture file after value seconds
126           have elapsed.
127
128           filesize:value Stop writing to a capture file after it reaches a
129           size of value kB.  If this option is used together with the -b
130           option, TShark will stop writing to the current capture file and
131           switch to the next one if filesize is reached.  When reading a
132           capture file, TShark will stop reading the file after the number of
133           bytes read exceeds this number (the complete packet  will be read,
134           so more bytes than this number may be read).  Note that the
135           filesize is limited to a maximum value of 2 GiB.
136
137           files:value Stop writing to capture files after value number of
138           files were written.
139
140       -b  <capture ring buffer option>
141           Cause TShark to run in "multiple files" mode.  In "multiple files"
142           mode, TShark will write to several capture files.  When the first
143           capture file fills up, TShark will switch writing to the next file
144           and so on.
145
146           The created filenames are based on the filename given with the -w
147           option, the number of the file and on the creation date and time,
148           e.g. outfile_00001_20050604120117.pcap,
149           outfile_00002_20050604120523.pcap, ...
150
151           With the files option it's also possible to form a "ring buffer".
152           This will fill up new files until the number of files specified, at
153           which point TShark will discard the data in the first file and
154           start writing to that file and so on.  If the files option is not
155           set, new files filled up until one of the capture stop conditions
156           match (or until the disk is full).
157
158           The criterion is of the form key:value, where key is one of:
159
160           duration:value switch to the next file after value seconds have
161           elapsed, even if the current file is not completely filled up.
162
163           filesize:value switch to the next file after it reaches a size of
164           value kB.  Note that the filesize is limited to a maximum value of
165           2 GiB.
166
167           files:value begin again with the first file after value number of
168           files were written (form a ring buffer).  This value must be less
169           than 100000.  Caution should be used when using large numbers of
170           files: some filesystems do not handle many files in a single
171           directory well.  The files criterion requires either duration or
172           filesize to be specified to control when to go to the next file.
173           It should be noted that each -b parameter takes exactly one
174           criterion; to specify two criterion, each must be preceded by the
175           -b option.
176
177           Example: -b filesize:1000 -b files:5 results in a ring buffer of
178           five files of size one megabyte each.
179
180       -B  <capture buffer size>
181           Set capture buffer size (in MiB, default is 4 MiB).  This is used
182           by the capture driver to buffer packet data until that data can be
183           written to disk.  If you encounter packet drops while capturing,
184           try to increase this size.  Note that, while Tshark attempts to set
185           the buffer size to 4 MiB by default, and can be told to set it to a
186           larger value, the system or interface on which you're capturing
187           might silently limit the capture buffer size to a lower value or
188           raise it to a higher value.
189
190           This is available on UNIX systems with libpcap 1.0.0 or later and
191           on Windows.  It is not available on UNIX systems with earlier
192           versions of libpcap.
193
194           This option can occur multiple times.  If used before the first
195           occurrence of the -i option, it sets the default capture buffer
196           size.  If used after an -i option, it sets the capture buffer size
197           for the interface specified by the last -i option occurring before
198           this option.  If the capture buffer size is not set specifically,
199           the default capture buffer size is used instead.
200
201       -c  <capture packet count>
202           Set the maximum number of packets to read when capturing live data.
203           If reading a capture file, set the maximum number of packets to
204           read.
205
206       -C  <configuration profile>
207           Run with the given configuration profile.
208
209       -d  <layer type>==<selector>,<decode-as protocol>
210           Like Wireshark's Decode As... feature, this lets you specify how a
211           layer type should be dissected.  If the layer type in question (for
212           example, tcp.port or udp.port for a TCP or UDP port number) has the
213           specified selector value, packets should be dissected as the
214           specified protocol.
215
216           Example: -d tcp.port==8888,http will decode any traffic running
217           over TCP port 8888 as HTTP.
218
219           Example: -d tcp.port==8888:3,http will decode any traffic running
220           over TCP ports 8888, 8889 or 8890 as HTTP.
221
222           Example: -d tcp.port==8888-8890,http will decode any traffic
223           running over TCP ports 8888, 8889 or 8890 as HTTP.
224
225           Using an invalid selector or protocol will print out a list of
226           valid selectors and protocol names, respectively.
227
228           Example: -d . is a quick way to get a list of valid selectors.
229
230           Example: -d ethertype==0x0800. is a quick way to get a list of
231           protocols that can be selected with an ethertype.
232
233       -D  Print a list of the interfaces on which TShark can capture, and
234           exit.  For each network interface, a number and an interface name,
235           possibly followed by a text description of the interface, is
236           printed.  The interface name or the number can be supplied to the
237           -i option to specify an interface on which to capture.
238
239           This can be useful on systems that don't have a command to list
240           them (e.g., Windows systems, or UNIX systems lacking ifconfig -a);
241           the number can be useful on Windows 2000 and later systems, where
242           the interface name is a somewhat complex string.
243
244           Note that "can capture" means that TShark was able to open that
245           device to do a live capture.  Depending on your system you may need
246           to run tshark from an account with special privileges (for example,
247           as root) to be able to capture network traffic.  If TShark -D is
248           not run from such an account, it will not list any interfaces.
249
250       -e  <field>
251           Add a field to the list of fields to display if -T fields is
252           selected.  This option can be used multiple times on the command
253           line.  At least one field must be provided if the -T fields option
254           is selected. Column names may be used prefixed with "col."
255
256           Example: -e frame.number -e ip.addr -e udp -e col.info
257
258           Giving a protocol rather than a single field will print multiple
259           items of data about the protocol as a single field.  Fields are
260           separated by tab characters by default.  -E controls the format of
261           the printed fields.
262
263       -E  <field print option>
264           Set an option controlling the printing of fields when -T fields is
265           selected.
266
267           Options are:
268
269           header=y|n If y, print a list of the field names given using -e as
270           the first line of the output; the field name will be separated
271           using the same character as the field values.  Defaults to n.
272
273           separator=/t|/s|<character> Set the separator character to use for
274           fields.  If /t tab will be used (this is the default), if /s, a
275           single space will be used.  Otherwise any character that can be
276           accepted by the command line as part of the option may be used.
277
278           occurrence=f|l|a Select which occurrence to use for fields that
279           have multiple occurrences.  If f the first occurrence will be used,
280           if l the last occurrence will be used and if a all occurrences will
281           be used (this is the default).
282
283           aggregator=,|/s|<character> Set the aggregator character to use for
284           fields that have multiple occurrences.  If , a comma will be used
285           (this is the default), if /s, a single space will be used.
286           Otherwise any character that can be accepted by the command line as
287           part of the option may be used.
288
289           quote=d|s|n Set the quote character to use to surround fields.  d
290           uses double-quotes, s single-quotes, n no quotes (the default).
291
292       -f  <capture filter>
293           Set the capture filter expression.
294
295           This option can occur multiple times.  If used before the first
296           occurrence of the -i option, it sets the default capture filter
297           expression.  If used after an -i option, it sets the capture filter
298           expression for the interface specified by the last -i option
299           occurring before this option.  If the capture filter expression is
300           not set specifically, the default capture filter expression is used
301           if provided.
302
303       -F  <file format>
304           Set the file format of the output capture file written using the -w
305           option.  The output written with the -w option is raw packet data,
306           not text, so there is no -F option to request text output.  The
307           option -F without a value will list the available formats.
308
309       -g  This option causes the output file(s) to be created with group-read
310           permission (meaning that the output file(s) can be read by other
311           members of the calling user's group).
312
313       -G  [fields|protocols|values|decodes|defaultprefs|currentprefs]
314           The -G option will cause Tshark to dump one of several types of
315           glossaries and then exit.  If no specific glossary type is
316           specified, then the fields report will be generated by default.
317
318           The available report types include:
319
320           fields  Dumps the contents of the registration database to stdout.
321           An independent program can take this output and format it into nice
322           tables or HTML or whatever.  There is one record per line.  Each
323           record is either a protocol or a header field, differentiated by
324           the first field.  The fields are tab-delimited.
325
326            * Protocols
327            * ---------
328            * Field 1 = 'P'
329            * Field 2 = descriptive protocol name
330            * Field 3 = protocol abbreviation
331            *
332            * Header Fields
333            * -------------
334            * Field 1 = 'F'
335            * Field 2 = descriptive field name
336            * Field 3 = field abbreviation
337            * Field 4 = type ( textual representation of the ftenum type )
338            * Field 5 = parent protocol abbreviation
339            * Field 6 = base for display (for integer types); "parent bitfield width" for FT_BOOLEAN
340            * Field 7 = bitmask: format: hex: 0x....
341            * Field 8 = blurb describing field
342
343           protocols Dumps the protocols in the registration database to
344           stdout.  An independent program can take this output and format it
345           into nice tables or HTML or whatever.  There is one record per
346           line.  The fields are tab-delimited.
347
348            * Field 1 = protocol name
349            * Field 2 = protocol short name
350            * Field 3 = protocol filter name
351
352           values Dumps the value_strings, range_strings or true/false strings
353           for fields that have them.  There is one record per line.  Fields
354           are tab-delimited.  There are three types of records: Value String,
355           Range String and True/False String.  The first field, 'V', 'R' or
356           'T', indicates the type of record.
357
358            * Value Strings
359            * -------------
360            * Field 1 = 'V'
361            * Field 2 = field abbreviation to which this value string corresponds
362            * Field 3 = Integer value
363            * Field 4 = String
364            *
365            * Range Strings
366            * -------------
367            * Field 1 = 'R'
368            * Field 2 = field abbreviation to which this range string corresponds
369            * Field 3 = Integer value: lower bound
370            * Field 4 = Integer value: upper bound
371            * Field 5 = String
372            *
373            * True/False Strings
374            * ------------------
375            * Field 1 = 'T'
376            * Field 2 = field abbreviation to which this true/false string corresponds
377            * Field 3 = True String
378            * Field 4 = False String
379
380           decodes Dumps the "layer type"/"decode as" associations to stdout.
381           There is one record per line.  The fields are tab-delimited.
382
383            * Field 1 = layer type, e.g. "tcp.port"
384            * Field 2 = selector in decimal
385            * Field 3 = "decode as" name, e.g. "http"
386
387           defaultprefs  Dumps a default preferences file to stdout.
388
389           currentprefs  Dumps a copy of the current preferences file to
390           stdout.
391
392       -h  Print the version and options and exits.
393
394       -H  <input hosts file>
395           Read a list of entries from a "hosts" file, which will then be
396           written to a capture file.  Implies -W n. Can be called multiple
397           times.
398
399           The "hosts" file format is documented at
400           <http://en.wikipedia.org/wiki/Hosts_(file)>.
401
402       -i  <capture interface> | -
403           Set the name of the network interface or pipe to use for live
404           packet capture.
405
406           Network interface names should match one of the names listed in
407           "tshark -D" (described above); a number, as reported by "tshark
408           -D", can also be used.  If you're using UNIX, "netstat -i" or
409           "ifconfig -a" might also work to list interface names, although not
410           all versions of UNIX support the -a option to ifconfig.
411
412           If no interface is specified, TShark searches the list of
413           interfaces, choosing the first non-loopback interface if there are
414           any non-loopback interfaces, and choosing the first loopback
415           interface if there are no non-loopback interfaces.  If there are no
416           interfaces at all, TShark reports an error and doesn't start the
417           capture.
418
419           Pipe names should be either the name of a FIFO (named pipe) or
420           ``-'' to read data from the standard input.  Data read from pipes
421           must be in standard pcap format.
422
423           This option can occur multiple times.  When capturing from multiple
424           interfaces, the capture file will be saved in pcap-ng format.
425
426           Note: the Win32 version of TShark doesn't support capturing from
427           pipes!
428
429       -I  Put the interface in "monitor mode"; this is supported only on IEEE
430           802.11 Wi-Fi interfaces, and supported only on some operating
431           systems.
432
433           Note that in monitor mode the adapter might disassociate from the
434           network with which it's associated, so that you will not be able to
435           use any wireless networks with that adapter.  This could prevent
436           accessing files on a network server, or resolving host names or
437           network addresses, if you are capturing in monitor mode and are not
438           connected to another network with another adapter.
439
440           This option can occur multiple times.  If used before the first
441           occurrence of the -i option, it enables the monitor mode for all
442           interfaces.  If used after an -i option, it enables the monitor
443           mode for the interface specified by the last -i option occurring
444           before this option.
445
446       -K  <keytab>
447           Load kerberos crypto keys from the specified keytab file.  This
448           option can be used multiple times to load keys from several files.
449
450           Example: -K krb5.keytab
451
452       -l  Flush the standard output after the information for each packet is
453           printed.  (This is not, strictly speaking, line-buffered if -V was
454           specified; however, it is the same as line-buffered if -V wasn't
455           specified, as only one line is printed for each packet, and, as -l
456           is normally used when piping a live capture to a program or script,
457           so that output for a packet shows up as soon as the packet is seen
458           and dissected, it should work just as well as true line-buffering.
459           We do this as a workaround for a deficiency in the Microsoft Visual
460           C++ C library.)
461
462           This may be useful when piping the output of TShark to another
463           program, as it means that the program to which the output is piped
464           will see the dissected data for a packet as soon as TShark sees the
465           packet and generates that output, rather than seeing it only when
466           the standard output buffer containing that data fills up.
467
468       -L  List the data link types supported by the interface and exit.  The
469           reported link types can be used for the -y option.
470
471       -n  Disable network object name resolution (such as hostname, TCP and
472           UDP port names); the -N flag might override this one.
473
474       -N  <name resolving flags>
475           Turn on name resolving only for particular types of addresses and
476           port numbers, with name resolving for other types of addresses and
477           port numbers turned off.  This flag overrides -n if both -N and -n
478           are present.  If both -N and -n flags are not present, all name
479           resolutions are turned on.
480
481           The argument is a string that may contain the letters:
482
483           m to enable MAC address resolution
484
485           n to enable network address resolution
486
487           N to enable using external resolvers (e.g., DNS) for network
488           address resolution
489
490           t to enable transport-layer port number resolution
491
492           C to enable concurrent (asynchronous) DNS lookups
493
494       -o  <preference>:<value>
495           Set a preference value, overriding the default value and any value
496           read from a preference file.  The argument to the option is a
497           string of the form prefname:value, where prefname is the name of
498           the preference (which is the same name that would appear in the
499           preference file), and value is the value to which it should be set.
500
501       -O  <protocols>
502           Similar to the -V option, but causes TShark to only show a detailed
503           view of the comma-separated list of protocols specified, rather
504           than a detailed view of all protocols.  Use the output of "tshark
505           -G protocols" to find the abbreviations of the protocols you can
506           specify.
507
508       -p  Don't put the interface into promiscuous mode.  Note that the
509           interface might be in promiscuous mode for some other reason;
510           hence, -p cannot be used to ensure that the only traffic that is
511           captured is traffic sent to or from the machine on which TShark is
512           running, broadcast traffic, and multicast traffic to addresses
513           received by that machine.
514
515           This option can occur multiple times.  If used before the first
516           occurrence of the -i option, no interface will be put into the
517           promiscuous mode.  If used after an -i option, the interface
518           specified by the last -i option occurring before this option will
519           not be put into the promiscuous mode.
520
521       -P  Decode and display the packet summary, even if writing raw packet
522           data using the -w option.
523
524       -q  When capturing packets, don't display the continuous count of
525           packets captured that is normally shown when saving a capture to a
526           file; instead, just display, at the end of the capture, a count of
527           packets captured.  On systems that support the SIGINFO signal, such
528           as various BSDs, you can cause the current count to be displayed by
529           typing your "status" character (typically control-T, although it
530           might be set to "disabled" by default on at least some BSDs, so
531           you'd have to explicitly set it to use it).
532
533           When reading a capture file, or when capturing and not saving to a
534           file, don't print packet information; this is useful if you're
535           using a -z option to calculate statistics and don't want the packet
536           information printed, just the statistics.
537
538       -Q  When capturing packets, only display true errors.  This outputs
539           less than the -q option, so the interface name and total packet
540           count and the end of a capture are not sent to stderr.
541
542       -r  <infile>
543           Read packet data from infile, can be any supported capture file
544           format (including gzipped files).  It's not possible to use named
545           pipes or stdin here!
546
547       -R  <Read filter>
548           Cause the specified filter (which uses the syntax of read/display
549           filters, rather than that of capture filters) to be applied during
550           the first pass of analysis. Packets not matching the filter are not
551           considered for future passes. Only makes sense with multiple
552           passes, see -2. For regular filtering on single-pass dissect see -Y
553           instead.
554
555           Note that forward-looking fields such as 'response in frame #'
556           cannot be used with this filter, since they will not have been
557           calculate when this filter is applied.
558
559       -Y  <displaY filter>
560           Cause the specified filter (which uses the syntax of read/display
561           filters, rather than that of capture filters) to be applied before
562           printing a decoded form of packets or writing packets to a file.
563           Packets matching the filter are printed or written to file; packets
564           that the matching packets depend upon (e.g., fragments), are not
565           printed but are written to file; packets not matching the filter
566           nor depended upon are discarded rather than being printed or
567           written.
568
569           Use this instead of -R for filtering using single-pass analysis. If
570           doing two-pass analysis (see -2) then only packets matching the
571           read filter (if there is one) will be checked against this filter.
572
573       -s  <capture snaplen>
574           Set the default snapshot length to use when capturing live data.
575           No more than snaplen bytes of each network packet will be read into
576           memory, or saved to disk.  A value of 0 specifies a snapshot length
577           of 262144, so that the full packet is captured; this is the
578           default.
579
580           This option can occur multiple times.  If used before the first
581           occurrence of the -i option, it sets the default snapshot length.
582           If used after an -i option, it sets the snapshot length for the
583           interface specified by the last -i option occurring before this
584           option.  If the snapshot length is not set specifically, the
585           default snapshot length is used if provided.
586
587       -S  <separator>
588           Set the line separator to be printed between packets.
589
590       -t  a|ad|d|dd|e|r|u|ud
591           Set the format of the packet timestamp printed in summary lines.
592           The format can be one of:
593
594           a absolute: The absolute time is the actual time the packet was
595           captured, with no date displayed
596
597           ad absolute with date: The absolute date and time is the actual
598           time and date the packet was captured
599
600           d delta: The delta time is the time since the previous packet was
601           captured
602
603           dd delta_displayed: The delta_displayed time is the time since the
604           previous displayed packet was captured
605
606           e epoch: The time in seconds since epoch (Jan 1, 1970 00:00:00)
607
608           r relative: The relative time is the time elapsed between the first
609           packet and the current packet
610
611           u UTC: The UTC time is the actual time the packet was captured,
612           with no date displayed
613
614           ud UTC with date: The UTC date and time is the actual time and date
615           the packet was captured
616
617           The default format is relative.
618
619       -T  pdml|psml|ps|text|fields
620           Set the format of the output when viewing decoded packet data.  The
621           options are one of:
622
623           pdml Packet Details Markup Language, an XML-based format for the
624           details of a decoded packet.  This information is equivalent to the
625           packet details printed with the -V flag.
626
627           psml Packet Summary Markup Language, an XML-based format for the
628           summary information of a decoded packet.  This information is
629           equivalent to the information shown in the one-line summary printed
630           by default.
631
632           ps PostScript for a human-readable one-line summary of each of the
633           packets, or a multi-line view of the details of each of the
634           packets, depending on whether the -V flag was specified.
635
636           text Text of a human-readable one-line summary of each of the
637           packets, or a multi-line view of the details of each of the
638           packets, depending on whether the -V flag was specified.  This is
639           the default.
640
641           fields The values of fields specified with the -e option, in a form
642           specified by the -E option.  For example,
643
644             -T fields -E separator=, -E quote=d
645
646           would generate comma-separated values (CSV) output suitable for
647           importing into your favorite spreadsheet program.
648
649       -v  Print the version and exit.
650
651       -V  Cause TShark to print a view of the packet details.
652
653       -w  <outfile> | -
654           Write raw packet data to outfile or to the standard output if
655           outfile is '-'.
656
657           NOTE: -w provides raw packet data, not text.  If you want text
658           output you need to redirect stdout (e.g. using '>'), don't use the
659           -w option for this.
660
661       -W  <file format option>
662           Save extra information in the file if the format supports it.  For
663           example,
664
665             -F pcapng -W n
666
667           will save host name resolution records along with captured packets.
668
669           Future versions of Wireshark may automatically change the capture
670           format to pcapng as needed.
671
672           The argument is a string that may contain the following letter:
673
674           n write network address resolution information (pcapng only)
675
676       -x  Cause TShark to print a hex and ASCII dump of the packet data after
677           printing the summary and/or details, if either are also being
678           displayed.
679
680       -X <eXtension options>
681           Specify an option to be passed to a TShark module.  The eXtension
682           option is in the form extension_key:value, where extension_key can
683           be:
684
685           lua_script:lua_script_filename tells Wireshark to load the given
686           script in addition to the default Lua scripts.
687
688       -y  <capture link type>
689           Set the data link type to use while capturing packets.  The values
690           reported by -L are the values that can be used.
691
692           This option can occur multiple times.  If used before the first
693           occurrence of the -i option, it sets the default capture link type.
694           If used after an -i option, it sets the capture link type for the
695           interface specified by the last -i option occurring before this
696           option.  If the capture link type is not set specifically, the
697           default capture link type is used if provided.
698
699       -z  <statistics>
700           Get TShark to collect various types of statistics and display the
701           result after finishing reading the capture file.  Use the -q flag
702           if you're reading a capture file and only want the statistics
703           printed, not any per-packet information.
704
705           Note that the -z proto option is different - it doesn't cause
706           statistics to be gathered and printed when the capture is complete,
707           it modifies the regular packet summary output to include the values
708           of fields specified with the option.  Therefore you must not use
709           the -q option, as that option would suppress the printing of the
710           regular packet summary output, and must also not use the -V option,
711           as that would cause packet detail information rather than packet
712           summary information to be printed.
713
714           Currently implemented statistics are:
715
716           -z help
717               Display all possible values for -z.
718
719           -z afp,srt[,filter]
720           -z camel,srt
721           -z compare,start,stop,ttl[0|1],order[0|1],variance[,filter]
722               If the optional filter is specified, only those packets that
723               match the filter will be used in the calculations.
724
725           -z conv,type[,filter]
726               Create a table that lists all conversations that could be seen
727               in the capture.  type specifies the conversation endpoint types
728               for which we want to generate the statistics; currently the
729               supported ones are:
730
731                 "eth"   Ethernet addresses
732                 "fc"    Fibre Channel addresses
733                 "fddi"  FDDI addresses
734                 "ip"    IPv4 addresses
735                 "ipv6"  IPv6 addresses
736                 "ipx"   IPX addresses
737                 "tcp"   TCP/IP socket pairs  Both IPv4 and IPv6 are supported
738                 "tr"    Token Ring addresses
739                 "udp"   UDP/IP socket pairs  Both IPv4 and IPv6 are supported
740
741               If the optional filter is specified, only those packets that
742               match the filter will be used in the calculations.
743
744               The table is presented with one line for each conversation and
745               displays the number of packets/bytes in each direction as well
746               as the total number of packets/bytes.  The table is sorted
747               according to the total number of frames.
748
749           -z dcerpc,srt,uuid,major.minor[,filter]
750               Collect call/reply SRT (Service Response Time) data for DCERPC
751               interface uuid, version major.minor.  Data collected is the
752               number of calls for each procedure, MinSRT, MaxSRT and AvgSRT.
753
754               Example: -z dcerpc,srt,12345778-1234-abcd-ef00-0123456789ac,1.0
755               will collect data for the CIFS SAMR Interface.
756
757               This option can be used multiple times on the command line.
758
759               If the optional filter is provided, the stats will only be
760               calculated on those calls that match that filter.
761
762               Example:
763               -z dcerpc,srt,12345778-1234-abcd-ef00-0123456789ac,1.0,ip.addr==1.2.3.4
764               will collect SAMR SRT statistics for a specific host.
765
766           -z diameter,avp[,cmd.code,field,field,...]
767               This option enables extraction of most important diameter
768               fields from large capture files.  Exactly one text line for
769               each diameter message with matched diameter.cmd.code will be
770               printed.
771
772               Empty diameter command code or '*' can be specified to mach any
773               diameter.cmd.code
774
775               Example: -z diameter,avp  extract default field set from
776               diameter messages.
777
778               Example: -z diameter,avp,280  extract default field set from
779               diameter DWR messages.
780
781               Example: -z diameter,avp,272  extract default field set from
782               diameter CC messages.
783
784               Extract most important fields from diameter CC messages:
785
786               tshark -r file.cap.gz -q -z
787               diameter,avp,272,CC-Request-Type,CC-Request-Number,Session-Id,Subscription-Id-Data,Rating-Group,Result-Code
788
789               Following fields will be printed out for each diameter message:
790
791                 "frame"        Frame number.
792                 "time"         Unix time of the frame arrival.
793                 "src"          Source address.
794                 "srcport"      Source port.
795                 "dst"          Destination address.
796                 "dstport"      Destination port.
797                 "proto"        Constant string 'diameter', which can be used for post processing of tshark output.  E.g. grep/sed/awk.
798                 "msgnr"        seq. number of diameter message within the frame.  E.g. '2' for the third diameter message in the same frame.
799                 "is_request"   '0' if message is a request, '1' if message is an answer.
800                 "cmd"          diameter.cmd_code, E.g. '272' for credit control messages.
801                 "req_frame"    Number of frame where matched request was found or '0'.
802                 "ans_frame"    Number of frame where matched answer was found or '0'.
803                 "resp_time"    response time in seconds, '0' in case if matched Request/Answer is not found in trace.  E.g. in the begin or end of capture.
804
805               -z diameter,avp option is much faster than -V -T text or -T
806               pdml options.
807
808               -z diameter,avp option is more powerful than -T field and -z
809               proto,colinfo options.
810
811               Multiple diameter messages in one frame are supported.
812
813               Several fields with same name within one diameter message are
814               supported, e.g. diameter.Subscription-Id-Data or
815               diameter.Rating-Group.
816
817               Note: tshark -q option is recommended to suppress default
818               tshark output.
819
820           -z expert[,error|,warn|,note|,chat][,filter]
821               Collects information about all expert info, and will display
822               them in order, grouped by severity.
823
824               Example: -z expert,sip will show expert items of all severity
825               for frames that match the sip protocol.
826
827               This option can be used multiple times on the command line.
828
829               If the optional filter is provided, the stats will only be
830               calculated on those calls that match that filter.
831
832               Example: -z "expert,note,tcp" will only collect expert items
833               for frames that include the tcp protocol, with a severity of
834               note or higher.
835
836           -z follow,prot,mode,filter[,range]
837               Displays the contents of a TCP or UDP stream between two nodes.
838               The data sent by the second node is prefixed with a tab to
839               differentiate it from the data sent by the first node.
840
841               prot specifies the transport protocol.  It can be one of:
842                 tcp   TCP
843                 udp   UDP
844                 ssl   SSL
845
846               mode specifies the output mode.  It can be one of:
847                 ascii ASCII output with dots for non-printable characters
848                 hex   Hexadecimal and ASCII data with offsets
849                 raw   Hexadecimal data
850
851               Since the output in ascii mode may contain newlines, the length
852               of each section of output plus a newline precedes each section
853               of output.
854
855               filter specifies the stream to be displayed.  UDP streams are
856               selected with IP address plus port pairs.  TCP streams are
857               selected with either the stream index or IP address plus port
858               pairs.  For example:
859                 ip-addr0:port0,ip-addr1:port1
860                 tcp-stream-index
861
862               range optionally specifies which "chunks" of the stream should
863               be displayed.
864
865               Example: -z "follow,tcp,hex,1" will display the contents of the
866               first TCP stream in "hex" format.
867
868                 ===================================================================
869                 Follow: tcp,hex
870                 Filter: tcp.stream eq 1
871                 Node 0: 200.57.7.197:32891
872                 Node 1: 200.57.7.198:2906
873                 00000000  00 00 00 22 00 00 00 07  00 0a 85 02 07 e9 00 02  ...".... ........
874                 00000010  07 e9 06 0f 00 0d 00 04  00 00 00 01 00 03 00 06  ........ ........
875                 00000020  1f 00 06 04 00 00                                 ......
876                     00000000  00 01 00 00                                       ....
877                     00000026  00 02 00 00
878
879               Example: -z
880               "follow,tcp,ascii,200.57.7.197:32891,200.57.7.198:2906" will
881               display the contents of a TCP stream between 200.57.7.197 port
882               32891 and 200.57.7.98 port 2906.
883
884                 ===================================================================
885                 Follow: tcp,ascii
886                 Filter: (ommitted for readability)
887                 Node 0: 200.57.7.197:32891
888                 Node 1: 200.57.7.198:2906
889                 38
890                 ...".....
891                 ................
892                     4
893                     ....
894
895           -z h225,counter[,filter]
896               Count ITU-T H.225 messages and their reasons.  In the first
897               column you get a list of H.225 messages and H.225 message
898               reasons, which occur in the current capture file.  The number
899               of occurrences of each message or reason is displayed in the
900               second column.
901
902               Example: -z h225,counter.
903
904               If the optional filter is provided, the stats will only be
905               calculated on those calls that match that filter.  Example: use
906               -z "h225,counter,ip.addr==1.2.3.4" to only collect stats for
907               H.225 packets exchanged by the host at IP address 1.2.3.4 .
908
909               This option can be used multiple times on the command line.
910
911           -z h225,srt[,filter]
912               Collect requests/response SRT (Service Response Time) data for
913               ITU-T H.225 RAS.  Data collected is number of calls of each
914               ITU-T H.225 RAS Message Type, Minimum SRT, Maximum SRT, Average
915               SRT, Minimum in Packet, and Maximum in Packet.  You will also
916               get the number of Open Requests (Unresponded Requests),
917               Discarded Responses (Responses without matching request) and
918               Duplicate Messages.
919
920               Example: -z h225,srt
921
922               This option can be used multiple times on the command line.
923
924               If the optional filter is provided, the stats will only be
925               calculated on those calls that match that filter.
926
927               Example: -z "h225,srt,ip.addr==1.2.3.4" will only collect stats
928               for ITU-T H.225 RAS packets exchanged by the host at IP address
929               1.2.3.4 .
930
931           -z hosts[,ipv4][,ipv6]
932               Dump any collected IPv4 and/or IPv6 addresses in "hosts"
933               format.  Both IPv4 and IPv6 addresses are dumped by default.
934
935               Addresses are collected from a number of sources, including
936               standard "hosts" files and captured traffic.
937
938           -z http,stat,
939               Calculate the HTTP statistics distribution. Displayed values
940               are the HTTP status codes and the HTTP request methods.
941
942           -z http,tree
943               Calculate the HTTP packet distribution. Displayed values are
944               the HTTP request modes and the HTTP status codes.
945
946           -z http_req,tree
947               Calculate the HTTP requests by server. Displayed values are the
948               server name and the URI path.
949
950           -z http_srv,tree
951               Calculate the HTTP requests and responses by server. For the
952               HTTP requests, displayed values are the server IP address and
953               server hostname. For the HTTP responses, displayed values are
954               the server IP address and status.
955
956           -z icmp,srt[,filter]
957               Compute total ICMP echo requests, replies, loss, and percent
958               loss, as well as minimum, maximum, mean, median and sample
959               standard deviation SRT statistics typical of what ping
960               provides.
961
962               Example: -z icmp,srt,ip.src==1.2.3.4 will collect ICMP SRT
963               statistics for ICMP echo request packets originating from a
964               specific host.
965
966               This option can be used multiple times on the command line.
967
968           -z icmpv6,srt[,filter]
969               Compute total ICMPv6 echo requests, replies, loss, and percent
970               loss, as well as minimum, maximum, mean, median and sample
971               standard deviation SRT statistics typical of what ping
972               provides.
973
974               Example: -z icmpv6,srt,ipv6.src==fe80::1 will collect ICMPv6
975               SRT statistics for ICMPv6 echo request packets originating from
976               a specific host.
977
978               This option can be used multiple times on the command line.
979
980           -z io,phs[,filter]
981               Create Protocol Hierarchy Statistics listing both number of
982               packets and bytes.  If no filter is specified the statistics
983               will be calculated for all packets.  If a filter is specified
984               statistics will only be calculated for those packets that match
985               the filter.
986
987               This option can be used multiple times on the command line.
988
989           -z io,stat,interval[,filter][,filter][,filter]...
990               Collect packet/bytes statistics for the capture in intervals of
991               interval seconds.  Interval can be specified either as a whole
992               or fractional second and can be specified with microsecond (us)
993               resolution.  If interval is 0, the statistics will be
994               calculated over all packets.
995
996               If no filter is specified the statistics will be calculated for
997               all packets.  If one or more filters are specified statistics
998               will be calculated for all filters and presented with one
999               column of statistics for each filter.
1000
1001               This option can be used multiple times on the command line.
1002
1003               Example: -z io,stat,1,ip.addr==1.2.3.4 will generate 1 second
1004               statistics for all traffic to/from host 1.2.3.4.
1005
1006               Example: -z "io,stat,0.001,smb&&ip.addr==1.2.3.4" will generate
1007               1ms statistics for all SMB packets to/from host 1.2.3.4.
1008
1009               The examples above all use the standard syntax for generating
1010               statistics which only calculates the number of packets and
1011               bytes in each interval.
1012
1013               io,stat can also do much more statistics and calculate COUNT(),
1014               SUM(), MIN(), MAX(), AVG() and LOAD() using a slightly
1015               different filter syntax:
1016
1017           -z io,stat,interval,"[COUNT|SUM|MIN|MAX|AVG|LOAD](field)field [and
1018           filter]"
1019               NOTE: One important thing to note here is that the field that
1020               the calculation is based on MUST also be part of the filter
1021               string or else the calculation will fail.
1022
1023               So: -z io,stat,0.010,AVG(smb.time) does not work.  Use -z
1024               io,stat,0.010,AVG(smb.time)smb.time instead.  Also be aware
1025               that a field can exist multiple times inside the same packet
1026               and will then be counted multiple times in those packets.
1027
1028               NOTE: A second important thing to note is that the system
1029               setting for decimal separator is set to "."! If it is set to
1030               "," the statistics will not be displayed per filter.
1031
1032               COUNT(field)field [and filter] - Calculates the number of times
1033               that the field name (not its value) appears per interval in the
1034               filtered packet list.  ''field'' can be any display filter
1035               name.
1036
1037               Example: -z io,stat,0.010,"COUNT(smb.sid)smb.sid"
1038
1039               This will count the total number of SIDs seen in each 10ms
1040               interval.
1041
1042               SUM(field)field [and filter] - Unlike COUNT, the values of the
1043               specified field are summed per time interval.  ''field'' can
1044               only be a named integer, float, double or relative time field.
1045
1046               Example: -z io,stat,0.010,"SUM(frame.len)frame.len"
1047
1048               Reports the total number of bytes that were transmitted
1049               bidirectionally in all the packets within a 10 millisecond
1050               interval.
1051
1052               MIN/MAX/AVG(field)field [and filter] - The minimum, maximum, or
1053               average field value in each interval is calculated.  The
1054               specified field must be a named integer, float, double or
1055               relative time field.  For relative time fields, the output is
1056               presented in seconds with six decimal digits of precision
1057               rounded to the nearest microsecond.
1058
1059               In the following example, the time of the first Read_AndX call,
1060               the last Read_AndX response values are displayed and the
1061               minimum, maximum, and average Read response times (SRTs) are
1062               calculated.  NOTE: If the DOS command shell line continuation
1063               character, ''^'' is used, each line cannot end in a comma so it
1064               is placed at the beginning of each continuation line:
1065
1066                 tshark -o tcp.desegment_tcp_streams:FALSE -n -q -r smb_reads.cap -z io,stat,0,
1067                 "MIN(frame.time_relative)frame.time_relative and smb.cmd==0x2e and smb.flags.response==0",
1068                 "MAX(frame.time_relative)frame.time_relative and smb.cmd==0x2e and smb.flags.response==1",
1069                 "MIN(smb.time)smb.time and smb.cmd==0x2e",
1070                 "MAX(smb.time)smb.time and smb.cmd==0x2e",
1071                 "AVG(smb.time)smb.time and smb.cmd==0x2e"
1072
1073
1074                 ======================================================================================================
1075                 IO Statistics
1076                 Column #0: MIN(frame.time_relative)frame.time_relative and smb.cmd==0x2e and smb.flags.response==0
1077                 Column #1: MAX(frame.time_relative)frame.time_relative and smb.cmd==0x2e and smb.flags.response==1
1078                 Column #2: MIN(smb.time)smb.time and smb.cmd==0x2e
1079                 Column #3: MAX(smb.time)smb.time and smb.cmd==0x2e
1080                 Column #4: AVG(smb.time)smb.time and smb.cmd==0x2e
1081                                 |    Column #0   |    Column #1   |    Column #2   |    Column #3   |    Column #4   |
1082                 Time            |       MIN      |       MAX      |       MIN      |       MAX      |       AVG      |
1083                 000.000-                 0.000000         7.704054         0.000072         0.005539         0.000295
1084                 ======================================================================================================
1085
1086               The following command displays the average SMB Read response
1087               PDU size, the total number of read PDU bytes, the average SMB
1088               Write request PDU size, and the total number of bytes
1089               transferred in SMB Write PDUs:
1090
1091                 tshark -n -q -r smb_reads_writes.cap -z io,stat,0,
1092                 "AVG(smb.file.rw.length)smb.file.rw.length and smb.cmd==0x2e and smb.response_to",
1093                 "SUM(smb.file.rw.length)smb.file.rw.length and smb.cmd==0x2e and smb.response_to",
1094                 "AVG(smb.file.rw.length)smb.file.rw.length and smb.cmd==0x2f and not smb.response_to",
1095                 "SUM(smb.file.rw.length)smb.file.rw.length and smb.cmd==0x2f and not smb.response_to"
1096
1097                 =====================================================================================
1098                 IO Statistics
1099                 Column #0: AVG(smb.file.rw.length)smb.file.rw.length and smb.cmd==0x2e and smb.response_to
1100                 Column #1: SUM(smb.file.rw.length)smb.file.rw.length and smb.cmd==0x2e and smb.response_to
1101                 Column #2: AVG(smb.file.rw.length)smb.file.rw.length and smb.cmd==0x2f and not smb.response_to
1102                 Column #3: SUM(smb.file.rw.length)smb.file.rw.length and smb.cmd==0x2f and not smb.response_to
1103                                 |    Column #0   |    Column #1   |    Column #2   |    Column #3   |
1104                 Time            |       AVG      |       SUM      |       AVG      |       SUM      |
1105                 000.000-                    30018         28067522               72             3240
1106                 =====================================================================================
1107
1108               LOAD(field)field [and filter] - The LOAD/Queue-Depth in each
1109               interval is calculated.  The specified field must be a relative
1110               time field that represents a response time.  For example
1111               smb.time.  For each interval the Queue-Depth for the specified
1112               protocol is calculated.
1113
1114               The following command displays the average SMB LOAD.  A value
1115               of 1.0 represents one I/O in flight.
1116
1117                 tshark -n -q -r smb_reads_writes.cap
1118                 -z "io,stat,0.001,LOAD(smb.time)smb.time"
1119
1120                 ============================================================================
1121                 IO Statistics
1122                 Interval:   0.001000 secs
1123                 Column #0: LOAD(smb.time)smb.time
1124                                         |    Column #0   |
1125                 Time                    |       LOAD     |
1126                 0000.000000-0000.001000         1.000000
1127                 0000.001000-0000.002000         0.741000
1128                 0000.002000-0000.003000         0.000000
1129                 0000.003000-0000.004000         1.000000
1130
1131               FRAMES | BYTES[()filter] - Displays the total number of frames
1132               or bytes.  The filter field is optional but if included it must
1133               be prepended with ''()''.
1134
1135               The following command displays five columns: the total number
1136               of frames and bytes (transferred bidirectionally) using a
1137               single comma, the same two stats using the FRAMES and BYTES
1138               subcommands, the total number of frames containing at least one
1139               SMB Read response, and the total number of bytes transmitted to
1140               the client (unidirectionally) at IP address 10.1.0.64.
1141
1142                 tshark -o tcp.desegment_tcp_streams:FALSE -n -q -r smb_reads.cap -z io,stat,0,,FRAMES,BYTES,
1143                 "FRAMES()smb.cmd==0x2e and smb.response_to","BYTES()ip.dst==10.1.0.64"
1144
1145                 =======================================================================================================================
1146                 IO Statistics
1147                 Column #0:
1148                 Column #1: FRAMES
1149                 Column #2: BYTES
1150                 Column #3: FRAMES()smb.cmd==0x2e and smb.response_to
1151                 Column #4: BYTES()ip.dst==10.1.0.64
1152                                 |            Column #0            |    Column #1   |    Column #2   |    Column #3   |    Column #4   |
1153                 Time            |     Frames     |      Bytes     |     FRAMES     |     BYTES      |     FRAMES     |     BYTES      |
1154                 000.000-                    33576         29721685            33576         29721685              870         29004801
1155                 =======================================================================================================================
1156
1157           -z mac-lte,stat[,filter]
1158               This option will activate a counter for LTE MAC messages.  You
1159               will get information about the maximum number of UEs/TTI,
1160               common messages and various counters for each UE that appears
1161               in the log.
1162
1163               Example: -z mac-lte,stat.
1164
1165               This option can be used multiple times on the command line.
1166
1167               If the optional filter is provided, the stats will only be
1168               calculated for those frames that match that filter.  Example:
1169               -z "mac-lte,stat,mac-lte.rnti3000"> will only collect stats for
1170               UEs with an assigned RNTI whose value is more than 3000.
1171
1172           -z megaco,rtd[,filter]
1173               Collect requests/response RTD (Response Time Delay) data for
1174               MEGACO.  (This is similar to -z smb,srt).  Data collected is
1175               the number of calls for each known MEGACO Type, MinRTD, MaxRTD
1176               and AvgRTD.  Additionally you get the number of duplicate
1177               requests/responses, unresponded requests, responses, which
1178               don't match with any request.  Example: -z megaco,rtd.
1179
1180               If the optional filter is provided, the stats will only be
1181               calculated on those calls that match that filter.  Example: -z
1182               "megaco,rtd,ip.addr==1.2.3.4" will only collect stats for
1183               MEGACO packets exchanged by the host at IP address 1.2.3.4 .
1184
1185               This option can be used multiple times on the command line.
1186
1187           -z mgcp,rtd[,filter]
1188               Collect requests/response RTD (Response Time Delay) data for
1189               MGCP.  (This is similar to -z smb,srt).  Data collected is the
1190               number of calls for each known MGCP Type, MinRTD, MaxRTD and
1191               AvgRTD.  Additionally you get the number of duplicate
1192               requests/responses, unresponded requests, responses, which
1193               don't match with any request.  Example: -z mgcp,rtd.
1194
1195               This option can be used multiple times on the command line.
1196
1197               If the optional filter is provided, the stats will only be
1198               calculated on those calls that match that filter.  Example: -z
1199               "mgcp,rtd,ip.addr==1.2.3.4" will only collect stats for MGCP
1200               packets exchanged by the host at IP address 1.2.3.4 .
1201
1202           -z proto,colinfo,filter,field
1203               Append all field values for the packet to the Info column of
1204               the one-line summary output.  This feature can be used to
1205               append arbitrary fields to the Info column in addition to the
1206               normal content of that column.  field is the display-filter
1207               name of a field which value should be placed in the Info
1208               column.  filter is a filter string that controls for which
1209               packets the field value will be presented in the info column.
1210               field will only be presented in the Info column for the packets
1211               which match filter.
1212
1213               NOTE: In order for TShark to be able to extract the field value
1214               from the packet, field MUST be part of the filter string.  If
1215               not, TShark will not be able to extract its value.
1216
1217               For a simple example to add the "nfs.fh.hash" field to the Info
1218               column for all packets containing the "nfs.fh.hash" field, use
1219
1220               -z proto,colinfo,nfs.fh.hash,nfs.fh.hash
1221
1222               To put "nfs.fh.hash" in the Info column but only for packets
1223               coming from host 1.2.3.4 use:
1224
1225               -z "proto,colinfo,nfs.fh.hash && ip.src==1.2.3.4,nfs.fh.hash"
1226
1227               This option can be used multiple times on the command line.
1228
1229           -z rlc-lte,stat[,filter]
1230               This option will activate a counter for LTE RLC messages.  You
1231               will get information about common messages and various counters
1232               for each UE that appears in the log.
1233
1234               Example: -z rlc-lte,stat.
1235
1236               This option can be used multiple times on the command line.
1237
1238               If the optional filter is provided, the stats will only be
1239               calculated for those frames that match that filter.  Example:
1240               -z "rlc-lte,stat,rlc-lte.ueid3000"> will only collect stats for
1241               UEs with a UEId of more than 3000.
1242
1243           -z rpc,programs
1244               Collect call/reply SRT data for all known ONC-RPC
1245               programs/versions.  Data collected is number of calls for each
1246               protocol/version, MinSRT, MaxSRT and AvgSRT.  This option can
1247               only be used once on the command line.
1248
1249           -z rpc,srt,program,version[,filter]
1250               Collect call/reply SRT (Service Response Time) data for
1251               program/version.  Data collected is number of calls for each
1252               procedure, MinSRT, MaxSRT and AvgSRT.
1253
1254               Example: -z rpc,srt,100003,3 will collect data for NFS v3.
1255
1256               This option can be used multiple times on the command line.
1257
1258               If the optional filter is provided, the stats will only be
1259               calculated on those calls that match that filter.
1260
1261               Example: -z rpc,srt,100003,3,nfs.fh.hash==0x12345678 will
1262               collect NFS v3 SRT statistics for a specific file.
1263
1264           -z rtp,streams
1265               Collect statistics for all RTP streams and calculate max.
1266               delta, max. and mean jitter and packet loss percentages.
1267
1268           -z scsi,srt,cmdset[,filter]
1269               Collect call/reply SRT (Service Response Time) data for SCSI
1270               commandset cmdset.
1271
1272               Commandsets are 0:SBC   1:SSC  5:MMC
1273
1274               Data collected is the number of calls for each procedure,
1275               MinSRT, MaxSRT and AvgSRT.
1276
1277               Example: -z scsi,srt,0 will collect data for SCSI BLOCK
1278               COMMANDS (SBC).
1279
1280               This option can be used multiple times on the command line.
1281
1282               If the optional filter is provided, the stats will only be
1283               calculated on those calls that match that filter.
1284
1285               Example: -z scsi,srt,0,ip.addr==1.2.3.4 will collect SCSI SBC
1286               SRT statistics for a specific iscsi/ifcp/fcip host.
1287
1288           -z sip,stat[,filter]
1289               This option will activate a counter for SIP messages.  You will
1290               get the number of occurrences of each SIP Method and of each
1291               SIP Status-Code.  Additionally you also get the number of
1292               resent SIP Messages (only for SIP over UDP).
1293
1294               Example: -z sip,stat.
1295
1296               This option can be used multiple times on the command line.
1297
1298               If the optional filter is provided, the stats will only be
1299               calculated on those calls that match that filter.  Example: -z
1300               "sip,stat,ip.addr==1.2.3.4" will only collect stats for SIP
1301               packets exchanged by the host at IP address 1.2.3.4 .
1302
1303           -z smb,sids
1304               When this feature is used TShark will print a report with all
1305               the discovered SID and account name mappings.  Only those SIDs
1306               where the account name is known will be presented in the table.
1307
1308               For this feature to work you will need to either to enable
1309               "Edit/Preferences/Protocols/SMB/Snoop SID to name mappings" in
1310               the preferences or you can override the preferences by
1311               specifying -o "smb.sid_name_snooping:TRUE" on the TShark
1312               command line.
1313
1314               The current method used by TShark to find the SID->name mapping
1315               is relatively restricted with a hope of future expansion.
1316
1317           -z smb,srt[,filter]
1318               Collect call/reply SRT (Service Response Time) data for SMB.
1319               Data collected is number of calls for each SMB command, MinSRT,
1320               MaxSRT and AvgSRT.
1321
1322               Example: -z smb,srt
1323
1324               The data will be presented as separate tables for all normal
1325               SMB commands, all Transaction2 commands and all NT Transaction
1326               commands.  Only those commands that are seen in the capture
1327               will have its stats displayed.  Only the first command in a
1328               xAndX command chain will be used in the calculation.  So for
1329               common SessionSetupAndX + TreeConnectAndX chains, only the
1330               SessionSetupAndX call will be used in the statistics.  This is
1331               a flaw that might be fixed in the future.
1332
1333               This option can be used multiple times on the command line.
1334
1335               If the optional filter is provided, the stats will only be
1336               calculated on those calls that match that filter.
1337
1338               Example: -z "smb,srt,ip.addr==1.2.3.4" will only collect stats
1339               for SMB packets exchanged by the host at IP address 1.2.3.4 .
1340

CAPTURE FILTER SYNTAX

1342       See the manual page of pcap-filter(7) or, if that doesn't exist,
1343       tcpdump(8), or, if that doesn't exist,
1344       <http://wiki.wireshark.org/CaptureFilters>.
1345

READ FILTER SYNTAX

1347       For a complete table of protocol and protocol fields that are
1348       filterable in TShark see the wireshark-filter(4) manual page.
1349

FILES

1351       These files contains various Wireshark configuration values.
1352
1353       Preferences
1354           The preferences files contain global (system-wide) and personal
1355           preference settings.  If the system-wide preference file exists, it
1356           is read first, overriding the default settings.  If the personal
1357           preferences file exists, it is read next, overriding any previous
1358           values.  Note: If the command line option -o is used (possibly more
1359           than once), it will in turn override values from the preferences
1360           files.
1361
1362           The preferences settings are in the form prefname:value, one per
1363           line, where prefname is the name of the preference and value is the
1364           value to which it should be set; white space is allowed between :
1365           and value.  A preference setting can be continued on subsequent
1366           lines by indenting the continuation lines with white space.  A #
1367           character starts a comment that runs to the end of the line:
1368
1369             # Capture in promiscuous mode?
1370             # TRUE or FALSE (case-insensitive).
1371             capture.prom_mode: TRUE
1372
1373           The global preferences file is looked for in the wireshark
1374           directory under the share subdirectory of the main installation
1375           directory (for example, /usr/local/share/wireshark/preferences) on
1376           UNIX-compatible systems, and in the main installation directory
1377           (for example, C:\Program Files\Wireshark\preferences) on Windows
1378           systems.
1379
1380           The personal preferences file is looked for in
1381           $HOME/.wireshark/preferences on UNIX-compatible systems and
1382           %APPDATA%\Wireshark\preferences (or, if %APPDATA% isn't defined,
1383           %USERPROFILE%\Application Data\Wireshark\preferences) on Windows
1384           systems.
1385
1386       Disabled (Enabled) Protocols
1387           The disabled_protos files contain system-wide and personal lists of
1388           protocols that have been disabled, so that their dissectors are
1389           never called.  The files contain protocol names, one per line,
1390           where the protocol name is the same name that would be used in a
1391           display filter for the protocol:
1392
1393             http
1394             tcp     # a comment
1395
1396           The global disabled_protos file uses the same directory as the
1397           global preferences file.
1398
1399           The personal disabled_protos file uses the same directory as the
1400           personal preferences file.
1401
1402       Name Resolution (hosts)
1403           If the personal hosts file exists, it is used to resolve IPv4 and
1404           IPv6 addresses before any other attempts are made to resolve them.
1405           The file has the standard hosts file syntax; each line contains one
1406           IP address and name, separated by whitespace.  The same directory
1407           as for the personal preferences file is used.
1408
1409           Capture filter name resolution is handled by libpcap on UNIX-
1410           compatible systems and WinPcap on Windows.  As such the Wireshark
1411           personal hosts file will not be consulted for capture filter name
1412           resolution.
1413
1414       Name Resolution (ethers)
1415           The ethers files are consulted to correlate 6-byte hardware
1416           addresses to names.  First the personal ethers file is tried and if
1417           an address is not found there the global ethers file is tried next.
1418
1419           Each line contains one hardware address and name, separated by
1420           whitespace.  The digits of the hardware address are separated by
1421           colons (:), dashes (-) or periods (.).  The same separator
1422           character must be used consistently in an address.  The following
1423           three lines are valid lines of an ethers file:
1424
1425             ff:ff:ff:ff:ff:ff          Broadcast
1426             c0-00-ff-ff-ff-ff          TR_broadcast
1427             00.00.00.00.00.00          Zero_broadcast
1428
1429           The global ethers file is looked for in the /etc directory on UNIX-
1430           compatible systems, and in the main installation directory (for
1431           example, C:\Program Files\Wireshark) on Windows systems.
1432
1433           The personal ethers file is looked for in the same directory as the
1434           personal preferences file.
1435
1436           Capture filter name resolution is handled by libpcap on UNIX-
1437           compatible systems and WinPcap on Windows.  As such the Wireshark
1438           personal ethers file will not be consulted for capture filter name
1439           resolution.
1440
1441       Name Resolution (manuf)
1442           The manuf file is used to match the 3-byte vendor portion of a
1443           6-byte hardware address with the manufacturer's name; it can also
1444           contain well-known MAC addresses and address ranges specified with
1445           a netmask.  The format of the file is the same as the ethers files,
1446           except that entries of the form:
1447
1448             00:00:0C      Cisco
1449
1450           can be provided, with the 3-byte OUI and the name for a vendor, and
1451           entries such as:
1452
1453             00-00-0C-07-AC/40     All-HSRP-routers
1454
1455           can be specified, with a MAC address and a mask indicating how many
1456           bits of the address must match.  The above entry, for example, has
1457           40 significant bits, or 5 bytes, and would match addresses from
1458           00-00-0C-07-AC-00 through 00-00-0C-07-AC-FF.  The mask need not be
1459           a multiple of 8.
1460
1461           The manuf file is looked for in the same directory as the global
1462           preferences file.
1463
1464       Name Resolution (ipxnets)
1465           The ipxnets files are used to correlate 4-byte IPX network numbers
1466           to names.  First the global ipxnets file is tried and if that
1467           address is not found there the personal one is tried next.
1468
1469           The format is the same as the ethers file, except that each address
1470           is four bytes instead of six.  Additionally, the address can be
1471           represented as a single hexadecimal number, as is more common in
1472           the IPX world, rather than four hex octets.  For example, these
1473           four lines are valid lines of an ipxnets file:
1474
1475             C0.A8.2C.00              HR
1476             c0-a8-1c-00              CEO
1477             00:00:BE:EF              IT_Server1
1478             110f                     FileServer3
1479
1480           The global ipxnets file is looked for in the /etc directory on
1481           UNIX-compatible systems, and in the main installation directory
1482           (for example, C:\Program Files\Wireshark) on Windows systems.
1483
1484           The personal ipxnets file is looked for in the same directory as
1485           the personal preferences file.
1486

ENVIRONMENT VARIABLES

1488       WIRESHARK_DEBUG_EP_NO_CHUNKS
1489           Normally per-packet memory is allocated in large "chunks."  This
1490           behavior doesn't work well with debugging tools such as Valgrind or
1491           ElectricFence.  Export this environment variable to force
1492           individual allocations.  Note: disabling chunks also disables
1493           canaries (see below).
1494
1495       WIRESHARK_DEBUG_SE_NO_CHUNKS
1496           Normally per-file memory is allocated in large "chunks."  This
1497           behavior doesn't work well with debugging tools such as Valgrind or
1498           ElectricFence.  Export this environment variable to force
1499           individual allocations.  Note: disabling chunks also disables
1500           canaries (see below).
1501
1502       WIRESHARK_DEBUG_EP_NO_CANARY
1503           Normally per-packet memory allocations are separated by "canaries"
1504           which allow detection of memory overruns.  This comes at the
1505           expense of some extra memory usage.  Exporting this environment
1506           variable disables these canaries.
1507
1508       WIRESHARK_DEBUG_SE_USE_CANARY
1509           Exporting this environment variable causes per-file memory
1510           allocations to be protected with "canaries" which allow for
1511           detection of memory overruns.  This comes at the expense of
1512           significant extra memory usage.
1513
1514       WIRESHARK_DEBUG_SCRUB_MEMORY
1515           If this environment variable is set, the contents of per-packet and
1516           per-file memory is initialized to 0xBADDCAFE when the memory is
1517           allocated and is reset to 0xDEADBEEF when the memory is freed.
1518           This functionality is useful mainly to developers looking for bugs
1519           in the way memory is handled.
1520
1521       WIRESHARK_DEBUG_WMEM_OVERRIDE
1522           Setting this environment variable forces the wmem framework to use
1523           the specified allocator backend for *all* allocations, regardless
1524           of which backend is normally specified by the code. This is mainly
1525           useful to developers when testing or debugging. See README.wmem in
1526           the source distribution for details.
1527
1528       WIRESHARK_RUN_FROM_BUILD_DIRECTORY
1529           This environment variable causes the plugins and other data files
1530           to be loaded from the build directory (where the program was
1531           compiled) rather than from the standard locations.  It has no
1532           effect when the program in question is running with root (or
1533           setuid) permissions on *NIX.
1534
1535       WIRESHARK_DATA_DIR
1536           This environment variable causes the various data files to be
1537           loaded from a directory other than the standard locations.  It has
1538           no effect when the program in question is running with root (or
1539           setuid) permissions on *NIX.
1540
1541       WIRESHARK_PYTHON_DIR
1542           This environment variable points to an alternate location for
1543           Python.  It has no effect when the program in question is running
1544           with root (or setuid) permissions on *NIX.
1545
1546       ERF_RECORDS_TO_CHECK
1547           This environment variable controls the number of ERF records
1548           checked when deciding if a file really is in the ERF format.
1549           Setting this environment variable a number higher than the default
1550           (20) would make false positives less likely.
1551
1552       IPFIX_RECORDS_TO_CHECK
1553           This environment variable controls the number of IPFIX records
1554           checked when deciding if a file really is in the IPFIX format.
1555           Setting this environment variable a number higher than the default
1556           (20) would make false positives less likely.
1557
1558       WIRESHARK_ABORT_ON_DISSECTOR_BUG
1559           If this environment variable is set, TShark will call abort(3) when
1560           a dissector bug is encountered.  abort(3) will cause the program to
1561           exit abnormally; if you are running TShark in a debugger, it should
1562           halt in the debugger and allow inspection of the process, and, if
1563           you are not running it in a debugger, it will, on some OSes,
1564           assuming your environment is configured correctly, generate a core
1565           dump file.  This can be useful to developers attempting to
1566           troubleshoot a problem with a protocol dissector.
1567
1568       WIRESHARK_EP_VERIFY_POINTERS
1569           This environment variable, if present, causes certain uses of
1570           pointers to be audited to ensure they do not point to memory that
1571           is deallocated after each packet has been fully dissected.  This
1572           can be useful to developers writing or auditing code.
1573
1574       WIRESHARK_SE_VERIFY_POINTERS
1575           This environment variable, if present, causes certain uses of
1576           pointers to be audited to ensure they do not point to memory that
1577           is deallocated after when a capture file is closed.  This can be
1578           useful to developers writing or auditing code.
1579
1580       WIRESHARK_ABORT_ON_OUT_OF_MEMORY
1581           This environment variable, if present, causes abort(3) to be called
1582           if certain out-of-memory conditions (which normally result in an
1583           exception and an explanatory error message) are experienced.  This
1584           can be useful to developers debugging out-of-memory conditions.
1585

SEE ALSO

1587       wireshark-filter(4), wireshark(1), editcap(1), pcap(3), dumpcap(1),
1588       text2pcap(1), mergecap(1), pcap-filter(7) or tcpdump(8)
1589

NOTES

1591       TShark is part of the Wireshark distribution.  The latest version of
1592       Wireshark can be found at <http://www.wireshark.org>.
1593
1594       HTML versions of the Wireshark project man pages are available at:
1595       <http://www.wireshark.org/docs/man-pages>.
1596

AUTHORS

1598       TShark uses the same packet dissection code that Wireshark does, as
1599       well as using many other modules from Wireshark; see the list of
1600       authors in the Wireshark man page for a list of authors of that code.
1601
1602
1603
16041.10.14                           2018-10-30                         TSHARK(1)
Impressum