Commit Graph

2326 Commits

Author SHA1 Message Date
Jaap Keuter 34ab3f308a sshdump: add option to select dumpcap as remote capture command 2022-08-10 17:26:49 +00:00
Gerald Combs 95069d8f78 Docs: Clean up some Python references.
Make sure we captitalize Python and use its HTTPS URL.
2022-08-08 16:34:45 +00:00
João Valverde 80f16015e2 epan: Refactor floating point display types
Remove the redundant BASE_FLOAT field display type. The name
BASE_FLOAT is meaningless and the value aliased to BASE_NONE.

Require BASE_NONE instead of BASE_FLOAT (corresponding to
the printf() %g format).

Add new float display types using BASE_DEC, BASE_HEX and BASE_EXP
corresponfing to %f, %a and %e respectively.

Add support for BASE_CUSTOM with floats.
2022-08-02 13:16:46 +00:00
Gerald Combs e2b0140edb Docs: extcap man page fixups. 2022-07-31 08:43:37 +00:00
Gerald Combs 6857e1ed04 Docs: Fix our man page dependencies.
Dependencies need to be set via add_custom_command.
2022-07-29 18:52:07 +00:00
Stig Bjørlykke f7a5efe87b doc: Update README.display_filter
Update fvalue_t definition in README.display_filter.
2022-07-26 12:08:57 +02:00
Gerald Combs a1c83a901b docbook: Port make-wsluarm to Python3
Port the script that creates docbook/wsluarm_src/*.adoc to Python3.
Ping #18152.
2022-07-23 20:51:24 +00:00
Jirka Novak 1e53e49a54 ciscodump: Added support for IOS XE and ASA
Changes:
- The tool now recognizes which software is running on a device - IOS, IOS XE
  or ASA. Based on it, it uses correct sequence of commands to setup
  capture, read captured packets and clear the capture.
- The tool reads packets on the fly so you don't have to wait till
  --remote-count of packets is reached.
- The tool reads timestamps from capture on the device for IOS and ASA (on
  IOS-XE, there is no timestamp in dump).
- Except Windows platform the tool handles early stop of capture on the device
  and clear of capture buffer on the device (it finish the capture).
- There are special interface names to allow the tool to generate
  specific capture types.
- Documentation updated.

Closes #17672.
2022-07-22 15:55:28 +00:00
Roland Knall 64549654db ExtcapExample: Harden and alternate mac address
Harden the code a little and alternate the mac address to allow
the code to be used for testing conversation and endpoint dialog.

Also transmit integer values not as ascii representations and include
a data packet that allows for reassembly to be tested
2022-07-13 18:40:57 +00:00
Martin Mathieson eab62aa768 Fix some spellings. 2022-07-06 09:02:37 +01:00
Gerald Combs eaae2d0ee7 Minor Python3 script fixups.
Make some scripts executable and use the shebang line recommended at
https://docs.python.org/3/using/unix.html#miscellaneous
2022-06-27 16:46:55 +00:00
Gerald Combs 4153af1dc7 wslua: Port make-init-lua to Python3
Port the script that creates init.lua to Python3. The generated init.lua
removes one newline and adds another, otherwise the output is identical
to the Perl version.
Ping #18152.
2022-06-27 16:28:36 +00:00
Gerald Combs ae3010cabe wslua: Port make-taps to Python3
Port the script that creates taps_wslua.c and taps.txt to Python3. The
generated taps_wslua.c has one less newline, otherwise the output is
identical to the Perl version. Make the "taps" configuration file an
ConfigParser / .ini file.
Ping #18152.
2022-06-27 16:11:34 +00:00
João Valverde e9e6431d7b dfilter: Change boolean string representation
Use "True" or "TRUE" instead of "true" and remove case insensivity.
Same for false. This should serve to differentiate booleans a bit
more from protocol names, which should be using lower-case.
2022-06-25 13:02:34 +01:00
Gerald Combs d3e2f1053b Doc: Port make-authors-short to Python3.
Port the script that creates AUTHORS-SHORT to Python3.
Ping #18152.
2022-06-24 18:32:50 +00:00
Moshe Kaplan 26f87b3250 wslua: Port epan/wslua/make-reg.py to Python3
Port the script that creates
declare_wslua.h and register_wslua.c
to Python3.
Ping #18152.
2022-06-24 15:02:38 +00:00
Gerald Combs 3b0d9194bc Docs: Update the ftype description list in wireshark-filter(4).
Update a couple of ftype descriptions and update the list in the
wireshark-filter man page.
2022-06-21 14:33:45 -07:00
João Valverde fe25d701ba Docs: Updates to wireshark-filter manpage 2022-06-21 16:56:06 +01:00
João Valverde e11c7559a8 plugins.example: Fix an installation path 2022-06-17 16:35:20 +01:00
Chuck Craft d008708552 editcap/mergecap: swap 'v'|'V' options to match other CLI utilities
Closes #18134
2022-06-16 02:13:50 +00:00
Chuck Craft f82ddef8d2 tshark/docs: add -X read_format: example to view file internals 2022-06-12 16:30:35 +00:00
João Valverde 3e543bb0af Docs: Update README.dissector for string encodings 2022-06-09 20:52:24 +01:00
Gerald Combs 8fa64a4773 Docs: Note that display filter layer numbers start at 1. 2022-06-08 17:21:58 +00:00
João Valverde 4015522162 Docs: Another display filter regex update 2022-06-08 16:40:09 +00:00
João Valverde bd0f0cbbed Docs: Update display filter manual page to PCRE2 2022-06-08 12:12:25 +01:00
John Thacker 06871d27df wiretap: merge support for IDBs in the middle of a file
Support merging files with IDBs in the middle of the file.
Use wtap_get_next_interface_description when doing the initial
list of interfaces so that we can correctly get IDBs later.

Note that while IDB merge modes "any" and "none" work as expected, the
default "all" mode can't really work for IDBs in the middle of the file
without adding a two-pass mode. In "all" mode, if there are any such IDBs,
merge them with duplicates iff the interfaces at the beginning of the
files were merged.

Related to #15502 and #16542.
2022-06-02 12:51:52 +00:00
Gerald Combs be929e162d epan: Allow conversations based on arbitrary element lists.
Add conversation_new_full and find_conversation_full, which take
arbitrary element lists instead of fixed addresses and ports.

Update the comments in conversation.h to be more Doxygen-conformant.
Update README.dissector.

Use the new functionality to add initial conversation support to the
Falco Bridge dissector.
2022-05-23 18:12:26 +00:00
Chuck Craft 609c0d3881 docs: adoc migration bolding typos; Windows pipe name syntax 2022-05-12 16:43:44 +00:00
John Thacker 2e5a78dc64 text2pcap: Switch default file format to pcapng
For the upcoming 4.0 release, switch the default file format for
text2pcap to pcapng from pcap, to match other tools and the GUI
behavior. Update the documentation and release notes appropriately.

Deprecate the old -n flag; since pcapng is the default this has no
effect. Changing the output capture file format is supported with
the -F option, consistent with the other command line tools.

Related to #18009.
2022-05-12 16:20:40 +00:00
João Valverde b602911b31 dfilter: Add support for universal quantifiers
Adds the keywords "any" and "all" to implement the quantification
to any existing relational operator.

Filter: all tcp.port in {100, 2000..3000}

Syntax tree:
 0 ALL TEST_IN:
   1 FIELD(tcp.port)
   1 SET(#2):
     2 FVALUE(100 <FT_UINT16>)
     2 FVALUE(2000 <FT_UINT16>) .. FVALUE(3000 <FT_UINT16>)

Instructions:
00000 READ_TREE		tcp.port -> reg#0
00001 IF_FALSE_GOTO	5
00002 ALL_EQ		reg#0 === 100 <FT_UINT16>
00003 IF_TRUE_GOTO	5
00004 ALL_IN_RANGE	reg#0 in { 2000 <FT_UINT16> .. 3000 <FT_UINT16> }
00005 RETURN
2022-05-12 14:26:54 +01:00
Odysseus Yang 36e834b6b7 ETW: Extract IP packets from Windows event trace
With this change, Wireshark will be enhanced to display IP packets from an event trace logfile
or an event trace live session.
2022-05-05 13:35:47 +00:00
John Thacker 536c685ea5 docs: Update reference to minimum versions of GLib and Qt 2022-04-28 23:12:24 -04:00
Roland Knall f595f3b6ad sshdump: Update doc for openssh key note
Add a note, that the key value pair format has to be openssh format

Fixes #18063
2022-04-28 19:59:07 +02:00
João Valverde 4f3f507eee dfilter: Add syntax to match specific layers in the protocol stack
Add support to display filters for matching a specific layer within a frame.
Layers are counted sequentially up the protocol stack. Each protocol
(dissector) that appears in the stack is one layer.

LINK-LAYER#1 <-> IP#1 <-> TCP#1 <-> IP#2 <-> TCP#2 <-> etc.

The syntax allows for negative indexes and ranges with the usual semantics
for slices (but note that counting starts at one):

    tcp.port#[2-4] == 1024

Matches layers 2 to 4 inclusive.

Fixes #3791.
2022-04-26 16:50:59 +00:00
João Valverde eb2a9889c3 dfilter: Add abs() function
Add an absolute value function for ftypes.
2022-04-18 17:09:00 +01:00
Chuck Craft 4e0cd3dbd2 epan: add ENC_TIME_USECS timestamp encoding
Needed to format timestamp in #18038 - packet-cql.c
Mirrors changes made in !1924 - Add ENC_TIME_NSECS timestamp encoding
Documentation in README.dissector, proto.c, proto.h - could use
refresh in a different merge request.
2022-04-14 15:18:30 +00:00
João Valverde cef02cc3a0 dfilter: Add max()/min() tests and documentation 2022-04-14 13:07:41 +00:00
Chuck Craft 55f7b27b35 tshark.adoc: update -z conv/endpoints descriptions 2022-04-13 12:58:14 +00:00
Moshe Kaplan 1e352c3e7b manpage: Fix grammar errors and improve phrasing
Quickly review of fixing common grammatical errors in
the man pages.
2022-04-13 03:39:56 +00:00
João Valverde fb9a176587 dfilter: Allow grouping arithmetical expressions with { }
This removes the limitation of having only two terms in an
arithmetic expression and allows setting the precedence using
curly braces (like any basic calculator).

Our grammar currently does not allow grouping arithmetic expressions
using parenthesis, because boolean expressions and arithmetic
expressions are different and parenthesis are used with the former.
2022-04-08 23:12:04 +01:00
Chuck Craft b52437ba28 WSUG/tshark: protocol summary and output with "-e" 2022-04-08 19:40:43 +00:00
John Thacker f0f0f05060 editcap: Document use of stdin and stdout
Editcap accepts '-' for stdin or stdout, document that. Also change
an incorrect statement that claims that the '-v' flag writes to
standard output; it writes to standard error.
2022-04-07 20:57:08 -04:00
João Valverde 34ad6bb478 dfilter: Make logical AND higher precedence than logical OR
In most, if not all, programming languages logical AND has
higher precedence than logical OR. Apply the principle of
least surprise and do the same for Wireshark display
filters.

Before: ip and tcp or udp => ip and (tcp or udp)

    Filter: ip and tcp or udp

    Instructions:
    00000 CHECK_EXISTS	ip
    00001 IF_FALSE_GOTO	5
    00002 CHECK_EXISTS	tcp
    00003 IF_TRUE_GOTO	5
    00004 CHECK_EXISTS	udp
    00005 RETURN

After: ip and tcp or udp => (ip and tcp) or udp

    Filter: ip and tcp or udp

    Instructions:
    00000 CHECK_EXISTS	ip
    00001 IF_FALSE_GOTO	4
    00002 CHECK_EXISTS	tcp
    00003 IF_TRUE_GOTO	5
    00004 CHECK_EXISTS	udp
    00005 RETURN
2022-04-04 19:51:38 +00:00
João Valverde 7b4ec1bd88 Docs: Add new display filter syntax to the manpage. 2022-04-01 07:22:22 +01:00
João Valverde 8df570294f plugins.example: Add some comments 2022-03-28 13:23:28 +00:00
João Valverde e3765215aa plugins.example: Add package target
Basic package target to create a .zip or tar.gz of the plugin
and README file.
2022-03-28 13:23:28 +00:00
João Valverde c451e572e5 plugins.example: Make installation relocatable
Fixes "make install" to be relocatable using DESTDIR. For that
we cannot use an absolute path as intallation directory target.
This is useful mostly to implement packaging using CPack.

It is a bit awkward to configure a default CMAKE_INSTALL_PREFIX
using WiresharkConfig.cmake but it seems to be working OK.

The previous non-relocatable behaviour may still be useful. It is
relegated to a custom "copy_plugin" target.
2022-03-28 13:23:28 +00:00
João Valverde 80eff54e83 Plugins.example: Fix typo and more rewording 2022-03-26 00:57:42 +00:00
João Valverde 16729be2c1 dfilter: Add bitwise masking of bits
Add support for masking of bits. Before the bitwise operator
could only test bits, it did not support clearing bits.

This allows testing if any combination of bits are set/unset
more naturally with a single test. Previously this was only
possible by combining several bitwise predicates.

Bitwise is implemented as a test node, even though it is not.
Maybe the test node should be renamed to something else.

Fixes #17246.
2022-03-22 12:58:04 +00:00
Gerald Combs 1e39a66746 etwdump: Clarify "ETW".
Not everyone knows what ETW is.
2022-03-21 15:35:48 -07:00