[CFRG] Re: I-D Action: draft-irtf-cfrg-rsa-guidance-01.txt

Alicja Kario <hkario@redhat.com> Fri, 06 September 2024 10:53 UTC

Return-Path: <hkario@redhat.com>
X-Original-To: cfrg@ietfa.amsl.com
Delivered-To: cfrg@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 93B84C14CE22 for <cfrg@ietfa.amsl.com>; Fri, 6 Sep 2024 03:53:42 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.253
X-Spam-Level:
X-Spam-Status: No, score=-2.253 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.148, 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_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001, T_SCC_BODY_TEXT_LINE=-0.01] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=redhat.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 lzdr3-4K-AfG for <cfrg@ietfa.amsl.com>; Fri, 6 Sep 2024 03:53:38 -0700 (PDT)
Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-256) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 2E267C14F600 for <cfrg@ietf.org>; Fri, 6 Sep 2024 03:53:37 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1725620017; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=0XSs4Nr7o0PVasAcm8AviMTNk/qreOK4shtgbf35fC4=; b=bDHZGOtOBZYPBJGCV7rjpIcavg0eU/JMhJZ9eMnF8N0YsYUIZ2F5LR4t1WOe7KMh5kesZ/ QEACblK4h/022sTGTXIzK8gTkhjMKuWFqmx/DqOLRC1GpW5ewG2nOyfTWF7DhGRI0Nv3da VYQDvfSus7q7x1tV37bZKct7k5VuB9I=
Received: from mail-wm1-f72.google.com (mail-wm1-f72.google.com [209.85.128.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-66-RfcHWB4TOEmM60IDwM_R5A-1; Fri, 06 Sep 2024 06:53:36 -0400
X-MC-Unique: RfcHWB4TOEmM60IDwM_R5A-1
Received: by mail-wm1-f72.google.com with SMTP id 5b1f17b1804b1-42bb2899d57so15030225e9.3 for <cfrg@ietf.org>; Fri, 06 Sep 2024 03:53:36 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1725620015; x=1726224815; h=content-transfer-encoding:user-agent:organization:references :in-reply-to:message-id:mime-version:date:subject:cc:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=Tf4EnevBxL4pPu3PJ2q2fnA2Igi2vi3VMgTXnkIkB0Y=; b=wxUDfdPYP64B8bgLxWzkTCkEkZSBLjsC1lbHdQ2Xe/nsk7O6dpH0e7CyF8Juo4XTxI h+P8wEOIJhs9HEBjEuDim+Xd6pfaWf29oiSf5mvKfVovx4FIynKCq1ITiBDVDb4T4ZBF OxOQCQiJimMWvqgQn747h7NLVmHuG7Io/stO6DUe2VQudTb5QammyEkF4A3gbQ3eoq13 eYGy8kH0dgEtukFk/iS9bGeWyne3LuD6SQGu80QUElzIsjP/h78w7Xd5gyx+QYrFcYoA ipIbZKXPJKILJGGCumF7obNkDiIpNvVeqLbenRvTx50SRhMcOjxZgvtg2lWie6Towfin lzQw==
X-Forwarded-Encrypted: i=1; AJvYcCWq2vRCN9xHhojd1uf6E/VYSnsCNS6RsTaPPNYnPEgUFcT5glQJjWKs4uLkVY9hw+rkf5c0@ietf.org
X-Gm-Message-State: AOJu0YxZqx4W5F73w70mThfcSOSk6XgAQHUCM36+6t2xXEPQFk4o4/e1 oOj6jkrthrX8ChHLYBaZcPW4tonPJVERO2tT0YEMRVdRrmbiTT+QnsEvx49UPqLJ6uFuw4q5Fft fb90N4tEm8Uqx/dFZienvMANevogWF5qKV/JEG06+g7jVLnm/IQ==
X-Received: by 2002:a05:600c:3511:b0:426:61af:e1d3 with SMTP id 5b1f17b1804b1-42c9f9e120cmr14959085e9.31.1725620014663; Fri, 06 Sep 2024 03:53:34 -0700 (PDT)
X-Google-Smtp-Source: AGHT+IGCeQb9iYQ/JZBmO9CxI57TBzcxcou83v+ocnQAAymZdboD0LqOv25ppcUvAxL5tx38sKJJdQ==
X-Received: by 2002:a05:600c:3511:b0:426:61af:e1d3 with SMTP id 5b1f17b1804b1-42c9f9e120cmr14958865e9.31.1725620014039; Fri, 06 Sep 2024 03:53:34 -0700 (PDT)
Received: from localhost (nat-pool-brq-u.redhat.com. [213.175.37.12]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42ca05c26a2sm16699425e9.1.2024.09.06.03.53.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Sep 2024 03:53:28 -0700 (PDT)
From: Alicja Kario <hkario@redhat.com>
To: "Riad S. Wahby" <rsw@jfet.org>
Date: Fri, 06 Sep 2024 12:53:22 +0200
MIME-Version: 1.0
Message-ID: <96769b45-db3a-4ab5-9a5f-dfcf635e4db6@redhat.com>
In-Reply-To: <g7dd62nttkb7u3qyki6b5hpjyk5opz36ehpbgvx4i3hr6batan@3vpb3ubbwt6p>
References: <172538719711.1420249.4393971363081609427@dt-datatracker-68b7b78cf9-q8rsp> <02e9a51e-b938-49f2-b832-de4d3ec575ee@redhat.com> <CAMm+Lwh3DwF1GA=WUMEsXZ-Ho__AKB6R-kfkxF9=pRZxn3jZBw@mail.gmail.com> <dad51c80-4eb6-423a-af8f-9a99c86377be@redhat.com> <g7dd62nttkb7u3qyki6b5hpjyk5opz36ehpbgvx4i3hr6batan@3vpb3ubbwt6p>
Organization: Red Hat
User-Agent: Trojita/0.7-git; Qt/5.15.13; xcb; Linux; Fedora release 39 (Thirty Nine)
X-Mimecast-Spam-Score: 0
X-Mimecast-Originator: redhat.com
Content-Type: text/plain; charset="utf-8"; format="flowed"
Content-Transfer-Encoding: quoted-printable
Message-ID-Hash: WETM54XAEWMPH4CDIEU6NAUAVMFN4XCS
X-Message-ID-Hash: WETM54XAEWMPH4CDIEU6NAUAVMFN4XCS
X-MailFrom: hkario@redhat.com
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-cfrg.irtf.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header
CC: cfrg@ietf.org
X-Mailman-Version: 3.3.9rc4
Precedence: list
Subject: [CFRG] Re: I-D Action: draft-irtf-cfrg-rsa-guidance-01.txt
List-Id: Crypto Forum Research Group <cfrg.irtf.org>
Archived-At: <https://mailarchive.ietf.org/arch/msg/cfrg/64mmsDMaPgZjCkqzzAoTjtviC5s>
List-Archive: <https://mailarchive.ietf.org/arch/browse/cfrg>
List-Help: <mailto:cfrg-request@irtf.org?subject=help>
List-Owner: <mailto:cfrg-owner@irtf.org>
List-Post: <mailto:cfrg@irtf.org>
List-Subscribe: <mailto:cfrg-join@irtf.org>
List-Unsubscribe: <mailto:cfrg-leave@irtf.org>

On Friday, 6 September 2024 07:31:50 CEST, Riad S. Wahby wrote:
> Hello,
>
> With apologies for wading in while short on both context and sleep:
>
> Alicja Kario <hkario@redhat.com> wrote:
>> RSA key generation is a very rare occurance, so it's easier to just
>> do it offline, on a trusted system, than to work to make it side
>> channel safe. So, no, I consider it out of scope.
>
> This strikes me as an assumption that makes things clean on paper but
> messy in the real world. I can imagine lots of users taking one look
> at the operational hassle of offline generation and saying "not worth it."
>
> An alternative take: RSA key generation is a very rare 
> occurrence, so it does
> not have to be particularly fast. Thus, we can afford to spend significant
> computational resources on attenuating the side channels.
>
> (Well, and implementation time, etc.)
>
> I'll stress again that I could be entirely mistaken about the context. But
> my experience has been that users of all stripes are pesky and tend to do
> what is easiest for them. And a subset of those users will not correctly
> decide which system should be trusted for offline generation.
>
> Take this drive-by opinion for what (very) little it is worth :)

The protections I talk in the Draft are for remote timing attacks, 
potentially
conducted even over the Internet.

How do you perform a remote network based attack against RSA key 
generation?

Also, RFC 8017 says nothing about how to generate the RSA parameters.

So, I consider key generation out of scope.
See https://github.com/tomato42/marvin-ietf/pull/new/outside-scope
for the proposed text.
-- 
Regards,
Alicja (nee Hubert) Kario
Principal Quality Engineer, RHEL Crypto team
Web: www.cz.redhat.com
Red Hat Czech s.r.o., Purkyňova 115, 612 00, Brno, Czech Republic