Commit Graph

7682 Commits

Author SHA1 Message Date
Gerald Combs 24a09965e6 Qt: More menu action cleanup.
We use the convention "actionSomeThing" for action names. Rename some
member functions that used that convention.

Manually connect another action.
2022-09-24 16:03:00 -07:00
Gerald Combs de387814bb Qt: Manually connect our "File" menu actions. 2022-09-23 19:41:32 +00:00
Gerald Combs 720090fb86 Qt: Manually connect more "Edit" menu actions.
Followup to ce44047584.
2022-09-23 19:38:07 +00:00
Chuck Craft 2a189d0a08 Qt: if regex not valid don't attempt search
Search is tried as user enter regex string. Regex will be
 invalid as they type it (starts with "\" or fat fingered "*")
 If Wireshark is run from command line, error line is generated
 for every attempted match in the search list.
 ** (wireshark:8344) 00:29:15.353028 [GUI WARNING] --
 QString::contains: invalid QRegularExpression object
2022-09-22 12:47:08 -05:00
Pau Espin 0c7e8ce9a5 ui: Fix Qt deprecation messages
Related: https://gitlab.com/wireshark/wireshark/-/issues/18358
2022-09-21 16:29:10 +02:00
Gerald Combs ce44047584 Qt: Manually connect our "Edit" menu actions.
Use manual, new-style connections for each of our "Edit" menu actions.
KDE's clazy project recommends them over auto-connnections:

https://github.com/KDE/clazy/blob/1.11/docs/checks/README-connect-by-name.md

Use queued connections for the mark, ignore, and other actions that might
run a nested event loop.
Fixes #18344.
2022-09-20 16:39:30 +00:00
Chuck Craft c199b747aa Revert "Qt: only half of enabled/disabled protocols list is processed"
This reverts commit 248955d614.

It speeds up the loop when type_ is EveryWhere (see: enum SearchType)
but a hang or crash for other combinations of type_ and protocolType_.
2022-09-20 11:07:13 -05:00
Gerald Combs 0e462b9aae Qt: Fix some QRC paths. 2022-09-18 23:31:09 +00:00
Gerald Combs b92b66c0f4 [Automatic update for 2022-09-18]
Update manuf, services enterprise numbers, translations, and other items.
2022-09-18 16:45:13 +00:00
Chuck Craft 248955d614 Qt: only half of enabled/disabled protocols list is processed
In Only enabled/disabled protocols lists, the rowCount decreases
as item state is changed in the parent. An equlibrium point is
reached at halfway when rows processed == remaining size of list.
Grab a static rowcount before entering the loop.
2022-09-18 14:58:47 +00:00
Chuck Craft 246e753d69 Qt6: add toInt() to QVariant == Qt::Checked
A change in Qt6 "==" comparison for QVariant for not defined types.

Closes #18336
2022-09-14 20:49:54 +00:00
John Thacker cbb2213021 Qt: Fix memory leak in Decode As
The correct place to delete the dissector_info_t pointers added
to the editor is when destroyEditor is called. Override the
virtual function and delete the pointers for the colProtocol
index before calling the inherited function.

Fix #17127
2022-09-14 12:43:55 +00:00
John Thacker 2762c64010 follow: Have followers register their stream count function
Instead of having the UI have to know about each type of follow
stream, and how to retrieve its total number of streams, have
each follow type register a function that returns the total
number of stream. (The function can be NULL, for protocols like
SIP that do not use this.)

This gets us closer to making follow stream registration generic.
2022-09-14 00:03:07 +00:00
Guy Harris c9342873e5 Clarify dissector description, protocol short name, and protocol ong name.
Rename dissector_handle_get_long_name() and
dissector_handle_get_short_name() to
dissector_handle_get_protocol_long_name() and
dissector_handle_get_protocol_short_name(), to clarify that they fetch
names for the protocol that the dissector dissects, not for the
dissector *itself*.  Leave a deprecated
dissector_handle_get_short_name() wrapper, and export
dissector_handle_get_protocol_long_name(), as it's now used in some
dissectors.

Change some calls to dissector_handle_get_description() back to
dissector_handle_get_protocol_short_name(), as they appear to be made in
order to display a *protocol* name.

Rename some methods, variables, enums, and table column names to reflect
cases where the dissector description is being used.
2022-09-13 00:47:24 -07:00
Chuck Craft 87a7260bb0 Qt6: migrate obsolete currentIndexChanged(QString)
Similar to work done in !8070 and !8072 to move off a function
that was deprecated in Qt5 and obsoleted in Qt6. Also migrate to
syntax laid out in !4560 and !4565.
2022-09-12 22:10:11 +00:00
Guy Harris d4394de669 Give dissectors a descriptive string.
It defaults to the short name of the protocol dissected by the
descriptor, but it's now possible to register a dissector with an
explicit description.

This is mainly for use in the Decode As UI.  It handles the case where
the same protocol might have different "Decode As..."-specifiable
dissectors for different situations.
2022-09-12 21:05:14 +00:00
Gerald Combs 55de00662d Qt: Clean a couple of context menus.
Set the Qt::WA_DeleteOnClose property on our packet list header and
about dialog context menus.
2022-09-12 20:16:23 +00:00
Gerald Combs 834bf08290 Qt: Fix 29West dialog deletion.
Set the Qt::WA_DeleteOnClose attribute (which calls deleteLater())
instead of deleting dialogs under themselves.
Fixes #18334.
2022-09-11 12:44:46 -07:00
Gerald Combs f0fac9e793 [Automatic update for 2022-09-11]
Update manuf, services enterprise numbers, translations, and other items.
2022-09-11 19:29:51 +00:00
Guy Harris e5951765d8 Dissector names are not protocol names.
A given protocol's packet format may depend, for example, on which
lower-level protocol is transporting the protocol in question.  For
example, protocols that run atop both byte-stream protocols such as TCP
and TLS, and packet-oriented protocols such as UDP or DTLS, might begin
the packet with a length when running atop a byte-stream protocol, to
indicate where this packet ends and the next packet begins in the byte
stream, but not do so when running atop a packet-oriented protocol.

Dissectors can handle this in various ways:

For example, the dissector could attempt to determine the protocol over
which the packet was transported.

Unfortunately, many of those mechanisms do so by fetching data from the
packet_info structure, and many items in that structure act as global
variables, so that, for example, if there are two two PDUs for protocol
A inside a TCP segment, and the first protocol for PDU A contains a PDU
for protocol B, and protocol B's dissector, or a dissector it calls,
modifies the information in the packet_info structure so that it no
longer indicates that the parent protocol is TCP, the second PDU for
protocol A might not be correctly dissected.

Another such mechanism is to query the previous element in the layers
structure of the packet_info structure, which is a list of protocol IDs.

Unfortunately, that is not a list of earlier protocols in the protocol
stack, it's a list of earlier protocols in the dissection, which means
that, in the above example, when the second PDU for protocol A is
dissected, the list is {...,TCP,A,B,...,A}, which means that the
previous element in the list is not TCP, so, again, the second PDU for
protocol A will not be correctly dissected.

An alternative is to have multiple dissectors for the same protocol,
with the part of the protocol that's independent of the protocol
transporting the PDU being dissected by common code.  Protocol B might
have an "over a byte-stream transport" dissector and an "over a packet
transport" dissector, with the first dissector being registered for use
over TCP and TLS and the other dissector being registered for use over
packet protocols.  This mechanism, unlike the other mechanisms, is not
dependent on information in the packet_info structure that might be
affected by dissectors other than the one for the protocol that
transports protocol B.

Furthermore, in a LINKTYPE_WIRESHARK_UPPER_PDU pcap or pcapng packet for
protocol B, there might not be any information to indicate the protocol
that transports protocol B, so there would have to be separate
dissectors for protocol B, with separate names, so that a tag giving the
protocol name would differ for B-over-byte-stream and B-over-packets.

So:

We rename EXP_PDU_TAG_PROTO_NAME and EXP_PDU_TAG_HEUR_PROTO_NAME to
EXP_PDU_TAG_DISSECTOR_NAME and EXP_PDU_TAG_HEUR_DISSECTOR_NAME, to
emphasize that they are *not* protocol names, they are dissector names
(which has always been the case - if there's a protocol with that name,
but no dissector with that name, Wireshark will not be able to handle
the packet, as it will try to look up a dissector given that name and
fail).

We fix that exported PDU dissector to refer to those tags as dissector
names, not protocol names.

We update documentation to refer to them as DISSECTOR_NAME tags, not
PROTO_NAME tags.  (If there is any documentation for this outside the
Wireshark source, it should be updated as well.)

We add comments for calls to dissector_handle_get_dissector_name() where
the dissector name is shown to the user, to indicate that it might be
that the protocol name should be used.

We update the TLS and DTLS dissectors to show the encapsulated protocol
as the string returned by dissector_handle_get_long_name(); as the
default is "Application Data", it appeaers that a descriptive name,
rather than a short API name, should be used.  (We continue to use the
dissector name in debugging messages, to indicate which dissector was
called.)
2022-09-10 22:37:11 -07:00
Gerald Combs 8f34e3df98 Add Logray capture icons. 2022-09-10 23:35:27 +00:00
Gerald Combs 1a9842b423 Qt: Fix a variable name.
Don't use a trailing underscore for a local variable name.
2022-09-10 15:39:35 -07:00
Tomasz Moń 1a148b1133 Qt: Fix crash on copy as actions in protocols pane
Allocate FieldInformation on heap instead of stack so it is available
when copy action is triggered.

Fixes #18282
2022-09-10 22:35:55 +00:00
Tomasz Moń 6346cf945a Qt: Connect menu actions with Qt::QueuedConnection
Prevent crash due to premature menu object deletion caused by call to
QCoreApplication::processEvents() by executing the slot only after menu
handling has finished.

Fixes #18251 and #18270
2022-09-10 22:34:48 +00:00
John Thacker 2c37027762 Qt: Fix resolved addresses dialog sorting, filtering, Ethernet groups
Qt6 removed QComboBox:currentIndexChanged(QString), which had
previously been deprecated in favor of the version with an int.
Switch to using the supported function, so that the comboboxes
work.

The models used for the resolved addresses require that the
source models be set first before setting other properties,
so do that so that filtering works.

For some reason the portTypeModel has to indicate that the
port number column is numeric in order for the ports to
numerically sort instead of lexicographically, so do that too.

Add the Ethernet addresses in their specific groups (Addresses,
Manufacturers, Well-Known Hosts) instead of adding them all
to the Well-Known hosts groups, so that that filtering works.

Fix #18087
2022-09-09 01:03:36 +00:00
Gerald Combs 74ec0f0816 Qt+extcap: Make our capture error dialog less noisy.
Strip the timestamps and function names from extcap errors before
displaying them in a dialog. This keeps us from spewing

```
Error by extcap pipe: ** (falcodump:24913) 15:08:20.263535 [falcodump
WARNING] extcap/falcodump.cpp:593 -- main(): cloudtrail plugin error:
failed to list objects: ExpiredToken: The provided token has expired.
status code: 400, request id: M2PYJOT4JGVAA6B9, host id:
+4V8Q+DGV+80Jd3fdc7tODyVdTRvepNgCD9zuvXeL7kzvp2oikaoi9CLMW+UKt/
aR1G2UXIqyQ8=
```

at the user.

Check for warning messages and set our dialog type accordingly.
2022-09-08 10:20:48 -07:00
John Thacker 33fe76612a Qt: Don't use obsolete signal in DCE-RPC/ONC-RPC SRT
QComboBox::currentIndexChanged(QString) has been marked
obsolete for a while and finally removed in Qt 6 in favor
of currentIndexChanged(int) and currentTextChanged(const QString)

Use QComboBox::currentTextChanged(const QString) instead.
Also do a little bit of checking to see if the return value
of dcerpc_get_proto_sub_dissector is NULL.

Fix #18319.
2022-09-08 03:55:43 +00:00
Uli Heilmeier b81948f534 Qt: Fix implicit conversion
Fix

ui/qt/widgets/syntax_line_edit.cpp:160:51: warning: implicit conversion loses integer precision: 'unsigned long' to 'int' [-Wshorten-64-to-32]
            .arg(QString('~').repeated(loc_length - 1));
                              ~~~~~~~~ ~~~~~~~~~~~^~~
ui/qt/widgets/syntax_line_edit.cpp:159:40: warning: implicit conversion loses integer precision: 'qsizetype' (aka 'long long') to 'int' [-Wshorten-64-to-32]
            .arg(QString(' ').repeated(loc_start))
                              ~~~~~~~~ ^~~~~~~~~

when building with Qt 5.
2022-09-07 15:17:00 +00:00
John Thacker 2dfbed7a5f Qt: Connect ExportDissectionDialog to filesSelected
QFileDialog.accept() emits the filesSelected signal when the
dialog is accepted but before it calls QDialog.accept().
Connect our dialogAccepted function the filesSelected signal
instead of the accepted signal, so that all the exporting
happens sooner, before the ExportDissectionDialog gets
closed (and then deleted, since DeleteOnClose is set on the
dialog.)

This fixes use-after-free and segfaults in Qt 6.3 (which changed
things so that QDialog and widgets that inherit from it get closed
earlier.) Fix #18318
2022-09-07 00:54:42 +00:00
Jim Young 1e030a8f59 Qt: Avoid clipping the text label field in progressFrame 2022-09-06 17:05:38 +00:00
Gerald Combs ab4a4304ee Add Logray icons.
Add lricon.svg and lriconinst.svg, which provide the core graphic
element for the various Logray icons. Add lricon*.png, which were
created using the templates at
https://developer.apple.com/design/resources/. Add Logray.icns,
logray.ico, and lograyinst.ico, and use them in various packaging
resources.
2022-09-04 23:01:06 +00:00
Gerald Combs 56a101f4d4 [Automatic update for 2022-09-04]
Update manuf, services enterprise numbers, translations, and other items.
2022-09-04 16:43:03 +00:00
John Thacker 95b45b2555 Qt: Add percent-encoding to Show Packet Bytes
Add Percent-encoding to the list of encoding types that Show
Packet Bytes can handle.

There's a function added to glib 2.66 to handle this for arbitrary
bytes that might have internal nulls (and which allows the result
to be non UTF-8), but we don't require that version yet, so extend
the existing function.

Related to #1084
2022-09-03 17:25:28 +00:00
Gerald Combs fce0b28a39 [Automatic update for 2022-08-28]
Update manuf, services enterprise numbers, translations, and other items.
2022-08-28 16:44:11 +00:00
João Valverde fc952ac2f1 Qt: Increase file dialog size with a scale factor
By default Qt file dialogs are too small and cramped.

Fixes #18230.
2022-08-26 09:33:58 +00:00
Guy Harris 8195bdd340 Rename a bunch of things with "conversation".
A conversation in Wireshark might have two endpoints or might have no
endpoints; few if any have one endpoint.  Distinguish between
conversations and endpoints.
2022-08-25 20:02:20 -07:00
João Valverde f2073b6d74 Qt: Fix build with Logray and Qt6
Copied from 349787051e.
2022-08-25 21:55:46 +01:00
Angelo Spampinato 52e34b2531 Adding some SharkFest info to the welcome screen 2022-08-25 16:43:56 +00:00
John Thacker 66e19f9622 Qt: Silence warning
In the case that this is being called with an address type that
is neither IPv4 or IPv6, make sure that the char array used
to construct the QString is null terminated so that there's no
warning about using addr uninitialized or a possible strlen running
off the end.
2022-08-24 00:36:12 +00:00
John Thacker 7bf4144494 Qt: Enable compilation on gcc 12.1 and Qt6
gcc 12.1 thinks that there's a signed/unsigned qsize issue with
the Qt6 sources. Enable compilation until this gets fixed upstream.

/usr/include/qt6/QtCore/qarraydataops.h:98:17: error: ‘void* memcpy(void*, const void*, size_t)’ specified size between 9223372036854775808 and 18446744073709551615 exceeds maximum object size 9223372036854775807 [-Werror=stringop-overflow=]
   98 |         ::memcpy(static_cast<void *>(this->end()), static_cast<const void *>(b), (e - b) * sizeof(T));
      |         ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2022-08-23 12:38:20 +00:00
Guy Harris d9e662bc54 Rename some functions and types for endpoint tables.
The "conversation table" mechanism supports two types of tables, one for
the "Conversations" menu item under "Statistics" and one for the
"Endpoints" menu item under "Statistics".  The first of them shows
statistics for conversations at various layers of the networking stack;
the second of them shows statistics for endpoints at various layers of
the networking stack.

The latter is *not* a table of hosts; an endpoint might be a host,
identified by an address at some network level (MAC, IP, etc.), or it
might be a port on a host, identified by an address/port pair.

Some data types, function names, etc. use "host" or "hostlist" or other
terms that imply that an endpoint is a host; change them to speak of
endpoints rather than hosts, using names similar to the corresponding
functions for conversations.

Provide wrapper functions and typedefs for backwards source and binary
compatibility; mark them as deprecated in favor of the new names.

Clean up some comment errors found in the process.
2022-08-23 09:55:14 +00:00
João Valverde 6b35aa0773 Qt: Add dfilter error location to tooltip
If display filter compilation fails and the expression has a syntax
error and associated location, it will be displayed in the filter
tooltip, using a textual underline.

As far as I can tell using a graphical squiggly underline seems extremely
difficult for an object inheriting from QLineEdit, so the tooltip
textual method was used instead.
2022-08-22 07:31:08 +00:00
John Thacker 00bfdf46a7 Qt: Fix export objects memory leak
The export object entries were never getting freed, creating a
pretty serious memory leak.

=1307558==ERROR: LeakSanitizer: detected memory leaks

Direct leak of 2237664 byte(s) in 46618 object(s) allocated from:
    #0 0x55ac70d80457 in malloc (/home/johnthacker/wireshark-clang/run/wireshark+0x1a4a457) (BuildId: ad576854e9259fb05a7d0aacbff6e3e1f8e41157)
    #1 0x7fe8ff2f4278 in g_malloc (/lib64/libglib-2.0.so.0+0x5a278) (BuildId: 8a4c270219135729dff508e4bb3cc03099af40e8)
    #2 0x7fe910912ff4 in tap_push_tapped_queue /home/johnthacker/wireshark/epan/tap.c:366:15
    #3 0x7fe910711548 in epan_dissect_run_with_taps /home/johnthacker/wireshark/epan/epan.c:640:2
    #4 0x55ac7263288d in retap_packet /home/johnthacker/wireshark/file.c:2241:5
    #5 0x55ac7263201c in process_specified_records /home/johnthacker/wireshark/file.c:2207:14
    #6 0x55ac726315fc in cf_retap_packets /home/johnthacker/wireshark/file.c:2292:11
    #7 0x55ac712aed41 in ExportObjectDialog::show() /home/johnthacker/wireshark/ui/qt/export_object_dialog.cpp:173:15
...
Indirect leak of 1700955 byte(s) in 139854 object(s) allocated from:
    #0 0x55ac70d80457 in malloc (/home/johnthacker/wireshark-clang/run/wireshark+0x1a4a457) (BuildId: ad576854e9259fb05a7d0aacbff6e3e1f8e41157)
    #1 0x7fe8ff2f4278 in g_malloc (/lib64/libglib-2.0.so.0+0x5a278) (BuildId: 8a4c270219135729dff508e4bb3cc03099af40e8)
...
SUMMARY: AddressSanitizer: 3961187 byte(s) leaked in 186587 allocation(s).
2022-08-22 03:45:20 +00:00
Gerald Combs 70dbe58aea [Automatic update for 2022-08-21]
Update manuf, services enterprise numbers, translations, and other items.
2022-08-21 16:39:53 +00:00
Martin Mathieson eb197df564 RLC Graph: store secs in time_t 2022-08-20 19:56:34 +00:00
Gerald Combs a24f1cbd8d [Automatic update for 2022-08-14]
Update manuf, services enterprise numbers, translations, and other items.
2022-08-14 16:53:51 +00:00
John Thacker c7a136a5c0 epan: Rearrange column includes
Move all the declarations of routines that are internal and
not for use by dissectors from column-utils.h column-info.h
Move the column max length defines into column-utils.h because
dissectors might need that

Since packet.h already includes column-utils.h, dissectors don't
need to include column-utils.h anymore.
Remove or downgrade a few other column header includes that are
unnecessary.
2022-08-13 19:37:28 +00:00
Tomasz Moń d0a9de2af1
capture: Stop extcaps before dumpcap
Send SIGTERM on UNIX systems to all extcap processes when user requests
capture stop. Wait up to 30 seconds for extcaps to finish. If extcaps do
not finish in time, send SIGKILL to remaining extcaps.

Do not call TerminateProcess() on Windows in the same place where UNIX
SIGTERM is sent. Instead schedule extcap termination timeout to happen
as soon as control returns back to the event loop.

There is no universally agreed replacement for SIGTERM on Windows, so
just keep things simple (forcefully terminate like always) until we
have agreed on something.
2022-08-13 20:23:51 +02:00
John Thacker b5cea67768 Qt: Expert Info: Return TAP_PACKET_REDRAW if any ei is added
Any time an expert info is added to the Expert Info tap, the
Expert Info GUI tap listener needs to set TAP_PACKET_REDRAW.

draw_tap_listeners(FALSE) is called from MainApplication::updateTaps()
on a timer (controlled by a preference, defaulting to 3 seconds),
and that clears the Expert Info tap's need_redraw flag. The larger
a capture and the more expert infos, the more likely that the timer
can trigger while epan_dissect_run_with_taps() is still generating
more EI entries, but has already generated EIs of all severities
that are present in the capture. This prevents the expertInfoTreeView
from being redrawn at the end when the captureEvent is finished
retapping the packets.

Fix #18232. Fix #16591.
2022-08-13 10:55:32 +00:00
Chuck Craft a6813db329 Qt: traffic tables - tcp/udp port name resolution
Allow conversation/endpoint tabs that include IP address and
port number to resolve either or both. Currently IP address
(network) resolution is required to resolve tcp/udp ports.
2022-08-08 09:10:10 +00:00
Gerald Combs dc24cdfc4b Qt: Add an "x-reset" icon and use to reset extcap options.
Add an "x-reset" stock icon and use it instead of Qt's SP_BrowserReload
icon to reset extcap options.
2022-08-07 20:21:12 +00:00
Gerald Combs a7be80b04a [Automatic update for 2022-08-07]
Update manuf, services enterprise numbers, translations, and other items.
2022-08-07 16:38:23 +00:00
Jaap Keuter da5603a0d0 extcap: implement saving and restoring radio button setting 2022-08-06 20:19:04 +00:00
Roland Knall d24d27ebc1 Qt: Fix interface auto slot
The signal attached "currentIndexChanged" takes only int as argument,
the correct signal is "currentTextChanged". This also fixes a crash
whenever you changed the visible/nonvisible setting for an interface
2022-08-05 08:56:22 +00:00
Gerald Combs 74e0b506be Windows: Don't define or check for WIN32.
_WIN32 is defined by the compiler, and is arguably a more reliable
test that WIN32. Switch to checking for _WIN32 in a couple of places in
the code.

Remove a WIN32 definition from config.h. It was added for the WinPcap
developer pack but we no longer use that.
2022-08-05 08:33:49 +00:00
Chuck Craft 077547d033 dccp: allow port resolution in conversation table 2022-08-05 00:52:56 +00:00
João Valverde 5a430097b0 About: Reformat and expand some text. 2022-08-03 09:10:07 +00:00
Guy Harris 20a013a8af Qt: fix speling. 2022-08-02 23:31:44 -07:00
Guy Harris 71f32ef2a8 Make sure we don't create comment options longer than 65535 bytes.
Check in both editcap and Wireshark to make sure that comments have
fewer than 65536 bytes before accepting them.

This shoudl fix #18235, although there should also be checks in
libwiretap to catch cases where the user interface code doesn't do the
check (it should be done in the UI so that the user gets notified
appropriately).
2022-08-02 16:38:49 -07:00
John Thacker 66b26d7251 follow: Only retrieve matching conversations
The TCP and UDP follow conversation filter functions should
only retrieve a conversation and conversation data, not
create new conversations or new stream numbers. (That should
only happen during actual packet processing.) So they should
match on the endpoint type and not look up endpoints (since
TCP and UDP don't use the endpoint API.)

They still don't work with tunneling, or any other situation where
the addresses and ports have been changed (see #18231), but this
at least works when some other protocol _has_ used the endpoint
API, and also avoids creating nonsensical streams.

Making them work properly with tunneling either requires adding
packet info to each packet with the stream information, or using
the endpoint API (after finishing it to allow more than one endpoint
on the packet, and a way of searching for endpoints other than
the most recent.)
2022-08-02 20:54:36 +00:00
João Valverde 269e4b7d10 Qt: Remove capitalization of preposition in title
Most style guides recommend against capitalizing preposition in titles
with less than 5 letters or so.

For example KDE: https://develop.kde.org/hig/style/writing/capitalization/
2022-08-02 13:48:43 +01:00
João Valverde 2c4557d7ad About: Tweak a sentence about the project
Uncapitalize Open Source Software. Prefer the well established umbrella
term "free and open source software". Add specifics about the license
version.

Most references use an hyphen with "open-source". Do that as well.
2022-08-02 00:26:24 +00:00
João Valverde a97e1ee581 About: Make clipboard info a close copy of dialog info
To maintain familiarity and keep to expectations do an exact copy.

The last sentence to check the man page is an exception because it
is an addenda and recognizing that this clipboard information will
be used mostly in bug reports, it might get annoying.
2022-08-02 00:26:24 +00:00
João Valverde b8ec3199ab Convert Acknowledgements to markdown and update GUI
Move Acknowledgements to a separate file to enable some code
simplification and improve maintenance and discoverability
for acknowlegements.

Convert the Acknowledgements file to Github flavored markdown
and display it in rich text using QTextBrowser.

Add Acknowledgements.md to NSIS installer
2022-08-02 00:09:29 +00:00
Gerald Combs f231711f1e [Automatic update for 2022-07-31]
Update manuf, services enterprise numbers, translations, and other items.

Asterix failed.
2022-07-31 16:36:50 +00:00
Chuck Craft f50cd81ecb Qt: initialize endpoints name resolution 2022-07-30 15:25:07 -05:00
Tomasz Moń 2d1380ae5b
capture: Move capture pipe polling out of UI
Both CLI and Qt interfaces spin GLib mainloop. Move the capture pipe
polling into common code to reduce code duplication.
2022-07-30 16:42:12 +02:00
John Thacker 5aba5772e9 gboolean bitfields considered harmful
ISO C Std § 6.7.2, 5: "for bit-fields, it is implementation-defined
whether the specifier int designates the same type as signed int or the
same type as unsigned int." (See also the note in § 6.7.2.1 and ISO C
Std Appendix J.3.9.)

A gboolean is a typedef'd gint. Therefore, many implementations,
including gcc and clang, treat a gboolean bitfield of width 1 as
signed, meaning that it has two possible values: 0 and -1, any time
the integer promotions occur (which is all the time.) Constructs like this:

        dgram_info->from_server = TRUE;
        if (dgram_info->from_server == TRUE) ws_warning("True");

will not work as expected, though gcc (but not clang) will give an
error:

/home/johnthacker/wireshark/epan/dissectors/packet-quic.c:3457:37: error: comparison is always false due to limited range of data type [-Werror=type-limits]
 3457 |         if (dgram_info->from_server == TRUE)
      |

        proto_tree_add_debug_text(quic_tree, "Connection: %d %p from_server:%d", pinfo->num, dgram_info->conn, dgram_info->from_server);

Connection: 1 0x7fc4b47f2be0 from_server:0
Connection: 2 0x7fc4b47f2be0 from_server:-1
Connection: 3 0x7fc4b47f2be0 from_server:0
Connection: 4 0x7fc4b47f2be0 from_server:-1

At worst this can cause buffer overruns.

If a bitfield is desired, to guarantee expected behavior the standard
_Bool/bool should be used instead.
2022-07-30 08:49:08 -04:00
Roland Knall 59e7c16425 Revert "Qt: remove unnecessary method from FunnelStatistics"
This reverts commit ddcb429979
2022-07-29 13:13:36 +00:00
João Valverde 35f3fe1b1d Qt: Enable About->License external hyperlinks
Replace QTexteEdit with QTextBrowser and enable external
hyperlinks.
2022-07-27 16:30:48 +00:00
João Valverde e7f439bc2f Convert capture file regex search to PCRE2.
Replace the use of the obsolete GRegex with PCRE2.

Fixes a crash reported in issue #17500.
2022-07-27 11:21:03 +00:00
Roland Knall cb8fc2874c macos: Remove no longer needed function
Fixes #18221
2022-07-25 17:00:55 +00:00
Tomasz Moń 18e08d04d1
Qt: Setup GLib mainloop when needed
GLib watches and timeouts require GLib mainloop iterations. If the GLib
mainloop is not running, then GLib watches and timeouts won't trigger.
Back in the GTK+ days, then GLib mainloop was running on all systems.
Since the Qt transition, GLib mainloop only runs on Linux when Qt does
support it and environment variable QT_NO_GLIB=1 is not set.

Start polling GLib mainloop in separate thread if Qt is not running GLib
mainloop. Note that only the polling is handled in separate thread, the
dispatch and thus all user callbacks execute in the main thread.

Running GLib mainloop when needed enables full GLib functionality on all
platforms and thus allows us to simplify our code by using GLib platform
specific code.
2022-07-24 20:57:18 +02:00
Gerald Combs c252852c9d [Automatic update for 2022-07-24]
Update manuf, services enterprise numbers, translations, and other items.

Asterix failed.
2022-07-24 16:37:40 +00:00
Jirka Novak 476eb0e627 RTP player: fixed issue with no audio card available in Qt6 2022-07-21 20:09:52 +00:00
Jirka Novak ea91c5785a Qt6: Audio code review
Changes:
- audio rates are fixed, I selected common ones
- fixed signal names - they didn't matched expected autogenerated ones
- first play notification delay on Qt6 compensated
2022-07-21 20:09:52 +00:00
Gerald Combs b8d85227f6 Qt: Update the RTP stream UI to support Qt6Multimedia.
Fixes #18115
2022-07-21 20:09:52 +00:00
João Valverde d2b6b89b94 Update license file structure and GUI display
Add the text of the GPLv2 in HTML, taken from the FSF website,
and use rich text to display the license in the GUI.

Move the introductory note about the GPL from the COPYING
license text file to the README.

Remove various other license callouts at the end of the COPYING file
as unnecessary and unhelpful. This information is present in
each source file, where it belongs.
2022-07-21 19:10:06 +00:00
Roland Knall b90fb0da55 Qt: Fix jump on packetlist
If the packetlist is navigated via the up/down keys, the viewport
may jump, if the cell that is being navigated to, has content that
is greated than what is currently displayed

Fixes #16363
2022-07-18 15:25:12 +02:00
Roland Knall ddcb429979 Qt: remove unnecessary method from FunnelStatistics 2022-07-18 15:08:23 +02:00
João Valverde b50880f329 Qt: Update display filter expression dialog with any/all 2022-07-17 19:23:15 +00:00
Gerald Combs a6b09b52b4 [Automatic update for 2022-07-17]
Update manuf, services enterprise numbers, translations, and other items.

services failed.
2022-07-17 16:38:11 +00:00
Roland Knall 06cd84a6e9 Qt: Recommend 5.12 and enforce 5.10
In order to phase out older versions, we recommed 5.12 as a
minimum Qt version going forward. Although build support for
5.10 and 5.11 is not being removed at this point, it might
be for 4.x at a later time.
2022-07-13 21:26:46 +00:00
Chuck Craft 4ff209e881 Qt: Edit->Preferences resets titlebar and statusBar to defaults
Caused by a LanguageChange event - similar to #16356 /
!689
Not sure if enough to close issue #12966
2022-07-13 18:08:22 +00:00
Chuck Craft f99b056025 Qt: Supported Protocols search - increase debounce timeout
Increase the Qtimer value added in !3325 to allow human typing speed.
See !3328 for typing speed math.
2022-07-12 15:25:06 +00:00
John Thacker 8ac995578c epan: Respect custom column resolved/unresolved status everywhere
Add a function to get the column text of the nth column, taking
into account whether the column is resolved or unresolved. Use
this function in the GUI, as well as in tshark, when writing
PSML, exporting dissection to PSML, etc., instead of accessing
col_data directly.

This removes the direct accesses of col_data from outside
column.c and column-utils.c

Fix #18168.
2022-07-12 00:22:11 +00:00
Tomasz Moń 0438fca96b Qt: Concurrently fill display filter expression dialog
Use QtConcurrent to create and sort widget items. The dialog window is
immediately visible and usable. Search becomes available once all items
are added to the tree.

When compiled with Qt5, all items are added in bulk. Qt6 features new
QPromise interface that makes it possible to add tree items one by one.
2022-07-11 16:36:43 +00:00
Tomasz Moń fc85196f61 Qt: Do not spin event loops in display filter dialog
Pass comparator function so the list gets sorted alphabetically. Without
the comparator function, the pointer values were sorted. Insert already
sorted data into tree widget and thus remove the redundant sort call.

Use std::stable_sort() instead of std::sort() as stable sort is actually
faster here. The std::stable_sort() tends to do fewer comparisons and
more moves than std::sort(). When sorting QTreeWidgetItem pointers, the
move is very low cost (only the pointer itself is moved) and string
comparison is quite heavy (especially because the strings share common
prefix).
2022-07-11 16:36:43 +00:00
Gerald Combs d10253ebea [Automatic update for 2022-07-10]
Update manuf, services enterprise numbers, translations, and other items.
2022-07-10 18:42:22 +00:00
Roland Knall 26b8674320 Qt: Fix unitialized TrafficTree members 2022-07-09 11:08:15 -05:00
Roland Knall 4742e0cade Qt: Filter column information for traffic dialogs
This enables the traffic dialogs to filter data based on the
context menu entries. For instance, one can only show rows,
where the number of packets is not greater than 10
2022-07-08 16:21:32 -05:00
John Thacker 1eeb0c9934 cli: Copy global configuration profile to personal as with the GUI
If a configuration profile is requested on the command line that
does not exist as a personal profile but does exist as a global
profile, copy it to the personal directory and use it, the same
as when selecting a global profile in the GUI.

Add the same feature to tshark and tfshark as well, where it
is particularly useful.
2022-07-07 12:14:41 +00:00
Gerald Combs f296a00f09 Add a default configuration profile for Logray.
Add and install default coloring rules and filter buttons for Logray.
Add is_packet_configuration_namespace() and use it to set the default
timestamp type for Logray to "Absolute", which is more appropriate for
log entries.
2022-07-06 10:53:21 -05:00
Gerald Combs 75efbb1ac4 Rename Logwolf to Logray
Switch to the name "Logray" for the log analyzer. Rays are biological
cousins of sharks and more people like the name "Logray" in a completely
unscientific survey here. Apologies for any inconvenience this might
cause.
2022-07-06 15:04:25 +00:00
Gerald Combs 78ebafd708 Qt: Explicitly set our SyntaxLineEdit background color.
It looks like 1eafee6566 wasn't sufficient to fix the Qt 6 background
paint issue, at least for Qt 6.2.3. Explicitly set our background brush
before filling our rect.
Fixes #18175.
2022-07-06 14:45:26 +00:00
Gerald Combs ff36056573 [Automatic update for 2022-07-03]
Update manuf, services enterprise numbers, translations, and other items.
2022-07-04 21:30:14 +00:00
Roland Knall c054501335 Qt: Fix compile issue for 5.9
Use the legacy method for when a Qt version below 5.10 is being used,
due to the fact, that QLocale::formattedDataSize had not been introduced
before
2022-07-04 19:22:17 +00:00
Tomasz Moń d1f7aa5acb
Qt: Do not spin new event loop on menu show
There is no need for nesting event loops when showing menus. Show menus
asynchronously to limit possibilities of hard to debug problems related
to re-entering event loop.
2022-07-03 13:41:30 +02:00
Roland Knall fe3d70e792 Qt: fix uninitialized member
_sortModel is not initialized properly
2022-07-02 17:58:09 +02:00
John Thacker 42567a59bc Qt: Support setting columns as un/resolved via Edit Preferences
Make it so that "Edit->Preferences->Columns" can also set the
resolved/unresolved status of custom columns. Hide the checkbox
when the fields don't support it (including any non custom
columns.) Also make the checkbox entries in the column list model
not editable.

Fix #15394
2022-07-01 11:22:59 +00:00
Roland Knall 2cebafc613 Qt: Filter TrafficListTypes
Add a textbox to allow for filtering the traffic types
in the conversation and endpoint dialog. The current implementation
allows for an easier growth of the list entries. To ensure that
the user can find the entry he/she/they is looking for fast, add
a textbox for filtering
2022-07-01 11:30:57 +02:00
Roland Knall 54aed0aa10 Qt: Cleanup TrafficTypesList
Consolidate two methods which practically do the same thing, as well
as remove some residues from earlier implementations
2022-07-01 08:02:47 +00:00
John Thacker a40e5f715a Qt: Check custom column syntax in Preferences properly
Not all display filters are valid for custom columns (see #15990).
Use the validation function for custom columns instead of the
display filter validation when adding or editing a custom column
through Edit->Preferences, as the Edit Column in the packet list
header already does.

Revisit this if we ever do expand the list of possible custom
columns.
2022-06-30 20:31:19 -04:00
Roland Knall 4149d52f4e Qt: column edit default checkbox 2022-06-30 21:15:21 +02:00
John Thacker 09800da792 Qt: Add resolved button to Edit Columns
Add the ability to set custom columns as resolved/unresolved via
the Edit Column frame, if the column fields support it.

Related to #15394.
2022-06-30 08:28:54 -04:00
Roland Knall ac4b9e174d Qt: Cleanup PacketListHeader
Remove unnecessary for-loop and subroutine
2022-06-29 15:46:19 +02:00
Roland Knall 413b383224 Qt: Reduce PacketListHeader complexity
Propagating the capture_file was required for a single
function as was the cast for the model. Both are not
needed, as the functionality can be either moved to
PacketListModel or was already included in PacketList
2022-06-29 14:47:05 +02:00
Roland Knall 5fb2324692 Qt: Improve sort for packet list 2022-06-29 12:42:22 +02:00
Roland Knall 505226d1e2 Ui: Centralize PacketList helper prototypes
To implement loading a packet list, a lot of helper
methods are required. Those prototypes where split up
over two places and have been moved to packet_list_utils.h
to ensure a single place for lookup
2022-06-29 09:31:09 +00:00
Roland Knall 94c439f603 Ui: Use only one method for exit
Replace the redundant main_window_quit with the
more specialized exit_application and return 0
as a state
2022-06-29 09:00:33 +00:00
Alexis La Goutte a2272362ce conversation_dialog.h: Fix -Wdocumentation
conversation_dialog.h:24:15: warning: parameter 'cli_proto_id' not found in the function declaration [-Wdocumentation]
conversation_dialog.h:25:15: warning: parameter 'filter' not found in the function declaration [-Wdocumentation]
2022-06-28 21:37:32 +00:00
Roland Knall 1d6b547029 Qt: Fix FileClose not available and segfault
Fixes #18160
2022-06-28 20:24:27 +00:00
Roland Knall c3b2cec3f2 Ui: Cleanup row number and select packet
Remove unneeded row number in capture file. The packet list is
the only object that should know the correct number, propagating
it further only complicates things. At the same time, rework
cf_select_packet to select the packet based on frame_data not on
the row (which can be unreliable).
2022-06-28 14:56:06 +02:00
Roland Knall f210edeaf0 Ui: Further simplify ws_ui_util
Remove duplicate functionality for jumping to packet and
remove unused function to move to the end. Furthermore
move the code for redraws of visible packets directly
into the calling code
2022-06-28 14:39:27 +02:00
Roland Knall ef8ed9dff9 Ui: Remove time column reformat callback
The code can be placed directly to packet list model
and does not need to be a generic callback
2022-06-28 14:23:05 +02:00
Roland Knall 1d42fcdd76 Ui: Remove call to recoloring
No callback needed, we can call the model directly
2022-06-28 14:06:49 +02:00
Roland Knall 865141e61b Ui: Remove unused prototype declaration
The functions are nowhere implemented
2022-06-28 11:34:22 +02:00
Roland Knall b6226cb136 Qt: Better handle sort restriction
Setting sorting enabled/disabled resorts the list. If this happens
too often, sometimes it can lead to the physical view models
not present anymore and therefore crashing.

Ping #18159
2022-06-28 10:12:24 +02:00
John Thacker 4ed4678859 Qt: Make the Resolve Names buttons checkable again
The checkable property got lost at some point, rendering it impossible
to make columns resolved.
2022-06-27 20:26:08 -04:00
Roland Knall 7f951eda3e Qt: Increase animation speed for progress frame
The progress frame animation is so slow, that it might not show
up on certain setups. Reduce the initial speed and duration for
the animation, which also speeds up calculations as well as dissection
as less animation has to be rendered/calculated
2022-06-27 14:03:34 +00:00
Gerald Combs b5e1e63dd0 [Automatic update for 2022-06-26]
Update manuf, services enterprise numbers, translations, and other items.
2022-06-26 17:40:36 +00:00
Roland Knall 006d20db9e Qt: Only sort if there are actually lines to sort
Remove the sort for physical rows, if there are no rows to sort

Ping #18159
2022-06-26 15:59:41 +00:00
João Valverde 0dbd0a6903 Qt: Fix endianness for an IPv4 value
ws_in4_addr is in network byte order (big endian) so convert from
BE to host byte order, not the other way around.
2022-06-24 20:26:38 +00:00
Roland Knall 2e5b09f486 Qt: Fix compiler warning on macOS 2022-06-22 17:52:15 +02:00
Roland Knall 1424e28c7d Qt: Fix stream id display in context menu
It was displayed for every protocol, but should only be displayed
for TCP and UDP alone
2022-06-22 15:48:51 +02:00
Gerald Combs 9c19f47394 Qt: Fix a couple of slot names.
QComboBox emits currentTextChanged with a QString argument, not
currentIndexChanged.

Switch to new-style connections where we can.
2022-06-21 12:20:02 -07:00
j.novak@netsystem.cz b6ccc65a92 RTP Analysis dialog: Fix of clock drift freq drift calculation 2022-06-21 19:08:28 +00:00
Gerald Combs 24cab126fd Qt: Fix our filter edit line lengths.
Make sure our bookmark border lines extend to the full height of the
text entry box.
2022-06-21 10:55:16 -07:00
Gerald Combs 3d52693eaa Qt+docs: Capitalize JSON.
JSON is an abbreviation and should be displayed in all caps.
https://www.json.org/json-en.html
2022-06-21 17:24:27 +00:00
Gerald Combs 1eafee6566 Qt: Work around a background fill issue with Qt 6.
It looks like QLineEdit no longer paints its background when it's a
QComboBox editor under Qt 6. Add a workaround for this to SyntaxLineEdit.
2022-06-21 09:39:46 -07:00
Roland Knall 847795d381 Qt: Add stream number to conversations
Adding the stream id to UDP/TCP conversations and allowing
filtering on those values as well.

Fixes: #14184
2022-06-21 10:01:18 +02:00
João Valverde 0615ba6317 ftypes: Make accessor functions type safe 2022-06-20 17:29:57 +00:00
Roland Knall e046877ad1 Qt: Fix column hiding for traffic model
Instead of letting the model do the filtering and having
a bunch of exceptions in cases where columns are hidden
in between other columns, the model will present all columns
all the time, and it is the job of a top-level proxy to
filter out columns not required for current display
2022-06-20 10:21:37 +02:00
Gerald Combs 058fe0dd09 [Automatic update for 2022-06-19]
Update manuf, services enterprise numbers, translations, and other items.
2022-06-19 16:40:16 +00:00
Roland Knall 2b4878d452 Qt: Hide columns for traffic tree
Allow columns to be hidden for the traffic tree dialogs
Conversations and Endpoints and store the information profile
specific
2022-06-19 16:39:35 +02:00
Roland Knall f75f577579 Qt: Fix TrafficTree typo
And also fix some prototypes
2022-06-19 11:21:53 +02:00
Gerald Combs 79310ebbd2 Qt: Remove our idle dissection wait period.
Set our idle dissection single-shot timer to 0, i.e. whenever the Qt
event loop can fit us in. This fixes a performance issue here with
libsinsp and doesn't appear to cause any issues otherwise.
2022-06-17 10:18:19 -07:00
Gerald Combs 5db7ddb209 ui: Add Logwolf software updates.
Set Logwolf information in the Appcast URL template as needed.
2022-06-17 16:31:44 +00:00
Roland Knall b3fd206822 Qt: Sort tap list initially
By sorting the list of taps, the initial sorting is kept also
for the tab order
2022-06-17 13:06:21 +00:00
Roland Knall 83e420913d Qt: Implement sort model for traffic type list 2022-06-17 13:22:22 +02:00
Roland Knall 300befc12a epan: Numeric address type
Add a numeric address type analog to StringZ for
protocols who only use numeric values as addresses
with no further handling.

e.g. IAT protocols which only enumerate the devices
2022-06-17 08:56:05 +00:00
Roland Knall bd6808c4a0 Qt: Fix missing includes
On some compiler variations an error can occur due to missing
glib.h include
2022-06-16 08:12:29 +02:00
John Thacker 2efe338b2e Qt: Use a combobox for Decode As selectors if there are packet values
Don't require there to be at least two values in a packet for
a dissector table in order to have a combobox instead of a single
text box.

While perhaps having an editable combobox with only one drop down
option looks a bit funny, that is outweighed by the UI advantages
of being able to easily select the values that occur in the packet.

This makes it possible to change the dissector for the currently
selected packet's IP protocol or Ethertype when those are not the
last protocol layer without having to type it in manually, for
example.
2022-06-16 03:15:08 +00:00
João Valverde c5b47cb839 Qt: Remove some bogus entries from Authors list
Some lines in Acknowledgements are mistakenly matching the regular
expression to capture authors and email addresses, resulting in
bogus authors entries.

Stop matching authors after we reach the Acknowledgements section.
This matches the structure of the AUTHORS-SHORT file and fixes the
bogus entries.
2022-06-15 06:46:50 +01:00
Roland Knall 1272b62106 Docs: Update documentation for redesigned Traffic Tabs
Update the documentation to document the change of features
that happen during the redesign of the UI as well as fix some
wordings in the data model.
2022-06-14 21:33:26 +00:00
Roland Knall 4f283e9ef8 Qt: Fix Qt6 compile warnings for traffic tabs
Some conversions are warning, that qsizetype is implicitly
converted, this fixes that
2022-06-14 22:10:31 +02:00
Roland Knall a4f25e5115 Qt: Redesign TrafficTree Dialogs UI
The new UI should better group functionality and as well as better
showing which taps are available and can be used.
2022-06-14 09:36:30 +00:00
Roland Knall 1dc37de740 Qt: Fix sorting for ports
Ports where sorted as string and not numerical
2022-06-13 17:33:38 +02:00
Roland Knall be112bd44e Qt: Fix maxmind open map
Fix an issue, where the map button is not correctly activated
and therefore the map cannot be shown or opened
2022-06-13 14:39:14 +00:00
Roland Knall 0cfe7a0d56 Qt: Better sorting for traffic dialogs
Allow the traffic columns to automatically sort on secondary columns if
applicable. e.g. the address and port column for TCP and UDP, or the
secondary address for conversations
2022-06-13 13:50:50 +02:00
Gerald Combs b3a102eb46 [Automatic update for 2022-06-12]
Update manuf, services enterprise numbers, translations, and other items.
2022-06-12 17:03:28 +00:00
Roland Knall 212abb7efe Qt: Autoset limit to display filter for expert dialog
Autoset the "Limit to display filter" if a display filter
was present, when the dialog was opened
2022-06-12 15:30:12 +00:00
Roland Knall a807047b95 Qt: Adapt sorting for traffic tables
Improve sorting for the traffic tables
2022-06-12 14:53:23 +02:00
Roland Knall 51d5cb42b2 Qt: Implement total columns for traffic tables
Implement a column type, which will show total values
for traffic columns.

Implements #15071
2022-06-10 12:38:56 +02:00
Roland Knall 2cf938cfa8 tap: Adding flags for tap_packet
This allows flags to be passed by the registering listener
to the collection of information
2022-06-10 05:46:15 +00:00
Roland Knall c03bf18db1 Qt: Remove double registered signals 2022-06-08 17:48:41 +02:00
Roland Knall 3029a4a4d9 Qt: Remove unnecessary cli option
There was an option that was never used, in that you
could set your protocol tap as a first tab in the
Conversations and Endpoint dialogs.
2022-06-08 17:42:58 +02:00
Roland Knall 176ba718f0 Qt: Fix displayfilter always on
The "Limit to display filter" was always set to true, even if
no filter had been set.
2022-06-08 10:50:12 +02:00
Roland Knall 4b9d152767 Qt: Auto apply "Limit to display filter"
If a display filter had been applied during the opening
of the conversation or endpoint dialog, automatically check
the entry for "Limit to display filter" to ensure that
the filtered result is being shown, as expected by the user.
2022-06-07 14:38:58 +02:00
Jakub Jirutka 3187fbbd61 Qt: Fix segfault when some ICU codec is not available
$ gdb --args wireshark
    (gdb) run
    Starting program: /usr/bin/wireshark
    [New LWP 10363]
    [New LWP 10364]
     ** (wireshark:10356) 13:13:14.137941 [GUI WARNING] -- codecForName: ucnv_open failed ISO-8859-2 U_FILE_ACCESS_ERROR
    (gdb) bt
    Thread 1 "wireshark" received signal SIGSEGV, Segmentation fault.
    0x00005555557b1959 in MainWindow::findTextCodecs (this=0x7fffecdfd390) at wireshark-3.6.5/ui/qt/main_window.cpp:2029
    2029            QString key = codec->name().toUpper();
    (gdb) bt
    #0  0x00005555557b1959 in MainWindow::findTextCodecs (this=0x7fffecdfd390) at wireshark-3.6.5/ui/qt/main_window.cpp:2029
    #1  0x00005555557b4ce3 in MainWindow::MainWindow (this=this@entry=0x7fffecdfd390, parent=parent@entry=0x0) at wireshark-3.6.5/ui/qt/main_window.cpp:362
    #2  0x000055555564f0af in main (argc=<optimized out>, qt_argv=0x7fffffffe748) at wireshark-3.6.5/ui/qt/main.cpp:725

See https://gitlab.alpinelinux.org/alpine/aports/-/issues/13814 for more
information.

Conflicts (cherry-picked from 635286ce):
	ui/qt/main_window.cpp
2022-06-05 17:01:04 -07:00
Jaap Keuter fe4210029a Qt: Reword menu item Seconds Since Beginning of Capture 2022-06-05 23:55:59 +00:00
John Thacker 9d716d793c Follow Stream: Allow using spin boxes with no packets visible
It's only necessary to check that cap_file_.capFile()->edt is
not NULL if use_stream_index is FALSE.

This prevents failure and an inaccurate error message about the
capture file being invalid when using the spinbox to cycle through
a stream when all packets are filtered out.(E.g., Follow a stream,
append to the filter looking for something, no packets match, try to
go to the next stream.)
2022-06-05 22:19:39 +00:00
João Valverde 2939c6d0dc Version info: Do not show plugin count
Plugin count is dependant on initialization order and showing
zero plugins loaded can be misleading.
2022-06-05 21:31:36 +00:00
Gerald Combs 5cd591129f epan: Convert remaining conversation code to elements.
Convert the address+port conversation code to element lists. Make our
conversation keys element lists. Document more of the conversation API.

Update the Conversation Hash Table dialog to use the new API.

Describe an alternative key type and data structure at the top of
conversation.c.
2022-06-05 19:05:33 +00:00
Gerald Combs 729b4d3b69 [Automatic update for 2022-06-05]
Update manuf, services enterprise numbers, translations, and other items.
2022-06-05 16:40:02 +00:00
Roland Knall b06c1c451c Qt: Make TrafficTable detachable
Allow the endpoint and conversation dialogs to have detachable
tabs. At the same time move the tree functionality to a subclass
to better be able to handle the context menu when detached.

Right now, still a lot of tree stuff is in the tabwidget, but
could be moved to the tree for the future
2022-06-04 21:28:05 +02:00
Roland Knall 9edf06383a Qt: Move most Contextmenu stuff to TrafficTree
Create a new class, which handles the context menu stuff for
the traffic data, as well as remove unnecessary signals used
by the sub-dialogs.
2022-06-04 15:57:02 +02:00
Roland Knall 05759d3ec5 Qt: Better handle retapping for traffic tables
Retapping can have some side-effects and was done in
an overflowing way. Reducing the number of times retapping
is required and done, and also giving control for taps
reload to TrafficTab
2022-06-03 10:25:15 +02:00
Roland Knall fc505eed29 Qt: Fix coverity warnings for TrafficView 2022-06-02 16:50:31 +00:00
John Thacker ea2ddd40f5 Qt: Fix leak in CaptureFileDialog
Instead of instantiating CaptureFileDialog with a reference to
the filter (which means allocating a new empty QString when using
it for Save As and Export Packets, which don't use a filter), pass
the filter reference into the open and merge functions.

This plugs a memory leak that happened each time the Save As or
Export Packets dialog was created.
2022-06-02 12:31:01 +00:00
Roland Knall f725bbef5e Qt: Minor changes to TrafficTrees
Move the corner button to a QToolButton and put it in a widget
to better handle size constraints. Also fix some fallthroughs
and remove unneeded code
2022-06-02 12:30:41 +02:00
Stig Bjørlykke 335795ab16 Qt: Fix build withouth MaxMindDB 2022-06-02 08:56:22 +02:00
Roland Knall dd9e4fd3fa Qt: Fix warning for TrafficData 2022-06-01 20:21:53 +02:00
Roland Knall 7306d7681a Qt: Save Trafficdata as raw
Allow the option to save the data from the traffic dialogs
as raw data and enable it as the default option for 4.0. The
option to display the data with pretty formatting is still
available.
2022-06-01 11:51:39 +02:00
Roland Knall cb56345175 Qt: Move Traffic Tables to Model/View
The current model makes it very hard to extend the traffic tables
with new functionality. For instance, having a total view column
additionally to the normal columns when filtered.

This change removes the QTreeWidget and moves to a more generic
approach using QAbstractListModel elements.

It is implemented in thtree parts:
- ATapDataModel implements the basic collection and handling of
  the tap data information, as well as updating if new data is
  becoming available
- EndpointDataModel / ConversationDataModel handles the display
  and representation of the data
- Implementing TrafficTab as a TabWidget which will handle the
  adding/removing of new protocol tabs
2022-06-01 11:26:22 +02:00
Gerald Combs 48ff21b573 [Automatic update for 2022-05-29]
Update manuf, services enterprise numbers, translations, and other items.
2022-05-29 17:20:25 +00:00
João Valverde ee7094d34c CMake: Fix typo 2022-05-25 23:46:01 +01:00
Gerald Combs 34d74031a9 epan+Qt: Add element tables to the ConversationHashTablesDialog.
Add get_conversation_hashtables() and use it to populate the
conversation hash tables dialog.
2022-05-25 19:09:12 +00:00
John Thacker 485aedf4e1 tap-iostat: Make a bunch of ints unsigned
Almost all the ints in tap-iostat are loop counters, numbers of columns
or rows, durations, lengths, widths, or magnitudes, all things that are
inherently unsigned. Make them unsigned.

This has the incidental effect of fixing an odd alloc-size-larger-than
error with gcc 12.1, which is afraid that if borderlen is signed that
g_malloc will somehow be called with value -1 (18446744071562067969):

Fix #18089
2022-05-24 20:27:04 -04:00
John Thacker 75f31638f2 Apply 1 suggestion(s) to 1 file(s) 2022-05-23 16:27:18 +00:00
Gerald Combs 349787051e CMake+Qt: Fix our Resource Compiler arguments.
We pass "--format-version 1" to rcc. If it's compiled with Zstandard we
need to pass "-compress-algo zlib" as well.
Fixes #18100.
2022-05-23 16:27:18 +00:00
John Thacker e1a6913a2b qt: Ignore gcc 12.1 optimization bug with Qt
The Qt implicit casts from QByteArray to QString all use
size = -1, meaning to the end of the string.

This causes gcc 12.1 with -O2 to produce a very dubious stringop-overread
warning, by computing both sides of a branch even when it shouldn't:

/usr/include/qt5/QtCore/qstring.h:706:69: error: ‘size_t strlen(const char*)’ reading 1 or more bytes from a region of size 0 [-Werror=stringop-overread]
  706 |         return fromUtf8_helper(str, (str && size == -1) ? int(strlen(str)) : size);
      |                                                               ~~~~~~^~~~~

There's also a similar error with QByteArray.constData(), even though
isEmpty() should return True when the QByteArray is NULL.
(Adding isNull() prevents the warning but is redundant.)

Use DIAG_OFF and DIAG_ON to ignore the warning on GCC 12.1 and higher.
Fix #18090.
2022-05-23 12:14:03 +00:00
Gerald Combs c8fc8de3d4 [Automatic update for 2022-05-22]
Update manuf, services enterprise numbers, translations, and other items.

services failed.
2022-05-22 16:37:34 +00:00
Roland Knall 5a53e72c63 Qt: Row colors and resize
Set the row colors in the traffic dialogs to alternating for better
readibility and add a context menu option to resize the columns back
to content

Fixes #16189
2022-05-19 15:58:20 +02:00
Roland Knall 6913bff6cd Qt: Simplify traffic type selection
Remove unnecessary subclass and make the code easier to
manage in the future
2022-05-19 15:01:00 +02:00
Roland Knall 1cde1cc1f5 Qt: Move type selection to tab
Move the type selection to the tab selection bar, so that new
users may find it faster and easier
2022-05-19 09:31:17 +02:00
Roland Knall 3d4dfb829b Qt: Allow translation for traffic tables
Allow the headers of the conversations and endpoint statistic
dialog to be used with the Qt translation system
2022-05-18 22:46:53 +02:00
Roland Knall f5b5d2c3c9 Qt: Cleanup Traffic Table
Remote traffic_table_ui.? and move the JSON stuff into endpoint.

This is in preparation for larger work on both the conversation
table as well as the endpoint table, and to start using Qt code
in the UI where it should be used.
2022-05-18 19:50:14 +00:00
Roland Knall b4e041a619 Qt: Fix packet diagram cleanup
After selecting field values to be shown or not shown
residues of the former diagram may reside until the next
scroll event. This updates the viewport to trigger the
paintEvent earlier.

Fixes #17997
2022-05-17 11:37:33 +02:00
Roland Knall 9ba4847a13 Qt: Fix some pathSelection warnings 2022-05-16 19:53:27 +02:00
Roland Knall eca007e617 Qt: Speedup for Resolved Addresses Dlg
This is a small speedup for the ResolvedAddressesDialog. QString::arg
is a copy-by-call method as QString::append just extends the space
occupied by the string, leading to a major speed improvement.

Same goes for configuring the proxymodels first and then assigning the
data model as this will lead not to reorganization everytime
invalideFilter is being called
2022-05-16 15:07:47 +00:00
Roland Knall 28b917a72e extcap: Close pipe on windows properly
Windows implements so called CRT handlers, which will catch any
assertions happening inside so called crt routines and either
displays a debug dialog (Cancel, Retry, Ignore) or outright crashes
the application.

See
https://docs.microsoft.com/en-us/cpp/c-runtime-library/parameter-validation?view=msvc-170
for an explanation of the behaviour.

Now, in the current situation here, close will detect (correctly)
that the pipe it is supposed to be closing is already closed. This
happens (again correctly) because it had been closed by the extcap
application.

The change added, checks for a closed pipe first, and if so just
returns -1 (as it should) silently without calling the CRT routine,
therefore not crashing
2022-05-16 14:48:37 +02:00
Roland Knall acdda8eb6b Qt: Fix File Path editor in table
The current situation in UatDelegate as well as PathChooserDelegate leads to issues, where Wireshark crashes if the button is clicked. This is due to the UI not correctly positioning the button inside the cell.

This change implements a widget, which will serve as cell content, handling all relations with choosing the file, but also properly handling the size and geometry of said cell content, therefore no longer leading to crashes and cleaning up code at the same time, as duplicate methods are being removed.

Fixes #17789, #17819, #18088
2022-05-16 09:54:08 +00:00
Gerald Combs 76423db8e0 Qt: Fix clazy-incorrect-emit warnings.
QAbstractItemModel::beginResetModel and endResetModel aren't signals, so
don't emit them. dataChanged is, so do.

Fixes clazy-incorrect-emit:
https://github.com/KDE/clazy/blob/master/docs/checks/README-incorrect-emit.md
2022-05-12 17:29:06 +00:00
Gerald Combs 7b749f5e15 Qt: Fix a version check.
Qt::endl was introduced in 5.14.
2022-05-11 09:21:41 -07:00
Roland Knall ad28888d2f Qt: Fix display filter read/write
Display filters on Windows where broken in such a way that the file was generated with empty lines and the wrong file delimiters.

Likewise, loading the file lead to issues when the formatting was not 100% match by the plattform being used

Fixes #18082
2022-05-11 12:22:29 +00:00
Roland Knall 4977e20ab2 Qt: Prevent remote interfaces to show up
Remote interfaces should not be displayed with local interfaces
as well as in the list of pipe interfaces
2022-05-10 20:00:02 +02:00
Roland Knall ae9e80a34d Qt: Fix proper preselection for remote interfaces 2022-05-10 14:52:27 +00:00
Roland Knall 5b59a38c3b Qt: Clean up remote management interface
Clean up a previous fix, which left the remtoe management interface
unloadable.

Fixes #18060
2022-05-10 16:26:37 +02:00
Roland Knall e43501cf9e qcustomsplot: revert for fix Clang Warnings[core.UndefinedBinaryOperatorResult]
The commit prevents compilation for Qt 6.3.0

This reverts commit 3afa8264cb.
2022-05-03 15:46:03 +02:00
Gerald Combs 2f31c09045 [Automatic update for 2022-05-01]
Update manuf, services enterprise numbers, translations, and other items.
2022-05-01 17:26:48 +00:00
Guy Harris 69e956d792 conversations, endpoints: sort resolved addresses as text.
If name resolution is enabled in the conversations and endpoints
dialogs, sort address columns by the resolved names, not by the
addresses; sorting them by address will give *very* unexpected results,
and not make it easier to look for addresses by name.
2022-04-30 19:37:50 -07:00
Gerald Combs 70bd130379 Fix "generated by" comments in configuration files.
Add get_configuration_namespace() and use it in code that writes
"generated by" comments at the top of various configuration files.

Update our Logwolf colorfilters.
2022-04-29 18:00:21 +00:00
Gerald Combs cfcfbbdd60 [Automatic update for 2022-04-24]
Update manuf, services enterprise numbers, translations, and other items.
2022-04-24 16:39:41 +00:00
Roland Knall aca0c5d175 Qt: Remove unrequired setTab
setTab(0) should not be required, as this belongs in the constructor as being
part of the general setup of the dialog itself. Outside code should not setup
the correct startview of the dialog.

(the problem exists in the first place, as the wrong tab may be selected via
the .ui file after editing that)
2022-04-22 17:05:29 +00:00
Roland Knall b9b1494cd1 Qt: Disable sorting for if acticity on default
Make the sorting for interface activity disabled by default
and enable it for interfaceFrame.
2022-04-22 14:29:17 +02:00
Roland Knall 374c5997da Qt: Remove unnecessary signal/slot
getPoints never worked in the new system therefore it is removed. SparkLineDelegate uses the underlying model to ensure the correct data being transmitted
2022-04-22 09:37:10 +00:00
Gerald Combs 4bb16383a3 macOS: Require Sparkle 2.
Remove our Sparkle 1 code. Fixes #18035.
2022-04-21 17:54:27 +00:00
Roland Knall 1278af07c3 Qt: Improve UIX for sparklines
Sparklines should display to the user, which interfaces are active
and ready for capture. Additionally it should be easy to find active
interfaces, without filtering first.

This change reorders the interface list, in order to sort active
interfaces on top, as well as hide information if no packet has been
received on that interface, to ensure that the user can find active
interfaces faster, making it easier to capture on systems where
the interfaces have very generic names.

The interface context menu has been amended to allow interfaces to be
hidden/unhidden from the main interface list as well
2022-04-21 15:41:12 +00:00
John Thacker d6fb90ecab proto_hier_stats: Skip non-protocols and reduce recursive calls
Skip non protocols in process_tree before calling process_node(), and
in process_node() before calling itself recursively, instead of at
the beginning of process_node(), decreaing the number of recursive
calls.

This reduces possible stack overflows in cases arising from dissectors
that call proto_item_get_parent(), which can result in many top level
non protocol items due to items not properly being faked. (#8069)

Use proto_register_is_protocol for the test instead of testing for
a name, which has not been a useful test for some time.

Add some comments about possibly wanting to skip PINOs that have
field_type FT_BYTES if they end up being toplevel items, and about
possibly wanting to descend into the tree to pick up protocols not
at the top level.
2022-04-21 08:56:12 -04:00
John Thacker 13075b4ff0 Require Qt 5.9 or later
Increase the minimum required version of Qt from 5.6 to the next
LTS version, 5.9. The various Linux distributions that have not
released an update to 5.9 or later (SLES 12, Debian stretch) are
nearing end of support, and can be supported by the Wireshark 3.6 LTS
release.

Qt 5.9 requires macOS 10.0, so make that the minimum macOS version
as well.

Remove unneeded version checks (except from QCustomPlot).
2022-04-20 18:59:32 -04:00
Gerald Combs 87b0288b8d epan: Add the ability to add conversation filter protocols.
Convert our conversation protocols to a dynamic list and add
add_conversation_filter_protocol(). Use it in the Falco Bridge plugin to
add protocols with conversation filters.
2022-04-19 22:25:32 +00:00
Roland Knall 27f6fd6f9a iface_lists: fix resource leak
Fixes CID 1504178 resource leak for ip_str
2022-04-19 15:37:21 +00:00
John Thacker ea62d7d6fa hierarchy stats: Don't add text only fields to the hierarchy
Use proto_registrar_is_protocol instead of directly comparing
hfinfo->parent to -1 when determining if the field info is related
to a protocol or not.

This avoids adding the special case text only field, which does not
have a parent protocol id, to the protocol hierarchy. These fields are
merely strings on the GUI tree, not actual protocols.
2022-04-19 11:03:37 +00:00
Roland Knall 2d48d49524 Allow to filter interface types
Allow to only use interface types, that are allowed by the implementing applications.
2022-04-19 09:19:50 +00:00
Gerald Combs fea6591b0c macOS: Add support for Sparkle 2.
Sparkle 2 deprecated the sharedUpdater singleton, so create our own
which uses Sparkle 2's updated API. Ping #18035.

Update our CMake version check.
2022-04-18 18:57:43 +00:00
Gerald Combs bce8825df8 [Automatic update for 2022-04-17]
Update manuf, services enterprise numbers, translations, and other items.
2022-04-17 16:37:54 +00:00
John Thacker a372497a85 hierarchy stats: Include appendix length in byte counts
The byte counts in Protocol Hierarchy Stats should include
the appendix length. Fix #17913.
2022-04-14 12:26:04 +00:00
Gerald Combs bcc286f341 UI: Rename the qt_logwolf directory to logwolf.
We might want to split the Wireshark-specific UI code into ui/wireshark,
but that can be done at another time.
2022-04-12 19:37:30 +00:00
Gerald Combs ca04f4c8cb Qt: Update our dynamic menu groups.
Add log-specific statistics groups, and use them to limit the dynamic
menu items in Wireshark and Logwolf.
2022-04-12 12:14:03 -07:00
John Thacker 7a3c2252f5 hierarchy stats: Only increment the total packet count once per frame
The same hierarchy of protocols can appear multiple times in a frame,
for example if there are multiple PDUs for a protocol that begin in
that frame. Keep track of the last frame where we incremented our
stat node and use that to only increment it once per frame.

Add a "total number of PDUs with this hierarchy" statistic and
display it as a new final column in the GUI. Update the User Guide.

In the purpose of doing this, get rid of temporary variables and
increment the ph_stats_t members directly, since we pass that
into our functions already, and thus have access to the current
packet count.

Fix #17553. Fix #18034. Fix #12565.
2022-04-12 13:38:33 +00:00
Gerald Combs fb3bdffaba Logwolf: Remove a bunch of packet-specific menu items.
Remove the following statistics and utility menu items and dialogs:

- 29West / lbmr
- ANCP
- BACnet / BACapp
- Credentials
- DCCP
- DNS
- Firewall rules
- HART-IP
- HPFEEDS
- HTTP
- HTTP2
- QUIC
- RSerPool
- SOME/IP
- Sametime
- Service response time
- TCP
- UDP
- UDP Multicast
2022-04-11 19:10:01 +00:00
Gerald Combs 4b556d6bc6 Qt+epan: Get log conversation filters working.
In conversation_filter.h, add a separate log_conv_filter_list. Use it in
register_log_conversation_filter and add conversation_filter_from_log.
It looks like we no longer use find_conversation_filter externally, so
remove it from the API.
2022-04-11 17:26:50 +00:00
Gerald Combs 58e31a2e77 Qt: Try to fix missing translations.
After splitting MainWindow into WiresharkMainWindow and
LogwolfMainWindow, a bunch of translations were marked "vanished". Do
the following in an attempt to restore them:

$ grep -c vanished ui/qt/*.ts
ui/qt/wireshark_de.ts:534
ui/qt/wireshark_en.ts:7
ui/qt/wireshark_es.ts:407
ui/qt/wireshark_fr.ts:367
ui/qt/wireshark_it.ts:534
ui/qt/wireshark_ja_JP.ts:534
ui/qt/wireshark_pl.ts:414
ui/qt/wireshark_ru.ts:513
ui/qt/wireshark_sv.ts:526
ui/qt/wireshark_tr_TR.ts:534
ui/qt/wireshark_uk.ts:264
ui/qt/wireshark_zh_CN.ts:455

$ git checkout 1c9538624f^ -- ui/qt/*.ts

$ sed -i -e 's,<name>MainWindow</name>,<name>WiresharkMainWindow</name>,g' ui/qt/*.ts

[ comment out `tx pull -f` in tools/update-tx ]

$ ./tools/update-tx -n

$ grep -c vanished ui/qt/*.ts
ui/qt/wireshark_de.ts:7
ui/qt/wireshark_en.ts:7
ui/qt/wireshark_es.ts:0
ui/qt/wireshark_fr.ts:5
ui/qt/wireshark_it.ts:7
ui/qt/wireshark_ja_JP.ts:7
ui/qt/wireshark_pl.ts:6
ui/qt/wireshark_ru.ts:7
ui/qt/wireshark_sv.ts:7
ui/qt/wireshark_tr_TR.ts:7
ui/qt/wireshark_uk.ts:2
ui/qt/wireshark_zh_CN.ts:6

$ ./tools update-tx

[ uncomment `tx pull -f` in tools/update-tx ]
2022-04-11 17:01:17 +00:00
Gerald Combs 1c9538624f [Automatic update for 2022-04-10]
Update manuf, services enterprise numbers, translations, and other items.
2022-04-10 19:23:47 +00:00
Gerald Combs 73770c61b4 Qt: Add a null pointer check.
Don't assume the main window has an SCTP menu.
2022-04-08 19:57:13 +00:00
Chuck Craft 6e9b19dcb0 Qt: only Show/Export Packet Bytes when field is selected and has_packet_bytes
This will also exclude generated [] and Lua added fields.
2022-04-08 18:47:42 +00:00
Gerald Combs c5da4f661a Logwolf: Fix building on Windows.
Add a couple of missing resource files. Fix a couple of paths.
2022-04-07 23:28:54 +00:00
Jirka Novak 411b3c1d78 Fix: Fixed issue with deadlock when same RTP dialog opened twice
RTP dialogs can stay opened, therefore calls of its functions are
protected by locks. There was issue that same mutex was used during
construction of the dialog and calling functions. It created possible
deadlock.
Change separates lock used for dialog creation and lock for function calls.
When function call lock is locked, new calls are ignored and warning is
printed to STDERR. Showing a dialog with warning looks too intrusive to me.

Fixes #18025
2022-04-06 07:16:59 +00:00
Gerald Combs 5971fcb941 Qt: Remove some unused code. 2022-04-04 21:05:17 +00:00
Gerald Combs 9ec6b50027 Rename ui/qt_logshark to ui/qt_logwolf. 2022-04-04 09:39:27 -07:00
Gerald Combs b153f040fc Qt: Start renaming Logshark to Logwolf.
Rename LogsharkApplication to LogwolfApplication. Rename other Logshark
references in ui/qt_logshark to Logwolf. Update our CMake target and
variable names.
2022-04-04 09:39:27 -07:00
Gerald Combs 3086774fa6 wsutil: Add configuration namespaces.
Rename init_progfile_dir to configuration_init. Add an argument which
specifies our configuration namespace, which can be "Wireshark"
(default) or "Logwolf".
2022-04-04 09:39:27 -07:00
Gerald Combs 6d2ab6900f Qt: Dynamically set our "Welcome to" banner in WelcomePage. 2022-04-04 09:39:27 -07:00
Gerald Combs dceffb8e56 Qt: Remove telephony and wireless code from Logwolf.
Remove the Telephony menu and associated code and dependencies from
LogWolf. Remove the remaining wireless code as well.
2022-04-04 09:39:27 -07:00
Gerald Combs d8008cb89e Qt: Split MainWindow into WiresharkMainWindow and LogwolfMainWindow.
Rename the main_window class and UIC files to wireshark_main_window and
the MainWindow class to WiresharkMainWindow. Copy wireshark_main_window
/ WiresharkMainWindow to logwolf_main_window / LogwolfMainWindow.

Remove the Wireless menu from Logwolf.
2022-04-04 09:39:27 -07:00
Gerald Combs 80de95ca71 Qt: Split MainApplication out from WiresharkApplication.
Move WiresharkApplication.{cpp,h} to MainApplication.{cpp,h}. Add back
WiresharkApplication as a thin superclass of MainApplication, similar to
LogsharkApplication. Change all of our wsApp references to mainApp. We
will likely have to change many or most of them back, but that's a
commit for another time.
2022-04-04 09:39:27 -07:00
Gerald Combs 245f988e9e Logshark: Add initial UI.
Add a separate UI application named "Logshark". It's currently a very
thin superclass of Wireshark, but that will change over time. Based on
work by Loris Degioanni.
2022-04-04 09:39:26 -07:00
Gerald Combs 2fdf85c6eb Create Wireshark and Logshark info plists.
Rename Info.plist.in to WiresharkInfo.plist.in and copy it to
LogsharkInfo.plist.in.
2022-04-04 09:39:26 -07: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
Jirka Novak 8b737033b0 RTP Analysis dialog: Update statistics when data are processed
Fixes #18018
2022-03-31 19:25:10 +00: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
Gerald Combs c805c0c16e Qt: Fix an about box signal and use new-style connections.
Fix

 ** (wireshark:77415) 10:53:35.149736 [GUI WARNING] -- QObject::connect: No such signal QComboBox::currentIndexChanged(QString) in ui/qt/about_dialog.cpp:352
 ** (wireshark:77415) 10:53:35.149760 [GUI WARNING] -- QObject::connect:  (sender name:   'cmbType')

Use new-style connections everywhere in about_dialog.cpp.
2022-03-27 18:19:37 +00:00
Gerald Combs b05a149acd [Automatic update for 2022-03-27]
Update manuf, services enterprise numbers, translations, and other items.
2022-03-27 16:53:18 +00:00
Gerald Combs e9a7f8c9e0 Qt: Fix some QCustomPlot Qt 6 warnings. 2022-03-27 14:35:55 +00:00
Gerald Combs 067b3805b7 Qt: Add float suffixes.
Fix

ui\qt\packet_list.cpp(2101,33): warning C4305: 'argument': truncation from 'double' to 'float' [c:\Users\gerald\Development\wireshark\build\ui\qt\qtui.vcxproj]
    ui\qt\packet_list.cpp(2101,33): warning C4305:         tick_color.setAlphaF(0.3); [c:\Users\gerald\Development\wireshark\build\ui\qt\qtui.vcxproj]
    ui\qt\packet_list.cpp(2101,33): warning C4305:         ^ [c:\Users\gerald\Development\wireshark\build\ui\qt\qtui.vcxproj]
2022-03-25 13:36:07 -07:00
Gerald Combs bcd3d05a3e Qt: Fix more Qt6-related warnings. 2022-03-25 12:48:01 -07:00
Roland Knall f0e4cedd69 Qt: Fix most of Qt6 compile warnings and issues 2022-03-25 11:16:18 -07:00
Gerald Combs f8d3ebe0e2 Qt: Handle qsizetype.
Qt 5.10 added qsizetype, aka an ssize_t and Qt 6 makes extensive use of
it. Add a compatibility typedef and use it where we can. Cast it away
where we can't.
2022-03-25 16:51:55 +00:00
Gerald Combs de0db2ad0a Qt: QVariant::type() is deprecated in Qt6.
Fix

ui/qt/rtp_stream_dialog.cpp:708:26: error: 'type' is deprecated: Use typeId() or metaType(). [-Werror,-Wdeprecated-declarations]
            } else if (v.type() == QVariant::String) {
                         ^

and similar errors. Although the warnings recommend typeId() or
metaType(), userType() exists in both Qt 5 and 6 so use it instead.
2022-03-23 09:30:49 +00:00