Re: What ASN.1 got right

Carsten Bormann <cabo@tzi.org> Tue, 02 March 2021 05:20 UTC

Return-Path: <cabo@tzi.org>
X-Original-To: ietf@ietfa.amsl.com
Delivered-To: ietf@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 91E543A10CA for <ietf@ietfa.amsl.com>; Mon, 1 Mar 2021 21:20:35 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.919
X-Spam-Level:
X-Spam-Status: No, score=-1.919 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, 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 hL7AMOIlYghZ for <ietf@ietfa.amsl.com>; Mon, 1 Mar 2021 21:20:31 -0800 (PST)
Received: from gabriel-vm-2.zfn.uni-bremen.de (gabriel-vm-2.zfn.uni-bremen.de [134.102.50.17]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id C3F713A10D2 for <ietf@ietf.org>; Mon, 1 Mar 2021 21:20:30 -0800 (PST)
Received: from [192.168.217.152] (p5089a828.dip0.t-ipconnect.de [80.137.168.40]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by gabriel-vm-2.zfn.uni-bremen.de (Postfix) with ESMTPSA id 4DqQSS11YMzyTK; Tue, 2 Mar 2021 06:20:23 +0100 (CET)
Content-Type: text/plain; charset=utf-8
Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.60.0.2.21\))
Subject: Re: What ASN.1 got right
From: Carsten Bormann <cabo@tzi.org>
In-Reply-To: <47fcbfb5-36ef-959b-0579-81b36c428e74@network-heretics.com>
Date: Tue, 2 Mar 2021 06:20:11 +0100
Cc: ietf@ietf.org
Content-Transfer-Encoding: quoted-printable
Message-Id: <B2905D48-9C3B-45D4-9987-36DE14723507@tzi.org>
References: <20210302010731.GL30153@localhost> <04f601d70f04$404c5870$c0e50950$@acm.org> <47fcbfb5-36ef-959b-0579-81b36c428e74@network-heretics.com>
To: Keith Moore <moore@network-heretics.com>
X-Mailer: Apple Mail (2.3654.60.0.2.21)
Archived-At: <https://mailarchive.ietf.org/arch/msg/ietf/N2gPMdzJeRTJi-E67Pa2uELj7sk>
X-BeenThere: ietf@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: IETF-Discussion <ietf.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/ietf>, <mailto:ietf-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/ietf/>
List-Post: <mailto:ietf@ietf.org>
List-Help: <mailto:ietf-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ietf>, <mailto:ietf-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 02 Mar 2021 05:20:36 -0000

On 2. Mar 2021, at 05:09, Keith Moore <moore@network-heretics.com> wrote:
> 
> There's something I used to call "ASN.1 disease", but it applies equally to XDR, some uses of XML, and a lot of other systems used to define data structures used in communications.

This is a complex subject.  Trying to do formal description techniques right has been keeping us busy for half a century, and will continue to do so.

The observation you make has been made by everyone watching the evolution of these techniques.
Once you have a tool that helps you manage complexity, you can use that to mitigate the bad effects of complexity, or (what you call ASN.1 disease) to help you create more complexity.  
The tool is neutral with respect to that choice!

Some real-world problems are complex, so a tool that helps manage that complexity is a good thing.

Some of the tools in this space generate their own complexity.
E.g., type systems in programming languages often require the addition of complexity to express the actual shape of the data being processed.

That brought us the differentiation between information models (which describe the natural complexity of the information at hand) and data models (which describe the complexity of that information mapped into specific data structures).

ASN.1 as the first major effort in describing the shape of data for interoperability of course didn’t have the benefit of things we have learned since 1983.

The most important difference between data modeling as used in programming languages’ type systems and as used for interoperability is the need to evolve protocols.  That need does occur in programming, too, but there is a big difference between evolving a system by a single actor and independently evolving parts of systems that are bound together by protocols.

The premier data modeling language that the IETF has is YANG.  YANG is still in the process of grappling with some of the issues arising in model evolution, and I’m sure that will be a major driving force for its own evolution.  But the fact that the tool helps designers to think about evolution issues may be one of its major contributions.

One of the interesting effects that I have seen over time is that experts for a specific modeling tool are often enthusiastic when they manage to express something in that tool that the tool wasn’t designed to support.  Even if that way of doing things creates additional complexity, instead of just managing it.  This is a bit of a Stockholm syndrome — if you have become the hostage of a description technique, and manage to negotiate a bit of freedom from your hostage takers, you may start to like what they are doing for you, forgetting that they are the hostage takers in the first place.  It can be hard to free hostages that have arranged themselves in their hostage situation that way.

So lamenting that more complex systems can be built now is like lamenting that society has become more complex because we now have transportation.
And something is to be said for arranging things in a way that many things can be done by walking.  But it is also important to understand what transportation issues are best solved by adding bicycles, cars, or tanks.  (You may now guess where ASN.1 fits into that parable…)

Grüße, Carsten