Commit Graph

52896 Commits

Author SHA1 Message Date
Jeff Morriss 989f4ffd69 Fix up indentation.
Change-Id: I9c217cfb0246c763ec7084bb928440d8aab88f99
Reviewed-on: https://code.wireshark.org/review/1416
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-28 18:20:00 +00:00
Philip Rosenberg-Watt 388859a2e3 DPoE OAM message decoding as per CableLabs spec.
Priority given to messages tested in DPoE 1.0 ATP.

Change-Id: I6ba3f1a8ca018f2231ad60f2f347ac57f1f93a00
Reviewed-on: https://code.wireshark.org/review/1076
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-04-28 17:35:56 +00:00
Jeff Morriss ab87070956 Fix Restoration-Priority's AVP code.
Fixes https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=10057

Bug: 10057
Change-Id: I88bb6825006b038065f8edff61066557445f1dc6
Reviewed-on: https://code.wireshark.org/review/1413
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-28 15:56:46 +00:00
Philip Rosenberg-Watt cd68b4744c Add dissector for LINKTYPE_EPON
See IEEE Standard 802.3-2012 Section 5, Clause 65 and CableLabs DPoE
Security and Certificate Specification 1.0, Section 6.

Currently dissects 1G mode. 10G mode will be added when hardware is
available.

Change-Id: I6232af9bf6807644ef66a120d97e5fa5927988fe
Reviewed-on: https://code.wireshark.org/review/1284
Tested-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-04-28 15:26:32 +00:00
Pascal Quantin 484b183e3f MBIM: make the backward compatibility function static
Change-Id: I51bbdf9c0dbb80a8350ec7762e588ca3182dce63
Reviewed-on: https://code.wireshark.org/review/1408
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-04-28 09:18:46 +00:00
Alexis La Goutte a203bbbd5b Fix Dead Store (Dead assignement/Dead increment) warning found by Clang
Change-Id: I349a5aa7248979aa32eda9f853fd660dc01bdd08
Reviewed-on: https://code.wireshark.org/review/1407
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-28 08:34:12 +00:00
Anish Bhatt 581cdcee10 Add Support for IEEE DCBx (8021az)
Sample captures attached at https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=10055

Closed-bug:10055
Change-Id: Ib10e8d2a8aecdcf488eb174ed76a259433528f4a
Signed-off-by: Anish Bhatt <anish@chelsio.com>
Reviewed-on: https://code.wireshark.org/review/1403
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-28 08:32:12 +00:00
Lorand Jakab 7aebb0cec9 Fix issues reported by clang-analyzer
Change-Id: Iefb52c674be99af167eef7b2eba249607c1dfefd
Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu>
Reviewed-on: https://code.wireshark.org/review/1406
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-28 06:25:59 +00:00
Mike Gerschefske e240c4e9cd Updated ospf link state router messages to use proto_tree_add_item instead of proto_tree_add_text.
Change-Id: Icb04aaa68e7e8b79116a6ac48d1897eb387aab3e
Reviewed-on: https://code.wireshark.org/review/1404
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-28 06:22:50 +00:00
Evan Huus 1a7e5c9e28 tvb_reported_length_remaining() returns gint
not size_t, which was giving 64/32 conversion errors on some platforms

Change-Id: Idf81dc98f8921a92840731d742d6e46a40e1387f
Reviewed-on: https://code.wireshark.org/review/1405
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-04-28 03:17:41 +00:00
Michael Mann 0cfd4eb4a1 Add support for DCBX cee/cin protocol
CEE Spec here : http://www.ieee802.org/1/files/public/docs2008/az-wadekar-dcbx-capability-exchange-discovery-protocol-1108-v1.01.pdf

From a wireshark POV, CIN is the same as CEE with a different OUI subtype, and one less supported TLV.

bug:10039
Change-Id: I5aa4f1be2ecc43ecad6e86633231e6e39695af6e
Reviewed-on: https://code.wireshark.org/review/1330
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-28 00:13:27 +00:00
Martin Mathieson 0a3f725260 Change preference default to use RRC-signalled value for SN field length of DRBs.
Change-Id: Ibc56c901938f490f1fb0fede7e2fe0fbfc659250
Reviewed-on: https://code.wireshark.org/review/1402
Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
2014-04-27 22:13:59 +00:00
Michael Mann 98ed927290 Fix rare case of wmem map being O(n)
For 'x' equal to 0, HASH() macro also returns 0 which makes wmem map O(n).
When random generator will return 0 just use 1.

Change-Id: If484091352a719aea27135a705d37ff4c184a13b
Reviewed-on: https://code.wireshark.org/review/1387
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-27 21:55:53 +00:00
Evan Huus 4272cb8786 Revert part of g757db64e484b009c3
It was intended to change the DTLS decryption test, but changed the SSL test
file instead, which led to the SSL test mysteriously failing. The SSL capture
really is http, so that's the right protocol, and the port is the standard 443,
not 4433 (which was perhaps a typo?).

Change-Id: I84448c2326d2a4301a4bba9607f8ba90a495531d
Reviewed-on: https://code.wireshark.org/review/1401
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-04-27 21:55:03 +00:00
Pascal Quantin 3b1903c394 MBIM: fix compilation with GLib versions < 2.22.0
Change-Id: I27e794347dc0988f0f34798cb62f08a11a217176
Reviewed-on: https://code.wireshark.org/review/1400
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-04-27 21:42:52 +00:00
Alexis La Goutte 5d2e945dbc Fix Dereference of null pointer found by Clang analyzer
packet-gvcp.c:2101:7: warning: Access to field 'req_frame' results in a dereference of a null pointer (loaded from variable 'gvcp_trans')

Change-Id: If39453f9f2ade551fd8c7e369fd60325c16df24b
Reviewed-on: https://code.wireshark.org/review/1393
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-27 21:22:56 +00:00
Pascal Quantin 7ddf2b4540 MBIM: use wmem hash map functions for request/response tracking
Change-Id: Ie550b0ef2b57827f610c4c6a83ff14868e853125
Reviewed-on: https://code.wireshark.org/review/1399
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-04-27 21:21:37 +00:00
Michael Mann 5ce5d0677e swIPe IP Security Protocol
bug:9996
Change-Id: I7c7ab7dfa81e44d6bf9affe7bfb0cd9f0a221adf
Reviewed-on: https://code.wireshark.org/review/1379
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-27 20:55:58 +00:00
Daniel Stenberg c35870b0af packet-http2: updated to http2 draft-12
From Alexis La Goutte
Fix warning found by pre-commit

Partial-Bug: 10054
Change-Id: I976884a240a55bb2287a802d72668a2c845179c0
Reviewed-on: https://code.wireshark.org/review/1295
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-27 20:23:27 +00:00
Alexis La Goutte b57fc91c68 Fix Dead Store (Dead assignement/Dead increment) warning found by Clang
Change-Id: I75aa99b020c92e7caf7efebe34cd1af3763cf592
Reviewed-on: https://code.wireshark.org/review/1397
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-27 20:23:01 +00:00
Alexis La Goutte 298633ec33 Add Modelines info
Change-Id: Ib6e1c68e47f2c66d444ac26d1d48f5ef3e14b949
Reviewed-on: https://code.wireshark.org/review/1396
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-27 19:55:40 +00:00
Alexis La Goutte ea729ed5b7 Add Modelines info
Change-Id: I8ce92fcd103a18fad2ea4c0b873914af38d48155
Reviewed-on: https://code.wireshark.org/review/1395
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-27 19:55:11 +00:00
Alexis La Goutte 574a3ef42b Add Modelines info
Change-Id: I978198266523a0b1f0ba9d4ed6848664a6fa3637
Reviewed-on: https://code.wireshark.org/review/1394
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-27 19:55:01 +00:00
Alexis La Goutte e0b15f5e17 Fix warning found by -Wunused-const-variable (Clang 3.5)
packet-gvcp.c:493:27: error: unused variable 'linkconfiguration_class' [-Werror,-Wunused-const-variable]

Change-Id: Id31ced029af9700f47230df4afa5c0a4aaecf6d3
Reviewed-on: https://code.wireshark.org/review/1392
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-27 19:42:56 +00:00
Jakub Zawadzki af2eebef2a Reorder fields in http_conv_t to save some memory.
On amd64 before patch: sizeof(http_conv_t) == 88, after: 72 bytes.

Change-Id: I2863f1c7223a904dadfbe68dc41bc61fc2cc378a
Reviewed-on: https://code.wireshark.org/review/1388
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-27 19:30:51 +00:00
Alexis La Goutte dec179eab8 Try to fix Mac OS X buildbot
packet-http.c:2629: warning: implicit conversion shortens 64-bit value into a 32-bit value

Change-Id: I6a423639a53c24431fcfd79e0a235f2885ea86c2
Reviewed-on: https://code.wireshark.org/review/1389
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-27 19:30:10 +00:00
Peter Wu 878f341ffa prefs: fix ASAN error due to invalid indirection
For pref_current, indirection of pref->varp.string will cause a read of
size 8. This will cause a global buffer overflow error for all smaller
types, for example lbmc_use_heuristic_subdissectors (size 4).

Reproduce: compile Wireshark with -fsanitize=address, open Preferences
and select OK or Apply. Result: ASAN crash.

To fix this, only indirect a pointer if the storage size is known, a
void pointer stores the address of the constant value (pref_default,
pref_stashed) or the address to the value (pref_current). Note that
pointers of different types are of equal size, I could take
valp.pref_(anything).

While at it, remove superfluous 'break' keywords where a 'return'
keyword is present.

Change-Id: I05a69e8f14a1ecb4e5d2a0c0f0b71ed3f0a41d70
Reviewed-on: https://code.wireshark.org/review/1286
Reviewed-by: Evan Huus <eapache@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-27 18:56:03 +00:00
Peter Wu 5600ae100a http: Fix src/dest mapping for proxied connections
Using value_is_in_range is making quite some assumptions, namely (1) the
proxy server is always run on a registered HTTP port, and (2) the
source (client) port is always not HTTP. The former is quite a strong
assertion which fails to hold when using a custom port (8008) that got
detected through heuristics.

Fix this by recording the source address and port pair for the server
and then check this against the current packet.

This fixes detection of a SSL conversation where two conversations got
detected instead of one. Example: 8008 is proxy, 443 is target server.
Now the proxied conversation got detected as 443 --> "client port"
(server to client, ok) and 443 --> 8008 (client to server, not ok,
should be "client port" --> 443).

bug:7717
Change-Id: I05113ec2aca6c9296184759a8a62eb32cbfcbb4f
Reviewed-on: https://code.wireshark.org/review/1380
Reviewed-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-04-27 18:08:44 +00:00
Hauke Mehrtens 338269fe41 ssl/dtls: add keyfile support to dtls
This moves the keyfile and psk options from the ssl code into ssl-utils
and then uses them also for dtls.

This is the last missing part for bug 9499 from my side.

Change-Id: Ie2fe5bc565eabe1e6ce62498c985b8a36e913b0f
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Reviewed-on: https://code.wireshark.org/review/1369
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-27 18:00:21 +00:00
Peter Wu 162a8c72f0 http: Display a list of cookies
For long cookies, the label "[truncated] Cookie: foo=v..." is not really
helpful. Add a new subtree to display individual cookies, this makes
copying values much easier.

A new "http.cookie_pair" field was added instead of re-using
"http.cookie". This has the advantage that `tshark -Tfields -e
http.cookie` does not end up with duplicates. At the same time, one can
match against individual cookie values.

I also considered to limit the number of cookies to be split, but as
there is no limit on the number of headers, I decided not to be
restrictive for cookies either.

Change-Id: I98d9522867811278ade3e04aab02e517f997928b
Reviewed-on: https://code.wireshark.org/review/1186
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Evan Huus <eapache@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-27 17:53:38 +00:00
Gerald Combs 7b401202d5 [Automatic manuf, services and enterprise-numbers update for 2014-04-27]
Change-Id: I0745df4a0a0447abf7ab4c7555d9d195ac40eb78
Reviewed-on: https://code.wireshark.org/review/1384
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2014-04-27 15:05:29 +00:00
Stefan Doehla ff854bc650 SAP: fix dissection of Originating Source address
Regression introduced in commit c131f9a074

Bug: 10029
Change-Id: Ia99ca36216dd26e41f926cc67e52827e665c40eb
Reviewed-on: https://code.wireshark.org/review/1383
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-04-27 12:39:37 +00:00
Michael Mann f8e8c85f99 Limit the start of HTTP request/response to a printable character.
From Martin Mathieson.

In a profiled run with FTP traffic, the HTTP dissector looking for the end of a line of data (which was binary) was taking around 3% of runtime.

bug:8822
Change-Id: I2617d1e49030bd5ad85b0e818c48c01dc6fae075
Reviewed-on: https://code.wireshark.org/review/1373
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-27 12:26:49 +00:00
Pascal Quantin b588511c9c T38: fix access to uninitialised variables
Bug: 10050
Change-Id: I7bc2d1b99bcb1241705a2561d9360a006fb9cb47
Reviewed-on: https://code.wireshark.org/review/1382
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-04-27 12:15:21 +00:00
Pascal Quantin 7929d9acf9 SSL: fix compilation without GnuTLS and Gcrypt
Change-Id: Ic783f9ac2b7abcbace67ce48239b0506ac237267
Reviewed-on: https://code.wireshark.org/review/1381
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-04-27 10:36:36 +00:00
Martin Mathieson 616d4c9c1b Change preferences - always want to try to decrypt signalling PDUs
Change-Id: Ib34f12b5f8dd276612aed2fe0192c94e847858f2
Reviewed-on: https://code.wireshark.org/review/1377
Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
2014-04-26 22:33:32 +00:00
Evan Huus c6d41f961b Have DTLS just dissect the test capture as data
Follow-up to g757db64e484b009c33b67b5fa38e109d7b8f5e78 which changed the filter
being tested but didn't change the target protocol, so the test was still
failing because it was still trying to use HTTP.

Change-Id: I6675cfad3bba63f7a536eb7ae82e4b25132d108e
Reviewed-on: https://code.wireshark.org/review/1375
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-04-26 21:45:48 +00:00
Guy Harris 1ba06e65b0 Fix FSF address.
Change-Id: Ic79fcf7e1bebb9821d9d9db43c2a4f4291beb706
Reviewed-on: https://code.wireshark.org/review/1374
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-26 17:50:08 +00:00
Hauke Mehrtens 3b76de7dc2 dtls: run dissector for decryption also on server hello extensions
The dissector only ran through the server hello extensions for the tree
and not in the ssl decryption pass. This resulted in
ssl_dissect_hnd_hello_ext() being always called with ssl == NULL. For
SSL this was also called with ssl != NULL.

Change-Id: I22f7b1089731124b3ca1a2b8515f307c4a021b7f
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Reviewed-on: https://code.wireshark.org/review/1370
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-04-26 15:47:47 +00:00
Peter Wu 720f504dd6 ssl: support any address/port combi for priv key
Both "any port" and "any address" are supported separatedly, but not the
combination of both. This also has the effect that the combination of
any address with the special keyword "start_tls" did not work.

Fix this by checking for a private key with the combination of any
address and port.

Change-Id: Icb49d6728f032a05007dcb7ac73ec0528778441a
Reviewed-on: https://code.wireshark.org/review/1368
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-04-26 15:36:17 +00:00
Peter Wu 4250dfd3f5 ssl: return early if no private keys are found
There is no need to check for private keys if there are none. In
addition, print the number of keys for debugging purposes.

Change-Id: Idc9d650e0bf087c0f647dba4e5bd4920b4f6e228
Reviewed-on: https://code.wireshark.org/review/1367
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-04-26 15:35:43 +00:00
Peter Wu 7805e5a495 ssl: Reduce chance of hash-collisions SSL private keys
The wildcard address contains all zeroes, resulting in the same hash
for 0.0.0.0 and ::. Not really problematic, but it does not sound
great either.

Change-Id: I099128973a1bd8bb5c88d0abcab3ea4ecc3a96c9
Reviewed-on: https://code.wireshark.org/review/1366
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-04-26 15:34:46 +00:00
Peter Wu c7cbdb4f22 Change ssl_find_private_key to void
No caller checks its return value (which is always 0).

Change-Id: I18461ee6e5d369722c8c2b2ea1e409423aa5d631
Reviewed-on: https://code.wireshark.org/review/1365
Reviewed-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-04-26 15:34:38 +00:00
Lasse Luttermann Poulsen 03cb700571 Added fields used by HP MSM access points.
Change-Id: I367c99bb351993f05161d683eb54f08e5852145f
Reviewed-on: https://code.wireshark.org/review/1347
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-26 02:46:59 +00:00
Lorand Jakab 742acca3f8 Dissect all details in NAT-T LCAF type...
... and remove last remaining proto_tree_add_text() calls!

Change-Id: I22e5446a06c22ba1f30f342b21f7676641a7f2e7
Signed-off-by: Lorand Jakab <ljakab@ac.upc.edu>
Reviewed-on: https://code.wireshark.org/review/1352
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-26 02:00:43 +00:00
warren babe895d3a Updated gvcp dissector
Change-Id: I49f6acecdbcdf171ba28af171f8067322cc5ecf1
Reviewed-on: https://code.wireshark.org/review/1220
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-26 01:53:38 +00:00
Guy Harris 662e4bd556 wtap_read() and wtap_seek_read() handle caplen > len; don't do it here.
Change-Id: Iac083abdbaaa4666124e5b296e6f8306ee90f32d
Reviewed-on: https://code.wireshark.org/review/1363
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-25 21:31:24 +00:00
Guy Harris 4f8c8c215d This doesn't have separate captured and actual length, either.
Change-Id: I4605bde8a2951ea78d507bab6fcf004ebef6f38f
Reviewed-on: https://code.wireshark.org/review/1362
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-25 21:26:18 +00:00
Guy Harris 6335782ccd Put the common code for reading Logcat packets into a routine.
Then have the read and seek-read routines both use that routine.

Change-Id: I3d11df82644207d0ae59486231c91e1f044090ab
Reviewed-on: https://code.wireshark.org/review/1361
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-25 21:17:01 +00:00
Guy Harris 6ef0420434 No need to set "line" when setting "firstline".
"line" is used only in the main loop processing the lines.

Change-Id: I370c6516867a9c972f9673b3362141f0f42d178a
Reviewed-on: https://code.wireshark.org/review/1360
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-25 20:13:14 +00:00