metze/wireshark/wip.git
4 years agossl-utils: Fix parsing pre-master-secrets in keylog-file
Gergely Nagy [Mon, 12 Oct 2015 14:23:31 +0000 (16:23 +0200)]
ssl-utils: Fix parsing pre-master-secrets in keylog-file

With "PMS_CLIENT_RANDOM xxxx yyyy" lines, only 32 byte long pre-master
secrets could be entered, but they are 48 byte long for RSA and can be
of any length for DHE cipher suites.

When a line had the "RSA xxxx yyyy" format then yyyy was previously
parsed with the <master_secret> regex group but it contains
the pre-master secret, so now it is parsed with the <pms> group.
This didn't cause a functional issue for RSA, but it couldn't be used
where the pre-master secret isn't 48 byte long.

After this change the regex will accept everything that was previously
working.

Change-Id: I71f43f3e9977a5e98758f387ad69893e8be0e27a
Reviewed-on: https://code.wireshark.org/review/10923
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
4 years agoqt: add missing initializers (CID 1325722)
Dario Lombardo [Mon, 12 Oct 2015 16:55:04 +0000 (18:55 +0200)]
qt: add missing initializers (CID 1325722)

Change-Id: Ie1ed72fe2efe31db1ce5b73ac6e659ba305f4001
Reviewed-on: https://code.wireshark.org/review/10961
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoQt: Recent list context menu.
Gerald Combs [Fri, 9 Oct 2015 20:56:27 +0000 (13:56 -0700)]
Qt: Recent list context menu.

Add a context menu to the main window recent list. Add items that let
the user open each file's containing folder and copy the file path to
the clipboard. When opening the folder on Windows and OS X try to
highlight the file in Explorer or the Finder.

Change-Id: I991e8df8ba9f1f8c6385d1a861eb40223cfdd047
Reviewed-on: https://code.wireshark.org/review/10915
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
4 years agobtatt: clear variable (CID 1268204)
Dario Lombardo [Mon, 12 Oct 2015 15:48:55 +0000 (17:48 +0200)]
btatt: clear variable (CID 1268204)

Change-Id: Id4d057d730899fac14146845a530fae2525ba965
Reviewed-on: https://code.wireshark.org/review/10955
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
4 years agoinet_v6def : fix warning: redundant redeclaration of 'inet_pton' [-Wredundant-decls]
Alexis La Goutte [Mon, 12 Oct 2015 07:57:29 +0000 (09:57 +0200)]
inet_v6def : fix warning: redundant redeclaration of 'inet_pton' [-Wredundant-decls]

Change-Id: I937a65378a62be50d3d0d2f4a049b8cd73c8875c
Reviewed-on: https://code.wireshark.org/review/10951
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoUse system highlight+hover colors in the welcome screen.
Gerald Combs [Mon, 12 Oct 2015 16:20:14 +0000 (09:20 -0700)]
Use system highlight+hover colors in the welcome screen.

Don't override the highlight and hover colors in the recent file list in
the main welcome screen. This appears to be a leftover from the
pre-g8b24471 layout.

Change-Id: Ia5239424340632f53f41f7f3067c798c882c069d
Reviewed-on: https://code.wireshark.org/review/10957
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoAdd BASE_PT_ types to proto_registrar_dump_fields()
João Valverde [Sun, 11 Oct 2015 16:51:40 +0000 (17:51 +0100)]
Add BASE_PT_ types to proto_registrar_dump_fields()

Change-Id: Ic6b3d71c3c9a14688b55d98f402d359f69524394
Reviewed-on: https://code.wireshark.org/review/10939
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoIPv6: Make extension headers filterable
João Valverde [Wed, 30 Sep 2015 14:30:33 +0000 (15:30 +0100)]
IPv6: Make extension headers filterable

Change-Id: I8d36dbbe255a58b3ca1e4059a15e993155ca9ba1
Reviewed-on: https://code.wireshark.org/review/10708
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoRTP player: Always include QPushButton.
Gerald Combs [Mon, 12 Oct 2015 17:15:09 +0000 (10:15 -0700)]
RTP player: Always include QPushButton.

It looks like QPushButton gets included via ui_rtp_player_dialog.h in Qt
5 but not in Qt 4. Make sure we include it explicitly whether or not
QT_MULTIMEDIA_LIB is defined.

Change-Id: I8203a1cc6f7b9beef0f749b93836a75885f85edd
Reviewed-on: https://code.wireshark.org/review/10962
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoTry to fix wireless toolbar behavior on Linux.
Gerald Combs [Fri, 9 Oct 2015 22:19:45 +0000 (15:19 -0700)]
Try to fix wireless toolbar behavior on Linux.

Split interface get and set activity into explicit getInterfaceInfo and
setInterfaceInfo member functions. Make sure we connect to QComboBox
"activated" signals (which are only triggered by user activity)
instead of "currentIndexChanged" signals (which are triggered on
any change). Hopefully this will make the wireless toolbar read-only
until the user selects a combobox item.

Bug: 11487
Change-Id: I236ff3f5972b0b7d543f21bb955d7892190a7814
Reviewed-on: https://code.wireshark.org/review/10918
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoextcap: fix a bug in create_tempfile() return check (CID 1323930)
Dario Lombardo [Sat, 10 Oct 2015 22:07:33 +0000 (00:07 +0200)]
extcap: fix a bug in create_tempfile() return check (CID 1323930)

Change-Id: Ifacdfee5c12e676969cfe536dfeda2be93426a46
Reviewed-on: https://code.wireshark.org/review/10929
Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
Petri-Dish: Michal Labedzki <michal.labedzki@tieto.com>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoFix hfinfo_*_format_display() for BASE_PT_ display types
João Valverde [Sun, 11 Oct 2015 13:15:20 +0000 (14:15 +0100)]
Fix hfinfo_*_format_display() for BASE_PT_ display types

Change-Id: I1a2a988a737c6821db6ac3a2b9ee9ff48add28c2
Reviewed-on: https://code.wireshark.org/review/10935
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoTry to fix OS X buildbot but using a different QBrush constructor in the cases that...
Martin Mathieson [Mon, 12 Oct 2015 08:35:18 +0000 (01:35 -0700)]
Try to fix OS X buildbot but using a different QBrush constructor in the cases that were failing (where implicit conversion seems to be failing)

Change-Id: Id0393c2403ed953579c7d571e9880849b7dff8b3
Reviewed-on: https://code.wireshark.org/review/10952
Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
4 years agoInclude <stdlib.h> to declare exit().
Guy Harris [Mon, 12 Oct 2015 07:45:18 +0000 (00:45 -0700)]
Include <stdlib.h> to declare exit().

Also, flag the exit() call as a Bad Idea, as is done in some other tap
files.

Change-Id: I4e077f5923bb36ed9c8b34aff3dda6d44b2b8721
Reviewed-on: https://code.wireshark.org/review/10950
Reviewed-by: Guy Harris <guy@alum.mit.edu>
4 years agoNTP: fix dissection of SHA1 based message authentication code
Pascal Quantin [Sun, 11 Oct 2015 12:58:19 +0000 (14:58 +0200)]
NTP: fix dissection of SHA1 based message authentication code

The maximum MAC length is 160 bits, not 128. MAX_MAC_LEN can be safely
increased as an extension should be > 4 bytes.

Bug: 11580
Change-Id: I0ea5a1f85d644e57315f033f09241d7a79dd3a45
Reviewed-on: https://code.wireshark.org/review/10934
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoGet rid of a void * in frame_data.
Gerald Combs [Fri, 9 Oct 2015 18:45:35 +0000 (11:45 -0700)]
Get rid of a void * in frame_data.

Forward-declare struct _color_filter and use it in struct _frame_data.

Change-Id: I4543206bc71ad1e088b60347e6deb6d87a573b35
Reviewed-on: https://code.wireshark.org/review/10914
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoRemove duplicate transport ports from proto tree summary
João Valverde [Mon, 5 Oct 2015 12:51:58 +0000 (13:51 +0100)]
Remove duplicate transport ports from proto tree summary

Don't display duplicate ports if transport name resolution is not
enabled (for UDP/TCP/DCCP).

Also introduce col_append_port() to handle info column port display
with name resolution in a uniform format.

Change-Id: Icb8ac45f726b7c539b4534c62061473e9b582753
Reviewed-on: https://code.wireshark.org/review/10804
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoIPv6: Don't call expert info under if(tree) (for options)
João Valverde [Fri, 9 Oct 2015 07:22:29 +0000 (08:22 +0100)]
IPv6: Don't call expert info under if(tree) (for options)

Change-Id: I94f096a0ca487311d44a03e4183732db015605b2
Reviewed-on: https://code.wireshark.org/review/10896
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoBack out the verbose Makefile stuff.
Guy Harris [Sun, 11 Oct 2015 23:43:41 +0000 (16:43 -0700)]
Back out the verbose Makefile stuff.

I give up.  I don't know whether this all means our build mechanism is
too fragile, our code is to fragile, autotools are too fragile, the
compilers we're using are too fragile, Qt is too fragile, or C++ is too
fragile, but if the build breaks that easily, maybe we should just give
up on Leopard.

Change-Id: If700d928da95d09ed5173b976261e4ddd236d654
Reviewed-on: https://code.wireshark.org/review/10946
Reviewed-by: Guy Harris <guy@alum.mit.edu>
4 years agoOn 10.5, don't set GTK+ etc. versions if we haven't already set them.
Guy Harris [Sun, 11 Oct 2015 23:38:36 +0000 (16:38 -0700)]
On 10.5, don't set GTK+ etc. versions if we haven't already set them.

When building for 10.5, if the version numbers of GTK+ and its support
libraries haven't been set, don't override the settings to get older
versions; that way, if you've changed macosx-setup.sh not to bother
installing GTK+, this won't force it to be installed.

Change-Id: Ia05f45fb6bd469b568a28a8769f3130a99180d7e
Reviewed-on: https://code.wireshark.org/review/10945
Reviewed-by: Guy Harris <guy@alum.mit.edu>
4 years agoLTE RLC graphs - initial version
Martin Mathieson [Sat, 10 Oct 2015 22:53:45 +0000 (15:53 -0700)]
LTE RLC graphs - initial version

Change-Id: Ic5f2c353ae1f787ac19cb575a938cb093ff5f6dc
Reviewed-on: https://code.wireshark.org/review/10930
Petri-Dish: Martin Mathieson <martin.r.mathieson@googlemail.com>
Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
4 years agoHandle installing Qt 4.x.
Guy Harris [Sun, 11 Oct 2015 21:35:47 +0000 (14:35 -0700)]
Handle installing Qt 4.x.

Or, at least, 4.8.6.  I guess they had to do an updated build or
something, as the actual dmg has "4.8.6-1", so handle that extra
versioning.

Clean up some white space while we're at it.

Change-Id: I62b99dd99e7e5cb84cca68bdc59b02e4bf65411f
Reviewed-on: https://code.wireshark.org/review/10943
Reviewed-by: Guy Harris <guy@alum.mit.edu>
4 years ago[Automatic update for 2015-10-11]
Gerald Combs [Sun, 11 Oct 2015 15:12:30 +0000 (08:12 -0700)]
[Automatic update for 2015-10-11]

Update manuf, services enterprise-numbers, translations, and other items.

Change-Id: Ic021a6b14deb368b9b6ee77995291c92de75426d
Reviewed-on: https://code.wireshark.org/review/10936
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoAllow TURN channeldata to be padded on both UDP and TCP.
Philipp Hancke [Thu, 8 Oct 2015 19:55:22 +0000 (12:55 -0700)]
Allow TURN channeldata to be padded on both UDP and TCP.
Microsoft's Edge browser does this, UDP padding is a MAY in https://tools.ietf.org/html/rfc5766#section-11.5

Bug: 11584
Change-Id: I513638d8a3eb257576af3cfc8e6b81cc93b22d05
Reviewed-on: https://code.wireshark.org/review/10889
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
4 years agoTemporarily make cmake builds verbose, for debugging purposes.
Guy Harris [Sun, 11 Oct 2015 04:57:03 +0000 (21:57 -0700)]
Temporarily make cmake builds verbose, for debugging purposes.

Try to figure out why CMake builds work on the 32-bit OS X buildbot but
autotools builds don't; either the compiler commands are different in
ways that break the autotools build, or the config.h files are different
in ways that break the autotools build, or magic pixies affect the
builds in different ways that only break the autotools build.

Change-Id: Id24bad04ff8ef755e4966e28fd445c2ab05c6913
Reviewed-on: https://code.wireshark.org/review/10931
Reviewed-by: Guy Harris <guy@alum.mit.edu>
4 years agoIPv6: Set destination address for RPL routing header
João Valverde [Fri, 9 Oct 2015 09:10:31 +0000 (10:10 +0100)]
IPv6: Set destination address for RPL routing header

Change-Id: I5d83370424cc0002a0bf965138b7fbdad69557fb
Reviewed-on: https://code.wireshark.org/review/10895
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoScan into a guint32 using %u.
Gerald Combs [Fri, 9 Oct 2015 23:55:56 +0000 (16:55 -0700)]
Scan into a guint32 using %u.

Change-Id: Ic0fa25f3ad78e2a1923610a17f764e1b0623eabc
Reviewed-on: https://code.wireshark.org/review/10919
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoQt: Horizontal- and vertical-only zoom modifier keys for IO and TCP Stream graphs.
Jim Young [Fri, 9 Oct 2015 05:19:21 +0000 (01:19 -0400)]
Qt: Horizontal- and vertical-only zoom modifier keys for IO and TCP Stream graphs.

Use lower case "x" or upper case "X" (Shift-X) to zoom in or out respectively only
the horizontal (X) axis.  Use lower case "y" or upper case "Y" (Shift-Y) to zoom
in or out respectively only the vertical (Y) axis.

Change-Id: I2f4de3c81795c289a626cc917d46ec0b1d620f49
Reviewed-on: https://code.wireshark.org/review/10894
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoSupport in 6lowpan for RFC4944 address generation
Pedro Jose Marron [Fri, 9 Oct 2015 12:59:37 +0000 (14:59 +0200)]
Support in 6lowpan for RFC4944 address generation

For the conversion of a 16-bit short address in 6lowpan to an IID, there
are several RFCs that produce different results. RFC 4944 section 6
specifies that the conversion uses the given PAN ID and the 16-bit short
address. RFC 6282, on the other hand, specifies thta the conversion only
uses the 16-bit short address and no longer uses the PAN ID.

The current version of the 6lowpan dissector supports only the newer RFC
6282, but there are protocols out there that assume that the address
conversion still abides to RFC 4944.

In order to support these protocols and following the discussion from

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8970

this patch introduces a boolean preference in the 6lowpan dissector that
indicates whether or not the older RFC 4944 should be used for address
conversion. By default, it is set to FALSE, thus leaving the behavior of
the dissector unchanged.

Besides the boolean preference, another helper function
lowpan_addr16_with_panid_to_ifcid has been written that implements the
expected behavior from RFC 4944 using the same hint mechanism already in
place in the dissector for the support of RFC 6282.

Change-Id: I8d202c69a225d7b1212080a174e0111e5203553c
Reviewed-on: https://code.wireshark.org/review/10902
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoDisplay of reserved octet in 6lowpan IPHC header
Pedro Jose Marron [Fri, 9 Oct 2015 15:13:49 +0000 (17:13 +0200)]
Display of reserved octet in 6lowpan IPHC header

The 6lowpan standard specifies a reserved octet in the extended header
of an IP_PROTO_FRAGMENT packet in the same place used for the header
length for other extension headers.

The current version of the 6lowpan dissector displays the reserved octet
and the rest of the header (6 more bytes) together as data, as opposed to
displaying the reserved octet by itself and then the data (using the
data dissector).

This patch does not change the functionality of the dissector in any
way, only how the 7 bytes are displayed. Instead of displaying the
header information and then 7 bytes of data, it displays the reserved
octet and then the data. This is also consistent with the way the ipv6
dissector displays it (showing the reserved octet and its value).

For this purpose, there is a new hf (hf_6lowpan_nhc_ext_reserved) and
the corresponding proto_tree calls. Also, depending on the type of
extension header, the octets sent to the general data dissector are
shifted by one.

Change-Id: I4c7fb58a3364307e79517b979808f3e34a2e0b94
Reviewed-on: https://code.wireshark.org/review/10908
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agonstime: fix -Wshift-negative-value
Peter Wu [Wed, 7 Oct 2015 13:48:46 +0000 (15:48 +0200)]
nstime: fix -Wshift-negative-value

Even if the result of the negative shift (in TIME_T_MIN) is not used
because the signedness check happens before, it still causes a
compile-time warning. Fix this by shifting on an unsigned value, then
truncate by casting it.

While at it, remove a "fix for broken SCO compiler", it might not apply
to us (fingers crossed).

Change-Id: Id9603149d8063e9eaaa65cf028323f10e60a6c42
Reviewed-on: https://code.wireshark.org/review/10862
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
4 years agoMake sure we can compile without QtMultimedia.
Gerald Combs [Thu, 8 Oct 2015 21:56:06 +0000 (14:56 -0700)]
Make sure we can compile without QtMultimedia.

Change-Id: I8db453a735956435fc6e2e4276961adb1f7ed11a
Reviewed-on: https://code.wireshark.org/review/10892
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoasn1.c: fix printf arguments used with DEBUG flag
Pascal Quantin [Fri, 9 Oct 2015 13:45:41 +0000 (15:45 +0200)]
asn1.c: fix printf arguments used with DEBUG flag

Bug: 11581
Change-Id: If960e45d5ed71abb3cadcb6dd83832b9098e11a7
Reviewed-on: https://code.wireshark.org/review/10904
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoAdd WS_DLL_PUBLIC for Address Type Registration
Pedro Jose Marron [Fri, 9 Oct 2015 09:48:35 +0000 (11:48 +0200)]
Add WS_DLL_PUBLIC for Address Type Registration

Dissectors developed as plugins in wireshark that create new address
types require the use of address_type_dissector_register. Without
WS_DLL_PUBLIC, the function is not found when loading the plugin and
wireshark refuses to initialize it.

This very simple patch fixes this problem.

Change-Id: I8594a7be525830dd4ab9e1b3ea633aac0a07938a
Reviewed-on: https://code.wireshark.org/review/10899
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
Petri-Dish: Balint Reczey <balint@balintreczey.hu>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoNow that we're using AC_PROG_CC_STDC, let it handle HP C.
Guy Harris [Fri, 9 Oct 2015 15:39:27 +0000 (08:39 -0700)]
Now that we're using AC_PROG_CC_STDC, let it handle HP C.

AC_PROG_CC_STDC should be setting whatever flags are needed for ISO C
plus extensions, including requesting C99 if available.  Don't set -Ae
ourselves for HP C.

Change-Id: Icd4dfc0c2078586d5773075ee25c40bfc787a482
Reviewed-on: https://code.wireshark.org/review/10910
Reviewed-by: Guy Harris <guy@alum.mit.edu>
4 years agoairpdcap: add free_key_string function, fix memleaks
Peter Wu [Wed, 7 Oct 2015 12:24:56 +0000 (14:24 +0200)]
airpdcap: add free_key_string function, fix memleaks

Do not leak the key and SSID. Note that there are still some leaks in
the GTK UI related to get_wireshark_keys(), but I did not track them
down.

Caught by LeakSanitizer.

Change-Id: I639166e6ea457605d6ae0ebd58e56d7594a7b7db
Reviewed-on: https://code.wireshark.org/review/10860
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
4 years agoWSP: Fix add_addresses()
João Valverde [Mon, 5 Oct 2015 23:04:26 +0000 (00:04 +0100)]
WSP: Fix add_addresses()

Change-Id: I25d84c725559f5f077dcc03fb425a89d87e90f55
Reviewed-on: https://code.wireshark.org/review/10897
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoFTP: Fix EPRT IPv6 set address
João Valverde [Mon, 5 Oct 2015 22:48:04 +0000 (23:48 +0100)]
FTP: Fix EPRT IPv6 set address

Change-Id: I944b3e6667027b251d0f3d894294bfda331abce2
Reviewed-on: https://code.wireshark.org/review/10898
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agocatapult_dct2000: code restyle
Dario Lombardo [Tue, 6 Oct 2015 11:55:07 +0000 (13:55 +0200)]
catapult_dct2000: code restyle

Remove a clang 3.7 complain.

Change-Id: I5237b130dcd0ffd3a4ea61a3c98fa344fddbe633
Reviewed-on: https://code.wireshark.org/review/10834
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
4 years agoThe second argument to AC_PATH_PROGS is a list of program names.
Guy Harris [Thu, 8 Oct 2015 20:43:08 +0000 (13:43 -0700)]
The second argument to AC_PATH_PROGS is a list of program names.

The *third* argument is the value to use if we don't find the program;
we shouldn't fall back on "python3" if we can't find "python", we should
try both "python" and "python3" and just set $PYTHON to nothing if we
don't find either one.

Change-Id: I5168455f09bc3165c49db4334f05856dec46bf62
Reviewed-on: https://code.wireshark.org/review/10890
Reviewed-by: Guy Harris <guy@alum.mit.edu>
4 years agoQt: Add a play button to the RTP Stream Analysis dialog.
Gerald Combs [Thu, 8 Oct 2015 18:31:42 +0000 (11:31 -0700)]
Qt: Add a play button to the RTP Stream Analysis dialog.

Rename the "Play Call" button to "Play Streams". Move the button
creation code to a common routine. Use it to add a "Play Streams" button
to the RTP Stream Analysis, similar to the GTK+ UI.

Don't restrict RTP to IPv[46] as suggested by Michal. I don't have any
RTP-over-Bluetooth captures so I can't test this directly.

Change-Id: I4703cac1d5bf5b3ff0255d36da2c5164feb0547d
Reviewed-on: https://code.wireshark.org/review/10888
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoGTPv2: display Sequence Number as BASE_HEX_DEC
Pascal Quantin [Thu, 8 Oct 2015 17:37:46 +0000 (19:37 +0200)]
GTPv2: display Sequence Number as BASE_HEX_DEC

As requested on https://ask.wireshark.org/questions/46393/gtpv2-teid-and-sqn-decoded-in-decimal-instead-of-hexa-in-ws-1127

Change-Id: Id0963394959eff979129470c70258323653e3fdf
Reviewed-on: https://code.wireshark.org/review/10886
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoUDP: Fix forgotten column info
João Valverde [Thu, 8 Oct 2015 10:28:16 +0000 (11:28 +0100)]
UDP: Fix forgotten column info

Change-Id: I620d24c1a1cf7340d651e8840275759de860e5ef
Reviewed-on: https://code.wireshark.org/review/10881
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Evan Huus <eapache@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoDCCP: Fix destination port offset
João Valverde [Thu, 8 Oct 2015 11:51:10 +0000 (12:51 +0100)]
DCCP: Fix destination port offset

Regression introduced in ga459ac72

Change-Id: Ib69299280599b181f9068b3b81eb9fd74bb1d55d
Reviewed-on: https://code.wireshark.org/review/10882
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
4 years agoReplace or rename "duplicate" UDP protocols shown in Decode As
Michael Mann [Wed, 7 Oct 2015 17:50:11 +0000 (13:50 -0400)]
Replace or rename "duplicate" UDP protocols shown in Decode As

Change-Id: I8cfd1c223c70c7e03728af8b2f7cbf9354d7ad86
Ping-Bug: 3949
Reviewed-on: https://code.wireshark.org/review/10865
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoBlind attempt trying to fix CMake based installer
Pascal Quantin [Thu, 8 Oct 2015 05:48:50 +0000 (07:48 +0200)]
Blind attempt trying to fix CMake based installer

Looks like Petri-Dish does not generate it

Change-Id: I90823d82ac9d223d840ab20331a856550dffdc87
Reviewed-on: https://code.wireshark.org/review/10872
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoAdd USBPcapPage.ini file to distribution
Pascal Quantin [Thu, 8 Oct 2015 05:29:25 +0000 (07:29 +0200)]
Add USBPcapPage.ini file to distribution

Change-Id: I05ed2c561818fd4293543199063551dd65fb5c55
Reviewed-on: https://code.wireshark.org/review/10871
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoAdd USBPcap 1.1.0.0-g794bf26 to Windows installer
Pascal Quantin [Wed, 7 Oct 2015 21:27:17 +0000 (23:27 +0200)]
Add USBPcap 1.1.0.0-g794bf26 to Windows installer

Change-Id: Idb88cd41436e49b7a29bd4a8e896c92d8489318d
Reviewed-on: https://code.wireshark.org/review/10868
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoepl: fix bug in g_hash_table_lookup_extended() call (CID 1254382)
Dario Lombardo [Fri, 2 Oct 2015 15:43:47 +0000 (17:43 +0200)]
epl: fix bug in g_hash_table_lookup_extended() call (CID 1254382)

Change-Id: Iebf0fc5d3e86fba9a2ea4da5784256d820598e39
Reviewed-on: https://code.wireshark.org/review/10744
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoAdded ICE TCP Framing support to STUN dissector
Nils Ohlmeier [Thu, 24 Sep 2015 19:58:15 +0000 (12:58 -0700)]
Added ICE TCP Framing support to STUN dissector

Change-Id: I1dddb09cb1eebc3d23375aa9d2450731fa51cb90
Reviewed-on: https://code.wireshark.org/review/10643
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoqt: add initialization of variable (CID 1311960)
Dario Lombardo [Wed, 7 Oct 2015 15:00:51 +0000 (17:00 +0200)]
qt: add initialization of variable (CID 1311960)

Change-Id: I25bae2899f19982ee52c5ffb933a1459897b933b
Reviewed-on: https://code.wireshark.org/review/10864
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoNo RCS/CVS/SVN Ids any more.
Guy Harris [Thu, 8 Oct 2015 00:52:01 +0000 (17:52 -0700)]
No RCS/CVS/SVN Ids any more.

Change-Id: Ia9057a1851be17238c35094f14e847b387943186
Reviewed-on: https://code.wireshark.org/review/10869
Reviewed-by: Guy Harris <guy@alum.mit.edu>
4 years agoDon't just ask for C, ask for standard C - preferably C99.
Guy Harris [Wed, 7 Oct 2015 18:00:31 +0000 (11:00 -0700)]
Don't just ask for C, ask for standard C - preferably C99.

We're using some C99 features, such as variadic macros, so if there's a
compiler flag needed for C99 features, make sure it's supplied.  If the
compiler doesn't support standard C, complain.

Change-Id: I6fb18f5222567249370b3d43065f2258dbde7e4d
Reviewed-on: https://code.wireshark.org/review/10866
Reviewed-by: Guy Harris <guy@alum.mit.edu>
4 years agowslua: fix memleak in lua_prime_all_fields
Peter Wu [Wed, 7 Oct 2015 12:22:32 +0000 (14:22 +0200)]
wslua: fix memleak in lua_prime_all_fields

Would leak some bytes after startup.

Caught by LeakSanitizer.

Change-Id: I4644f204343ce5a803a7dfdedac6a1960882807f
Reviewed-on: https://code.wireshark.org/review/10859
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
4 years agoAMQP: Fix usage of p_(add|get)_proto_data.
Petr Gotthard [Tue, 6 Oct 2015 15:00:34 +0000 (17:00 +0200)]
AMQP: Fix usage of p_(add|get)_proto_data.

The p_(add|get)_proto_data() functions are used to store data related
to an AMQP frame. The stored information gets overwritten if there are
multiple small AMQP frames in one TCP/IP packet.

As suggested by Pascal and https://code.wireshark.org/review/#/c/10579/,
we should use tvb_raw_offset as key for p_(add|get)_proto_data().

Change-Id: I860df8af51a6fbbef495985747313ae96402cc5c
Reviewed-on: https://code.wireshark.org/review/10836
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoIPv6: add changes forgotten in gbedda9b
Pascal Quantin [Wed, 7 Oct 2015 06:11:57 +0000 (08:11 +0200)]
IPv6: add changes forgotten in gbedda9b

Bug: 11570
Change-Id: I5a8d89253becd550e0330c82ab0811c502db6d61
Reviewed-on: https://code.wireshark.org/review/10849
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoUpdate last updated DNS parameters (2015-07-26)
Alexis La Goutte [Tue, 6 Oct 2015 07:06:54 +0000 (09:06 +0200)]
Update last updated DNS parameters (2015-07-26)

* draft-ietf-dnsop-delegation-trust-maintainance-14 => RFC 7344

Update also DNS-Based Authentication of Named Entities (DANE) Parameters (
    2014-04-23) (no change)

Change-Id: I7aa7dddf8c26d2ea2ccb4a0533d835ce119737bd
Reviewed-on: https://code.wireshark.org/review/10825
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoDNS: Add DNS Cookie Option
Alexis La Goutte [Fri, 2 Oct 2015 10:00:04 +0000 (12:00 +0200)]
DNS: Add DNS Cookie Option

draft-ietf-dnsop-cookies-05.txt

Change-Id: Ife550d8fe0c6604329c78bb34e94276050148a8a
Reviewed-on: https://code.wireshark.org/review/10824
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agossl-utils: load RSA keys based on their modulus+exponent
Peter Wu [Sun, 4 Oct 2015 09:22:41 +0000 (11:22 +0200)]
ssl-utils: load RSA keys based on their modulus+exponent

Load RSA private keys based on their public key instead of relying on
the user to specify a valid address and port mapping. This is more
reliable and prepares for simplification of the SSL Keys dialog.

After this change, the "address" part of the UAT dialog will be ignored
when loading the private key. The port+protocol mapping is still
imported, but should probably be removed too.

Change-Id: I4d7a2bfcf63d17e66e336ef770759f20510fc176
Reviewed-on: https://code.wireshark.org/review/10766
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agossl-utils: simplify private key storage, fix resource leaks
Peter Wu [Sat, 3 Oct 2015 17:23:55 +0000 (19:23 +0200)]
ssl-utils: simplify private key storage, fix resource leaks

The certificate and GnuTLS private key are never used except for
reporting in the log file. Remove the unused certificate-related code
from the PKCS#12 file parsing. Report an immediate error instead of
opening key file if GnuTLS is disabled.

Made ssl_load_key and ssl_load_pkcs12 static, they are not used outside
the SSL dissector. If for some reason the PKCS#12 bag contains multiple
private keys, then the previous one would be overwritten (leaking
memory). Fix this by returning the first private key found.

Simplify key_hash (dtls_key_hash/ssl_key_hash) memory management, now
the table automatically frees keys/values when items are removed.

Fix memory leaks:
 - ssldecrypt_uat_fld_password_chk_cb: release ssl_load_pkcs12 memory.
 - ssl_load_key: avoid leaking gnutls_x509_privkey_t on error.
 - ssl_load_pkcs12: fix ssl_pkey leak on error path.

Change-Id: I5db6fecb0d74e5c78796392aeb17e3eb7985a2ef
Reviewed-on: https://code.wireshark.org/review/10764
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoUDP: Refactor some dissector code
João Valverde [Sat, 3 Oct 2015 22:27:49 +0000 (23:27 +0100)]
UDP: Refactor some dissector code

Add UDP length as a generated field of UDP-Lite subtree.

Change-Id: I35291cc5f5b2a8909a7124cbae8c39fc91d7751d
Reviewed-on: https://code.wireshark.org/review/10775
Reviewed-by: Evan Huus <eapache@gmail.com>
Petri-Dish: Evan Huus <eapache@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoRemove heur_dissector_set_enabled.
Michael Mann [Wed, 7 Oct 2015 02:23:19 +0000 (22:23 -0400)]
Remove heur_dissector_set_enabled.

With the adjustment to heur_dissector_add passing an enable/disable flag and "global" control of heuristic dissectors just like regular ones, this is no longer needed.

Change-Id: I2d433c7bff8353421eca31f8813992e38b716911
Reviewed-on: https://code.wireshark.org/review/10848
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoBGP: Add BGP-Extended Message Capability
Alexis La Goutte [Tue, 6 Oct 2015 07:28:13 +0000 (09:28 +0200)]
BGP: Add BGP-Extended Message Capability

From draft-ietf-idr-bgp-extended-messages
Update BGP Capability Codes to 2015-09-30

Change-Id: I2f3b44ad8ad7a9e5444cdfbfb22bf7d0538ffbfc
Reviewed-on: https://code.wireshark.org/review/10826
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoCMake: Don't clobber ZLIB_*.
Gerald Combs [Tue, 6 Oct 2015 20:29:14 +0000 (13:29 -0700)]
CMake: Don't clobber ZLIB_*.

On Windows we set a few (but not all) ZLIB_* variables, then depend on
FindZLIB to fill in the rest. Make sure FindZLIB doesn't unset everything
the first time we run CMake.

Bug: 11569
Change-Id: I199c83570c29343466b9ff63080b6a964dfd8d73
Reviewed-on: https://code.wireshark.org/review/10843
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoSCTP: fix dissection of DATA chunks
Pascal Quantin [Tue, 6 Oct 2015 21:28:38 +0000 (23:28 +0200)]
SCTP: fix dissection of DATA chunks

Regression introduced in gd52322e

Change-Id: I57baf53d81c7e95ea8ad15e4799033d341e4ee61
Reviewed-on: https://code.wireshark.org/review/10845
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoReport an error if we don't find fop and are going to try to use it.
Guy Harris [Tue, 6 Oct 2015 18:44:51 +0000 (11:44 -0700)]
Report an error if we don't find fop and are going to try to use it.

Change-Id: Ide5c43b797a2fa07c7d3c7f986d306a158d68c6b
Reviewed-on: https://code.wireshark.org/review/10840
Reviewed-by: Guy Harris <guy@alum.mit.edu>
(cherry picked from commit 6c45d217d9d4fbf2a4dbc17d0b92334e3bc93052)
Reviewed-on: https://code.wireshark.org/review/10841

4 years agoFix an I/O graph crash.
Gerald Combs [Tue, 6 Oct 2015 00:28:39 +0000 (17:28 -0700)]
Fix an I/O graph crash.

QTreeWidget::removeItemWidget calls QAbstractItemView::setIndexWidget,
which deletes the current item widget. As a result we shouldn't try to
delete itemWidgets ourselves.

Add a note explaining why we use hand-crafted item widgets instead of a
custom item delegate.

Bug: 11449
Change-Id: I485bacc0fae60ea3174e003ef0032948ee5c720f
Reviewed-on: https://code.wireshark.org/review/10820
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years ago[NSIP] Wrong offset used for proto_tree_add_bitmask() for the reset flag.
AndersBroman [Tue, 6 Oct 2015 09:00:41 +0000 (11:00 +0200)]
[NSIP] Wrong offset used for proto_tree_add_bitmask() for the reset flag.

Change-Id: Ica9ed514e593079ba4cb287d4165eb6e967ec903
Reviewed-on: https://code.wireshark.org/review/10833
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoopenSAFETY: Add Producer ID to info field
Roland Knall [Tue, 6 Oct 2015 08:00:54 +0000 (10:00 +0200)]
openSAFETY: Add Producer ID to info field

 Cosmetic change, to better distinguish if multiple
 SPDO packages have been detected.

 This should also be back-ported to 1.12 and 2.0

Change-Id: I3d0b26ecb6e0cc60b3cdc9861920c5ccaeb70cbd
Reviewed-on: https://code.wireshark.org/review/10829
Reviewed-by: Roland Knall <rknall@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
4 years agoRemove an extra comma
Pascal Quantin [Tue, 6 Oct 2015 08:46:49 +0000 (10:46 +0200)]
Remove an extra comma

Change-Id: I14e89d9db53166b43ef6bee901ba0fdc545657b1
Reviewed-on: https://code.wireshark.org/review/10831
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoFix SoupBinTCP sequence number tracking.
David Arnold [Sun, 20 Sep 2015 12:04:08 +0000 (22:04 +1000)]
Fix SoupBinTCP sequence number tracking.

Change-Id: Ia31b21894a6f0ba2da6cc2aea6babda9f37f5e09
Reviewed-on: https://code.wireshark.org/review/10579
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
4 years agoCalculate the channel if we have only the frequency.
Guy Harris [Tue, 6 Oct 2015 06:46:53 +0000 (23:46 -0700)]
Calculate the channel if we have only the frequency.

That way, the generic 802.11 radio dissector, and any future taps if we
add a tap with radio information, can get the channel for radiotap and
PPI headers, as we do for some other radio headers that supply just a
frequency.

Change-Id: I9e3037f69938bed3b3ba563689ff00aaed486a16
Reviewed-on: https://code.wireshark.org/review/10821
Reviewed-by: Guy Harris <guy@alum.mit.edu>
4 years agoQt: refine some strings for l10n
YFdyh000 [Mon, 5 Oct 2015 15:03:30 +0000 (23:03 +0800)]
Qt: refine some strings for l10n

Change-Id: I460559c99c79c9fd40f284c750d64210fe5de50b
Reviewed-on: https://code.wireshark.org/review/10813
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
4 years agoShow progress in the Supported Protocols dialog.
Gerald Combs [Mon, 5 Oct 2015 16:38:51 +0000 (09:38 -0700)]
Show progress in the Supported Protocols dialog.

Make sure we update the UI when building our tree.

Change-Id: I8b24e5c017c9521a00e3dfcb48afe0e6b6124aa2
Reviewed-on: https://code.wireshark.org/review/10806
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agodebian: Build .debs with Qt 5
Balint Reczey [Mon, 5 Oct 2015 00:58:00 +0000 (02:58 +0200)]
debian: Build .debs with Qt 5

Change-Id: I085d5332a0a1c8151b5781c0a94cffe2fe32aeb7
Reviewed-on: https://code.wireshark.org/review/10800
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
Tested-by: Balint Reczey <balint@balintreczey.hu>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
4 years agoInitialize 2.1.
Gerald Combs [Mon, 5 Oct 2015 20:09:52 +0000 (13:09 -0700)]
Initialize 2.1.

Change-Id: I515c53bb56cf82d1911b58f2cb2103afd0e597a5
Reviewed-on: https://code.wireshark.org/review/10810
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoFix capitalization in MATE's "you need to restart to reconfigure" message.
Jeff Morriss [Mon, 5 Oct 2015 18:56:42 +0000 (14:56 -0400)]
Fix capitalization in MATE's "you need to restart to reconfigure" message.

Fix up some formatting and white space while we're there.

Change-Id: I869659d6fb1f8b4946f6e13a928ecd53dbabf1a4
Reviewed-on: https://code.wireshark.org/review/10807
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
4 years agoMATE: Add ~ operator support
Michael Mann [Sat, 3 Oct 2015 03:42:38 +0000 (23:42 -0400)]
MATE: Add ~ operator support

Bug: 9025
Change-Id: Ica92a7026ba8a89a8970b76e4e7d27f9e6288eb6
Reviewed-on: https://code.wireshark.org/review/10760
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
4 years agoQt: fix crash when double clicking on a row in 'Decode As' dialog
Pascal Quantin [Mon, 5 Oct 2015 06:01:44 +0000 (08:01 +0200)]
Qt: fix crash when double clicking on a row in 'Decode As' dialog

No need to register for the destroyed() signal: it is emitted after the new
QComboBox object is created and resetting pointers to NULL is useless as they
are locals initialized in the constructor

Bug: 11532
Change-Id: Ie707cafa370053df846a4732aed20c182e030c40
Reviewed-on: https://code.wireshark.org/review/10792
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoAdd BASE_PT_ field display types
João Valverde [Mon, 5 Oct 2015 10:53:07 +0000 (11:53 +0100)]
Add BASE_PT_ field display types

Avoid displaying duplicate port numbers with transport name resolution disabled and
make some dissector code simpler.

Introduces port_with_resolution_to_str_buf() function and amends UDP/TCP/DCCP/SCTP to
use the new field display type.

Change-Id: Ifb97810b9c669ccbb1a310a2c0ffd6e2b63af210
Reviewed-on: https://code.wireshark.org/review/10625
Petri-Dish: Michael Mann <mmann78@netscape.net>
Reviewed-by: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoSCTP I-DATA support
ruengeler [Mon, 5 Oct 2015 13:55:40 +0000 (15:55 +0200)]
SCTP I-DATA support

Change-Id: I459942b9e3287d500dda517568252d4cb56d3216
Reviewed-on: https://code.wireshark.org/review/10802
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Michael Tüxen <tuexen@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Tüxen <tuexen@wireshark.org>
4 years agoMake the capture comment icon more Wireshark-y.
Gerald Combs [Sun, 4 Oct 2015 17:20:55 +0000 (10:20 -0700)]
Make the capture comment icon more Wireshark-y.

Change-Id: Ic693c7afc1658c3b89ae5cddf9c7ab32c435cf2e
Reviewed-on: https://code.wireshark.org/review/10788
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoFix initialization order.
Gerald Combs [Mon, 5 Oct 2015 16:12:43 +0000 (09:12 -0700)]
Fix initialization order.

Change-Id: I5eb59108860c9282d798aedfe40eccf1ee85658d
Reviewed-on: https://code.wireshark.org/review/10805
Reviewed-by: Gerald Combs <gerald@wireshark.org>
4 years agoH225, H245 over IPv6
Michal Pazdera [Mon, 5 Oct 2015 10:25:05 +0000 (12:25 +0200)]
H225, H245 over IPv6

This commit extends h225 and h245 dissectors to support dissection
of ipv6 packets.

Change-Id: Id8c045344711a96f15d619ddd72065aa3712c429
Reviewed-on: https://code.wireshark.org/review/10799
Reviewed-by: Tomáš Kukosa <tomas.kukosa@unify.com>
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
4 years agoMove utf8_entities.h to wsutil
João Valverde [Sun, 4 Oct 2015 17:10:29 +0000 (18:10 +0100)]
Move utf8_entities.h to wsutil

Change-Id: I6298b3de5f0a1cb988014ff16082eaf8c2a3c3c0
Reviewed-on: https://code.wireshark.org/review/10786
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoDon't count packets twice for average using avg_stat_node_add_value_notick.
Michael Mann [Sat, 3 Oct 2015 15:56:43 +0000 (11:56 -0400)]
Don't count packets twice for average using avg_stat_node_add_value_notick.

Bug: 10535
Change-Id: I9c61a1f10f257bc6dd390c2a9370653bbd45b205
Reviewed-on: https://code.wireshark.org/review/10772
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agofile.c: fix resource leak reported by Coverity (CID 1159387)
Pascal Quantin [Mon, 5 Oct 2015 09:43:32 +0000 (11:43 +0200)]
file.c: fix resource leak reported by Coverity (CID 1159387)

Change-Id: I24f85f41bcb0c3a0dda0b6658dbfdb4098eb64b9
Reviewed-on: https://code.wireshark.org/review/10796
Reviewed-by: Dario Lombardo <lomato@gmail.com>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoQt: fix uninitialized members (UNINIT_CTOR) reported by Coverity (CID 1228882)
Pascal Quantin [Mon, 5 Oct 2015 09:27:54 +0000 (11:27 +0200)]
Qt: fix uninitialized members (UNINIT_CTOR) reported by Coverity (CID 1228882)

Change-Id: I1f09fa9a8421e702d2fff963afc899617f2e6222
Reviewed-on: https://code.wireshark.org/review/10794
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoQt: fix control flow issues (UNREACHABLE) reported by Coverity (CID 1224614)
Pascal Quantin [Mon, 5 Oct 2015 09:29:04 +0000 (11:29 +0200)]
Qt: fix control flow issues (UNREACHABLE) reported by Coverity (CID 1224614)

Change-Id: I5e59490e0c913f4648fd1024bcf1792a936a39dd
Reviewed-on: https://code.wireshark.org/review/10795
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoAMQP: Fix warnings and the OSX 10.5 x86 build
Petr Gotthard [Mon, 5 Oct 2015 06:24:46 +0000 (08:24 +0200)]
AMQP: Fix warnings and the OSX 10.5 x86 build

The AMQP channel number is 16-bit only.

packet-amqp.c: In function 'dissect_amqp_0_9_method_channel_close':
packet-amqp.c:8481: warning: cast to pointer from integer of different size
packet-amqp.c: In function 'get_conversation_channel':
packet-amqp.c:10512: warning: cast to pointer from integer of different size
packet-amqp.c:10518: warning: cast to pointer from integer of different size

Change-Id: I398ecfb19ecb7e741c2ed0675c1c625bf6a894f9
Reviewed-on: https://code.wireshark.org/review/10793
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
4 years agoAllow use of variadic macros
Peter Wu [Sun, 4 Oct 2015 14:27:02 +0000 (16:27 +0200)]
Allow use of variadic macros

Remove variadic macros restriction (c99, c++11 feature) from
README.developer. GCC, Clang, MSVC 2005 all support it.

Enable -Wno-variadic-macros in configure.ac and CMakeLists.txt when
-Wpedantic is enabled (which would enable -Wvariadic-macros).

For all files matching 'define\s*\w+[0-9]\(', replace "FOO[0-9]" by
"FOO" and adjust the macro definition accordingly. The nbap dissector
was regenerated after adjusting its template and .cnf file. The
generated code is the same since all files disabled the debug macros.

Discussed at:
https://www.wireshark.org/lists/wireshark-dev/201209/msg00142.html
https://www.wireshark.org/lists/wireshark-dev/201510/msg00012.html

Change-Id: I3b2e22487db817cbbaac774a592669a4f44314b2
Reviewed-on: https://code.wireshark.org/review/10781
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
4 years agoFix warnings introduced by "Qt: Initial RTP playback"
Peter Wu [Sun, 4 Oct 2015 09:52:26 +0000 (11:52 +0200)]
Fix warnings introduced by "Qt: Initial RTP playback"

Change-Id: I28ae077be535f32ef81ac370d6782033f219017d
Reviewed-on: https://code.wireshark.org/review/10777
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoFix typos in rtp_player_dialog files
YFdyh000 [Sun, 4 Oct 2015 18:35:57 +0000 (02:35 +0800)]
Fix typos in rtp_player_dialog files

Change-Id: I0df33dc156601187a6a180d8786ef18c5c05467a
Reviewed-on: https://code.wireshark.org/review/10787
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoAMQP: Navigation between publish/delivery and related ack/nack
Petr Gotthard [Fri, 2 Oct 2015 18:06:04 +0000 (20:06 +0200)]
AMQP: Navigation between publish/delivery and related ack/nack

This patch adds cross-references between publish/delivery and
ack/nack frames. This improves user comfort when inspecting the traffic.

Change-Id: I819b19474a3f0351eb769eadf3d32042cb5f5256
Reviewed-on: https://code.wireshark.org/review/10745
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoQt: Don't update the recent list while capturing.
Gerald Combs [Sat, 3 Oct 2015 16:45:16 +0000 (09:45 -0700)]
Qt: Don't update the recent list while capturing.

If a recent file is on a network share we'll create traffic which can
show up in the capture.

This doesn't fix the issue entirely, e.g. if you're capturing in one
instance of Wireshark and have another one open. The proper fix in that
case is to switch to QFileSystemWatcher as described at the top of
::WiresharkApplication.

Ping-Bug: 11546
Change-Id: If21f1bb213fe1d862c09b1b2edd78c8baf983461
Reviewed-on: https://code.wireshark.org/review/10774
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
4 years agoRemove tr() for setObjectName
YFdyh000 [Sun, 4 Oct 2015 18:35:13 +0000 (02:35 +0800)]
Remove tr() for setObjectName

Change-Id: I4561ded123df3c2152da543e8a6786cb8b386dd5
Reviewed-on: https://code.wireshark.org/review/10790
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
4 years agoUDP: Make port column info similar to TCP, add length information
João Valverde [Sun, 4 Oct 2015 01:52:10 +0000 (02:52 +0100)]
UDP: Make port column info similar to TCP, add length information

Change-Id: I3f7a35db53a1ecc9d543b80f143eb6082616e458
Reviewed-on: https://code.wireshark.org/review/10702
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Evan Huus <eapache@gmail.com>
4 years agowslua: fix crash when a LUA error is raised in TRY block
Peter Wu [Tue, 29 Sep 2015 10:20:07 +0000 (12:20 +0200)]
wslua: fix crash when a LUA error is raised in TRY block

The dissect_tcp_pdus function in LUA is passed two LUA functions that
get the PDU length and the dissect a PDU. When one of these functions
fail, a longjmp is made to the the caller of lua_pcall.

This is no problem for the PDU length function, but the PDU dissect
function is wrapped in a TRY/CATCH/ENDTRY block which also uses longjmp
and need to be fully executed. Without doing so, LUA exceptions will
crash on a weird location (except_pop).

Fix the crash by not using luaL_error, but throw dissector errors which
properly breaks out of the tcp_dissect_pdus C function and then convert
it to a LUA error such that the dissector can handle it.

Test with `tshark -X lua_script:crash.lua -r ssl.pcap`:

    trivial_proto = Proto("trivial", "Trivial Protocol")
    function dissect_foo(tvb, pinfo, tree)
        error("triggering a LUA error");
    end
    function get_pdu_len(tvb, pinfo, tree) return 5; end
    function trivial_proto.dissector(tvb, pinfo, tree)
        dissect_tcp_pdus(tvb, tree, 5, get_pdu_len, dissect_foo)
    end
    tcp_table = DissectorTable.get("tcp.port")
    tcp_table:add(443, trivial_proto)

It should not crash and will print this:

    Lua Error: dissect_tcp_pdus dissect_func: [string "crash.lua"]:3: triggering a LUA error

Change-Id: Ibd079cc5eb3a2e4d2e62ea49a512fa2cc8e561ea
Reviewed-on: https://code.wireshark.org/review/10685
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Evan Huus <eapache@gmail.com>
4 years agobacapp: attempt to fix windows build
Peter Wu [Sun, 4 Oct 2015 17:08:03 +0000 (19:08 +0200)]
bacapp: attempt to fix windows build

Reported by Graham:

    packet-bacapp.c(5299) : warning C4146: unary minus operator applied to unsigned type, result still unsigned

Regression in v1.99.10rc0-330-g71ec57a ("bacapp: fix
-Wshift-negative-value").

Change-Id: Ia3ea3acad3afdf7b8a449224c815ea45d7fdbc2b
Reviewed-on: https://code.wireshark.org/review/10785
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
4 years agoUDP: Rename UDPlite to UDP-Lite
João Valverde [Sat, 3 Oct 2015 14:23:36 +0000 (15:23 +0100)]
UDP: Rename UDPlite to UDP-Lite

Keep "UDPLite" in ipproto.c in accordance with the IANA Considerations
section of RFC 3828.

Change-Id: Icfa2bc07ea3c6782e838b4896f9e4aec28422d34
Reviewed-on: https://code.wireshark.org/review/10765
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>