Commit Graph

50440 Commits

Author SHA1 Message Date
Stig Bjørlykke 52ce5acbdf Detect out-of-bounds when handling zero terminated strings from a TvbRange.
This avoids a wireshark crash.

svn path=/trunk/; revision=53470
2013-11-21 08:42:21 +00:00
Guy Harris 0604779baa Add ui_stats_tree_dialog.h to the list of generated headers not to
install; that should fix the "make distclean" errors.

svn path=/trunk/; revision=53469
2013-11-21 05:55:30 +00:00
Michael Mann 32b66a9671 Fix memory leak from formatted string.
svn path=/trunk/; revision=53468
2013-11-21 03:26:42 +00:00
Gerald Combs daa8b5e046 Fix buildbing ui/qt/wireshark-tap-register.c with autotools.
svn path=/trunk/; revision=53467
2013-11-21 02:12:56 +00:00
Gerald Combs 26325020a2 Try to get qmake to create wireshark-tap-register.c.
svn path=/trunk/; revision=53466
2013-11-21 02:05:36 +00:00
Gerald Combs 31b216d8ce Add the new stats tree.
svn path=/trunk/; revision=53465
2013-11-21 01:31:36 +00:00
Gerald Combs ea28298e96 Add a statistics tree dialog.
Add menu items for each corresponding item in gtk/main_menubar.c that
calls gtk_stats_tree_cb(). Hopefully that's everything. Note that we use
quite a bit less code than the GTK+ flavor and why we might not want to
do that. Change a few things in ui/qt/CMakeLists.txt to more closely
match the GTK+ version. Add plumbing for tap registrations in
CMakeLists.txt and Makefile.am. Add the ability to copy text as CSV or
YAML.

svn path=/trunk/; revision=53464
2013-11-21 01:28:17 +00:00
Michael Mann 3111b6c889 USB CCID and PN532_HCI can be now used in Decode As. Bug 9445 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9445)
From Michal Labedzki

svn path=/trunk/; revision=53463
2013-11-21 01:18:23 +00:00
Michael Mann 091fd3d12b Fix DecodeBy priorities. Bug 9445 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9445)
From Michal Labedzki.

svn path=/trunk/; revision=53462
2013-11-21 01:12:25 +00:00
Guy Harris 8b8cf5671d strncpy() consideered unsafe (it doesn't, for example, guarantee that
the result is null-terminated); use g_strlcpy() (which *does* guarantee
null termination) instead.

svn path=/trunk/; revision=53461
2013-11-21 00:38:22 +00:00
Guy Harris 1ee50439ca We don't need "ws_symbol_export.h" if we're not using anything from it;
see whether that's what's currently causing Windows build problems.

svn path=/trunk/; revision=53460
2013-11-21 00:34:38 +00:00
Jörg Mayer 254614fe73 GTK3 >= 3.10 will fail building if deprecation warnings are on.
Fix this for the cmake build by disabling these warnings.

svn path=/trunk/; revision=53459
2013-11-21 00:28:33 +00:00
Evan Huus 123caff957 Remove one accidentally remaining reference to emem in XMPP utils.
Kill a bunch of now-unused emem tree code.

svn path=/trunk/; revision=53458
2013-11-21 00:18:12 +00:00
Jakub Zawadzki 50aa247c72 Fix Bug #9457 Update BACnet vendor list
Based on attachment #12139 (diff for adding the table) by rtsking117,
but keep original formatting and encoding (ASCII).

svn path=/trunk/; revision=53457
2013-11-20 23:32:02 +00:00
Evan Huus a252026213 Fix minor issue introduced with conversion to new expert API in r51688.
Specifically, proto_tree_add_expert() must take an actual tree node (for example
from proto_item_add_subtree()) and cannot take just any old item node. The
original intent (before the conversion) appeared to be just to put it on the
tree, so do that.

Another assertion gone from
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9406

svn path=/trunk/; revision=53456
2013-11-20 22:51:14 +00:00
Guy Harris bd625113ea status, in main, is now used only if we have libpcap.
svn path=/trunk/; revision=53455
2013-11-20 22:38:15 +00:00
Guy Harris 44b4d2aab0 libui is an static library, not a dynamic library, so the WS_DLL_PUBLIC
stuff isn't necessary and doesn't work on Windows.

svn path=/trunk/; revision=53454
2013-11-20 22:36:05 +00:00
Evan Huus 3b6573c2fb As per suggestion of Mike Morrin via
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9406

The GSM CBCH assertion should be <= 48 not <48. Fixes one of the failing
assertions with the capture from that bug.

svn path=/trunk/; revision=53453
2013-11-20 22:34:36 +00:00
Guy Harris f7f4efabb8 Add support for a new type of frame data record seen in a k18 file, and
handle that file not ending with a 2-byte 0xffff end-of-file record.

This fixes bug 9455, although it doesn't add support for reading an
"index" file for a capture that's in multiple .rf5 files, which is a
separate issue noted in that bug.

It also doesn't attempt to figure out what the data in the new record
type following the data that appears to be the same as that in the other
data record format but preceding the actual packet data is.

svn path=/trunk/; revision=53452
2013-11-20 21:00:55 +00:00
Pascal Quantin ff6a590edb Mark another parameter as unused
svn path=/trunk/; revision=53451
2013-11-20 20:36:22 +00:00
Guy Harris 7d2ae28357 Add code to dump part of a record as ASCII, and use it to dump strings
in a source description record, including the stack.  Dump some other
fields in those records as well.

Attach separate sequential and random read buffers to the private data
structure, rather than allocating them in various routines (and not
always freeing them) and, in at least one case, allocating a single
*common* buffer for all wth's to use.

Fix some comments (the DS0 mask is 32 bytes long, but gets turned into a
bitmask).

Put in a description of what a "stack file"'s contents look like.  Much
of it may be useless to us (for example, we have the notion that TCP has
protocol number 6 built-in...), but the RELATION entries that map from
"BASE" to a protocol could obviate the need to have the user specify a
map from stack file names to starting protocols, and we might be able to
use, for example, entries that map TCP/UDP/SCTP port numbers to
protocols to obviate the need for the user to explicitly use Decode As
or otherwise configure port-to-protocol mappings themselves.

Add a bunch of record length checks before we fetch data from records.

svn path=/trunk/; revision=53450
2013-11-20 20:17:33 +00:00
Pascal Quantin 564b444eb3 Add explicit casts to please GCC
svn path=/trunk/; revision=53449
2013-11-20 20:07:42 +00:00
Pascal Quantin 61a4e7d46d Add explicit casts to please GCC
svn path=/trunk/; revision=53448
2013-11-20 20:05:17 +00:00
Anders Broman 304eba4d95 Mark parameter as unused
packet-ber.c:391: warning: unused parameter 'table_name'

svn path=/trunk/; revision=53447
2013-11-20 19:52:21 +00:00
Michael Mann 01c8945438 Provide "Decode As" functionality through dissectors themselves instead of the GUI. Bug 9450 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9450)
The basic idea behind this design is to have dissectors register with a "decode as list" with their name and dissector table.  When "Decode As" dialog is launched, any "registered" dissector found in the packet will cause a tab to be created in the dialog.  Any GUI (GTK+/Qt/tshark) can just hook into the "decode as list" to see what can be provided.

This patch includes the GUI portion of the functionality (including packet-dcerpc.[ch] because it had some GUI dependencies that are now removed).

Other notes:
1. Some "GUI text" (UTF8_LEFTWARDS_ARROW and similar) made their way into the dissector code.  Not sure how necessary it is and if reformatting the strings to avoid the macros is desired (TCP/UDP use it, SCTP doesn't).

2. I converted the SCTP functionality to have 2 tabs (instead of radio button), currently both are labeled "Transport" which could be confusing to users.  Naming suggestions welcome (as well as for naming of tabs from other dissectors).

3. BER and DCERPC have more opportunity to use Decode As now that they are selected based on dissector presense, not packet_info values.

4. Catapult DCT2000 populates pinfo->ipproto, yet under new design will not show up to do Decode As.  Should a "decode as item" be created for it?

5. BER dissector doesn't have Clear/Show Current functionality working (never did)

6. Bluetooth (in old design) could have been used "capture wide" instead of single packet (creating tabs of values not present in current packet), which goes against what I believe to be in the intent of Decode As, but I'm willing to hear counter-arguments.

svn path=/trunk/; revision=53446
2013-11-20 19:23:02 +00:00
Michael Mann 76ab93ea94 Provide "Decode As" functionality through dissectors themselves instead of the GUI. Bug 9450 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9450)
The basic idea behind this design is to have dissectors register with a "decode as list" with their name and dissector table.  When "Decode As" dialog is launched, any "registered" dissector found in the packet will cause a tab to be created in the dialog.

This patch includes just the dissector portion of the functionality (minus packet-dcerpc.[ch] because it has hooks to the current GUI)

svn path=/trunk/; revision=53445
2013-11-20 19:17:08 +00:00
Alexis La Goutte 91b972ae5e From Jakub via http://www.wireshark.org/lists/wireshark-dev/201311/msg00153.html
Wrong offset incrementation in r53416 (Add status_request_v2 TLS extension dissection (RFC6961))

From me
Fix encoding args

svn path=/trunk/; revision=53444
2013-11-20 18:38:48 +00:00
Michael Mann f34e11fabe Convert ethertype() function into a pure dissector. Bug 9454 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9454)
The main driving force for this was my new Decode As functionality (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9450) that wants a dissector/subdissector table relationship for all dissectors wanting to use Decode As functionality.  The ethertype() function provides the value to the "ethertype" subdissector table, so I think it should be matched to a dissector.  Only odd side effect is the display filter of "ethertype" returns no packets because there is no "item" associated with the dissector.


svn path=/trunk/; revision=53443
2013-11-20 02:28:14 +00:00
Michael Mann ea278d3bf8 Remove a few (now unused) variables.
svn path=/trunk/; revision=53442
2013-11-20 01:44:06 +00:00
Guy Harris a8a3b22e25 Update URL for the Tektronix manual, and fix a typo in the same comment.
Dump the raw contents of records as hex and ASCII, not just hex.

Sort the record types, and add a new one for a type we've seen in a k18
file and about which we know nothing.

For unknown record types, print the type in hex.

svn path=/trunk/; revision=53441
2013-11-19 22:22:16 +00:00
Gerald Combs 22389d7295 Set our IPv6 status when we set addresses.
svn path=/trunk/; revision=53440
2013-11-19 20:30:31 +00:00
Gerald Combs 80db2d0ade Print one YAML item per packet.
svn path=/trunk/; revision=53439
2013-11-19 20:29:58 +00:00
Guy Harris ffd96e2317 Fix some problems with the debugging code.
svn path=/trunk/; revision=53438
2013-11-19 20:12:51 +00:00
Guy Harris 30620ff1be Fix missing semicolon.
svn path=/trunk/; revision=53437
2013-11-19 20:06:47 +00:00
Guy Harris bfc1e51d2d Constants that don't fit in 32 bits must be wrapped in
G_GINT64_CONSTANT().

svn path=/trunk/; revision=53436
2013-11-19 20:05:21 +00:00
Guy Harris 06098fce7b Add routines to set the personal file directory paths (personal
configuration file directory and directory in which to save captures),
have the routine to parse -P options use them, and move that routine to
libui.

Have that routine just return a gboolean.

svn path=/trunk/; revision=53435
2013-11-19 19:45:38 +00:00
Pascal Quantin 935a4debb1 Add dissection of UICC Application Identifier
svn path=/trunk/; revision=53434
2013-11-19 18:20:15 +00:00
Pascal Quantin 5064834661 Fix a typo
svn path=/trunk/; revision=53433
2013-11-19 18:18:52 +00:00
Alexis La Goutte d28d1a8240 Fix compilation with Clang (Remove limitation to -fPIE to only C)
/usr/include/qt5/QtCore/qglobal.h:1079:4: error:
"You must build your code with position independent code if Qt was built with -reduce-relocations. " "Compile your code with -fPIC or -fPIE."

svn path=/trunk/; revision=53432
2013-11-19 12:27:09 +00:00
Alexis La Goutte 11b3ae8653 From Glen Parker via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9449
Add support for new PostgreSQL (9.3) error/notice message fields

Improves the PostgreSQL protocol dissector by adding support for the new error and notice fields which are new in PG 9.3:

http://www.postgresql.org/docs/9.3/interactive/protocol-error-fields.html

In particular, it adds support for the 'p', 'q', 's', 't', 'c', 'd', and 'n' field codes.

From me :
Fix wrong hf name...

svn path=/trunk/; revision=53431
2013-11-19 12:27:01 +00:00
Alexis La Goutte afe84fe4fd From Ralph Böhme via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9439
Add missing SMB_QUERY_CIFS_UNIX_INFO capability flags

Listed in https://git.samba.org/?p=samba.git;a=blob_plain;f=libcli/smb/smb_unix_ext.h;hb=HEAD

svn path=/trunk/; revision=53430
2013-11-19 12:26:49 +00:00
Martin Kaiser 566d080869 add editor modelines
svn path=/trunk/; revision=53429
2013-11-19 08:03:31 +00:00
Martin Kaiser ebc201d640 remove unnecessary if(tree) checks
svn path=/trunk/; revision=53428
2013-11-19 07:56:30 +00:00
Martin Kaiser 6812969bc6 From DSR Corporation
fix segfault in ZigBee APS tunnel commands
pass the data parameter to subdissectors

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

svn path=/trunk/; revision=53427
2013-11-19 07:26:01 +00:00
Martin Kaiser 3d0c92e017 fix compiler warning about write-only variable
svn path=/trunk/; revision=53426
2013-11-19 07:05:34 +00:00
Anders Broman 864431b900 Fix [-Wmissing-prototypes]
svn path=/trunk/; revision=53425
2013-11-19 06:06:38 +00:00
Michael Mann bfcc63972e Remove ppid member from packet_info structure and just pass it to SCTP subdissectors. There are no subdissectors currently in Wireshark source that use the ppid member so any third party dissectors need to update accordingly.
svn path=/trunk/; revision=53424
2013-11-19 01:07:28 +00:00
Guy Harris d766ab6560 The GTK+ "follow stream" dialogs don't support "save as YAML"; put in a
stub case, complete with a "this can't happen" assert failure, to
squelch compiler warnings.

svn path=/trunk/; revision=53423
2013-11-19 00:32:02 +00:00
Guy Harris f089b4cd9d #if 0 out an error check that wasn't doing anything interesting for an
error, and put in a pseudo-code call to stand in for error reporting
code.

Fix a signed-vs-unsigned comparison issue.

svn path=/trunk/; revision=53422
2013-11-19 00:29:37 +00:00
Gerald Combs 45fc7b65e0 Follow dialog data display improvements.
Change the "Raw" character type to UTF-8. I'm not sure it's possible
to show true raw data in a QTextEdit widget and calling it UTF-8 more
accurately repesents what happens when you pass a char * to a QString.
Add a YAML display. Hopefully Scapy users will find it useful.

Sort the the character display items alphabetically. Make sure we go
back to the top of the buffer when we change the direction or character
set. Be less aggressive about setting focus on the "find text" entry.

svn path=/trunk/; revision=53421
2013-11-18 23:39:47 +00:00