Wireshark-commits: [Wireshark-commits] master 69e50be: HTTP: fix bad reassembly with Content-Type a
From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Wed, 08 May 2019 01:54:47 +0000
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=69e50be150eb21af03f3dc526e8c2dada948ecf2
Submitter: "Peter Wu <peter@xxxxxxxxxxxxx>"
Changed: branch: master
Repository: wireshark

Commits:

69e50be by Peter Wu (peter@xxxxxxxxxxxxx):

    HTTP: fix bad reassembly with Content-Type and no Content-Length
    
    Any request or response with the Content-Type header and no
    Content-Length header would cause the HTTP dissector to combine all
    segments until the end of the connection. This is bogus, it should only
    do this for HTTP responses under stricter conditions.
    
    To fix this issue: 1) explicitly disable body desegmentation for
    messages that never have a message body, 2) restrict "desegmentat until
    the end" to HTTP responses.
    
    The "Connection: Keep-Alive" case was a fix for bug 1142, but that is
    now properly addressed by checking for the 304 status code.
    
    Bug: 13116
    Change-Id: I02371ac88ec2de6ee966fdc6df0dd246ad49c46d
    Reviewed-on: https://code.wireshark.org/review/33035
    Petri-Dish: Peter Wu <peter@xxxxxxxxxxxxx>
    Tested-by: Petri Dish Buildbot
    Reviewed-by: Alexis La Goutte <alexis.lagoutte@xxxxxxxxx>
    Reviewed-by: Peter Wu <peter@xxxxxxxxxxxxx>
    

Actions performed:

    from  bc4ffef   print: remove leak in ek_check_protocolfilter().
     add  69e50be   HTTP: fix bad reassembly with Content-Type and no Content-Length


Summary of changes:
 epan/dissectors/packet-http.c | 68 ++++++++++++++++++++++++++++++++++++++-----
 epan/dissectors/packet-rtsp.c |  5 +++-
 epan/dissectors/packet-sip.c  |  4 ++-
 epan/req_resp_hdrs.c          | 42 ++++++++------------------
 epan/req_resp_hdrs.h          |  8 +++--
 5 files changed, 85 insertions(+), 42 deletions(-)