[Multiformats] IETF 116 Dispatch Multiformats: Responses to Jonathan Rosenberg

Manu Sporny <msporny@digitalbazaar.com> Tue, 11 April 2023 20:55 UTC

Return-Path: <msporny@digitalbazaar.com>
X-Original-To: multiformats@ietfa.amsl.com
Delivered-To: multiformats@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id B9B32C1CCCA5 for <multiformats@ietfa.amsl.com>; Tue, 11 Apr 2023 13:55:09 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.097
X-Spam-Level:
X-Spam-Status: No, score=-2.097 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, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=digitalbazaar.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id cZZBOUC6sYIp for <multiformats@ietfa.amsl.com>; Tue, 11 Apr 2023 13:55:05 -0700 (PDT)
Received: from mail-il1-x133.google.com (mail-il1-x133.google.com [IPv6:2607:f8b0:4864:20::133]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id A65DBC1CCCA0 for <multiformats@ietf.org>; Tue, 11 Apr 2023 13:55:05 -0700 (PDT)
Received: by mail-il1-x133.google.com with SMTP id r11so3988839ilb.9 for <multiformats@ietf.org>; Tue, 11 Apr 2023 13:55:05 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=digitalbazaar.com; s=google; t=1681246504; h=cc:to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=DypCS0RXe2a0fLBswjiypvu1UkjHgudSjOVHq5dkGTE=; b=F9iQ9l2nxkzZRgkzh9VIIEgFzdB9p0DAVs51fFAOwKns6HB1SdyQulmAox2cfffsge lmiSca3odbsfVb+YhpbsPh2JPGZIoTRbHXoph0PByi3q8S3CUT2DgWHsJKS26Z3g6zbs +xfivjGAAzPfIBY7UT+bRI1h5qGEzjmoBg04PkMRh/nBnnMtY2Iw4uFahXd6/E8DRphS XinhVh7925Eoo1iNh0kEDXC3t7hi6agMN5JxwEBIzgYMGNRWotSpOLtNjcqjXEYVnXfh uRjDoO5SsJuY5KpPDzqU4XeenaWYyMnbXQ4LFBgoxB4OSEOWfYD+3pDL39lsbVQoVbzn XWvQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681246504; h=cc:to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=DypCS0RXe2a0fLBswjiypvu1UkjHgudSjOVHq5dkGTE=; b=J3sRJollo28hmP/EqPAx5weMJdjBF38xOAyf33Vezcrks6fudwwXS/koql6AA1M8U6 JKLJ43f34r50+0qL6799syVEwdE6/masebl0vMXFAB9MB5UoOUeYda11sq0Lp7skxEKY 2UrcnOgF696HH1yR++b56smpDeq1sDjQvkl9lgvJBOzRCzOMk3GuCivjcjzuJx4sj6lQ bBwxs7SYt35jJUxfeedD4VjYKGANzJyySVnnO6QfP5izsxnQ4NrnzXNsr3bsPM5MKYAH BXtsygUk3Ac7xrG4HWBSSku4kcRRoPNyKiv7upv/1zcrosfd/5QjS+g2cv9wEmOdfg6f chXg==
X-Gm-Message-State: AAQBX9fzfgqS8niRilEzAM6FBGcHBFHx9EJ7HkJjU7WBcilmi1HqW93N xkt/Bf8vu4RRgKiR+gnYTOAi2uI2LLjVE5FMbrmbEbfsxGxr66qe5+Y=
X-Google-Smtp-Source: AKy350Zc6S0How6s1iR0SNMYw/p7wMYfYFyg6gejQHTlJG7IVnObOtp/UiszRsfuMlq2GVxlhPhxHyypcLkG5HA+9qI=
X-Received: by 2002:a92:c54b:0:b0:326:d02c:c756 with SMTP id a11-20020a92c54b000000b00326d02cc756mr7351137ilj.4.1681246504371; Tue, 11 Apr 2023 13:55:04 -0700 (PDT)
MIME-Version: 1.0
From: Manu Sporny <msporny@digitalbazaar.com>
Date: Tue, 11 Apr 2023 16:54:28 -0400
Message-ID: <CAMBN2CRybrgLB=M-Thgidv6tif=PdCfkRsQSNgm+aYFskrZa5w@mail.gmail.com>
To: multiformats@ietf.org
Cc: jdrosen@jdrosen.net
Content-Type: text/plain; charset="UTF-8"
Archived-At: <https://mailarchive.ietf.org/arch/msg/multiformats/FDsMI_tKHGa45ukBfABa-yN83to>
Subject: [Multiformats] IETF 116 Dispatch Multiformats: Responses to Jonathan Rosenberg
X-BeenThere: multiformats@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: Discussion related to the various Multiformats data formats <multiformats.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/multiformats>, <mailto:multiformats-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/multiformats/>
List-Post: <mailto:multiformats@ietf.org>
List-Help: <mailto:multiformats-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/multiformats>, <mailto:multiformats-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 11 Apr 2023 20:55:09 -0000

Jonathan Rosenberg said:
> I was surprised there was no magic cookie in front of these Multiformats, it collides with UU-encoded strings, is this a specific domain encoding or something meant for global use? Is there a reason there is no magic cookie in front of it?

If I understand your question correctly, Multiformats are not designed
to be a replacement for magic bytes in file headers or as a
replacement for things like uuencoding.

They are meant to be used in application-specific data structures
expressed in syntaxes like JSON, YAML, and CBOR. In other words, there
is always an encapsulating data model that signals that the value is a
Multiformat. For example, in JSON

{
  "url": "https://foo.example/file.dat",
  "digestMultibase": "zjEkl...Wkd"
}

One could imagine that the JSON object above is identifying a file by
a URL and then associating a Multibase encoded digest value
(presumably encoded as a Multihash value). The specification
associated with that JSON object would state clearly what Multibase
and Multihash combinations are expected/allowed.

Therefore, I believe that the answer to your question is: "There is no
magic cookie in front of it because Multiformats are always used where
the fact that the value is a Multiformat value is known before the
value is consumed. Multiformats are not a replacement for magic bytes
in file headers or uuencoding."

Did that answer your question, Jonathan?

-- manu

-- 
Manu Sporny - https://www.linkedin.com/in/manusporny/
Founder/CEO - Digital Bazaar, Inc.
https://www.digitalbazaar.com/