Re: [Cbor] CBOR tag for RFC 3339 full-date values

"Richter, Jörg" <Joerg.Richter@pdv-FS.de> Wed, 11 March 2020 20:31 UTC

Return-Path: <Joerg.Richter@pdv-FS.de>
X-Original-To: cbor@ietfa.amsl.com
Delivered-To: cbor@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 8C1403A0C03 for <cbor@ietfa.amsl.com>; Wed, 11 Mar 2020 13:31:51 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.898
X-Spam-Level:
X-Spam-Status: No, score=-1.898 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_NONE=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 J2viNbbnH6Kk for <cbor@ietfa.amsl.com>; Wed, 11 Mar 2020 13:31:49 -0700 (PDT)
Received: from mail.pdv-fs.de (mail.pdv-fs.de [213.208.220.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 7F4353A0C59 for <cbor@ietf.org>; Wed, 11 Mar 2020 13:31:49 -0700 (PDT)
Received: from mail.pdv-fs.de (unknown [192.168.180.94]) by mail.pdv-fs.de (Postfix) with ESMTPS; Wed, 11 Mar 2020 21:31:47 +0100 (CET)
Received: from EXCHDB1.pdv-fs.de (192.168.180.94) by EXCHDB1.pdv-fs.de (192.168.180.94) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1913.5; Wed, 11 Mar 2020 21:31:46 +0100
Received: from EXCHDB1.pdv-fs.de ([fe80::6c4a:8b1b:60f4:4437]) by EXCHDB1.pdv-fs.de ([fe80::6c4a:8b1b:60f4:4437%15]) with mapi id 15.01.1913.007; Wed, 11 Mar 2020 21:31:46 +0100
From: "Richter, Jörg" <Joerg.Richter@pdv-FS.de>
To: Carsten Bormann <cabo@tzi.org>, Mike Jones <Michael.Jones=40microsoft.com@dmarc.ietf.org>
CC: "cbor@ietf.org" <cbor@ietf.org>, Anthony Nadalin <tonynad@microsoft.com>
Thread-Topic: [Cbor] CBOR tag for RFC 3339 full-date values
Thread-Index: AQHV8a0B9fEeIB5RW0GE31JPZx9/XKg3arYAgACfx6iAC3PngIAAF+AAgABFU5A=
Date: Wed, 11 Mar 2020 20:31:46 +0000
Message-ID: <ca2d18b543ce4e60acadad861b8d17da@pdv-FS.de>
References: <CH2PR00MB0679818FABC93C37FF88A404F5E40@CH2PR00MB0679.namprd00.prod.outlook.com> <AB18584F-BA25-464E-8DEC-217067D7643E@tzi.org> <282209381d8b4a8b8e77515142266df2@pdv-FS.de> <DD66072D-5319-49D7-85A0-F6F2D354A52D@tzi.org> <5D27981B-81C8-43C0-A229-66343D9D67B4@tzi.org>
In-Reply-To: <5D27981B-81C8-43C0-A229-66343D9D67B4@tzi.org>
Accept-Language: de-DE, en-US
Content-Language: de-DE
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
x-originating-ip: [192.168.185.1]
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: base64
MIME-Version: 1.0
X-TMASE-Version: DDEI-3.5-8.5.1020-25284.001
X-TMASE-Result: 10--0.029000-10.000000
X-TMASE-MatchedRID: 5IBTOSGC9OS5rzEqaXlmzfHkpkyUphL9s9oMcuQXwlDkMnUVL5d0E5Yj XCUnFqgeiK4AoRG6tnCIV5WesVAuqdEUjczUrsJlD2tWc5ns1ranZS/aYgjrzm2ByMVAI+ZIWiM H3xEQxoP+M7N/it0rQ92ib8sTd6MuNZgeA8Gk1dbJ/bVh4iw9hh+26QzoWaY2a73+XlYDLuytab Krs9q4eSgju7NFfqM/Gg/kX2OR0In6nTFnNW6djhlJRfzNw8afxYt6Ilbxn6lZt8OgpoPsDeiqq 9cInCOjW9zSv8665/7giyJNf8JB3FsibBvw54hingIgpj8eDcDBa6VG2+9jFNZE3xJMmmXc+gtH j7OwNO0NstCXmf87HLOuelgNCzz/hYVD0FfmpwvgXdWmCRAI4N6tWvsRM7YpdDgnzkqM+leCFT9 qgcHJrWLrfmHAqc7dQcBXoYOQIyJd4Cb0CF6MJU8jxvONzeaafEwSr4v8H0fxemJbhO7ZfZTIXc erO/Bu
X-TMASE-SNAP-Result: 1.821001.0001-0-1-12:0,22:0,33:0,34:0-0
X-TMASE-INERTIA: 1-0;;J4gzHMCxkPyYUJl0x8cA1w==;;
Archived-At: <https://mailarchive.ietf.org/arch/msg/cbor/qh27iQpS-yys92ghfsPH0BwhEc4>
Subject: Re: [Cbor] CBOR tag for RFC 3339 full-date values
X-BeenThere: cbor@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Concise Binary Object Representation \(CBOR\)" <cbor.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/cbor>, <mailto:cbor-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/cbor/>
List-Post: <mailto:cbor@ietf.org>
List-Help: <mailto:cbor-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/cbor>, <mailto:cbor-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 11 Mar 2020 20:31:59 -0000

(Replying to more than one message here)

Carsten Bormann: 
> Is that a good way forward?

I am fine with the suggested procedure. 

> What I like about Mike’s draft is that he references RFC 3339, which already is 
> an established specification for how to write dates textually

ISO 8601 also defines this format for dates. It is mentioned in the "Detailed Semantics" 
section of my proposal.

Mike Jones:
> I'm fine merging Jörg's numeric date tag into my draft, provided that the result is 
> not a polymorphic tag, in which the value could be either a number or a string.  
> We should allocate separate tags for string date and numeric date, just as tags 
> 0 and 1 are different, and not polymorphic.

I've got the impression that using a polymorphic tag would be no major problem.
We can even specify that decoders might only support one representation of the tag.
I think it would have the same effect if a decoder supports only one of the two tags.
But either way I would have no objections to using two tags.

Laurence Lundblade:
> I’d suggest the numeric date be restricted to integers. No floats, bignums,
> decimal fractions… 

Yes, that was the plan. Only major types 0 and 1. 

> Fractions of days can be represented by tag 0 or tag 1 using
> hours, minutes, seconds. 64-bit integer counts of days are large enough.

This I don't understand. The proposal only handles whole days as one number.

Another thing to consider:
We should mention that this tag(s) use the proleptic Gregorian calendar. So that 
dates before the Gregorian calendar have a unique semantics.

- Jörg