[Lake] Security levels for EDHOC for formal verification

John Mattsson <john.mattsson@ericsson.com> Thu, 11 February 2021 08:13 UTC

Return-Path: <john.mattsson@ericsson.com>
X-Original-To: lake@ietfa.amsl.com
Delivered-To: lake@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 6F8FF3A1382 for <lake@ietfa.amsl.com>; Thu, 11 Feb 2021 00:13:27 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.351
X-Spam-Level:
X-Spam-Status: No, score=-2.351 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.25, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, 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=ericsson.com
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 Ftrm2Lq_28g1 for <lake@ietfa.amsl.com>; Thu, 11 Feb 2021 00:13:25 -0800 (PST)
Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-eopbgr30071.outbound.protection.outlook.com [40.107.3.71]) (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 6C2693A0DFF for <lake@ietf.org>; Thu, 11 Feb 2021 00:13:25 -0800 (PST)
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AhR8q3+JtHtdfgPNRjgvsZ257Ya3+QwNiLYE2G7cyWkV8yuAYzpP9NqcnVcRe7heOuu6Qvoz7w4LaiDmrfaTwOsp8lm8GL5lErLVeBvj7GekWs/oFss/OUx6TwQbfLJOg9lMEwsWGnLUJerks6tScd56dr97+8/Rl7G3VW/SVneavrLwVuhmESld46vQ/rNivUahax4wTc/XGgxgm7Oo/Y9DWlFB/OUYTi4UiOGudR0P/yzDi0+GJJcZ9HJVTROLW0xg0XJtyF3q03gXJGFPp8l1tvoW+QcguFg1mjM6vHMhimlTWEUf2rFwz7FfWd/LBKsmB85sTjoH3Doibebq9A==
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=uYBgA0lCSNE4AtPZ8f327ZEgMWEyisLA9kgXBRlLs2g=; b=JJS4fstGCp5H5UcI/SDeB4TRh84lnoFfJPk3cEkva2VSDfHaHdGiXPE/uGCGdtb5vj6WZ5210d82fRSya2v3aSoIOZzjuBO7oJGBudP63uijUXP3fLJLsp/hrk2qvUPa7bf5XoE/FGkEbwGK2duBPBGuFzcPNnqyitUZo5XtxEzrWo7i+vIqrHZcqfdMqZDLx2j80WZeLq36DB9f8i3oxCiuNiXzWQ3iw1kIK9ZmLFi0tY26ocVoiOdRX2gNQUm/jCDmyKw5K63CmZLytyPy1BPOtpO2cgQlwuMfzf3+AHwyXl2DVGnIpreLbsuxxH/HDlmgdPYrf5jotMzJjXdULg==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=ericsson.com; dmarc=pass action=none header.from=ericsson.com; dkim=pass header.d=ericsson.com; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ericsson.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=uYBgA0lCSNE4AtPZ8f327ZEgMWEyisLA9kgXBRlLs2g=; b=GxwagP0So/HM6paK6QOa27qk0Hk9HKfYPdGNOmikDRQbYstOgixj78vULDE0G90nvmzk5Qc0krwMZY/qvE+pZabI7+LnT+QWUgdtxk+a9aHiKh8VdjCf/mK9hO8d3k/vLmcbuRUx+5mC8fbxCXTxSG2qBP9WfRqkf5t7Q8gCFhg=
Received: from (2603:10a6:3:4b::8) by HE1PR0701MB2825.eurprd07.prod.outlook.com (2603:10a6:3:53::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3846.18; Thu, 11 Feb 2021 08:13:20 +0000
Received: from HE1PR0701MB3050.eurprd07.prod.outlook.com ([fe80::c555:6e47:970c:1268]) by HE1PR0701MB3050.eurprd07.prod.outlook.com ([fe80::c555:6e47:970c:1268%11]) with mapi id 15.20.3846.027; Thu, 11 Feb 2021 08:13:20 +0000
From: John Mattsson <john.mattsson@ericsson.com>
To: "lake@ietf.org" <lake@ietf.org>
Thread-Topic: Security levels for EDHOC for formal verification
Thread-Index: AQHXAE3CIo84kXTI0k20kQP+0TZxfg==
Date: Thu, 11 Feb 2021 08:13:20 +0000
Message-ID: <87582CFB-7166-49DB-85F1-E6D389A966F0@ericsson.com>
Accept-Language: en-US
Content-Language: en-GB
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
user-agent: Microsoft-MacOutlook/16.45.21011103
authentication-results: ietf.org; dkim=none (message not signed) header.d=none;ietf.org; dmarc=none action=none header.from=ericsson.com;
x-originating-ip: [81.225.97.222]
x-ms-publictraffictype: Email
x-ms-office365-filtering-correlation-id: d50989d5-07b0-4a81-4052-08d8ce64e4e6
x-ms-traffictypediagnostic: HE1PR0701MB2825:
x-microsoft-antispam-prvs: <HE1PR0701MB28253E73822DDC0B7A8BC9AF898C9@HE1PR0701MB2825.eurprd07.prod.outlook.com>
x-ms-oob-tlc-oobclassifiers: OLM:10000;
x-ms-exchange-senderadcheck: 1
x-microsoft-antispam: BCL:0;
x-microsoft-antispam-message-info: h0dXMa1+K3ix+TKfiFOGfA/I5lAURV/9bNBu/V7tNqfekePNuGnntXxmDM1sbnGBvmASOzxwNKognK53GyuIDOoLRWjM0bouG5VV1/B6/rrE+0gKyy+eSkEoWphtocNk/uYsYe4ymGTj2ARjM0CX8H42VNFaAW9arf1NByjjo5opUwZ5hSmsdrSJXIVdaNJV9C4WYPt12CR510FsH8cAQr5aHk8/Men+a15SrRwqrAddW5oq4erVmHGWZzoqLbKqAOR+MPLxFxY3JbzwbVQoMjgAsBZEgp2QYX8vOBg6CBqZtM8cMtD/PEL+aamoKsU9/IDWPtLW5+x9iO4A2SlH9P9jttN+G2D+EltyeUmWXPxNZnP+z4QwcYmmuChnhZTFQeVqC+mEDI8j8dlFYwzdZg0Gngewz5rGsk968l35o79hUbrloKTM7NyrJA/npmWlsVBrcXg0U/3hQoBsTSedq30yshwfIMCxwv/tivZrJa63cm2gPKG2ru9NAj7Xn7R3yCPtd1i3Mmc2LzlGsJjOBY/IHHgPife002s0OkJP3zd6cYp1g/R1Eq2+fhICqb0IdwRhSLCH4hojCZPrGfgbsw==
x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:HE1PR0701MB3050.eurprd07.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(346002)(366004)(376002)(136003)(396003)(39860400002)(36756003)(66946007)(186003)(76116006)(86362001)(6512007)(6506007)(6916009)(26005)(71200400001)(8676002)(66556008)(6486002)(44832011)(5660300002)(2616005)(33656002)(66446008)(64756008)(8936002)(66476007)(2906002)(83380400001)(15650500001)(478600001)(316002)(45980500001); DIR:OUT; SFP:1101;
x-ms-exchange-antispam-messagedata: =?utf-8?B?WXdXaTB1bVo3S2hmaWRKem5mNjI2STZWeVY1aXFVU0p3OHQ1azZvY1pXSlND?= =?utf-8?B?NFFPb3YxRk10QlpFdXBpdVprLzRzZFdmdytTbXJrS0xNVVlHK3EwNndvVFVh?= =?utf-8?B?UmlUN2pNNWw2Q1lGcWxCejQxcW0raGhabWtuT1hPRlYxQ0EzOUcyV09CY0gx?= =?utf-8?B?amlVdGhLRlFVK0dENzMzUmlBb1UrWWZ6S2tON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FXR09Gb2hBN0g3Y2lZ?= =?utf-8?B?QTdDQnNQamFvdzFCTlc0MzZQakNYenlQWU1ycm02QUhrOFc4YVNyeUkrenFG?= =?utf-8?B?U3NuMEJoOHFnL1U5RG1ISkFlUk1jQkVCWGUwQkZuc3ZrYjFnYWkvQUpMOWtj?= =?utf-8?B?eW1DUEdML1pETnpmbVhLVnl2eE0zOVRpYnE0d3JSRXdBYVVwUUhlc09hM1U1?= =?utf-8?B?bEo3eVVpM0ZjMUdpY0NudjQwNlBwSzBOK2dhZ2EzbkQ0aFNadmNjckJqam8x?= =?utf-8?B?U09YYUx3bUdzRUJPeXdWelZmc1F0OUwyRlNFdGdUMXlhME1nVFl1L2Mvb1Ar?= =?utf-8?B?MUw3b2lFMVBITFN2eVR0SEJFRTNMWitETWRqNURzb3YwdnRhZ3ZiemFqSWJl?= =?utf-8?B?cys2ZElPS2xkRlRWVm50YUtjbXdUa25GemZSVm9PNEZ0M0kvbXp0Z1ByQUJX?= =?utf-8?B?RXhIU1VUYnA3K0RNeVBJVWMzb1BVcHhyN0FCZ2VSWnc2M0F6dUxUUXZTeVk4?= =?utf-8?B?Q1FKdGdtY0tVaVNuY3Rpa1djclVnbHZPbXAxZkJJU1N6VDlySHg1Z2VXN3dp?= =?utf-8?B?V29lblNvNFVEbk8vWitjaXNGcEV6amlEYXAweU1zc2NhdkFacjVrOGpOWGN1?= =?utf-8?Q?tpp2RgunMrxnAVNt0QJ0U7WUmr1/q/mh+LcqfOS?=
x-ms-exchange-transport-forked: True
Content-Type: text/plain; charset="utf-8"
Content-ID: <2CF3CE3B24258145923934F8C6E2781A@eurprd07.prod.outlook.com>
Content-Transfer-Encoding: base64
MIME-Version: 1.0
X-OriginatorOrg: ericsson.com
X-MS-Exchange-CrossTenant-AuthAs: Internal
X-MS-Exchange-CrossTenant-AuthSource: HE1PR0701MB3050.eurprd07.prod.outlook.com
X-MS-Exchange-CrossTenant-Network-Message-Id: d50989d5-07b0-4a81-4052-08d8ce64e4e6
X-MS-Exchange-CrossTenant-originalarrivaltime: 11 Feb 2021 08:13:20.4382 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 92e84ceb-fbfd-47ab-be52-080c6b87953f
X-MS-Exchange-CrossTenant-mailboxtype: HOSTED
X-MS-Exchange-CrossTenant-userprincipalname: OxTgaWd3qU9dtvyWDeWwHNY5m9Mo1NZLefdZDOPFcsHaTQQ69Rh5/O1GJEoF8FDIXe7rVS9wHCTQL1q7JZiHPp0NBWT76oDLD0bQON4ssJg=
X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR0701MB2825
Archived-At: <https://mailarchive.ietf.org/arch/msg/lake/FwatDCWvukMVkFAn-Ms-8-7Vr7k>
Subject: [Lake] Security levels for EDHOC for formal verification
X-BeenThere: lake@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Lightweight Authenticated Key Exchange <lake.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/lake>, <mailto:lake-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/lake/>
List-Post: <mailto:lake@ietf.org>
List-Help: <mailto:lake-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/lake>, <mailto:lake-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 11 Feb 2021 08:13:28 -0000

Hi,

There was a request from Karthik to have specified security levels for EDHOC so that formal verification can verify or falsify the claims. This is not trivial. Below is a first try. Let's discuss if this is enough or if more or different information is needed.

The design objectives of EDHOC has been to have approximatly the same security level as TLS when the same algorithms are used, but to have much smaller messages. Just like TLS I think the expected security level depends heavily on the chosen algorithms and the method. Method 3 should be comparable with TLS 1.3 with mutual certificate based authentication. Methed 0 is a bit trickier to compare to TLS.

In general there should not be much difference between EDHOC and TLS 1.3 when certificate based authentication is used. The exported keys should be a bit stronger as EDHOC include message_2 and the for Static DH also the private authentication keys. The Static DH Method with 64 bit tags does not offer the same security level as TLS 1.3 with certificate-based authentication, but should offer better security than TLS 1.3 with PSK authentication and short tags.

EDHOC can use all algorithms defined for COSE (but maybe you will restrict your work to
the pre-defined cipher suites). Below are the relevant algorithms defined for COSE.

EDHOC AEAD algorithm:
---------------------------
AES-CCM-16-64-128
AES-CCM-16-64-256
AES-CCM-64-64-128
AES-CCM-64-64-256
AES-CCM-16-128-128
AES-CCM-16-128-256
AES-CCM-64-128-128
AES-CCM-64-128-256
A128GCM
A192GCM
A256GCM
ChaCha20/Poly1305

EDHOC hash algorithm
---------------------------
SHAKE256
SHA-512
SHA-384
SHAKE128
SHA-512/256
SHA-256
[SHA-1 and SHA-256/64 not allowed]

EDHOC ECDH curve
---------------------------
P-256
P-384
P-521
X25519
X448
Wei25519 (expected to be registered soon)
[Ed25519, Ed448, secp256k1 are not allowed] 

EDHOC signature algorithm
---------------------------
ES256
ES512
ES384
EdDSA
ES256K

EDHOC signature algorithm curve
---------------------------
P-256 (ECDSA only)
P-384 (ECDSA only)
P-521 (ECDSA only)
Ed25519 (EdDSA only)
Ed448 (EdDSA only)
secp256k1 (ECDSA only)
[X25519, X448 are not allowed] 

(Non-ECC signatures algorithms are supposed to be allowed as well. I think the draft needs to be updated.)

Below are two initial ways to express the security level, one as a function of the Mehtod and algorithms. The second as a comparision with TLS 1.3. In general, EDHOC with the weakest options SHALL offer 64-bit security against on-line attacks and 128-bit security against off-line attacks. I think this aligns with TLS 1.3.

Let me know if this is enough for the formal verification, if you need something different, or if something is missing. It would be good if somebody reviews the information is this mail.


EDHOC security levels for different aspects
---------------------------

The security level of confidenciality protection against passive attackers should be the key length of the AEAD (128, 192, or 256 bits).

The security lebel of integrity protection and confidentiality against active attackers should be the tag length of the AEAD (64 or 128 bits)

The authentication security in the static DH modes are determined by the  tag length of the AEAD (64 or 128 bits)

The authentication security in the Signature Key modes are determined by the security level of the signature algorithm (128, 192, or 256 bit)

The integrity protection of some fields are detemined by the security level of the signature algorithm (128, 192, or 256 bit).



EDHOC security levels compared with TLS 1.3
---------------------------

Method 0 (2* Signature Key ) should offer the same security level as TLS 1.3 with the same algorithms.

0. (AES-CCM-16-64-128, SHA-256, X25519, EdDSA, Ed25519)
1. (AES-CCM-16-128-128, SHA-256, X25519, EdDSA, Ed25519)
4. (A128GCM, SHA-256, X25519, ES256, P-256)
5  (A256GCM, SHA-384, P-384, ES384, P-384)


Method 0 (2* Static DH Key ) is a bit trickier.

0. (AES-CCM-16-64-128, SHA-256, X25519, EdDSA, 

The authentication security level here is bounded by the 128-bit tag. Should offer at least the same security level as TLS 1.3 with PSK authentication with CCM_8, and the other algorithms the same.

1. (AES-CCM-16-128-128, SHA-256, X25519, EdDSA, Ed25519)
4. (A128GCM, SHA-256, X25519, ES256, P-256)

Should both offer similar security level as TLS 1.3 with certificate authentication and the the other algorithms the same.

5	(A256GCM, SHA-384, P-384, ES384, P-384)

The authentication security level here is bounded by the 128-bit tag.

Cheers,
John