From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id C8F553858439 for ; Mon, 25 Jul 2022 10:14:14 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org C8F553858439 Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-219-U5nKQRjYNVCWkv5_ngfTQQ-1; Mon, 25 Jul 2022 06:14:11 -0400 X-MC-Unique: U5nKQRjYNVCWkv5_ngfTQQ-1 Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id DDFC41C05149; Mon, 25 Jul 2022 10:14:10 +0000 (UTC) Received: from oldenburg.str.redhat.com (unknown [10.39.192.195]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 6C5A2492CA2; Mon, 25 Jul 2022 10:14:09 +0000 (UTC) From: Florian Weimer To: Cristian =?utf-8?Q?Rodr=C3=ADguez?= Cc: "Jason A. Donenfeld" , libc-alpha@sourceware.org, Adhemerval Zanella Netto , Yann Droneaud , jann@thejh.net, Michael@phoronix.com Subject: Re: arc4random - are you sure we want these? References: Date: Mon, 25 Jul 2022 12:14:08 +0200 In-Reply-To: ("Cristian =?utf-8?Q?Rodr=C3=ADguez=22's?= message of "Sat, 23 Jul 2022 15:04:36 -0400") Message-ID: <877d41sdn3.fsf@oldenburg.str.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.85 on 10.11.54.9 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-5.8 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_LOW, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Jul 2022 10:14:15 -0000 * Cristian Rodr=C3=ADguez: > On Sat, Jul 23, 2022 at 12:25 PM Jason A. Donenfeld via Libc-alpha > wrote: > >> For that reason, past discussion of having some random number generation >> in userspace libcs has geared toward doing this in the vDSO, somehow, >> where the kernel can be part and parcel of that effort. > > On linux just making this interface call "something" from the VDSO that > > - does not block. > - cannot ever fail or if it does indeed need to bail out it kills the > calling thread as last resort. > > (if neither of those can be provided, we are back to square one) > > Will be beyond awesome because it could be usable everywhere, > including the dynamic linker, malloc or whatever else > question is..is there any at least experimental patch with a hope of > beign accepted available ? I agree that this would be nice, but we'd like have to donate thread-specific data for kernel use, and that's currently totally vaporware. The =E2=80=9Ccannot ever fail=E2=80=9D part is impossible to achieve due to= old kernels and seccomp filters. Low-level userspace needs to paper over it in some way, so that applications don't have to deal with it. Thanks, Florian