Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486bis-06.txt
Ben Maddison <benm@workonline.africa> Fri, 08 October 2021 07:53 UTC
Return-Path: <benm@workonline.africa>
X-Original-To: sidrops@ietfa.amsl.com
Delivered-To: sidrops@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 84ECF3A1429 for <sidrops@ietfa.amsl.com>; Fri, 8 Oct 2021 00:53:54 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.1
X-Spam-Level:
X-Spam-Status: No, score=-2.1 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MSGID_FROM_MTA_HEADER=0.001, RCVD_IN_MSPIKE_H2=-0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=workonline.africa
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 i_PMqGeGkT-r for <sidrops@ietfa.amsl.com>; Fri, 8 Oct 2021 00:53:48 -0700 (PDT)
Received: from EUR02-AM5-obe.outbound.protection.outlook.com (mail-eopbgr00053.outbound.protection.outlook.com [40.107.0.53]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id B30043A142B for <sidrops@ietf.org>; Fri, 8 Oct 2021 00:53:47 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jnRVVWYnetRs2uOA7UDb4Ilt3Sch4R381EfUeWW8OtaXa6n5eDCHYLEeId3CWtScEm/doI33gNUf4/iALoXECO8jmRAmzEdmRJXwT3rl4+69XUszaVEmzzpbPNKAcPuS9nyjj/XayLXBkkafQRuk63gYf/GK2eBJkMeZZhTCXXzaueKeLdGgaxbmp5whRgsgU3VyvUeJQ8VxTjRuEy4Rk63J1E2jMII0NdnGYjxz3ump80HHOMeD09pItnXPhsv2a3awj+iqsJfnxNs9DuAKwks11FRd9C/qzUVqTwjXVKiuNOeSQtJ9KNvP9rJ5gz0wgrlqN4Sy/z82lC9j19tuZw==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=9kIUfbErM6wLpCtQXACzz5bwBGSfD1B5Awn14uu9kEQ=; b=AKSEu+lj8ceoeDRp/WlTuNOQUheBtueEjG/evdFzACAKzV7eF9TkyLSWsC5+yPx+IlJHFJ4j/g4pylFrvLo124JYvfWPhVE6rW/7Q+JyjuZY0Pf4TPYbMYqnEZZS/i8OlkDJ3yU5Ah/29BY/0V3elgaVpLHfTgAMPuZQGwfxgPnZOE5UTSJ3gsmWfh11qkItlg3kD7SoxyC1DnLDrZUZIIyKQDYJLhoCaQ6p6kPIysUxYORprjTC7HgkStv2GJN1Qj1UP2hg+14D/H9cIe5eJX+XNUNxpEACegYfJ7HxONwj+UP5lfRhxlL8M/wIyP7hfcotqazyzRrydN2ZaZy49w==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=workonline.africa; dmarc=pass action=none header.from=workonline.africa; dkim=pass header.d=workonline.africa; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=workonline.africa; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=9kIUfbErM6wLpCtQXACzz5bwBGSfD1B5Awn14uu9kEQ=; b=T1ra+YRqlw5cttjEIXkCCwIPsPVq0nIHYnCMVx+JmQGz41g0sQajyFoZ2giNudlRzlEOUvW+/noW3jir8G75q3i8n8UV+zDncY9H2kUklKOAGcXcKaJs9U1kZWAsXVuWqN6wIZ5pWv5/OZO7CTIdSVNNiDRcTCP1omn8nrY/m7s=
Authentication-Results: vigilsec.com; dkim=none (message not signed) header.d=none;vigilsec.com; dmarc=none action=none header.from=workonline.africa;
Received: from AS8P190MB1078.EURP190.PROD.OUTLOOK.COM (2603:10a6:20b:2e7::13) by AS8P190MB1526.EURP190.PROD.OUTLOOK.COM (2603:10a6:20b:3fb::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4587.20; Fri, 8 Oct 2021 07:53:39 +0000
Received: from AS8P190MB1078.EURP190.PROD.OUTLOOK.COM ([fe80::15f5:8c34:b1be:6006]) by AS8P190MB1078.EURP190.PROD.OUTLOOK.COM ([fe80::15f5:8c34:b1be:6006%7]) with mapi id 15.20.4587.022; Fri, 8 Oct 2021 07:53:39 +0000
Date: Fri, 08 Oct 2021 09:53:33 +0200
From: Ben Maddison <benm@workonline.africa>
To: Russ Housley <housley@vigilsec.com>
Cc: Tim Bruijnzeels <tim@nlnetlabs.nl>, SIDR Operations WG <sidrops@ietf.org>, Steve Kent <stephen.kent@verizon.net>
Message-ID: <20211008075333.muhym3dbscuqmafu@benm-laptop>
References: <51acd845-d937-34a1-359b-7379b45e3fe3@verizon.net> <49e73d37-6d26-7715-da60-c2411020d595@verizon.net> <20210930171302.m7b5utqceotecooc@benm-laptop> <B2E57F08-CA61-4713-BFAE-6D36B20EA1D2@vigilsec.com> <20210930205213.kzwpn3e4ft3q33a6@benm-laptop> <F32DADF2-48C1-4CE7-AC4F-5ADB01C0C224@vigilsec.com> <F069C65C-2BD2-4DD7-9CDB-96DBAA122CD1@nlnetlabs.nl> <AF18F2E7-D16D-4352-8D2C-E9B6D2DE9271@vigilsec.com> <4E8ED276-A8A2-42FC-B0ED-9BB1EEB0C0BF@nlnetlabs.nl> <90554F86-FA27-4364-B13D-BBE7CA4885B1@vigilsec.com>
Content-Type: multipart/signed; micalg="pgp-sha512"; protocol="application/pgp-signature"; boundary="3xuwbugqwyjgcliq"
Content-Disposition: inline
In-Reply-To: <90554F86-FA27-4364-B13D-BBE7CA4885B1@vigilsec.com>
X-ClientProxiedBy: CTXP275CA0019.ZAFP275.PROD.OUTLOOK.COM (2603:1086:100::31) To AS8P190MB1078.EURP190.PROD.OUTLOOK.COM (2603:10a6:20b:2e7::13)
MIME-Version: 1.0
Received: from localhost (160.119.236.41) by CTXP275CA0019.ZAFP275.PROD.OUTLOOK.COM (2603:1086:100::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4566.14 via Frontend Transport; Fri, 8 Oct 2021 07:53:38 +0000
X-MS-PublicTrafficType: Email
X-MS-Office365-Filtering-Correlation-Id: 3a38cf97-3f97-4463-8b87-08d98a30bd38
X-MS-TrafficTypeDiagnostic: AS8P190MB1526:
X-Microsoft-Antispam-PRVS: <AS8P190MB1526DA976320724E61934585C0B29@AS8P190MB1526.EURP190.PROD.OUTLOOK.COM>
X-MS-Oob-TLC-OOBClassifiers: OLM:10000;
X-MS-Exchange-SenderADCheck: 1
X-MS-Exchange-AntiSpam-Relay: 0
X-Microsoft-Antispam: BCL:0;
X-Microsoft-Antispam-Message-Info: AKUnh/W1wdnDpnvAP16urAnRxr6KiMsCnHeX4MsiorgmMiAI135G/AtXnSLaJv7Xt6Qxt/HfRbGvM9Gm080y+6spIaJO08qD5IL9dTJ27enEGxL03jRv8L4Su02hltDEz/3JNAdFR4c6t/GINl4wg5+SGIRQ2+Pk0M+pqyvgW3Q8FcS5F1Ggp2XkhpZG035ukk+jvrQ+L5QBdyBlhwWtX0AHWl9WhuFVLfEL4Fk62imEUxL1n9L2GHRCiFfVxL64x/t4peU0WQFx/nr7fVehDz3/KQWNgu9iMxJHCaCk6+7WBKMvGRYF9jkjXLcOiiHlQ4x7ATfRW03wQKlcPvMUEyv48bWcfV/orkUmEeOKUqaxqFszVVvG+CTeLHuY0b0o4Ii5CITZdqSvrrIRSPhIY20Pw7eXNEChRNdoSKj/TDOProwNwQT4DbXqMbvFHIN888LB0TbyUTTz/6kUsuJfQRGDibW8x9FWcwJ7bhb7CSPBnj871N7ayPpCG2cVFrtmIDtWQm5f21zuWPQnHoy0Mf9lWWROWgEsQuAq5IqEKj7541wXVkq2jbcbH4qS5JdX3H9w61AMu/pGNUohpXv/hVtT3BxBByECRxB6w9wbG4SB9zXN4zQCMvgfE+6juLm0tpdtpcclgGQ7arfv6muhgb3xv9lp3JeNs9eoO1R55c2mJJqJsMGvBmPFnTyVDazRblu9cWCNO1VvBrnCN5DAvJlySl5ZLqkzz7YMBC+7r3SKDq/qtCCgkolU8pyPlcDhVF+NW9BzIYM4NrUBsj9dRg==
X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AS8P190MB1078.EURP190.PROD.OUTLOOK.COM; PTR:; CAT:NONE; SFS:(7916004)(376002)(39830400003)(136003)(366004)(396003)(346002)(6496006)(9686003)(66556008)(186003)(66946007)(66476007)(33716001)(5660300002)(956004)(508600001)(316002)(54906003)(1076003)(44144004)(21480400003)(6916009)(52116002)(6666004)(2906002)(38100700002)(38350700002)(6486002)(86362001)(4326008)(26005)(83380400001)(8676002)(8936002)(46492013)(2700100001); DIR:OUT; SFP:1101;
X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1
X-MS-Exchange-AntiSpam-MessageData-0: xMmRISarrrx+kisQ76RpctNn+r2rWewvPO+DAWSgtiarJtpB6DgmqUDynQGE5RjP61GXUHRGEw+RDQIv9AVkFe2hPEZBhxOQ6uBZxk18COgL9WNl79m9oVgDC1EOrxIifvxDwtyiwMllxM/kp6ruGkaPZShvQXSKj2b8V0e/defj1lehhKjgSPsd/suPl6B3YRe28Ewl0n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R2OCoe4KY1jE7NaP5L5+aAasGvwOgCo+29Qsy293rx+ReA/ZTROY8mnawumETrMM
X-OriginatorOrg: workonline.africa
X-MS-Exchange-CrossTenant-Network-Message-Id: 3a38cf97-3f97-4463-8b87-08d98a30bd38
X-MS-Exchange-CrossTenant-AuthSource: AS8P190MB1078.EURP190.PROD.OUTLOOK.COM
X-MS-Exchange-CrossTenant-AuthAs: Internal
X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Oct 2021 07:53:39.0325 (UTC)
X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted
X-MS-Exchange-CrossTenant-Id: b4e811d5-95e8-453a-b640-0fba8d3b9ef7
X-MS-Exchange-CrossTenant-MailboxType: HOSTED
X-MS-Exchange-CrossTenant-UserPrincipalName: +wzYp1TGvHJ8z+QmMtKvliOe2o3wKbfQVBayYqFuQmlh6tNYBjuoyuU147oOYuRDMxDxs43dIxfCJWKnD2IXAg==
X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8P190MB1526
Archived-At: <https://mailarchive.ietf.org/arch/msg/sidrops/Q3yTWb6A5OwHjHr9ko0t3_YscNM>
Subject: Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486bis-06.txt
X-BeenThere: sidrops@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: A list for the SIDR Operations WG <sidrops.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/sidrops>, <mailto:sidrops-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/sidrops/>
List-Post: <mailto:sidrops@ietf.org>
List-Help: <mailto:sidrops-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/sidrops>, <mailto:sidrops-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 08 Oct 2021 07:53:55 -0000
Hi Russ, Tim, On 10/06, Russ Housley wrote: > > <snip/> > > This is just a matter of style I think. > I've been thinking about this some more, and actually I think that this choice *is* important when considering asn1 -> code compiler friendliness. Consider: Foo ::= SEQUENCE { bar Bar, baz Baz, qux INTEGER } Bar ::= INTEGER Baz ::= INTEGER { a(0), b(1), c(2) } Compiling this to (for the sake of example) rust would be expected to produce something like: struct Foo { bar: Bar, baz: Baz, qux: usize, } struct Bar(usize); enum Baz { a = 0, b, c, } Of course other language type systems have more-or-less direct parallels. Each has advantages and disadvantages: - the "qux" style can be used directly as an integer with no additional work, but you get no safeguards from the type system to prevent using a bare integer where you expected a "qux" value; - the "baz" style gives the type system the ability to distinguish Baz integers from other integers, at the expense of some extra work to define the operations on Baz types that are permitted; and - the "bar" style is not usable as an integer at all (at least not conveniently). The integer value is just there to distinguish the variants in memory. I think this leads to the following general guidance: 1. Use a bare INTEGER ("qux"-style) for unit-less, context-less integer values, that can be sensibly combined in an operation with any other integer value. This seems to be rare in practise to me, so should probably be limited to situations where simplicity is more important than correctness. 2. Use a named type of type INTEGER ("bar"-style) for numbers that can be combined or compared with other numbers of a particular type. For example: bob.age != sue.age # makes sense bob.height + sue.shoe_size # probably a bug! 3. Use enumerations ("baz"-style) when the *only* sensible operation that exists on the underlying numbers is equality comparison. In the present case, I would suggest that the 'version' field falls under category #2, since `foo.version < bar.version` could make sense in some situations. So, I would suggest: Manifest ::= SEQUENCE { version [0] Version DEFAULT 0, ... } Version ::= INTEGER Note that this is orthogonal to whether we explicitly limit the permitted value to 0, which can be done in any of the three schemes. I have no particular view on whether that is a good idea or not. Cheers, Ben
- [Sidrops] I-D Action: draft-ietf-sidrops-6486bis-… internet-drafts
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Christopher Morrow
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Russ Housley
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Stephen Kent
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Russ Housley
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Stephen Kent
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Tim Bruijnzeels
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Christopher Morrow
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Stephen Kent
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Ben Maddison
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Russ Housley
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Ben Maddison
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Russ Housley
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Tim Bruijnzeels
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Russ Housley
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Ben Maddison
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Tim Bruijnzeels
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Russ Housley
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Job Snijders
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Ben Maddison
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Russ Housley
- Re: [Sidrops] I-D Action: draft-ietf-sidrops-6486… Ben Maddison