Wireshark-commits: [Wireshark-commits] master-3.0 7dab25f: Fix the FCS handling.

From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Wed, 27 Feb 2019 23:35:22 +0000
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=7dab25fcac7114535d0613cfa0716c887db44d41
Submitter: "Guy Harris <guy@xxxxxxxxxxxx>"
Changed: branch: master-3.0
Repository: wireshark

Commits:

7dab25f by Guy Harris (guy@xxxxxxxxxxxx):

    Fix the FCS handling.
    
    All the complicated stuff to see whether the captured data includes all
    of, some of, or none of the FCS is necessary, and should not have been
    removed.  The previous code would sometimes dissect packet data at the
    end as both payload *and* FCS.
    
    This also means that the decryption code doesn't have to worry about the
    FCS, and expects the payload handed to it *not* to have the FCS.  Update
    callers to handle that.
    
    This puts back the changes from
    e4d3916530aed332fcb39d4017e633bd51c4277c, for which the comment was:
    
        Clean up the way we handle the FCS.
    
        For the "802.15.4 with FCS" link-layer type, strip what FCS we find,
        if any, off and use that new tvbuff for all dissection except for
        checking and dissection of the FCS itself.
    
        For the "802.15.4 without FCS" link-layer type, don't fake an
        uncaptured FCS by increasing the reported length, just use the
        tvbuff as is.
    
        This means we handle 802.15.4 the same way we handle other
        link-layer types where the FCS might, or might not, appear as
        part of the captured data.
    
    "Handling stuff at the ends of packets is hard, let's go shopping!"
    
    Change-Id: Iaf3e8392efec9d1c35f73966e22f2a3ae91317a1
    Reviewed-on: https://code.wireshark.org/review/32254
    Reviewed-by: Guy Harris <guy@xxxxxxxxxxxx>
    (cherry picked from commit 6e6781919a1e0f21ec99d92df184f53616f7d0a1)
    Reviewed-on: https://code.wireshark.org/review/32255
    

Actions performed:

    from  d1a13b2   QUIC: update ref draft url to draft-18
     add  7dab25f   Fix the FCS handling.


Summary of changes:
 epan/dissectors/packet-ieee802154.c | 103 ++++++++++++++++++++++++++++++------
 epan/dissectors/packet-wisun.c      |   2 -
 2 files changed, 88 insertions(+), 17 deletions(-)