metze/wireshark/wip.git
7 years agowtap: Make default_filter static
Stig Bjørlykke [Fri, 11 Mar 2016 17:42:49 +0000 (18:42 +0100)]
wtap: Make default_filter static

Address of stack memory associated with local variable 'default_filter'
is still referred to by the global variable 'filter_option' upon returning
to the caller.  This will be a dangling reference.

Change-Id: I6160a37f05b8aea245b723ec50803e4062886738
Reviewed-on: https://code.wireshark.org/review/14427
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoDisplay "IP DSCP" column as short text
João Valverde [Wed, 30 Sep 2015 13:34:39 +0000 (14:34 +0100)]
Display "IP DSCP" column as short text

Ping-Bug: 12429
Change-Id: I618b2017e161d89f0efa25ce2fb82a1808e8d315
Reviewed-on: https://code.wireshark.org/review/10701
Reviewed-by: João Valverde <j@v6e.pt>
7 years agoandroiddump: fix leak on --extcap-interfaces
Peter Wu [Wed, 15 Jun 2016 15:45:54 +0000 (08:45 -0700)]
androiddump: fix leak on --extcap-interfaces

extcap_base_register_interface duplicates the memory, so there is no
need to keep it around.

Change-Id: I2bac8be519b659504c512d4eb29be8f7ef6dbd59
Reviewed-on: https://code.wireshark.org/review/15919
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agowin-setup.ps1: stop downloading user-guide; with CMake it is generated from source...
Pascal Quantin [Wed, 15 Jun 2016 15:24:48 +0000 (08:24 -0700)]
win-setup.ps1: stop downloading user-guide; with CMake it is generated from source code

Change-Id: I3b015594bd6a6b0c41938ba17d5690c08e04f490
Reviewed-on: https://code.wireshark.org/review/15917
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>
7 years agoproto_tree_add_boolean -> proto_tree_add_bitmask_list_value
Michael Mann [Wed, 15 Jun 2016 03:17:25 +0000 (23:17 -0400)]
proto_tree_add_boolean -> proto_tree_add_bitmask_list_value

Change-Id: Ic644042d238b5f2abcd874bca92c6dea55804ba9
Reviewed-on: https://code.wireshark.org/review/15913
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoMore Sysdig / system event support.
Gerald Combs [Sun, 24 Apr 2016 18:21:50 +0000 (11:21 -0700)]
More Sysdig / system event support.

Add REC_TYPE_SYSCALL to wiretap and use it for Sysdig events. Call the
Sysdig event dissector from the frame dissector. Create a "syscall"
protocol for system calls, but add "frame" items to it for now.

Add the ability to write Sysdig events. This lets us merge packet
capture and syscall capture files.

Change-Id: I12774ec69c89d8e329b6130c67f29aade4e3d778
Reviewed-on: https://code.wireshark.org/review/15078
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoLet the calculated window scale be 16 bit wide.
Jaap Keuter [Wed, 15 Jun 2016 06:53:14 +0000 (08:53 +0200)]
Let the calculated window scale be 16 bit wide.

Even though TCP window scale shift is only 8 bits, the scale
calculated from it is max 16384. therefor a 16 bit value.
Let the tree item map to the single byte in the TVB, while
allowing the value to be 16 bit.

Bug: 12525
Change-Id: I41cebc62f6b8b09e13efa5f3b7432001e8d994e1
Reviewed-on: https://code.wireshark.org/review/15914
Petri-Dish: Jaap Keuter <jaap.keuter@xs4all.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoAllow control of individual columns to be (un)writable.
Michael Mann [Tue, 14 Jun 2016 15:55:08 +0000 (11:55 -0400)]
Allow control of individual columns to be (un)writable.

Most protocols just want to limit COL_INFO or COL_PROTOCOL
so give that level of granularity.

Bug: 12144
Bug: 5117
Bug: 11144
Change-Id: I8de9b7d2c69e90d3fbfc0a52c2bd78c3de58e2f8
Reviewed-on: https://code.wireshark.org/review/15894
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.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>
7 years agocmake: fix ENABLE_ASAN detection
Peter Wu [Tue, 14 Jun 2016 21:52:01 +0000 (14:52 -0700)]
cmake: fix ENABLE_ASAN detection

Do not add -fsanitize=undefined when ASAN is requested, UBSAN is a
different feature (which could be added later as desired). This makes
the -DENABLE_ASAN=1 option match the autotools --enable-asan option.

Fail hard if ASAN support is requested but not supported, this avoids
surprises when something is wrong. Fix ASAN detection by setting the
linker option too.

Note: if you have previously set ENABLE_ASAN=1 with the broken ASAN
detection, you have to clear your CMakeCache.txt file to redo the
detection.

Change-Id: Iba6ca0da0336eccedd0cf31a251baad9d1aff5b4
Reviewed-on: https://code.wireshark.org/review/15908
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: 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>
7 years agoChange how dissectors do late-field-registration to avoid a double-registration
Jeff Morriss [Mon, 13 Jun 2016 19:28:16 +0000 (15:28 -0400)]
Change how dissectors do late-field-registration to avoid a double-registration
assertion.

If a dissector forces registration of fields during dissection it needs to do
so in a way that clears the prefix registration.  Otherwise epan will call the
registration routine a 2nd time (which will cause us to assert out) if a user
types a display filter (with the dissector's prefix) that doesn't exist.

Update the proto_register_prefix() comments to reflect this.

Change-Id: I3ce29243395fb55192bb5dfd950baa88410ac136
Reviewed-on: https://code.wireshark.org/review/15881
Petri-Dish: Jeff Morriss <jeff.morriss.ws@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jaap Keuter <jaap.keuter@xs4all.nl>
7 years agomount: fix a memory leak
Martin Kaiser [Tue, 14 Jun 2016 01:05:11 +0000 (18:05 -0700)]
mount: fix a memory leak

don't copy the wmem-buffer from address_to_str() into a g_malloc()ed one
that is never freed

instead, realloc the wmem-buffer and add the nfs path to it

(nfs_name_snoop_add_name() will make a copy internally)

Change-Id: I4274a4a413c09f3f1d78beba65d94748ce185413
Reviewed-on: https://code.wireshark.org/review/15902
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoClean up some messages.
Guy Harris [Wed, 15 Jun 2016 00:35:51 +0000 (17:35 -0700)]
Clean up some messages.

We're checking for more than just a 64-bit off_t; we're checking for the
ability to do 64-bit seeks in files, even if, as on Windows, the APIs
are different.

Remove trailing white space and clean up some comments while we're at
it.

Change-Id: I6122b6d6b44ff5dd3a4d8268f9793193e65817ce
Reviewed-on: https://code.wireshark.org/review/15912
Reviewed-by: Guy Harris <guy@alum.mit.edu>
7 years agoFix OSX buildbot
Pascal Quantin [Tue, 14 Jun 2016 23:11:18 +0000 (16:11 -0700)]
Fix OSX buildbot

Dirty CORBA IDL dissectors must be compiled without -Werror option

Change-Id: I46431c635274399cd6d365a608cdc0aecbc59c95
Reviewed-on: https://code.wireshark.org/review/15911
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
7 years agodns_stats: generate stats just for pure dns (not mDNS, not LLMR).
Dario Lombardo [Tue, 14 Jun 2016 17:35:32 +0000 (19:35 +0200)]
dns_stats: generate stats just for pure dns (not mDNS, not LLMR).

The stats for mDNS and llmnr are pending. The change just resolves a bug
in the stats that are wrongly generated when the traffic is mDNS or LLMR.

Bug: 12492
Change-Id: Ie772e204d0ddea997dd8cbf609725605c8a507c8
Reviewed-on: https://code.wireshark.org/review/15897
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
7 years agoproto(.h): fix '@return' command used in a comment that is attached to a function...
Alexis La Goutte [Tue, 14 Jun 2016 21:43:15 +0000 (23:43 +0200)]
proto(.h): fix '@return' command used in a comment that is attached to a function returning void [-Wdocumentation]

Change-Id: Ie0e502adcc8eb00f65ffa6c018d5b9d79655ddb7
Reviewed-on: https://code.wireshark.org/review/15907
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
7 years agoFIX dissector - Improve Message info
Michael Mann [Tue, 14 Jun 2016 21:23:58 +0000 (17:23 -0400)]
FIX dissector - Improve Message info

Bug: 5350
Change-Id: I4b2d60549f9680bbc008a2abba5d7ec108f6bf22
Reviewed-on: https://code.wireshark.org/review/15905
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoCORBA IDL: compile dissectors with /Ox when using MSVC2013 x64
Pascal Quantin [Mon, 13 Jun 2016 22:11:55 +0000 (15:11 -0700)]
CORBA IDL: compile dissectors with /Ox when using MSVC2013 x64

By default Windows files are compiled with /O2 optimization flag (that brings the best performance).
But MSVC2013 x64 compiler generates buggy code for CORBA IDL dissectors.
Let's downgrade the optimization to /Ox for those files specifically.

Bug: 12495
Change-Id: Ibbb532653808d915c82bd20b55dd9e68d86b1207
Reviewed-on: https://code.wireshark.org/review/15884
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
7 years agoDon't list "AVP" as a possible member of a grouped AVP.
Jeff Morriss [Tue, 14 Jun 2016 21:38:17 +0000 (17:38 -0400)]
Don't list "AVP" as a possible member of a grouped AVP.

There's no AVP named "AVP".  And there's no need to tell Wireshark that any AVP
may put in the group (the RFC lists "AVP" for that purpose).

Change-Id: I3591af725ebe089e13eae7b712ef4404cb7924a2
Reviewed-on: https://code.wireshark.org/review/15906
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agopacket.c: remove const compiler warning.
Dario Lombardo [Tue, 5 Apr 2016 16:24:25 +0000 (18:24 +0200)]
packet.c: remove const compiler warning.

Change-Id: Ida9384dccb0e8bacbc9aad39515c3dae9c5ce563
Reviewed-on: https://code.wireshark.org/review/14768
Reviewed-by: João Valverde <j@v6e.pt>
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoQt: fix crash when opening Expert Info dialog
Pascal Quantin [Tue, 14 Jun 2016 18:31:10 +0000 (11:31 -0700)]
Qt: fix crash when opening Expert Info dialog

g6ff19ff tried to access cinfo by following a chain of pointers from
expert_info. Access cinfo from cap_file_, which is more reliable. While
we are at it, let's explicitly check the pointer validity.

Change-Id: I0da72c5b1d2230a49c125a1b57c81c3115c4f2fb
Reviewed-on: https://code.wireshark.org/review/15901
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
7 years agoGive unique names to a bunch of reserved, experimental, etc., AVPs.
Jeff Morriss [Tue, 14 Jun 2016 14:52:28 +0000 (10:52 -0400)]
Give unique names to a bunch of reserved, experimental, etc., AVPs.

Also remove a bunch of AVPs that are unassigned/unallocated--there's no
real benefit to telling users that...

Change-Id: I1b18a11a1b65189d21520c74aae3dde77688e592
Reviewed-on: https://code.wireshark.org/review/15895
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoReplace wlan_ignore_wep_ by wlan_ignore_prot_ and WLAN_IGNORE_WEP_ by WLAN_IGNORE_PROT_
Joerg Mayer [Tue, 14 Jun 2016 19:45:53 +0000 (21:45 +0200)]
Replace wlan_ignore_wep_ by wlan_ignore_prot_ and WLAN_IGNORE_WEP_ by WLAN_IGNORE_PROT_

Change-Id: I870cc1e5293dd6e1a1b71157987e27399e080a73
Reviewed-on: https://code.wireshark.org/review/15904
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
7 years agotvbparse: change g_hash_table to wmem_map.
Dario Lombardo [Mon, 2 May 2016 15:21:57 +0000 (17:21 +0200)]
tvbparse: change g_hash_table to wmem_map.

Change-Id: I245595051617f6d6333314240825a526adf19339
Reviewed-on: https://code.wireshark.org/review/15244
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoaddr_resolv: change g_hash to wmem_map.
Dario Lombardo [Thu, 21 Apr 2016 16:04:16 +0000 (18:04 +0200)]
addr_resolv: change g_hash to wmem_map.

Change-Id: Ice7533fbeac700dae0a46766838818a32b0d5736
Reviewed-on: https://code.wireshark.org/review/15051
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agodcm: remove g_malloc
Dario Lombardo [Tue, 12 Apr 2016 16:14:14 +0000 (18:14 +0200)]
dcm: remove g_malloc

Change-Id: I3d00b710c6fc6e5798ecc5eca9af11ccac920e5a
Reviewed-on: https://code.wireshark.org/review/14913
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agotvbparse: change g_malloc to wmem_alloc.
Dario Lombardo [Mon, 2 May 2016 15:50:38 +0000 (17:50 +0200)]
tvbparse: change g_malloc to wmem_alloc.

Change-Id: I6a6363400d9fd1d76b9de0c5deea83dfc7cea1e2
Reviewed-on: https://code.wireshark.org/review/15245
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoAdd Aerohive gre tunnel between APs.
Joerg Mayer [Tue, 14 Jun 2016 19:12:16 +0000 (21:12 +0200)]
Add Aerohive gre tunnel between APs.

Change-Id: I24d0320cd164ead2802af37d07016c9c46d18e9e
Reviewed-on: https://code.wireshark.org/review/15903
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
7 years agowslua: remove FAIL_ON_NULL_MEMBER_OR_EXPIRED
Peter Wu [Sun, 3 Apr 2016 09:10:02 +0000 (11:10 +0200)]
wslua: remove FAIL_ON_NULL_MEMBER_OR_EXPIRED

Ensure that the member cannot be NULL at initialization, simplifies
checkCaptureInfo and checkCaptureInfoConst logic.

Change-Id: I2d9caa4a235310569ebbf0b30199dd3df7a4c093
Reviewed-on: https://code.wireshark.org/review/14791
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agowslua: Drop unused "push_code" macro parameter
Peter Wu [Sun, 3 Apr 2016 08:58:44 +0000 (10:58 +0200)]
wslua: Drop unused "push_code" macro parameter

Reduce noise, no caller has used this parameter since its introduction.
Msotly automated regex search and replace.

Change-Id: I4b1180bfee8544b38d19c9c440ff5b9b0dc080b2
Reviewed-on: https://code.wireshark.org/review/14790
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>
7 years agoAdd dissector for Real Time Location System (RTLS)
Alexis La Goutte [Fri, 3 Jun 2016 15:56:54 +0000 (17:56 +0200)]
Add dissector for Real Time Location System (RTLS)

Change-Id: I494cbb8c3c6da18dfd7901d098dde6448226f67e
Reviewed-on: https://code.wireshark.org/review/15711
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>
7 years agoFix SCTP analysis broken
Irene Ruengeler [Mon, 13 Jun 2016 15:39:42 +0000 (17:39 +0200)]
Fix SCTP analysis broken

Bug: 12513
Change-Id: I3fdf79106ed007aadf528f0b373fb7a487f3d9a9
Reviewed-on: https://code.wireshark.org/review/15870
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>
7 years agogtk: Allow restoring maximized windows as maximized
Balint Reczey [Tue, 23 Jun 2015 20:51:32 +0000 (13:51 -0700)]
gtk: Allow restoring maximized windows as maximized

without losing window decorations on GNOME on the secondary monitor.

Bug: 11303
Change-Id: Ie8f541dba9d49f9fe5d4892a8dc1cd42091afe1d
Reviewed-on: https://code.wireshark.org/review/9077
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoAdded XML proper decoding for XML CDATASection
Binh Trinh [Tue, 14 Jun 2016 04:37:53 +0000 (00:37 -0400)]
Added XML proper decoding for XML CDATASection

Bug: 11755
Change-Id: Iecf7ce4bfad45d0c49f3af205e8489e53077198b
Reviewed-on: https://code.wireshark.org/review/15889
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>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoRevert "Move inclusion of CmakeListsCustom to the end of the file in order to have...
Anders Broman [Tue, 14 Jun 2016 15:37:33 +0000 (15:37 +0000)]
Revert "Move inclusion of CmakeListsCustom to the end of the file in order to have all defines in place."

This reverts commit bcbcad1e597f89e64389b6cc25b2fdbe9f89d960.

This change breaks building of custom plugins.

Change-Id: I63e88ceb922ca23ead9784705ad8ba088a504fd1
Reviewed-on: https://code.wireshark.org/review/15893
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agobrowser (dcerpc): Fix Dead Store (Dead assignement/Dead increment) Warning found...
Alexis La Goutte [Tue, 14 Jun 2016 13:40:57 +0000 (15:40 +0200)]
browser (dcerpc): Fix Dead Store (Dead assignement/Dead increment) Warning found by Clang

Change-Id: I158a5fd8a645cd4d58565a6a4ee64371d271eb8e
Reviewed-on: https://code.wireshark.org/review/15892
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
7 years agoGTK: Disable liboverlay-scrollbar that crashed wireshark on Ubuntu
Balint Reczey [Tue, 14 Jun 2016 03:01:08 +0000 (20:01 -0700)]
GTK: Disable liboverlay-scrollbar that crashed wireshark on Ubuntu

Bug: 11400
Change-Id: I40d901ab3ef43a61ef984014dabc0547605ef77c
Reviewed-on: https://code.wireshark.org/review/15888
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agomount: don't THROW() an exception from a dissector
Martin Kaiser [Mon, 13 Jun 2016 22:50:33 +0000 (15:50 -0700)]
mount: don't THROW() an exception from a dissector

if the length is too large, we can simply skip nfs_name_snoop_add_name()
and the code to prepare its input

Change-Id: I30c9a89edf7b48c45b52e7dad099ac4151f7f4a7
Reviewed-on: https://code.wireshark.org/review/15883
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoDon't register Wireshark for .pfx (IPFIX) files.
Jeff Morriss [Mon, 13 Jun 2016 23:51:29 +0000 (19:51 -0400)]
Don't register Wireshark for .pfx (IPFIX) files.

(As pointed out by Gerald) .pfx files are (more commonly) PKCS#12 files.
People may be upset if we start grabbing them.

Change-Id: Iecf857d082b7f2a0ad4fdd1a932332fc3c9d9498
Reviewed-on: https://code.wireshark.org/review/15886
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>
7 years agoAdjust the Diameter DTD to accept applications and vendors in any order.
Jeff Morriss [Tue, 14 Jun 2016 00:14:41 +0000 (20:14 -0400)]
Adjust the Diameter DTD to accept applications and vendors in any order.

Change-Id: I301a138b7f6db2d1a9ce1a20ebecf94e100bf831
Reviewed-on: https://code.wireshark.org/review/15887
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
7 years agoextcap: Check libssh >= 0.6.0 for sshdump, ciscodump
John A. Thacker [Mon, 13 Jun 2016 20:36:07 +0000 (16:36 -0400)]
extcap: Check libssh >= 0.6.0 for sshdump, ciscodump

sshdump and ciscodump require libssh >= 0.6.0. Check for this version and
only build them if a sufficient version is present. (The other checks
stay; in particular, ssh_userauth_agent doesn't exist on Windows and
must be checked separately.)

Bug: 12507
Change-Id: Ibe42b0cbb597cd9c4aab51f44d48185940ad954b
Reviewed-on: https://code.wireshark.org/review/15882
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Dario Lombardo <lomato@gmail.com>
Tested-by: Dario Lombardo <lomato@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoFix Custom.xml so it can be (correctly) included into the main dictionary.
Jeff Morriss [Mon, 13 Jun 2016 23:28:04 +0000 (19:28 -0400)]
Fix Custom.xml so it can be (correctly) included into the main dictionary.

This file is included into dictionary.xml so it doesn't need all the DOCTYPE
stuff.

Change-Id: I8397b3babe45c28706867be3169ce6ed566930e6
Reviewed-on: https://code.wireshark.org/review/15885
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
7 years agoAdd missing const to inet_ipv6.h
João Valverde [Mon, 13 Jun 2016 04:35:14 +0000 (05:35 +0100)]
Add missing const to inet_ipv6.h

Make it simpler too.

Change-Id: I97dc79d7ac536089c1fa6ec2c20f19754d47a9d4
Reviewed-on: https://code.wireshark.org/review/15866
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: João Valverde <j@v6e.pt>
7 years agodcerpc: don't THROW() an exception from a dissector
Martin Kaiser [Sat, 11 Jun 2016 11:56:33 +0000 (13:56 +0200)]
dcerpc: don't THROW() an exception from a dissector

remove the checks in dissect_ndr_ucarray_core() where a block or bytes
dissection function is called and an exception is thrown if the offset
wraps around, i.e. the final offset is lower than the initial one

the block functions eventually call proto_tree_add_item(), which throws
an exception if necessary

the bytes functions end up calling functions to dissect basic types.
insert calls to tvb_ensure_bytes_exist() if those functions increase our
offset without reading data.  thus, an exception is thrown if there's an
overflow.

remove some unnecessary if (tree) checks while at it

Change-Id: I8006399ae20934daeec231246debe247f8dedbf0
Reviewed-on: https://code.wireshark.org/review/15832
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoAdd proto_tree_add_bitmask_list_value.
Michael Mann [Mon, 13 Jun 2016 19:34:16 +0000 (15:34 -0400)]
Add proto_tree_add_bitmask_list_value.

Ran across enough situations that proto_tree_add_bitmask_list couldn't
solve that it seemed necessary.

Change-Id: I6a540ac6efca76cae7c4571a84bb400538652784
Reviewed-on: https://code.wireshark.org/review/15880
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>
7 years agoUpdates on AVB IEEE 1722 protocol to support more 1722 subtypes.
Andreas Leibold [Fri, 10 Jun 2016 08:41:19 +0000 (10:41 +0200)]
Updates on AVB IEEE 1722 protocol to support more 1722 subtypes.

packet-ieee1722.c now contains the entire protocol.
packet-ieee1722a.c file was removed, because the term 1722a is outdated
and now part of 1722 protocol.

Change-Id: Ic2f44a2752f9254cde62d878dc971f09cddc5adc
Reviewed-on: https://code.wireshark.org/review/15810
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agouse #include <file.h> for generated include files
Martin Kaiser [Sun, 12 Jun 2016 23:31:57 +0000 (16:31 -0700)]
use #include <file.h> for generated include files

the same mechanism as described in
7c40de5c38ac71323455c51dcc14a5eb385ce718
could trick us into using the wrong config.h

fix this for some occassions where config.h is included before we
include zlib.h

I saw compile errors on windows where we picked up config.h from a linux
build and zlib failed because of a mission unistd.h

Change-Id: I91cf73b96c9e1b6f009fb2376fabfe973d1ac941
Reviewed-on: https://code.wireshark.org/review/15874
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>
7 years agoqt: use #include <file.h> for generated include files
Martin Kaiser [Sun, 12 Jun 2016 21:00:21 +0000 (14:00 -0700)]
qt: use #include <file.h> for generated include files

make sure that generated include files are picked up only from the
directories set by -I (or /I), not from the current directory

if we use #include "file.h", Visual Studio searches for file.h in the
same diretory as the source file that includes file.h

if we do an out-of-tree build with cmake and the source directory
contains files from an in-tree build (done with autotools), we might end
up including the wrong file

Change-Id: Iaaed2626258b6ff0c12485fe3f436bd03bbb5adf
Reviewed-on: https://code.wireshark.org/review/15873
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoIPv6: Add text marker for SRH next segment
João Valverde [Sat, 11 Jun 2016 22:15:01 +0000 (23:15 +0100)]
IPv6: Add text marker for SRH next segment

Change-Id: If13ffe4ddb9ae08e738ccf0c715dc12ce7a076e8
Reviewed-on: https://code.wireshark.org/review/15834
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>
7 years agosip: remove some unnecessary if (tree) checks
Martin Kaiser [Mon, 13 Jun 2016 18:36:10 +0000 (11:36 -0700)]
sip: remove some unnecessary if (tree) checks

which shouldn't have any impact on performance

we should not remove the chcks around blocks where
vb_format_text() is called

Change-Id: Idc191cc70e7458225bbc5dfececb3c88c83ab5f1
Reviewed-on: https://code.wireshark.org/review/15879
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoMove inclusion of CmakeListsCustom to the end of the file in order to have
AndersBroman [Mon, 13 Jun 2016 18:51:48 +0000 (20:51 +0200)]
Move inclusion of CmakeListsCustom to the end of the file in order to have
all defines in place.

Change-Id: I190257e9b833c409921bbca74c8ab531b632c60d
Reviewed-on: https://code.wireshark.org/review/15878
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>
7 years agoisns: fix dead code
Martin Kaiser [Mon, 13 Jun 2016 16:30:30 +0000 (09:30 -0700)]
isns: fix dead code

do the special handling for len==0 and tag==ISNS_ATTR_TAG_PORTAL_GROUP_TAG
before going into the different attributes

Bug: 12503
Change-Id: I4dd6dcea25aba2e4963811a7a85f1eed1b906bcd
Reviewed-on: https://code.wireshark.org/review/15875
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>
7 years agotvbparse: change g_strdup_printf to wmem_strdup_printf.
Dario Lombardo [Tue, 3 May 2016 14:51:45 +0000 (16:51 +0200)]
tvbparse: change g_strdup_printf to wmem_strdup_printf.

Change-Id: I57ff604d23967eb1f6481c7019e3eab0389dc3a5
Reviewed-on: https://code.wireshark.org/review/15257
Petri-Dish: Dario Lombardo <lomato@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Reviewed-by: Dario Lombardo <lomato@gmail.com>
7 years agoQt: Fix a Windows version check.
Gerald Combs [Mon, 13 Jun 2016 18:17:48 +0000 (11:17 -0700)]
Qt: Fix a Windows version check.

Fetch the version using QSysInfo::windowsVersion.

Ping-Bug: 12010
Change-Id: If63c576ec4f56f34b76f320cdd927bee427c8cb7
Reviewed-on: https://code.wireshark.org/review/15876
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
7 years agoQt: Main window tab behavior.
Gerald Combs [Sun, 12 Jun 2016 23:07:30 +0000 (16:07 -0700)]
Qt: Main window tab behavior.

Make the main window tab order more closely match the GTK+ UI. Draw a
focus rect in the byte view text while we're here.

Change-Id: I04212c14ea7f0d6865b709533246760adc02f45a
Reviewed-on: https://code.wireshark.org/review/15862
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
7 years agoCisco Diameter: move the XML declaration to the top of the file.
Jeff Morriss [Mon, 13 Jun 2016 18:29:22 +0000 (14:29 -0400)]
Cisco Diameter: move the XML declaration to the top of the file.

... That's where it's supposed to be.

Change-Id: I0ec68dc8757776bf757b52e75bc156acc7264ee5
Reviewed-on: https://code.wireshark.org/review/15877
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
7 years agoDiameter (NSN): the attribute name is 'mandatory' not 'mandatory-flag'.
Jeff Morriss [Mon, 13 Jun 2016 17:52:19 +0000 (13:52 -0400)]
Diameter (NSN): the attribute name is 'mandatory' not 'mandatory-flag'.

Change-Id: Ifa19b59e23278abf332d8ab06dd5ad2059f3e679
Reviewed-on: https://code.wireshark.org/review/15872
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
7 years agoDiameter: close command elements.
Jeff Morriss [Mon, 13 Jun 2016 17:37:08 +0000 (13:37 -0400)]
Diameter: close command elements.

... in order to make the XML (more) valid.

Change-Id: Iefffff3208c98d6ea55d509ed35b57abd268baf3
Reviewed-on: https://code.wireshark.org/review/15871
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
7 years agoConvert AT_SS7PC to a "dissector address type"
Michael Mann [Sun, 12 Jun 2016 16:28:02 +0000 (12:28 -0400)]
Convert AT_SS7PC to a "dissector address type"

The formatting of the address type is determined by a preference in
packet-mtp3.c, so just make MTP3 register the address type.
Use address_type_get_by_name in other dissectors (and export_pdu)
to use the address type.

Change-Id: Ifb32d7de27aeaa23cee8e803e25ffb3c905547b5
Reviewed-on: https://code.wireshark.org/review/15856
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>
7 years agoUse getc_unlocked in a few places.
Gerald Combs [Fri, 18 Mar 2016 20:13:44 +0000 (13:13 -0700)]
Use getc_unlocked in a few places.

Use getc_unlocked or _fgetc_nolock instead of getc in a few places. This
reduces startup time by about 100ms here.

Change-Id: I59ceb09678457c871cce79fcc3ce71998fe4f5af
Reviewed-on: https://code.wireshark.org/review/14518
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>
7 years agoGSM RLC/MAC: add dissection of EC-GSM-IoT control messages
Anton Thomasson [Fri, 10 Jun 2016 14:12:24 +0000 (16:12 +0200)]
GSM RLC/MAC: add dissection of EC-GSM-IoT control messages

Change-Id: Ib7096039aa9761fda96ed8552899833597ba70a6
Reviewed-on: https://code.wireshark.org/review/15812
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
7 years agoGSM RR: add dissection of EC-GSM-IoT ccch control messages
Anton Thomasson [Fri, 10 Jun 2016 14:13:44 +0000 (16:13 +0200)]
GSM RR: add dissection of EC-GSM-IoT ccch control messages

Change-Id: Ib40f78a0d1822bf216af0911f9672c750a78b265
Reviewed-on: https://code.wireshark.org/review/15813
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
7 years agoDiameter: free the diameter directory variable.
Jeff Morriss [Sun, 12 Jun 2016 23:00:37 +0000 (19:00 -0400)]
Diameter: free the diameter directory variable.

It's only needed for a few milliseconds--there's no need for it to stick around
until the epan scope ends.

As discussed on I51813815babb4c40722c38459139ab9e3e3ccb42.

Change-Id: I81fef351ef2d700cc5ec5866340605704173fbdb
Reviewed-on: https://code.wireshark.org/review/15861
Petri-Dish: Jeff Morriss <jeff.morriss.ws@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoQt: Make the capture filter read-only only in main welcome.
Gerald Combs [Sun, 12 Jun 2016 22:10:02 +0000 (15:10 -0700)]
Qt: Make the capture filter read-only only in main welcome.

As noted in gb7897dd, CaptureFilterCombo needs to be read-only until the
app is initialized. Move the code to do so to MainWelcome, otherwise the
capture filter entry in CaptureInterfacesDialog starts out read-only and
stays that way. Disable / enable the entire CaptureFilterCombo instead
of setting its lineEdit read-only status, which provides a stronger
visual indicator.

Change-Id: Ic7bf5b5631b861ecf4dc8cca67beb5bf4ed27510
Reviewed-on: https://code.wireshark.org/review/15859
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoQt: Add the Info column contents to Expert Info.
Gerald Combs [Fri, 10 Jun 2016 16:57:17 +0000 (09:57 -0700)]
Qt: Add the Info column contents to Expert Info.

When "group by summary" is enabled, packet items contain a packet number
followed by a lot of empty space. Fill it with the contents of the Info
column.

Set the first column title to "Severity" or "Packet" depending on the
item selection.

Change-Id: Iff96ab2ec631300ec8f08e55019e191e88cff84a
Reviewed-on: https://code.wireshark.org/review/15814
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoIndent register.c and other cosmetic changes
João Valverde [Wed, 27 Apr 2016 14:07:03 +0000 (15:07 +0100)]
Indent register.c and other cosmetic changes

Change-Id: I06e863e0b87118047f4c3b7618df02b9c7384a34
Reviewed-on: https://code.wireshark.org/review/15836
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>
7 years agoAdded Diameter 3GPP decoding of AVP 1404 - QoS-Subscribed
Binh Trinh [Sun, 12 Jun 2016 18:21:12 +0000 (14:21 -0400)]
Added Diameter 3GPP decoding of AVP 1404 - QoS-Subscribed
(removed spaces)
(removed C++ style comments)

Change-Id: I0f6c7586486b48eab8659a048be451ce3fe1c72b
Reviewed-on: https://code.wireshark.org/review/15850
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>
7 years agoQt: Multi line import from hex dump without offsets
Stig Bjørlykke [Mon, 13 Jun 2016 08:00:28 +0000 (10:00 +0200)]
Qt: Multi line import from hex dump without offsets

Fix importing hex dump without offsets with multiple lines.

Change-Id: I7a7339e375b3125688f5b5d29f493704c7b9944a
Reviewed-on: https://code.wireshark.org/review/15868
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
7 years agoRADIUS: Add Sangoma dictionary
Alexis La Goutte [Sat, 11 Jun 2016 04:14:35 +0000 (06:14 +0200)]
RADIUS: Add Sangoma dictionary

From FreeRADIUS master

commit ba4b4402588ae87497a0b7c87e26eb5cb433c8a7
Author: Alan T. DeKok <aland@freeradius.org>
Date:   Fri Jun 10 14:38:55 2016 -0400

    Added dictionary.sangoma

    from http://wiki.sangoma.com/files/NSC-Radius-Support/dictionary.sangoma.txt

Change-Id: Ie51ea6343a2a8a5b286d70451abce81ca920261f
Reviewed-on: https://code.wireshark.org/review/15823
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoAdd address_type_get_by_name
Michael Mann [Sun, 12 Jun 2016 15:12:15 +0000 (11:12 -0400)]
Add address_type_get_by_name

This allows the decoupling of a dissector registering an address type
so it doesn't need to export the returned registered type.

Change-Id: I49c913d042e70bd4b7ea1e964ba9511bb27304f5
Reviewed-on: https://code.wireshark.org/review/15855
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoCompletely remove dissector_add_handle.
Michael Mann [Sun, 12 Jun 2016 13:38:55 +0000 (09:38 -0400)]
Completely remove dissector_add_handle.

It has been deprecated and replaced with dissector_add_for_decode_as.

Change-Id: I5a4976f83951f749e70b5267570fca188daa7a07
Reviewed-on: https://code.wireshark.org/review/15854
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoUSB: fix dissection of URB setup when the payload was claimed by a sub dissector
Pascal Quantin [Sun, 12 Jun 2016 21:50:04 +0000 (14:50 -0700)]
USB: fix dissection of URB setup when the payload was claimed by a sub dissector

Bug: 12511
Change-Id: Ic9af8358e2a8110f53c587201cafc337630c302a
Reviewed-on: https://code.wireshark.org/review/15858
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
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>
7 years agoUSB HID: add dissector to USB Device 'Decode As' list
Pascal Quantin [Sun, 12 Jun 2016 21:49:04 +0000 (14:49 -0700)]
USB HID: add dissector to USB Device 'Decode As' list

Ping-Bug: 12511
Change-Id: I6193e3bb084adf9925bb6800a756804164030630
Reviewed-on: https://code.wireshark.org/review/15857
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
7 years agoRename a variable
João Valverde [Mon, 13 Jun 2016 02:49:37 +0000 (03:49 +0100)]
Rename a variable

Change-Id: Ie5d859e166fbc8073be88cbbd96bffa877e6b654
Reviewed-on: https://code.wireshark.org/review/15865
Reviewed-by: João Valverde <j@v6e.pt>
7 years agoFinish moving the parenthesis.
Guy Harris [Mon, 13 Jun 2016 02:15:40 +0000 (19:15 -0700)]
Finish moving the parenthesis.

Change-Id: I02f099ef198e360663b03857bdf9538bb63a7de8
Reviewed-on: https://code.wireshark.org/review/15864
Reviewed-by: Guy Harris <guy@alum.mit.edu>
7 years agoFix a compile error.
Guy Harris [Mon, 13 Jun 2016 01:45:45 +0000 (18:45 -0700)]
Fix a compile error.

(Perhaps the Petri dish buildbots should, if a build fails, immediately
mark the change as failing the Petri dish build, without waiting for the
other build(s), so that you don't have to, for example, wait for the
Ubuntu buildbot to finish doing a test build for a change that doesn't
affect code built on UN*X.)

Change-Id: I89ee1616d35c186fcabc0ec989936fa94116df70
Reviewed-on: https://code.wireshark.org/review/15863
Reviewed-by: Guy Harris <guy@alum.mit.edu>
7 years agoDon't assume we can get a module handle for kernel32.dll.
Guy Harris [Sun, 12 Jun 2016 22:30:35 +0000 (15:30 -0700)]
Don't assume we can get a module handle for kernel32.dll.

A failure "shouldn't happen", but check anyway; if nothing else, that
squelches some complaining from the VS Code Analysis tool.

Change-Id: I9b06db399741176d0e9f859eb650bed8a2f96d9c
Reviewed-on: https://code.wireshark.org/review/15860
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
7 years agoQt: Add import from hex dump without offsets
Stig Bjørlykke [Sun, 5 Jun 2016 19:06:51 +0000 (21:06 +0200)]
Qt: Add import from hex dump without offsets

Added support for importing from hex dump without offsets.
This will create one packet with all hex values found in the file.

Change-Id: I0414441721078befeb59aa6a87b9412646cfcf5c
Reviewed-on: https://code.wireshark.org/review/15743
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoFix typo in dissector doc
Léo Gaspard [Sun, 12 Jun 2016 20:35:16 +0000 (22:35 +0200)]
Fix typo in dissector doc

Change-Id: I5ca20080f99905ab23d484d0be054a89c406c583
Reviewed-on: https://code.wireshark.org/review/15852
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoexpert_info_dialog (Qt): fix Uninitialized members (UNINIT_CTOR) reported by Coverity...
Alexis La Goutte [Sun, 12 Jun 2016 16:46:46 +0000 (18:46 +0200)]
expert_info_dialog (Qt): fix Uninitialized members (UNINIT_CTOR) reported by Coverity (CID 1362692)

Change-Id: I1bc71ac7b9c08a9a5749aa9bc88863fa10eb27c7
Reviewed-on: https://code.wireshark.org/review/15848
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jaap Keuter <jaap.keuter@xs4all.nl>
7 years agoIPv6: Add dissection for SRH flags
João Valverde [Sat, 11 Jun 2016 17:09:05 +0000 (18:09 +0100)]
IPv6: Add dissection for SRH flags

Change-Id: I535aba36cc906e8d78cb594900e9a7fdcbd26c83
Reviewed-on: https://code.wireshark.org/review/15828
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: João Valverde <j@v6e.pt>
7 years agoIPv6: Add support for Segment Routing (Type 4) Extension Header
Thibault Gerondal [Sat, 28 May 2016 00:55:04 +0000 (02:55 +0200)]
IPv6: Add support for Segment Routing (Type 4) Extension Header

Bug: 12512
Change-Id: I5672ff3b8c4e8afcc82e957933330e0bf9454b08
Reviewed-on: https://code.wireshark.org/review/15593
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: João Valverde <j@v6e.pt>
7 years agoCMake: Make PROJECT_VERSION_EXTENSION code simpler
João Valverde [Sat, 11 Jun 2016 05:10:17 +0000 (06:10 +0100)]
CMake: Make PROJECT_VERSION_EXTENSION code simpler

The intent was to allow all sorts of overrides but, ugly.

I don't think we need $cmake_package_string either, at least with
these changes.

Follow-up to 7c6e859ccf210a45e1cc0f6da17692845e6b5a23.

(And bdec712166ba924a2cdeaaca8ae580c343eaf02c).

Change-Id: I808b6bd3a3c64d2a67165344e8fe23e8314c27db
Reviewed-on: https://code.wireshark.org/review/15835
Reviewed-by: João Valverde <j@v6e.pt>
7 years agoHave MemoryCheck() directly incorporate the error message and exit.
Guy Harris [Sun, 12 Jun 2016 19:18:14 +0000 (12:18 -0700)]
Have MemoryCheck() directly incorporate the error message and exit.

Manually inline memory_error() in MemoryCheck(), so that static
analyzers know that, if MemoryCheck() sees a null pointer, it exists,
and the null pointer isn't subsequently used.

Use MemoryCheck() instead of the one place where we manually checked for
a null pointer and called memory_error().

Change-Id: Id6b0328cfd17cb14ec9d1e461420896a31573c71
Reviewed-on: https://code.wireshark.org/review/15851
Reviewed-by: Guy Harris <guy@alum.mit.edu>
7 years agoAdd more memory checks, and use MemoryCheck() for some existing checks.
Guy Harris [Sun, 12 Jun 2016 17:34:16 +0000 (10:34 -0700)]
Add more memory checks, and use MemoryCheck() for some existing checks.

Always check for malloc() and realloc() failing.  Use MemoryCheck() for
most of the checks - it's a bit cleaner and makes the error message the
same for those checks.

Change-Id: I533153c697b37b85adfa0259c1352efece0b0486
Reviewed-on: https://code.wireshark.org/review/15849
Reviewed-by: Guy Harris <guy@alum.mit.edu>
7 years agoQt: Draw a border around inactive+selected packet list items.
Gerald Combs [Fri, 10 Jun 2016 18:16:10 +0000 (11:16 -0700)]
Qt: Draw a border around inactive+selected packet list items.

Try to make inactive+selected packet list items more visible by drawing
a border around them. Make an exception for Windows 7 and Vista if a
theme is active.

Bug: 12010
Change-Id: I974069dda92588b80772f577f319569751ff3347
Reviewed-on: https://code.wireshark.org/review/15816
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
7 years ago[Automatic update for 2016-06-12]
Gerald Combs [Sun, 12 Jun 2016 15:11:17 +0000 (08:11 -0700)]
[Automatic update for 2016-06-12]

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

Change-Id: I14deff6b9a13a51d66ebdea361686822583b07c0
Reviewed-on: https://code.wireshark.org/review/15843
Reviewed-by: Gerald Combs <gerald@wireshark.org>
7 years agomongo: don't THROW() an exception from a dissector
Martin Kaiser [Sat, 11 Jun 2016 12:23:59 +0000 (14:23 +0200)]
mongo: don't THROW() an exception from a dissector

just return the overall length even if the value is not in line with the
protocol specification

Change-Id: Ieeb5d1d265acb6de807a1175f07c7981db4b6c2b
Reviewed-on: https://code.wireshark.org/review/15833
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>
7 years agoActually progress through the command data (CID-281394)
Jaap Keuter [Sat, 11 Jun 2016 12:21:17 +0000 (14:21 +0200)]
Actually progress through the command data (CID-281394)

The loop reading through the command data doesn't progress through
it, it just reads until the available data (represented by max_length)
runs out. It therefore:
- doesn't present the commands
- doesn't detect a missing final marker bit (CID-281394)
This change does make the code progress through the command data,
fixing both issues in the process.

Change-Id: I61ba8b56b4a153affe9b4f9a574267f981ef0594
Reviewed-on: https://code.wireshark.org/review/15825
Petri-Dish: Jaap Keuter <jaap.keuter@xs4all.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agodebian: Regenerate ASN.1 dissector code during package build
Balint Reczey [Fri, 29 Apr 2016 08:21:44 +0000 (10:21 +0200)]
debian: Regenerate ASN.1 dissector code during package build

Change-Id: I3f7378ae5c048d3f954238bd04c707f039401ea1
Reviewed-on: https://code.wireshark.org/review/15161
Petri-Dish: Balint Reczey <balint@balintreczey.hu>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoMove Gateway Control Protocol (Context Tracking) into packet-h248.h
Michael Mann [Fri, 10 Jun 2016 04:00:39 +0000 (00:00 -0400)]
Move Gateway Control Protocol (Context Tracking) into packet-h248.h

The Gateway Control Protocol (Context Tracking) is used by both H248
and MEGACO, so the functionality was refactored to epan, but should
really be kept in the dissector directory to minimize (and eventually
completely remove) the epan directory's dependence on it.

Change-Id: I387b46aecde97234086bfdb7d8c546854fa301cd
Reviewed-on: https://code.wireshark.org/review/15798
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoAdd missing scale in TDS type info
Michael Vigovsky [Fri, 10 Jun 2016 12:17:49 +0000 (15:17 +0300)]
Add missing scale in TDS type info

Change-Id: I6734fe448e4ee6f20a0d57b1aaae5e7e61f0cb5c
Reviewed-on: https://code.wireshark.org/review/15811
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoHandle zero-length addresses in cmp_address().
Guy Harris [Sun, 12 Jun 2016 02:13:14 +0000 (19:13 -0700)]
Handle zero-length addresses in cmp_address().

Don't compare the data if there's none to compare.

Change-Id: Ib0e3541e448127869d19afddfc71bb441dba5874
Reviewed-on: https://code.wireshark.org/review/15840
Reviewed-by: Guy Harris <guy@alum.mit.edu>
7 years agoAdd checks to address setting routines.
Guy Harris [Sun, 12 Jun 2016 01:59:25 +0000 (18:59 -0700)]
Add checks to address setting routines.

Fail if:

1) you have an AT_NONE address with data;

2) you have a non-AT_NONE address with a zero length and a
   non-null data pointer, or with a non-zero length and a null
   data pointer.

When comparing addresses for equality, just make sure the types are the
same, the lengths are the same and, if the lengths are non-zero, the
data is the same; don't treat AT_NONE specially - the "lengths are
non-zero" check will make sure we do the right thing.

Make sure when we create an AT_NONE address it has a zero length and
null data pointer.

Change-Id: I5c452ef0d140c2d9aef3004f1cfd124a95b78fb2
Reviewed-on: https://code.wireshark.org/review/15839
Reviewed-by: Guy Harris <guy@alum.mit.edu>
7 years agoStore the tree item to add to later (CID-1159152)
Jaap Keuter [Sat, 11 Jun 2016 12:49:59 +0000 (14:49 +0200)]
Store the tree item to add to later (CID-1159152)

The tree item needed to test and append to isn't being stored,
so the items are never amended with notes, resulting in dead code.

Change-Id: Ib1a9b7994ad12a9a9013d1bc1e1e4c165f34f20f
Reviewed-on: https://code.wireshark.org/review/15826
Petri-Dish: Jaap Keuter <jaap.keuter@xs4all.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoH225: Replace globals that track packet data with p_add_proto_data/p_get_proto_data.
Michael Mann [Thu, 9 Jun 2016 15:02:33 +0000 (11:02 -0400)]
H225: Replace globals that track packet data with p_add_proto_data/p_get_proto_data.

Change-Id: I0380151fb0f45063b81bc55dd5b8dc4add99ad30
Reviewed-on: https://code.wireshark.org/review/15794
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
7 years agoLine up comments.
Guy Harris [Sat, 11 Jun 2016 20:28:29 +0000 (13:28 -0700)]
Line up comments.

Change-Id: Ifda0499e00dfa38c936f7e054ab4d5b3a0fd627f
Reviewed-on: https://code.wireshark.org/review/15830
Reviewed-by: Guy Harris <guy@alum.mit.edu>
7 years agoGSM RLC/MAC: improve dissection of Packet Resource Request message
Vincent Helfre [Thu, 9 Jun 2016 15:47:20 +0000 (17:47 +0200)]
GSM RLC/MAC: improve dissection of Packet Resource Request message

Change-Id: I8513ef550e81a97e1a8ac1c1f365355118d5ebae
Reviewed-on: https://code.wireshark.org/review/15827
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>
7 years agodcerpc-browser: don't THROW() an exception from a dissector
Martin Kaiser [Sun, 29 May 2016 14:35:22 +0000 (16:35 +0200)]
dcerpc-browser: don't THROW() an exception from a dissector

the condition for THROW() will never be true

there's no way to decrement offset below its initial value
the dissect_browser_TYPE_x_data() functions read a uint32 and increment
offset by 4 + the uint32 value that was read

Change-Id: Ia5a63e714ffa0add601960d858452152e4d9b10b
Reviewed-on: https://code.wireshark.org/review/15627
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
7 years agoiso14443: dissect attrib's p3 byte
Martin Kaiser [Fri, 3 Jun 2016 18:11:56 +0000 (20:11 +0200)]
iso14443: dissect attrib's p3 byte

Change-Id: Iec3595a9ee0f7037af1f949804f1022f315d1edc
Reviewed-on: https://code.wireshark.org/review/15824
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
7 years agoftype-protocol: Fix [-Wcast-qual] warnings
João Valverde [Fri, 10 Jun 2016 18:30:36 +0000 (19:30 +0100)]
ftype-protocol: Fix [-Wcast-qual] warnings

Change-Id: Ia8a02d8dc66aead486c8ae3f0bdf4cd82717ed20
Reviewed-on: https://code.wireshark.org/review/15817
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>