websocket: restructure tree, always unmask payload
authorPeter Wu <peter@lekensteyn.nl>
Sat, 21 Feb 2015 17:46:25 +0000 (18:46 +0100)
committerAlexis La Goutte <alexis.lagoutte@gmail.com>
Sun, 31 May 2015 16:27:37 +0000 (16:27 +0000)
commitd555aa759b9fb3199eb5822c20c86ed80c4608d3
treef8ccf91ba5c37cda6681226927dbe55f79c17855
parentb407e452797715c056880cc7c5df45c37eece84f
websocket: restructure tree, always unmask payload

Changes:
 - Instead of special-casing masked and unmasked payload data, always
   unmask the payload before using it. This fixes handling of SIP
   requests which are masked and would previously not be dissected by
   the SIP handle. (As a result, many fields are removed).
 - Dissected text protocols (for example SIP) are now shown below the
   Websocket layer instead of inside the payload tree.
 - Use line-based text dissector as fallback for text decoding, and use
   data dissector for binary decoding.
 - Treat the optional close reason as UTF-8 instead of ASCII.
 - Group the close fields (status code, reason) in a subtree below close
   to avoid confusion. Make Close FT_NONE to avoid displaying hex.
 - Split dissection of the payload in separate functions for control and
   data frames.

Change-Id: I78b0078d51271bef94229d4b7c6c528b5e3a424d
Reviewed-on: https://code.wireshark.org/review/7294
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
epan/dissectors/packet-websocket.c