Re: [Cbor] draft-ietf-cbor-network-addresses: tag validity; deterministic encoding

Brian E Carpenter <> Sat, 09 October 2021 02:55 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 2CD8E3A0FCF for <>; Fri, 8 Oct 2021 19:55:36 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -2.099
X-Spam-Status: No, score=-2.099 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, FREEMAIL_FROM=0.001, NICE_REPLY_A=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (2048-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id wy3vEXOI4tQx for <>; Fri, 8 Oct 2021 19:55:31 -0700 (PDT)
Received: from ( [IPv6:2607:f8b0:4864:20::62d]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 9E79B3A0FD0 for <>; Fri, 8 Oct 2021 19:55:31 -0700 (PDT)
Received: by with SMTP id 21so1124784plo.13 for <>; Fri, 08 Oct 2021 19:55:31 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20210112; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=74KNGUneqTJweMzDVXNC3w1rPkJsheZ20MgeAMHc+aQ=; b=pXypLB8rAFJkF/92njMJ/v6tE8vyV9A/L7E7e1XNCs+jSC+kFpbR+uXmuFRhKf58m2 F6YzBt/Ygjg7W220DpPPhaCoZD5t8DsaqN+1hjZVWhRAfcJMXhreuGMBdtR65unhUgAP 5AhkVQTSjfewHDDgvkI3SMpNKMkaUd2KHe9v0L+MhYkbSUt8teK+nl5lnLYDlPI+uLJo naapkh3YHAe/nnQJdYA0AcsNtimF1NK3qTHT3RquU1EHoZ1rNowRhytsVTFCPFRrGCN3 Trk1gXM6KLAvFNTg22c7cisqnEAglVzRcOBT9iHI/0J2zdoZD8drNVLX1oRytfeTIB+K l9CQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20210112; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=74KNGUneqTJweMzDVXNC3w1rPkJsheZ20MgeAMHc+aQ=; b=T9bdbd3bSJsrZLyssXGgCCVTrscE1cPOonef/0nvWdFt8s2/OyZHotQ/GaF+YsgSlH w8miSpLwrne6Yguw2BmhSWQlE+gvxGcmuYMrC8MPHSEIXrMI86rpVucMlWcE1alFLc5J hDSiKztIgsOwzBJ7bpv+npxMBLUrQq2UNmopjwDsk8xPTKE1WARAVqON081DsuCXdUdl tiXqpArzMV94Z3mZh31sqi9cZDvBiesHeBIw5nqjq3JSxsA1svGi0yFV6v/pqhvrBdTJ 911uarCu4HQcrNiAVeZuhjchR1ynMlj7YCczqhvmKTZv6U+gjNtuIjiGVntfwGdvp0ut KBmg==
X-Gm-Message-State: AOAM531PUFD5s/vE1XszQF/79rc8BB4UXhlNSLbWC/QEYnK4dHl2lWCi Lhx/CvI109IEKtN+ftAjXKXN9DFJ7sk0ag==
X-Google-Smtp-Source: ABdhPJxsif/H9rJ1d6tHr75yXuUXqSdWCEAz/Abxd+/0XQMjYluzQ9r+IBmGcPaqlOGFOqkslJc7vQ==
X-Received: by 2002:a17:902:bb81:b0:12d:a7ec:3d85 with SMTP id m1-20020a170902bb8100b0012da7ec3d85mr12911850pls.17.1633748130528; Fri, 08 Oct 2021 19:55:30 -0700 (PDT)
Received: from ?IPv6:2406:e003:1018:b901:db7:d041:a2d:ce65? ([2406:e003:1018:b901:db7:d041:a2d:ce65]) by with ESMTPSA id c192sm566184pfb.110.2021. (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 08 Oct 2021 19:55:29 -0700 (PDT)
To: Carsten Bormann <>
Cc:, Michael Richardson <>
References: <> <> <>
From: Brian E Carpenter <>
Message-ID: <>
Date: Sat, 9 Oct 2021 15:55:26 +1300
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.10.0
MIME-Version: 1.0
In-Reply-To: <>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: quoted-printable
Archived-At: <>
Subject: Re: [Cbor] draft-ietf-cbor-network-addresses: tag validity; deterministic encoding
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Concise Binary Object Representation \(CBOR\)" <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Sat, 09 Oct 2021 02:55:36 -0000

On 09-Oct-21 12:07, Carsten Bormann wrote:
> On 9. Oct 2021, at 00:40, Brian E Carpenter <> wrote:
>> I think 'recommendation' is a bit strong.
> It’s just “A recommendation” :-)
> Better text that achieves “do this if you don’t know what you are doing” without insulting the reader gladly appreciated.

Oh, we can certainly let this slide. Indeed, my code does expand the bytes object out to 4 or 16 bytes. The spec is fine and entirely implementable in Python3, which is what I wanted to check.

Not midnight here, just Saturday afternoon so maybe this was not the best 
use of my time, but I had to re-debug my code. It took me a while to realise that with one module using calling another one using, the tag handling is slightly different. It's not good if one module thinks the type is cbor.cbor.Tag and the other thinks it's cbor.CBORTag.