Commit Graph

20 Commits

Author SHA1 Message Date
Michael Mann 9bcac48403 Manually add protocol dependencies derived from find_dissector.
Started by grepping call_dissector_with_data, call_dissector_only and call_dissector and traced the handles passed into them to a find_dissector within the dissector.  Then replaced find_dissector with find_dissector_add_dependency and added the protocol id from the dissector.
"data" dissector was not considered to be a dependency.

Change-Id: I15d0d77301306587ef8e7af5876e74231816890d
Reviewed-on: https://code.wireshark.org/review/14509
Petri-Dish: Michael Mann <mmann78@netscape.net>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-03-20 12:48:48 +00:00
Dave Rigby 3dddc52bb8 Couchbase: Dissect optional expiry in subdoc mutation requests
Add support for dissecting the optional 4-byte expiry field in
sub-document API request packets. This is permitted for any
single-path mutation request; increasing the length of the extras
section from 3 to 7 bytes.

Change-Id: I0609dbc6f6a8e62028cd20a28609fc3016e44910
Reviewed-on: https://code.wireshark.org/review/14004
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2016-02-20 07:35:13 +00:00
Alexis La Goutte 0a00e8a04f couchbase: Fix Dead Store (Dead assignement/Dead increment) Warning found by Clang
Change-Id: Ifee6ba30761cd22a7437f099cbef3764759fe985
Reviewed-on: https://code.wireshark.org/review/13724
Reviewed-by: Dave Rigby <daver@couchbase.com>
Reviewed-by: Dario Lombardo <lomato@gmail.com>
Petri-Dish: Dario Lombardo <lomato@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-02-05 23:31:31 +00:00
Alexis La Goutte b1aa1be33c couchbase: Use some unused hf (and remove unused hf...)
Change-Id: I767a334c82c27b06be7e72461b7f3e3d961784b4
Reviewed-on: https://code.wireshark.org/review/13725
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Dave Rigby <daver@couchbase.com>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-02-05 15:03:23 +00:00
Dave Rigby 2a2cb9dace Couchbase: Dissect multi-path mutation responses
Multi-path mutation responses can have a variable number of values
encoded in them:

- Successful requests have 0..N values, one for each mutation which
  wishes to return a value (e.g. SUBDOC_COUNTER)

- Unsuccessful requests have 1 value, specifying the index and status
  of the first failing mutation

Add support for decoding a variable number of response values.

Change-Id: Ia1f682f7f701829bd808a44ee142ffe912095e15
Reviewed-on: https://code.wireshark.org/review/13688
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-02-04 05:02:54 +00:00
Michael Mann 443a7ed259 new_create_dissector_handle -> create_dissector_handle for dissector directory.
Some of the ASN.1 dissectors still generate a new_create_dissector_handle from the tool itself, so leave those for now.

Change-Id: Ic6e5803b1444d7ac24070949f5fd557909a5641f
Reviewed-on: https://code.wireshark.org/review/12484
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-12-09 12:37:36 +00:00
Sergey Avseyev a4b1cde793 couchbase: implement comand 0x48 to get vbucket seqnos
Also add missing extras definition for DCP buffer acknowledgement

Change-Id: I29cd1e4751b92f119627e42329b2dcfdd7c378df
Reviewed-on: https://code.wireshark.org/review/11419
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: Anders Broman <a.broman58@gmail.com>
2015-10-30 12:11:45 +00:00
Dave Rigby b5ca69b1a6 Couchbase: dissect sub-document commands
Add support for dissecting Couchbase sub-document commands (those
which operate on a subset of a whole document).

Example pcap file:
  https://wiki.wireshark.org/SampleCaptures?action=AttachFile&do=get&target=couchbase_subdoc_multi.pcap

Change-Id: I5394a6f86c036ebd339574bac4e52f7d0821e4bf
Reviewed-on: https://code.wireshark.org/review/10151
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>
2015-08-21 14:23:51 +00:00
Hadriel Kaplan ceb8d954d2 Lua: Expose tcp_dissect_pdus() to Lua
Provide a way for Lua-based dissectors to invoke tcp_dissect_pdus()
to make TCP-based dissection easier.

Bug: 9851
Change-Id: I91630ebf1f1fc1964118b6750cc34238e18a8ad3
Reviewed-on: https://code.wireshark.org/review/6778
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Hadriel Kaplan <hadrielk@yahoo.com>
Tested-by: Hadriel Kaplan <hadrielk@yahoo.com>
2015-01-27 15:14:12 +00:00
Sergey Avseyev 352bd87486 packet-couchbase.c: remove field which does not exists
Change-Id: Ia4a2a6127edbb6a92becf22cd6ee689e5e2a7966
Reviewed-on: https://code.wireshark.org/review/5981
Reviewed-by: Sergey Avseyev <sergey.avseyev@gmail.com>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-12-22 16:17:25 +00:00
Bill Meier b5d7b7ab6e Cleanup use of #includes in non-generated epan/dissector/*.c
Specifically:
- Set packet.h to be the first wireshark #include after
   config.h and "system" #includes.
   packet.h added as an #include in some cases when missing.
- Remove some #includes included (directly/indirectly) in
   packet.h. E.g., glib.h.
   (Done only for those files including packet.h).
- As needed, move "system" #includes to be after config.h and
   before wireshark #includes.
- Rework various #include file specifications for consistency.
- Misc.

Change-Id: Ifaa1a14b50b69fbad38ea4838a49dfe595c54c95
Reviewed-on: https://code.wireshark.org/review/5923
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-12-21 05:46:22 +00:00
Sergey Avseyev bd8d2f583d packet-couchbase.c: dissect more DCP commands
Change-Id: I0e06c89cdda3c1f8e98412fd20737ff6afd26666
Reviewed-on: https://code.wireshark.org/review/5694
Reviewed-by: Sergey Avseyev <sergey.avseyev@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-10 07:23:49 +00:00
Alexis La Goutte 5abfc6028d Couchbase: fix missing comma...
Change-Id: Ic86e07b434e693d2f0fbd9518a23ed49cf49f24d
Reviewed-on: https://code.wireshark.org/review/5572
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-12-02 15:10:11 +00:00
Alexis La Goutte d5aa8a4f4d Couchbase: fix Extended value string 'opcode_vals' forced to fall back to linear search
entry 85, value 128 [0x80] < previous entry, value 245 [0xf5]

Change-Id: I14bbe276eef5fdaa70561764ac4e6f2e174ceabe
Reviewed-on: https://code.wireshark.org/review/5570
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-12-02 14:33:22 +00:00
Sergey Avseyev 485399a780 Update Couchbase dissector
* Include DCP port to the list default ports
* Parse payloads for DCP commands:
  * OPEN_CONNECTION
  * ADD_STREAM
  * STREAM_REQUEST
* Reorganize if conditions to cases
* Update list of known commands

Change-Id: Id37b5c61f0d1084628c6286fd6e4ad722e1d6d99
Reviewed-on: https://code.wireshark.org/review/5388
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Sergey Avseyev <sergey.avseyev@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-12-02 12:20:11 +00:00
Sergey Avseyev 7cdfe52227 Update Couchbase dissector:
* Register new commands:
    * 0x5c: DCP_NOOP
    * 0x5d: DCP_BUFFER_ACKNOWLEDGEMENT
    * 0x5e: DCP_CONTROL
    * 0x5f: DCP_RESERVED4

Change-Id: I22d8eb8f6628e07b2e2ab2bc137688329eead1be
Reviewed-on: https://code.wireshark.org/review/5385
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-11-18 18:53:11 +00:00
Alexis La Goutte 55cc577f33 Couchbase: fix no previous prototype for ... [-Wmissing-prototypes]
Change-Id: Ieaefb9d50bf0224f4e90585d138867d0b88d5814
Reviewed-on: https://code.wireshark.org/review/4956
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-10-28 01:25:43 +00:00
Pascal Quantin e6750fecb3 Couchbase: fix some warnings found by the pre-commit hook
Change-Id: I16c8f5690973465728071abdf85c0f275433951e
Reviewed-on: https://code.wireshark.org/review/4913
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-10-22 18:11:47 +00:00
Pascal Quantin c5a88763fe Couchbase: fix FSF address and reorder opcode_vals array
Change-Id: I41448f9a111dde24c29984d8e4f053fc2a668c9e
Reviewed-on: https://code.wireshark.org/review/4912
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-10-22 17:47:25 +00:00
Sergey Avseyev 589db1c35b Add Couchbase dissector (binary protocol)
Include new Couchbase Server 3.0 DCP support

Change-Id: I38d0edd7d135a92c130a60dab650aef0ab1205be
Reviewed-on: https://code.wireshark.org/review/2956
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-22 13:48:17 +00:00