Re: [OPSAWG] draft-gharris-opsawg-pcap.txt --- FCS length description

Michael Richardson <mcr+ietf@sandelman.ca> Tue, 22 December 2020 04:13 UTC

Return-Path: <mcr+ietf@sandelman.ca>
X-Original-To: opsawg@ietfa.amsl.com
Delivered-To: opsawg@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id B83633A09AC for <opsawg@ietfa.amsl.com>; Mon, 21 Dec 2020 20:13:41 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.899
X-Spam-Level:
X-Spam-Status: No, score=-1.899 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id gqaLdTtyNkJO for <opsawg@ietfa.amsl.com>; Mon, 21 Dec 2020 20:13:36 -0800 (PST)
Received: from tuna.sandelman.ca (tuna.sandelman.ca [IPv6:2607:f0b0:f:3:216:3eff:fe7c:d1f3]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 603833A09A8 for <opsawg@ietf.org>; Mon, 21 Dec 2020 20:13:35 -0800 (PST)
Received: from localhost (localhost [127.0.0.1]) by tuna.sandelman.ca (Postfix) with ESMTP id 71969389BE; Mon, 21 Dec 2020 23:13:41 -0500 (EST)
Received: from tuna.sandelman.ca ([127.0.0.1]) by localhost (localhost [127.0.0.1]) (amavisd-new, port 10024) with LMTP id svT3lDAsLu-9; Mon, 21 Dec 2020 23:13:40 -0500 (EST)
Received: from sandelman.ca (obiwan.sandelman.ca [209.87.249.21]) by tuna.sandelman.ca (Postfix) with ESMTP id 7F7A8389BC; Mon, 21 Dec 2020 23:13:40 -0500 (EST)
Received: from localhost (localhost [IPv6:::1]) by sandelman.ca (Postfix) with ESMTP id 9E405CDD; Mon, 21 Dec 2020 23:13:32 -0500 (EST)
From: Michael Richardson <mcr+ietf@sandelman.ca>
To: Carsten Bormann <cabo@tzi.org>
cc: Pcap-ng file format <pcap-ng-format@winpcap.org>, tcpdump-workers <tcpdump-workers@lists.tcpdump.org>, opsawg@ietf.org
In-Reply-To: <045B17F6-EC38-461D-98BA-F19B002A780F@tzi.org>
References: <12531.1608597102@localhost> <045B17F6-EC38-461D-98BA-F19B002A780F@tzi.org>
X-Mailer: MH-E 8.6+git; nmh 1.7+dev; GNU Emacs 26.1
X-Face: $\n1pF)h^`}$H>Hk{L"x@)JS7<%Az}5RyS@k9X%29-lHB$Ti.V>2bi.~ehC0; <'$9xN5Ub# z!G,p`nR&p7Fz@^UXIn156S8.~^@MJ*mMsD7=QFeq%AL4m<nPbLgmtKK-5dC@#:k
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
Date: Mon, 21 Dec 2020 23:13:32 -0500
Message-ID: <2330.1608610412@localhost>
Archived-At: <https://mailarchive.ietf.org/arch/msg/opsawg/tXMx2keNPg8KY0ZN_LRzjHn_0nE>
Subject: Re: [OPSAWG] draft-gharris-opsawg-pcap.txt --- FCS length description
X-BeenThere: opsawg@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: OPSA Working Group Mail List <opsawg.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/opsawg>, <mailto:opsawg-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/opsawg/>
List-Post: <mailto:opsawg@ietf.org>
List-Help: <mailto:opsawg-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/opsawg>, <mailto:opsawg-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 22 Dec 2020 04:13:42 -0000

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512


Carsten Bormann <cabo@tzi.org> wrote:
    > On 2020-12-22, at 01:31, Michael Richardson <mcr+ietf@sandelman.ca> wrote:
    >>
    >> #define LT_FCS_LENGTH(x)		(((x) & 0xF0000000) >> 28)
    >> #define LT_FCS_DATALINK_EXT(x)		((((x) & 0xF) << 28) | 0x04000000)
    >>
    >> this suggests that the FCS length is really only 3 bits

    > 4 bits, really (assuming 32-bit unsigned integers).

The LT_FCS_LENGTH(x) (bit 28) is treated as a flag to say that the thing is there.
The DATALINK_EXT(x) might be borked here, only accepting odd values, which
would really be a problem.  I suspect there are bugs here.

- --
Michael Richardson <mcr+IETF@sandelman.ca>   . o O ( IPv6 IøT consulting )
           Sandelman Software Works Inc, Ottawa and Worldwide




-----BEGIN PGP SIGNATURE-----

iQEzBAEBCgAdFiEEbsyLEzg/qUTA43uogItw+93Q3WUFAl/hcmwACgkQgItw+93Q
3WWUmQf/cGNrWzIqKeCjf8u76FPPEDckcL9/6EObSfKkiQ+qvdjqcG5FQnBngHmO
Wpj9sodteZaqsWtRvz3KckChk94WGPZ/1QcoCNo31Lpa5sYsDI0NYBPjD8NNsOLg
z4IINSHjhY4jVxVJuvDDf31e1vAnlKze8uFCnPZ954V6p3k1pV6xcAYtOvXWThKt
XKu0MwXX2GkXoHabpmYJesVL1s1LZDKZ4R8reAzbx+DFyDyM/0qYYprrjOUO6xGd
FkaQaJ37D08TTZ9sjrpJ9xKruPysTYc7QluXgtCuAGtvqeU56wAaWVPJxhzNK4N3
mrApAK/q4NBEjyTP0A/BYD4HcRDW4Q==
=pfBZ
-----END PGP SIGNATURE-----