Commit Graph

84129 Commits

Author SHA1 Message Date
Dylan Ulis df5941d467 debian: add ccache to additional_list packages 2022-04-02 17:39:08 +00:00
Jiří Engelthaler 248f11dd1b Qt: Fix interface statistics update if some interfaces are hidden
Closes issue #18023
2022-04-02 16:43:15 +00:00
Martin Mathieson 6065552dd4 Skinny: revert previous change 2022-04-02 15:05:40 +00:00
John Thacker 6dfd96f6fe rdp: Register RDP as a TLS subdissector for port 3389 directly
ssl_dissector_add registers TLS as the dissector for TCP for the given
port. We can't use it, since on port 3389 TPKT (for RDP) can be over TLS
or directly over TCP, depending on the RDP security settings.
Fix #17952.
2022-04-02 07:47:07 -04:00
Martin Mathieson cf629e2547 ZBNCP: Fix some filter names. 2022-04-02 11:21:14 +00:00
Dylan Ulis 436abf4cf7 CIP: Show Attribute ID as decimal 2022-04-01 20:01:53 +00:00
Nan Xiao 1997a86634 EVS: Refactor dissecting compact format code 2022-04-01 19:32:34 +00:00
João Valverde 67e5e5c3ab dfilter: Fix arithmetic expressions on the LHS
Filter: _ws.ftypes.framenum % 3 == 0

Instructions:
00000 READ_TREE		_ws.ftypes.framenum -> reg#0
00001 IF_FALSE_GOTO	4
00002 MODULO		reg#0 % 3 <FT_FRAMENUM> -> reg#1
00003 ANY_EQ		reg#1 == 0 <FT_FRAMENUM>
00004 RETURN
2022-04-01 14:33:38 +01:00
John Thacker 856cd96bb3 http2: Use the actual maximum table size for partial header workaround
Use the actual maximum table table size, which may have been set to
a value other than the default 4096, to fill the table with dummy
entries. Fix #17936
2022-04-01 12:10:48 +00:00
Stig Bjørlykke e6202cf1d9 coap: Format text used in COL_INFO
Use format_text_wsp() on strings from packet used in COL_INFO to
show non-printable characters as C-style escapes.
2022-04-01 12:42:58 +02:00
Dylan Ulis f23a774819 CIP: Correct DATE type handling 2022-04-01 07:13:56 +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 15cc673c8e Fix release notes 2022-03-31 23:56:33 +01:00
João Valverde a81617fda5 Fix build on CentOS 7
CentOS 7 has an old version of GCC that lacks support for C11
macro generics.
2022-03-31 19:48:48 +00:00
Jirka Novak 8b737033b0 RTP Analysis dialog: Update statistics when data are processed
Fixes #18018
2022-03-31 19:25:10 +00:00
Dror Eiger af716cdb4a Geneve: add parsing of GCP options 2022-03-31 19:05:56 +00:00
João Valverde 74d385548e Fix comment 2022-03-31 17:46:38 +01:00
João Valverde 8bc214b5bb dfilter: Add remaining arithmetic integer ops 2022-03-31 16:49:42 +01:00
João Valverde d54e22b872 safe-math: Remove unnecessary clutter 2022-03-31 15:49:43 +01:00
João Valverde e15658d1c0 safe-math: Fix non-existent built-ins
Divison and modulo are not built-ins implemented by GCC or Clang.

Replace the spurious macro definition with the internal implementation.
2022-03-31 15:49:43 +01:00
Nardi Ivan 85aa5939f1 NNTP: fix indentation 2022-03-31 15:21:02 +02:00
Nardi Ivan 88840f61a2 NNTP: add support for STARTTLS
Close #18020
2022-03-31 15:04:58 +02:00
Dario Lombardo 45268efd0a
debian: add missing symbol. 2022-03-31 14:08:18 +02:00
Roman Volkov 59bd93413a mpeg table: fix, shows a CRC32 field for an empty PAT 2022-03-31 11:07:14 +00:00
João Valverde 2a9cb588aa dfilter: Add binary arithmetic (add/subtract)
Add support for display filter binary addition and subtraction.

The grammar is intentionally kept simple for now. The use case
is to add a constant to a protocol field, or (maybe) add two
fields in an expression.

We use signed arithmetic with unsigned numbers, checking for
overflow and casting where necessary to do the conversion.
We could legitimately opt to use traditional modular arithmetic
instead (like C) and if it turns out that that is more useful for
some reason we may want to in the future.

Fixes #15504.
2022-03-31 11:27:34 +01:00
Martin Mathieson ae537e24f0 Skinny: Set some masks to match boolean field width 2022-03-30 20:44:39 +01:00
João Valverde 3c2c6b175f Minor release notes cleanup. 2022-03-30 13:59:45 +00:00
João Valverde 5cd0e4cc97 dfilter: Fix use after free with references
By the time we are using the reference fvalue the tree may have gone
away and with it the fvalue. We need to duplicate the reference
fvalues and take ownership of the memory.
2022-03-30 14:05:22 +01:00
João Valverde 9ab2837637 dfilter: Add fvalue duplicate method 2022-03-30 14:05:22 +01:00
Alexis La Goutte 19c0e83d8b quic: add missing draft uri for quic cibir TP 2022-03-30 07:37:48 +00:00
Alexis La Goutte eac578445c QUIC: Add cibir_encoding TP
From  https://datatracker.ietf.org/doc/html/draft-banks-quic-cibir-01
2022-03-30 07:37:48 +00:00
João Valverde 260942e170 dfilter: Refactor macro tree references
This replaces the current macro reference system with
a completely different implementation. Instead of a macro a reference
is a syntax element. A reference is a constant that can be filled
in the dfilter code after compilation from an existing protocol tree.
It is best understood as a field value that can be read from a fixed
tree that is not the frame being filtered. Usually this fixed tree
is the currently selected frame when the filter is applied. This
allows comparing fields in the filtered frame with fields in the
selected frame.

Because the field reference syntax uses the same sigil notation
as a macro we have to use a heuristic to distinguish them:
if the name has a dot it is a field reference, otherwise
it is a macro name.

The reference is synctatically validated at compile time.

There are two main advantages to this implementation (and a couple of
minor ones):

The protocol tree for each selected frame is only walked if we have a
display filter and if the display filter uses references. Also only the
actual reference values are copied, intead of loading the entire tree
into a hash table (in textual form even).

The other advantage is that the reference is tested like a protocol
field against all the values in the selected frame (if there is more
than one).

Currently the reference fields are not "primed" during dissection, so
the entire tree is walked to find a particular reference (this is
similar to the previous implementation).

If the display filter contains a valid reference and the reference is
not loaded at the time the filter is run the result is the same as a
non existing field for a regular READ_TREE instruction.

Fixes #17599.
2022-03-29 12:36:31 +00:00
João Valverde 431cb43b81 dfilter: Remove parenthesis deprecation warning
This usage devalues a mechanism for warning users that deserves more
attention than this minor suggestion.

The warning is inconvenient for intermediate and advanced users.
2022-03-29 12:19:26 +00:00
Joakim Karlsson f401cdeaae asn1: fix missing dissector generation 2022-03-29 12:05:27 +00:00
Anders Broman 2c5f2ac6f3 BER: Add a function to add a BER encoded boilerplate. 2022-03-29 11:23:07 +00:00
Gerald Combs 499a33c709 Debian: Add a symbol. 2022-03-28 18:53:27 +00:00
Chuck Craft 4476db5798 zigbee/isis-clv/wsdg: depreciate -> deprecate
zigbee per Document 07-5356-19
Unchanged: packet-cfm.c per ITU standard
packet-opa-mad.c - unable to confirm status
2022-03-28 18:20:24 +00:00
João Valverde d2907d91c0 dfilter: Add more logging for bytecode 2022-03-28 17:59:07 +01:00
João Valverde 9ee9b40b64 dfilter: Store expanded text 2022-03-28 17:22:01 +01:00
João Valverde a1299d63d9 dfilter: Lower level of two debug messages 2022-03-28 17:20:00 +01:00
Fabian Viöl b55e012524 uds: Don't append parameter record if not available 2022-03-28 15:29:10 +00:00
João Valverde b9b45a4a8f dfilter: Add ftypes pseudofields
This adds a _ws.ftypes namespace with protocol fields with all
the existing field types.

Currently this is only useful to debug the display filter compiler,
without having to find a real protocol field with the desired type.

Later it may find other uses.
2022-03-28 15:42:32 +01:00
Gerald Combs f54bad026f Qt: Fix another qsizetype warning.
Fix

ui/qt/models/filter_list_model.cpp:299:33: warning: implicit conversion loses integer precision: 'qsizetype' (aka 'long long') to 'int' [-Wshorten-64-to-32]
            storage.move(strow, storeTo);
                    ~~~~        ^~~~~~~

when building with Qt 5.
2022-03-28 09:05:24 -05: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 842f53c329 Revert "epan: Allow nested dependent packets"
This reverts commit 2d8607e7e0.

This reverts commit be915d7374.

Introduces a segmentation fault, needs more work.
2022-03-28 12:40:21 +00:00
João Valverde ac0a69636b dfilter: Add support for unary arithmetic
This change implements a unary minus operator.

Filter: tcp.window_size_scalefactor == -tcp.dstport

Instructions:
00000 READ_TREE		tcp.window_size_scalefactor -> reg#0
00001 IF_FALSE_GOTO	6
00002 READ_TREE		tcp.dstport -> reg#1
00003 IF_FALSE_GOTO	6
00004 MK_MINUS		-reg#1 -> reg#2
00005 ANY_EQ		reg#0 == reg#2
00006 RETURN

It is supported for integer types, floats and relative time values.
The unsigned integer types are promoted to a 32 bit signed integer.

Unary plus is implemented as a no-op. The plus sign is simply ignored.

Constant arithmetic expressions are computed during compilation.

Overflow with constants is a compile time error. Overflow with
variables is a run time error and silently ignored. Only a debug
message will be printed to the console.

Related to #15504.
2022-03-28 11:20:41 +00:00
João Valverde 677b68aa3b tests: Remove not implemented tests 2022-03-28 11:55:24 +01:00
João Valverde f574f3fbe8 tests: Remove broken wslua gregex tests 2022-03-28 11:55:24 +01:00