Re: [Ace] WGLC draft-ietf-ace-mqtt-tls-profile

Marco Tiloca <marco.tiloca@ri.se> Sun, 20 September 2020 16:45 UTC

Return-Path: <marco.tiloca@ri.se>
X-Original-To: ace@ietfa.amsl.com
Delivered-To: ace@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id A13483A0B4B for <ace@ietfa.amsl.com>; Sun, 20 Sep 2020 09:45:39 -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, HTML_MESSAGE=0.001, MSGID_FROM_MTA_HEADER=0.001, NICE_REPLY_A=-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=ri.se
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 jv6gZFP2aUGc for <ace@ietfa.amsl.com>; Sun, 20 Sep 2020 09:45:35 -0700 (PDT)
Received: from EUR02-HE1-obe.outbound.protection.outlook.com (mail-eopbgr10042.outbound.protection.outlook.com [40.107.1.42]) (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 5B12F3A0ADD for <ace@ietf.org>; Sun, 20 Sep 2020 09:45:34 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=auWmiIA/YDmo2KMw7r/BmHoT/BjXfYF6qYTa6ur0XadUGBpTWJWDf52yGBB+tDfelMUTxcbws+NR754ssWeMCgZJ4T+z8dm55E9KcA4b6Yo1Q0nKlfxOBJ2vwO/0BM8i7hOMqmwh7WMku0cR+87y7ZQn7QumdZ4Q1nDGgqLiXnYETQqhjt1GBgUyHIMPCFk7a5eeeWKhfngdv2UMBuslLYaEHHw0QJVp4TsS0a2OciqtoDs3YHCmdrrvjW+f98In/JyL652mU2IEqg6RtY76rHlg79BewueDhvoUI0GkRq9RafU8mzlz9ptPzZoTGjuJtZiieZz94/DaDgiZlUA22Q==
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-SenderADCheck; bh=y9AqSh6KYMM7WY2+mVs0BQpxn4wHIJahynAm/6l0RHs=; b=WF0rbaBdHfpwcvZY8oDGge7pcXMsUH8YKouXvqTwucrJVYHSVgpoAwg2WGVBppPwggO/KAVK4WnHOZcQjzbagJMj18JC7ZiTk1uxn9qmpQaM09uNjl/AppbTRtye8PEqpcressLUjbxiIkdo4qYigUdUfiQuKOJPCfeaIYZgPYOrs+PsDBVxu0J5KWnlw3wQHRzQ9uTWHqTBlUdVg7d36QaxsO5YJ5Vy/N1jBGT1VUkIKQHYbcPlShywxVkBfg+YZIrRhPwFYqNVZe9QtmG3RHFhHdnYw/mSMf7ffu2qH85JoRBxLeZQkhA+DWCfV/n3Gxb6Z2CTj+HkQeKevM/OEA==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=ri.se; dmarc=pass action=none header.from=ri.se; dkim=pass header.d=ri.se; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ri.se; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=y9AqSh6KYMM7WY2+mVs0BQpxn4wHIJahynAm/6l0RHs=; b=Z8GGOUxtcvX1Kqf65PVMixTbdhFkAM/pvlOzIB+PLvIAjJ9PL2fVdK0JJ8f+NB89M3HRjislAyBS1o2J0SuFfPvEZ42/mUD6oEZ6eFiBLqZcRIh6O/lmXdnWpeiFHCj2KwSEG+sHLmv3Bepkj8Lj8B58ppKNCKRsHCy7p+my3FA=
Authentication-Results: ietf.org; dkim=none (message not signed) header.d=none;ietf.org; dmarc=none action=none header.from=ri.se;
Received: from DB8P189MB1032.EURP189.PROD.OUTLOOK.COM (2603:10a6:10:16e::14) by DB8P189MB0714.EURP189.PROD.OUTLOOK.COM (2603:10a6:10:125::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3391.11; Sun, 20 Sep 2020 16:45:31 +0000
Received: from DB8P189MB1032.EURP189.PROD.OUTLOOK.COM ([fe80::a11e:4abe:4099:5157]) by DB8P189MB1032.EURP189.PROD.OUTLOOK.COM ([fe80::a11e:4abe:4099:5157%9]) with mapi id 15.20.3391.011; Sun, 20 Sep 2020 16:45:31 +0000
To: Cigdem Sengul <cigdem.sengul@gmail.com>
Cc: Ace Wg <ace@ietf.org>
References: <CADZyTkmMd7iO3jo359QSS+y1LoSKvoDw+vJonD8VUfheEgXLTA@mail.gmail.com> <41fa81ca-fd99-8a04-03c0-e33007bca78b@ri.se> <CAA7SwCObG4KS_mDCLOmPe2B7Y1sVYXCR1tSdHrPKMbJR3=Ua-g@mail.gmail.com>
From: Marco Tiloca <marco.tiloca@ri.se>
Autocrypt: addr=marco.tiloca@ri.se; prefer-encrypt=mutual; keydata= mQENBFSNeRUBCAC44iazWzj/PE3TiAlBsaWna0JbdIAJFHB8PLrqthI0ZG7GnCLNR8ZhDz6Z aRDPC4FR3UcMhPgZpJIqa6Zi8yWYCqF7A7QhT7E1WdQR1G0+6xUEd0ZD+QBdf29pQadrVZAt 0G4CkUnq5H+Sm05aw2Cpv3JfsATVaemWmujnMTvZ3dFudCGNdsY6kPSVzMRyedX7ArLXyF+0 Kh1T4WUW6NHfEWltnzkcqRhn2NcZtADsxWrMBgZXkLE/d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Yj3aOz0NbUyf5GW+iotr3h8+KIC OYZ34/BQaOLzdvDNmRoGHn+NeTzhF7eSeiPKi2jex+NVodhjOVGXw8EhYGkeZLvynHEboiLM 4TbyPbVR9HsdVqKGVTDxKSE3namo3kvtY6syRFIiUz5WzJfYAuqbt6m3TxDEb8sA9pzaLuhm fnJRc12H5NVZEZmE/EkJFTlkP4wnZyOSf/r2/Vd0iHauBwv57cpY6HFFMe7rvK4s7ME5zctO Ely5C6NCu1ZaNtdUuqDSPA==
Message-ID: <d0931b48-0eb5-2c08-a22d-f881024c9e8d@ri.se>
Date: Sun, 20 Sep 2020 18:45:23 +0200
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0
In-Reply-To: <CAA7SwCObG4KS_mDCLOmPe2B7Y1sVYXCR1tSdHrPKMbJR3=Ua-g@mail.gmail.com>
Content-Type: multipart/signed; micalg="pgp-sha512"; protocol="application/pgp-signature"; boundary="1eRftb4WU8wHsvrysjQU9DlwYS0CazXoz"
X-ClientProxiedBy: HE1P190CA0043.EURP190.PROD.OUTLOOK.COM (2603:10a6:7:52::32) To DB8P189MB1032.EURP189.PROD.OUTLOOK.COM (2603:10a6:10:16e::14)
MIME-Version: 1.0
X-MS-Exchange-MessageSentRepresentingType: 1
Received: from [10.8.1.8] (45.83.91.172) by HE1P190CA0043.EURP190.PROD.OUTLOOK.COM (2603:10a6:7:52::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3391.11 via Frontend Transport; Sun, 20 Sep 2020 16:45:30 +0000
X-Originating-IP: [45.83.91.172]
X-MS-PublicTrafficType: Email
X-MS-Office365-Filtering-Correlation-Id: 20dbe39e-0ae2-48e3-86ac-08d85d849621
X-MS-TrafficTypeDiagnostic: DB8P189MB0714:
X-Microsoft-Antispam-PRVS: <DB8P189MB0714A22B1CE5B54D08923B6E993D0@DB8P189MB0714.EURP189.PROD.OUTLOOK.COM>
X-MS-Oob-TLC-OOBClassifiers: OLM:8273;
X-MS-Exchange-SenderADCheck: 1
X-Microsoft-Antispam: BCL:0;
X-Microsoft-Antispam-Message-Info: KeKfqPPLxdyc8KF+hSSXkX8kDwlk08nbaNUTAtKzJla+wBZ5cQi0+3YvEhWQkJ0gYHvfvmSLvDw9mM9eXCShPFg1plHSp01EhnQ6+971WvT9PsGbjImImKBJRM9Ydwx8HwGejSHWQQtXCH1I2QFNwElcFr4P/7iO8rbO5ddGVKtfj1f0bR0zg860BL3s/DF72kaBFuLP66e+CpHYC8KA3NtDu4GPbWTq2CCxQQpkxneeoICTar4iVeEiXFirsMKyzMClnFh3ToGloMm3++SjAjVlBilCQjwuuF3J2yVlJTUueooW5+iL8uSILTbJiVViNL0vsVuODZdfy+BGHFWs+hfH4MfTaxoeAt4NdUwthmJqHGIw/Rjgt1RFwTllH0gRQJy7Inj1ya53h1magIoggapGsGPNyHxHyOaGMWlCe1XM3LUvVNttq/Oe8YfFWPwMesSKTGeps5AR8FIvKcn2sQ==
X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DB8P189MB1032.EURP189.PROD.OUTLOOK.COM; PTR:; CAT:NONE; SFS:(4636009)(396003)(39850400004)(366004)(346002)(376002)(136003)(8936002)(6666004)(316002)(86362001)(235185007)(30864003)(16576012)(83380400001)(52116002)(186003)(16526019)(21480400003)(8676002)(31696002)(36756003)(5660300002)(2906002)(166002)(2616005)(66574015)(478600001)(6916009)(66946007)(966005)(44832011)(31686004)(66556008)(66476007)(53546011)(956004)(6486002)(4326008)(26005)(33964004)(43740500002); DIR:OUT; SFP:1101;
X-MS-Exchange-AntiSpam-MessageData: LbHV06C8vx0qcusOKqScDug04tuQqzyYygoesVrC7n4XkWpI/ec1T8NhawBQcXZ1EvjCpPeCLsXOv7tfcYcpwA1gouPSdkCFuUhS6CyD4nQsOSZnWBy/L2tnJDSTh15ex0PYAI+F1kFK9DDdCHBIK8r7vho90V+ahQ3DnymtALI/abCVs5IEvPnmo6UUgogucR+QUavZBUX4+40aGFTeRDn803BlatdmejBC6olCV+QrGJLKoWbURX+/5kCZyWQrB+oSD5qJ4YbWXwYE+R/8Mb9NTt8dKIv/qDfNT7SohmTNCBQnouV4H3i0ZdWNua6EpLbMUUja5NjyUcbttG2pxa3HbF20eIcEB8xG110RB8jBkC5TVeJmrpgXIorhYRvGBCKhuF4t187DA5kXHRIcOUZS1QNoqbNvV+XmCoEnqIKxGZm6CwAD3NciFOmpWrDDhVLbspZ7MHyCPlc4NfhtDatCF6EUcCdeHpiLZFmgemlBLRXebJ+rcZhVI1+V7yGdgaaNz9sH+DVVySU03JUHmZAhYaCnV27rUALYu7VgMfVT38SXnoIdWtMClMHP+WvmxE5CqKvZEd1VeoW7XkPBfk4vhEzFqNlVxmf3a3pTIZ0W25GbXJJ23IgX07Y8yQsB4urefi77HtLV8uqHR4uXlQ==
X-OriginatorOrg: ri.se
X-MS-Exchange-CrossTenant-Network-Message-Id: 20dbe39e-0ae2-48e3-86ac-08d85d849621
X-MS-Exchange-CrossTenant-AuthSource: DB8P189MB1032.EURP189.PROD.OUTLOOK.COM
X-MS-Exchange-CrossTenant-AuthAs: Internal
X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Sep 2020 16:45:31.1887 (UTC)
X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted
X-MS-Exchange-CrossTenant-Id: 5a9809cf-0bcb-413a-838a-09ecc40cc9e8
X-MS-Exchange-CrossTenant-MailboxType: HOSTED
X-MS-Exchange-CrossTenant-UserPrincipalName: zipyk2gNNvbEP1Rxz/R2ep9UlMrZ1KXZCub0zQ9Ruq19EpFAAKNMoO+OI9d0fWzGTyVx8nZnbp5l2t4gaT19sw==
X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB8P189MB0714
Archived-At: <https://mailarchive.ietf.org/arch/msg/ace/iCI2nAF047mY2zOYbaVxKoMo1gw>
Subject: Re: [Ace] WGLC draft-ietf-ace-mqtt-tls-profile
X-BeenThere: ace@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Authentication and Authorization for Constrained Environments \(ace\)" <ace.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/ace>, <mailto:ace-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/ace/>
List-Post: <mailto:ace@ietf.org>
List-Help: <mailto:ace-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ace>, <mailto:ace-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sun, 20 Sep 2020 16:45:40 -0000

Hello Cigdem,

Thanks, please see my replies inline.

Best,
/Marco

On 2020-09-20 16:02, Cigdem Sengul wrote:
> Hello Marco, 
> Thank you for the review. My responses are inline. 
> Kind regards, 
> --Cigdem
>
>
>
>
>     [General]
>
>     * Refer the AIF adopted draft rather than the individual submission.
>
>     * Some references are included twice side by side, e.g. RFC 4949
>     and RFC 7800. 
>
>      
>
>     [Section 1]
>
>     * Add an inline reference to RFC 8446 for TLS 1.3. I think it's
>     good adding also references to CoAP and CBOR(-bis).
>
>
>  
>   [CS: Added to https://github.com/ace-wg/mqtt-tls-profile/issues/65 
> <https://github.com/ace-wg/mqtt-tls-profile/issues/65>, will be fixed
> in the next submission]  
>
>  
>
>     [Section 2.2.1]
>
>     * In the paragraph on "TLS:Known(RPK/PSK)-MQTT:none", the last two
>     sentences can clarify that they apply to TLS 1.2. As to the
>     analogous alternative provision of the token in PSK mode for TLS
>     1.3, that can point to "identity" in the "identities" entry of
>     "Pre-Shared Key" ClientHello Extension.
>
>
> [CS: I think it is better to change the wording to match what is
> defined for TLS 1.3, as it is the recommended version.
> Created new issues at https://github.com/ace-wg/mqtt-tls-profile/issues/69
>  Will fix. ]
>  
>
>
>     [Section 2.2.4.1]
>
>     * Section 2.2.4 said that the two-byte integer length indicates
>     the amount of following bytes within Authentication Data. However
>     this section refers to the two-byte length as only the token
>     length, i.e. it does not seem to cover also the MAC/Signature
>     (whose length might be assumed from the used algorithm), even
>     though that's still part of Authentication Data. Could you please
>     confirm or clarify?
>
>
> [CS: This is because the Authentication Data explained under 2.2.4  is
> binary data.  The
>    binary data in MQTT is represented by a two-byte integer length,
> which indicates the number of data bytes, followed by that number of
>    bytes.
> So, we have the total length of the entire Authentication Data, 
> Token length + token  + (total length - token length) of MAC data. 
> I hope this is more clear. 
>
> Do you think I should repeat what binary data is at the subsections
> rather than explaining in 2.2.4?
> ]

==>MT
So the Authentication Data includes some <Length ; Content> binary data,
possibly followed by some extra data (here a MAC/Signature). Correct?

I think it's worth clarifying this when introducing the Authentication
Data, and say what is part of the binary data here in Section 2.2.4.1.
<==

>
>
>     * It's worth making it explicit that the PoP key is used to
>     compute the MAC or the client signature. 
>
>
>     * s/and, the server/and the server
>
>     * Remove the final closed parenthesis.
>
> [CS: Added to https://github.com/ace-wg/mqtt-tls-profile/issues/65 
> <https://github.com/ace-wg/mqtt-tls-profile/issues/65>, will be fixed
> in the next submission]  
>  
>
>     [Section 2.2.4.2]
>
>     * Shouldn't the Authentication Data in the AUTH message from the
>     server start with a 2-byte server nonce length?
>
> [CS: the client is calculating a MAC over its nonce and server nonce
> and sending it back, with the information of its nonce. 
> I assumed the RS would remember its nonce length]

==>MT
I was referring to the AUTH packet from the server, including its RS
challenge.

The message is still including Authentication Data, and in any other
case this seems to start with a 2-byte length field, as also described
in Section 2.2.4.

If that length field is actually optional, I can see it might be omitted
here, since the client is supposed to get always an 8-byte nonce from
the server.
<==

>  
>
>
>     * Like for the AUTH message from the client, see the comment above
>     for Section 2.2.4.1 about what the 2-byte length covers (i.e.,
>     here too I would have expected it to cover also the MAC/signature,
>     not just the nonce).
>
>
> [CS: Has my previous explanation clarified this?
>
> client_nonce length + nonce
> (the size of AUTH DATA - client_nonce_length)  of MAC  of
> (client_nonce+server nonce)

==>MT
Yes, I think similar clarifications would help here in Section 2.2.4.2.
<==

>
>
>     * Like for the comment above for Section 2.2.4.1, it's worth
>     making it explicit that the PoP key is used to compute the MAC or
>     the client signature.
>
>
>     [Section 2.2.5]
>
>     * s/RS MUST verify/the RS MUST verify
>
>     * Please, add references for HS256 and Ed25519.
>
>
>     [Section 3]
>
>     * s/to all topic3/to all 'topic3' 
>
>        
>
>     [Section 6.1]
>
>     * s/as a UTF-8/is a UTF-8
>
>
>   [CS: Added to https://github.com/ace-wg/mqtt-tls-profile/issues/65 
> <https://github.com/ace-wg/mqtt-tls-profile/issues/65>, will be fixed
> in the next submission]    
>  
>
>
>     ================================
>
>
>     On 2020-09-01 22:54, Daniel Migault wrote:
>>     Hi, 
>>
>>     This email starts a 2 weeks Working Group Last Call
>>     for draft-ietf-ace-mqtt-tls-profile. Please review the document
>>     available here [1] and provide your feed backs by September 15
>>     2020.  
>>
>>     Yours, 
>>     Jim and Daniel
>>
>>     [1] https://datatracker.ietf.org/doc/draft-ietf-ace-mqtt-tls-profile/
>>
>>
>>     -- 
>>     Daniel Migault
>>     Ericsson
>>
>>     _______________________________________________
>>     Ace mailing list
>>     Ace@ietf.org <mailto:Ace@ietf.org>
>>     https://www.ietf.org/mailman/listinfo/ace
>
>     -- 
>     Marco Tiloca
>     Ph.D., Senior Researcher
>
>     RISE Research Institutes of Sweden
>     Division ICT
>     Isafjordsgatan 22 / Kistagången 16
>     SE-164 40 Kista (Sweden)
>
>     Phone: +46 (0)70 60 46 501
>     https://www.ri.se
>
>     _______________________________________________
>     Ace mailing list
>     Ace@ietf.org <mailto:Ace@ietf.org>
>     https://www.ietf.org/mailman/listinfo/ace
>

-- 
Marco Tiloca
Ph.D., Senior Researcher

RISE Research Institutes of Sweden
Division ICT
Isafjordsgatan 22 / Kistagången 16
SE-164 40 Kista (Sweden)

Phone: +46 (0)70 60 46 501
https://www.ri.se