Commit Graph

25259 Commits

Author SHA1 Message Date
Guy Harris 7cbc790832 Avoid bug 9962 - don't use variables that haven't been set.
See the comment for details.

Change-Id: I0b1800dd884736e00201f09166c0d2bd6795b6c3
Reviewed-on: https://code.wireshark.org/review/1047
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-10 00:49:01 +00:00
Guy Harris 7fb9e9beb0 Fix white space.
Change-Id: Ia36d439d1210f93be25a31d2a7288474688e0d9c
Reviewed-on: https://code.wireshark.org/review/1046
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-09 22:59:35 +00:00
Evan Huus b3350ed946 Update kafka OffsetFetchResponse dissection
Per https://github.com/Shopify/sarama/pull/77 the spec is out of date, there is
no longer a clientID field in certain messages.

Change-Id: Ieeb7b8f1dd32b326b3d9507e3d5897574a1b09fd
Reviewed-on: https://code.wireshark.org/review/1043
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-09 22:42:14 +00:00
Michael Mann 800cd7b95e Improve dissection of RFC 6607. Bug 9960
Change-Id: Ibab13b0ab7b3f0ac1d9c2e305cb428bb17689313
Reviewed-on: https://code.wireshark.org/review/1039
Reviewed-by: Evan Huus <eapache@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-09 22:38:01 +00:00
Michael Mann 4990a8e4ee Added support for MQTT protocol. Bug 9930
Change-Id: I04fc3a6225c56af9905f4f9bbbca5bc10f214843
Reviewed-on: https://code.wireshark.org/review/873
Reviewed-by: Evan Huus <eapache@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-09 22:35:08 +00:00
Guy Harris a07dd033d8 Clean up white space.
Change-Id: If274c6239859127485d306b92a59e4d473c26d39
Reviewed-on: https://code.wireshark.org/review/1045
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-09 21:37:58 +00:00
Guy Harris 4e8d739609 Use tvb_strncaseeql() to check for XML.
This avoids using tvb_get_nstringz0(), and simplifies the check.

Change-Id: Ib33cf22bf79d4fac8896c25a8b879eeb6e506831
Reviewed-on: https://code.wireshark.org/review/1044
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-09 21:32:42 +00:00
Martin Kaiser baa9d10407 iTXt chunk name
Change-Id: I0310368319fe70782bd2c3b48e100292cd93d8c4
Reviewed-on: https://code.wireshark.org/review/1042
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
Tested-by: Martin Kaiser <wireshark@kaiser.cx>
2014-04-09 18:19:30 +00:00
AndersBroman a653014e69 There seems to be some ambigiousy on how to calculate V3 checksums for
IPv4. Introduce a preference to use the same metod as for VRRP V2.
http://ask.wireshark.org/questions/15291/does-wireshark-uses-a-pseudo-header-for-vrrpv3-ipv4-checksum-calculation

Change-Id: I14bf279b0c85405c1963784737add9321d5cb7c4
Reviewed-on: https://code.wireshark.org/review/1040
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-09 14:00:12 +00:00
Guy Harris 1c162ffc7e Clean up the dissection of ServiceContexts.
Make the top-level item for a ServiceContext an item for the
ServiceContext as a while, and put the VSCID under it like other items,
rather than making the VSCID the top-level item.

Don't dissect the VSCID using the value_string field for the Object
Management Group's SCIDs; use that value_string field for the SCID if
the VSCID is 0 (meaning "Object Management Group"), and have no
value_string field for the VSCID otherwise (the interpretation of the
SCID depends on the value of the VSCID).

Dissect the encapsulation information even for unknown ServiceContexts.

If the ServiceContext's length is bigger than what it's supposed to be,
throw an exception if it's also bigger than the data available in the
packet; this squelches a run-time warning in that case.

Change-Id: I11cc62c2e32f4623dba2a551119b3146a7037e6d
Reviewed-on: https://code.wireshark.org/review/1038
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-09 09:45:13 +00:00
Martin Kaiser 9c14703d7b remove usb_trans_info parameter
trans_info is part of the conversation info

Change-Id: I3eafe893324d7d6d23c5475f6f7aa34b7520a6b8
Reviewed-on: https://code.wireshark.org/review/1018
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-09 08:56:28 +00:00
Martin Kaiser 3e228c0f15 setup dissectors don't need bus_id and device_address parameters
these values are already part of usb_conv_info

Change-Id: I79f0c67c91f0f93ba2d52ef08875833eee5e9efd
Reviewed-on: https://code.wireshark.org/review/1017
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-09 08:56:16 +00:00
Guy Harris 7d83a8755a Don't use tvb_get_nstringz0(), use tvb_get_string_enc().
Change-Id: I8e654fa857fca6713198e3d20f2a14a0a444e935
Reviewed-on: https://code.wireshark.org/review/1037
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-09 08:05:07 +00:00
Evan Huus 8d9c45d965 Update some Kafka API constants per lastest spec
Change-Id: Icef981f50e81e5059916e3bde5fa8a1e1fcd92ae
Reviewed-on: https://code.wireshark.org/review/1033
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-09 07:53:35 +00:00
Guy Harris 130b94fa61 Sadly, packet-dcerpc-mapi.c is not yet free of warnings.
Change-Id: Ic208c89a915fc34d0f42ce788a60aa15029d105b
Reviewed-on: https://code.wireshark.org/review/1036
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-09 02:02:26 +00:00
Guy Harris d8a647ece1 OK, that might mean packet-dcerpc-mapi.c now has no warnings.
Change-Id: I22688f0a9b6c04b1e0e9f16c92e7c0713610854c
Reviewed-on: https://code.wireshark.org/review/1035
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-09 00:58:56 +00:00
Guy Harris ed075f2022 Fix some C++ warnings about implicit casts.
Change-Id: I19730e723700f0cc7dcc7ba0db2689f076c7bb5b
Reviewed-on: https://code.wireshark.org/review/1034
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-09 00:51:21 +00:00
Guy Harris 07ee5de75c Get the UDP protocol number from a Wireshark header.
We have epan/ipproto.h to define various IP protocol numbers; use that.

Change-Id: I1ec72028182125f7e11dc159791753ee26d35f12
Reviewed-on: https://code.wireshark.org/review/1027
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-08 19:20:15 +00:00
Guy Harris 7d458fa4a6 Make sure IPv4 address structures really have 4 bytes of data.
Change-Id: If89827677f7503fc67ba9a025f28447a68a98f07
Reviewed-on: https://code.wireshark.org/review/1025
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-08 18:04:22 +00:00
Guy Harris beb4876cb4 Don't assume the data pointed to by an address structure is aligned.
And don't assume you can dereference the pointer nonetheless; that
doesn't work on SPARC, for example - you get an unaligned-access trap.

Instead, use pntoh32() to fetch IPv4 address values from the address
structures.

While we're at it, just use guint32 for those addresses; we don't need
in_addr_t.

Change-Id: I84e6c653fe33b1bc6e67d9097ce423b82f1eb0c8
Reviewed-on: https://code.wireshark.org/review/1024
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-08 17:58:30 +00:00
Guy Harris 3c13e983da Squelch another warning; fix a place assuming 8-bit device IDs.
Change-Id: I0b2d30a7724f9493ef0388232f6c13751e707255
Reviewed-on: https://code.wireshark.org/review/1023
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-08 16:35:55 +00:00
Guy Harris 45f019249c Get rid of some unused functions.
Change-Id: I3b1529826c04334d2df8e3f80a69e8b51651b9cf
Reviewed-on: https://code.wireshark.org/review/1022
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-08 16:14:03 +00:00
Guy Harris 63f18c46b9 USB device addresses need to be 16-bit.
They are 16-bit in the Windows header; make them that way everywhere, so
that we don't get "shortening 16 bits to 8 bits" warnings.

Change-Id: I18f4c4254f224d76a90f3e87bc2f28cba011b5a3
Reviewed-on: https://code.wireshark.org/review/1021
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-08 16:11:51 +00:00
AndersBroman 946dfdbb74 Add application/vnd.oma.xdm-apd+xml
Change-Id: I7d5c3757d5c66da4b1ce91026bdacd9631eda78c
Reviewed-on: https://code.wireshark.org/review/1020
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-08 15:31:20 +00:00
AndersBroman fa4c104812 Update to V11.6.0
Change-Id: I91def9d33901f82b9516a0be464ba9e609da0007
Reviewed-on: https://code.wireshark.org/review/1019
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-08 15:15:28 +00:00
Martin Kaiser 7a3cd91a0a reformat the code for bulk, interrupt urbs
Change-Id: Ib2374df62daf0fc26fb02202d3a64e59b902a1e8
Reviewed-on: https://code.wireshark.org/review/1016
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
2014-04-08 15:04:26 +00:00
Martin Kaiser 8d6b20ad2d move the assignments for is_request, endpoint behind the if statements
Change-Id: Id3938253bbc63cc27823afa326b1997182e3943d
Reviewed-on: https://code.wireshark.org/review/1015
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
2014-04-08 15:04:12 +00:00
Martin Kaiser 7952e2aadf get rid of src_endpoint, dst_endpoint
Change-Id: I0d12586afb3723a0da9d24ab2a4b7aa2426b5512
Reviewed-on: https://code.wireshark.org/review/1014
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
2014-04-08 15:03:56 +00:00
Martin Kaiser e140c0aee5 get rid of tmp_address
Change-Id: I67b83c07c591ef926e5eee94a5526479453d6955
Reviewed-on: https://code.wireshark.org/review/1013
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
2014-04-08 15:03:37 +00:00
Martin Kaiser 6acb386a80 remove another two NULL checks
Change-Id: I091f35ecca8c1418e86ac41018beca705bb1fcd6
Reviewed-on: https://code.wireshark.org/review/1012
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
2014-04-08 15:03:23 +00:00
Martin Kaiser ab145d2057 reformat the nested switch-case part
Change-Id: Idd98825cbbc6bcc27823afac26b1997182e994cd
Reviewed-on: https://code.wireshark.org/review/1011
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
2014-04-08 15:03:08 +00:00
AndersBroman dfd3680ae7 Fix a typo, missing ","
Change-Id: I848cf4c63f9b4c7daf6e63f2e60cd1d5aded7b82
Reviewed-on: https://code.wireshark.org/review/1010
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-08 13:36:28 +00:00
Alexis La Goutte d3b599e6dc Remove some variant of tfs_set_notset...
Change-Id: Ida21963cd68f8fc7387cd2ca37d9436f98318d40
Reviewed-on: https://code.wireshark.org/review/1004
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-08 11:34:07 +00:00
Graham Bloice 7077aaa54f Fixes for Windows build post change 1006
Windows still needs the definition of in_addr_t

Change-Id: I43c417de8e8199cfa58b9d494be5e828f959f1a9
Reviewed-on: https://code.wireshark.org/review/1009
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Graham Bloice <graham.bloice@trihedral.com>
2014-04-08 11:31:37 +00:00
Alexis La Goutte 717613e529 Fix Hello options Flags
* Remove flag I and F (from old draft of draft-ietf-ospf-manet-or)
* Add flag AT (Authentication) from RFC6506 (RFC7166)

Closed-bug: 9941
Change-Id: If6e9c2aa3d2e437ac499253a3061579f344fe607
Reviewed-on: https://code.wireshark.org/review/1003
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-08 10:47:27 +00:00
Alexis La Goutte 1d8cab5029 Make filterable OSPF Hello Packet
Change-Id: Idc7e84fe9f00c30ad6edebcdd11c72d3a7fb77e7
Reviewed-on: https://code.wireshark.org/review/1005
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-08 10:43:34 +00:00
Guy Harris d3df2e588b On UN*X, <arpa/inet.h> suffices for struct in_addr and in_addr_t.
So don't pull in <netinet/in.h>.  Also, avoid <sys/types.h> in
packet-dcom.c.

While we're at it, do *not* assume that pinfo->src or pinfo->dst are
IPv4 addresses.

Change-Id: I5fc8e859780a8d863aaf6e90a21a7039cabae0e6
Reviewed-on: https://code.wireshark.org/review/1006
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-08 08:23:34 +00:00
Alexis La Goutte abbdcd8750 Fix warning found by -Wunused-const-variable (Clang 3.5)
Change-Id: I4506be6ae8deda5e8d1e038b089620a15b650b03
Reviewed-on: https://code.wireshark.org/review/1000
Reviewed-by: Hadriel Kaplan <hadrielk@yahoo.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-08 08:15:11 +00:00
Guy Harris 872dd7031b Don't pretend that sizeof(guintN) will give us more robust values.
What matter in these cases is the number of bytes on the wire; either
sizeof(guint8) = 1, sizeof(guint16) = 2, and sizeof(guint32) = 4, in
which case just using 1, 2, and 4 avoids "64-bit to 32-bit conversion"
warnings on LP64 and LLP64 environments, or they're not equal, in which
case using 1, 2, and 4 rather than the sizeof()s is correct.

Change-Id: I4f15c5fae51958c1aff17ff819a9878fa6bd1f54
Reviewed-on: https://code.wireshark.org/review/999
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-08 01:52:11 +00:00
Guy Harris 75dcbc4f47 Make sure packet-lbttcp.h ends up in the release tarball.
Change-Id: I9e0eec78bd2020040eb8d5fe5e527fb2a6fc6f9b
Reviewed-on: https://code.wireshark.org/review/998
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-08 00:46:17 +00:00
Marko Hrastovec e1ce405449 ASTERIX - added dissector for category 023.
Sample file with traffic is the same as for CAT021 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9953). Apply filter "asterix.category == 23" to see only CAT023 packets.
A small change in actual dissecting code was also needed because of strange item I023/101. The first FX bit is in the second byte and then grows only for a byte.

Change-Id: I3f80e6e46b642efc6f2e19e6f931cdef1c39495a
Reviewed-on: https://code.wireshark.org/review/993
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-08 00:38:50 +00:00
Michael Mann 2f4ca9c8d9 Initial checkin of LBM aka 29West dissectors. See Bug 9718.
Change-Id: If8fcfe1971c8863f370e440f64c36eb7566f6852
Reviewed-on: https://code.wireshark.org/review/113
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-07 23:28:46 +00:00
Guy Harris 8c7fae2da2 Absolute and relative OIDs have different FT_ values.
This squelches some run-time dissector asserts.

Change-Id: I0ce33c4eb6e9c3bd371e47363a981e9a7a0dc789
Reviewed-on: https://code.wireshark.org/review/997
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-07 23:24:54 +00:00
Guy Harris 2b5fc4efdc The encoding of a string is *not* part of its type.
So get rid of the commented-out FT_UCS2_LE; that would be handled as an
FT_STRING, FT_UINT_STRING, or FT_STRINGZ with an encoding of
ENC_UCS_2|ENC_LITTLE_ENDIAN.

Change-Id: I828fc1ed49843a503ec70e6adaf6dadd256df407
Reviewed-on: https://code.wireshark.org/review/996
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-07 23:14:29 +00:00
Guy Harris 172f5cd280 Sort the values in value_strings that we'll treat as extended.
This squelches a run-time warning.

Change-Id: I5b147530b7f9255c3564fe24b56e0ea3eab45852
Reviewed-on: https://code.wireshark.org/review/995
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-07 23:07:35 +00:00
Guy Harris 26f46d40e9 Handle string types with somewhat appropriate encodings.
For various string types defined in X.680, use the appropriate encoding,
or ENC_ASCII|ENC_NA in some cases where we don't have an appropriate
encoding yet.

This most significantly fixes the handling of BMPString and
UniversalString, which are supersets of ASCII (Unicode Basic
Multilingual Plane and Unicode, respectively), but don't encode ASCII
characters as single octets.  It also fixes UTF8String to, well,
properly recognize UTF-8.

This also lets us get rid of the special handling of SyntaxBMPString in
X.509sat (and, in fact, *requires* us to get rid of it, as, otherwise,
the string value appears twice).

Change-Id: I325c4e71a6110278eb23b86e0d986e6439cfc328
Reviewed-on: https://code.wireshark.org/review/994
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-07 22:46:30 +00:00
Gerald Combs a5cb72fe9e Add a Qt I/O Graph dialog.
For each graph you can set:
- Its visibility
- A name
- A display filter
- Color, from a fixed list
- Plot style: Line, Impulse, Bar, Stacked Bar, Dot, Square, Diamond
- Basic Y Axes (packets/s, bytes/s, bits/s)
- Computed Y Axes (SUM, MIN, AVG, MAX)
- Smoothing

You can pan and zoom using the mouse and keyboard. Clicking on a graph
selects the last packet for that interval. If all graphs have the same Y
axis a single label is shown, otherwise a legend is shown.

The time scale (X axis) can be toggled between relative seconds and the
time of day.

Graphs can be saved as PDF, PNG, BMP, and JPEG. Settings are "sticky"
via the io_graphs UAT.

To do:
- Minimize graph drawing delays.
- Figure out why smoothing differs from GTK+
- Everything else at the top of io_graph_dialog.cpp
- Fix empty resets.

A fair amount of code was copied from TCPStreamDialog. We might want to
subclass QCustomPlot and place the shared code there.

Move common syntax checking to SyntaxLineEdit.

Move some common code from ui/gtk/io_stat.c to ui/io_graph_item.[ch] and
use it in both GTK+ and Qt.

Make the io_graph_item_t array allocation in io_stat.c static. The
behavior should be identical and this gives us additional compile-time
checks.

Change-Id: I9a3d544469b7048f0761fdbf7bcf20f44ae76577
Reviewed-on: https://code.wireshark.org/review/435
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Tested-by: Gerald Combs <gerald@wireshark.org>
2014-04-07 20:56:42 +00:00
Hadriel Kaplan e32b38164b Fix Bug 9958: 'SDP displays double spaces between payload formats as a 0 payload format'
Given an SDP m= line such as this:

    m=audio 29156 RTP/AVP 18  0

SDP will show a media format of G.729 (the 18) and then two G.711 entries: one
for the extra space between the 18 and 0, and one format for the 0. The latter
is correct, but the extra space one isn't.

Technically such an m= line is malformed, since only one space is allowed
between payload formats; but it's definitely not a format of 0.

A similar thing happens in many parts of SDP dissection code. It needs to issue
an expert error and handle it gracefully.

Change-Id: I1f1500489a13a55e03fc8ea14b37d99a019fc449
Reviewed-on: https://code.wireshark.org/review/989
Reviewed-by: Hadriel Kaplan <hadrielk@yahoo.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-07 04:22:15 +00:00
Jeff Morriss 26dcdbb402 Tweak the Diameter heuristics a bit more.
Increase the max Diameter message size to 65534 and reject messages whose
flags have both the E- and R-bits set.

Change-Id: Ib11701a47d23ff042a346d59c56f9f0f4410e6b7
Reviewed-on: https://code.wireshark.org/review/990
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-07 04:12:13 +00:00
Alexis La Goutte 58a6487b54 Add WS_DLL_PUBLIC for p_remove_proto_data and tvb_child_uncompres function
Change-Id: If043683f366fedd849688ca3c512707954221a3b
Reviewed-on: https://code.wireshark.org/review/984
Reviewed-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-07 04:09:10 +00:00