[Suit] SUIT Firmware Encryption with Dependency
Ken Takayama <ken.takayama.ietf@gmail.com> Fri, 30 September 2022 12:43 UTC
Return-Path: <ken.takayama.ietf@gmail.com>
X-Original-To: suit@ietfa.amsl.com
Delivered-To: suit@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id E4DA0C14F747 for <suit@ietfa.amsl.com>; Fri, 30 Sep 2022 05:43:46 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.107
X-Spam-Level:
X-Spam-Status: No, score=-2.107 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, HTML_MESSAGE=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.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 j5JFqK9sMzb2 for <suit@ietfa.amsl.com>; Fri, 30 Sep 2022 05:43:46 -0700 (PDT)
Received: from mail-pl1-x636.google.com (mail-pl1-x636.google.com [IPv6:2607:f8b0:4864:20::636]) (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 3EEBBC14F741 for <suit@ietf.org>; Fri, 30 Sep 2022 05:43:46 -0700 (PDT)
Received: by mail-pl1-x636.google.com with SMTP id 10so266525pli.0 for <suit@ietf.org>; Fri, 30 Sep 2022 05:43:46 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:mime-version:from:to:cc:subject :date; bh=rxO6JlimyVpCklZoQv9Wyd2TaiGbeITZ654BSPn0M50=; b=JSZ0630qjycJfry5oGksIH9qv93VaNNILorUjSkxfj1XjdaLT47qWXWCoaaw9rj1+r uuNFUo5eqZZR3spZBb0VISdZPptuTBc+StIy2hNLlBujK0UVVTKLj1U5rtEAQNdaXL/w qcUDlqP0rafrPUkzlckuqDMwoITLpq9on3r3QjnxSu/vTdSXklXozE7o2Pr09XeYggM7 7qnmWwfXibHmYPXZsTZ/QH3DSElnLmbND71aJGRtn7ZCQwgnHpoKOzDgrFWNz3WkwWNZ YlT87Iajht6NeKtY9GgZ0NSVC4OKXp+mFEHoAKju6vE5USnMBoZ1kNWJWrzrtzzuIq9C /oMw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date; bh=rxO6JlimyVpCklZoQv9Wyd2TaiGbeITZ654BSPn0M50=; b=cYWgsLomQivZ32+xZE0FSP60pDaNDyXH/XDaE1nmBewzIk+LwU1jDNmqO4RxEIFOOX rCimVmcV8PqKX0o6op/3QPe51eytsySEOJ/4ercx1K4twLwvuVWguks0sHWHEzE+AYIC cheuNm78fOeNccPKvtygaMTnpG//8aTsWccptZnu46QpoyT+c2VvnwrKhQujhviiHQbG RgWfmp84lSl0iYDECVpyNIcEJs8Wio1XedGSeqQukFsrpc28lv+MHAZh883j72W884RP iuqdOGsrib4E84bR0yJed1UDd/wheY7b4o0w2XCyD5AStD3NkImS8qKiSncQJHXUzC1G c1Bw==
X-Gm-Message-State: ACrzQf2zCR+odN3ahnW8s20yVsIKnC9HCZBngSkQctDSNPu2ff60qGzS gsxtglsnkU68lmm/Vpno0/AaJO3/FZiJF8PBx/k5N2A4cVM=
X-Google-Smtp-Source: AMsMyM54MFK5dRR6sFQ8BVwrJY8xkGC+kPxoVYSDNwLPA5XKsayrcdteV91SNE8cZyK9S5OviiD6bkzjWKIrqj4DJSk=
X-Received: by 2002:a17:902:d4d2:b0:17d:d70:8045 with SMTP id o18-20020a170902d4d200b0017d0d708045mr521006plg.73.1664541825060; Fri, 30 Sep 2022 05:43:45 -0700 (PDT)
MIME-Version: 1.0
From: Ken Takayama <ken.takayama.ietf@gmail.com>
Date: Fri, 30 Sep 2022 21:43:32 +0900
Message-ID: <CAOZByRCwgnBMMtU8b=phGMwT6zEsiBMG+uOPs-6nMm_HROCnmA@mail.gmail.com>
To: suit@ietf.org
Cc: hannes.tschofenig@arm.com, Brendan Moran <Brendan.Moran@arm.com>, housley@vigilsec.com, david.brown@linaro.org, oyvind.ronningstad@gmail.com
Content-Type: multipart/alternative; boundary="00000000000032527705e9e458bb"
Archived-At: <https://mailarchive.ietf.org/arch/msg/suit/slZ531RmYN-m4PSggeo_qKyO7go>
Subject: [Suit] SUIT Firmware Encryption with Dependency
X-BeenThere: suit@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: Software Updates for Internet of Things <suit.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/suit>, <mailto:suit-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/suit/>
List-Post: <mailto:suit@ietf.org>
List-Help: <mailto:suit-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/suit>, <mailto:suit-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 30 Sep 2022 12:56:22 -0000
A new idea to leverage SUIT Dependency for Firmware Encryption has come up to my mind. Please review and make comments, especially for SUIT Manifest usage and security considerations. # Background ## Condition - The Author creates firmware and its manifest - The Distribution System encrypts the firmware and distribute it to Devices - The Device fetches and decrypts encrypted firmware, then check and install it ## Current I-D - It introduces new section suit-security-wrapper holding SUIT_Encryption_Info, which is appended by the Distribution System - The Device decrypts the encrypted firmware with SUIT_Encryption_Info and then check it with condition-image-match ## Issues - Distribution System cannot modify the URI in the manifest where the encrypted firmware is stored - SUIT_Encryption_Info is used without verification because it locates out of the Author's signature # New idea ## Proposal - The Author and the Distribution System create manifest respectively - Distribution System's manifest fetches encrypted firmware and decrypts it, and depends on Author's manifest - Author's manifest check the decrypted firmware with condition-image-match - The Device MUST trust both Author and Distribution System keys to verify manifests ## Solves - The Distribution System can freely set the URI to distribute encrypted firmware in Distribution System's manifest - SUIT_Encryption_Info is inside signature created by the Distribution System ## Author's manifest (dependee) (Only important parts are shown in this example) ``` / SUIT_Envelope = / { suit-authentication-wrapper: SUIT_Authentication / by Author /, / inside the signature / suit-manifest : << { suit-common: << { suit-components: [ [h'00'] / decrypted firmware / ] } >>, suit-install: << [ / verify that the decrypted firmware is intact / suit-directive-set-component-index 0 / [h'00'] /, suit-directive-override-parameters { suit-parameter-image-digest: <<the digest of raw firmware image [h'00']>>, suit-parameter-image-size: <<the size of raw firmware image [h'00']>> }, suit-condition-image-match ] >> } >> } ``` ## Distribution System's manifest (dependent) (Only important parts are shown in this example) ``` / SUIT_Envelope = / { suit-authentication-wrapper: SUIT_Authentication / by Distribution System /, / inside the signature / suit-manifest : << { suit-common: << { suit-components: [ [h'00'] / to be decrypted firmware /, [h'01'] / encrypted firmware / ] } >>, suit-dependency-resolution: << [ suit-directive-set-dependency-index 0, suit-directive-override-parameters { suit-parameter-uri: "https://ds.example.com/manifest_a.suit" }, suit-directive-fetch ] >>, suit-install: << [ / loads encrypted firmware / suit-directive-set-component-index 1 / [h'01'] /, suit-directive-override-parameters { suit-parameter-uri: "https://ds.example.com/encrypted-firmware.bin" }, suit-directive-fetch, / decrypts it / suit-directive-set-component-index 0 / [h'00'] /, suit-directive-override-parameters { suit-parameter-source-component: 1 / [h'01'] / suit-parameter-encryption-info: SUIT_Encryption_Info / how to decrypt / }, suit-directive-copy, / request to parse Author's manifest / suit-directive-set-dependency-index 0 / Author's Manifest /, suit-process-dependency / triggers suit-install section in Author's manifest / ] >> } >> } ``` Best, Ken
- [Suit] SUIT Firmware Encryption with Dependency Ken Takayama
- Re: [Suit] SUIT Firmware Encryption with Dependen… Hannes Tschofenig