Received: by 2002:a17:90a:c8b:0:0:0:0 with SMTP id v11csp2355147pja; Wed, 10 Apr 2019 18:40:40 -0700 (PDT) X-Google-Smtp-Source: APXvYqwc08TvuyZ7vm5AuxXqj3tp2CoJBWgnjZzUpz2uHLJNchdX4W+GkoY/nt0EF3lifBdEnCu0 X-Received: by 2002:a63:1912:: with SMTP id z18mr44736866pgl.115.1554946840140; Wed, 10 Apr 2019 18:40:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554946840; cv=none; d=google.com; s=arc-20160816; b=FViMxudLXVV6h7H01INgdXRQ1AnyPtmSe9VzV9pjbqnncgd8FAPXcTpksRvRId9pcT EioWYxM0LKD5xHgUd1d9yqej+HuoTQFH2p5GGyGR11+R7biR8RxTGU/qACAoOIYVILlW LcGOkkhQIKOZylwwUK0ssIP6hTucqpX4NSI7x96NPHL612La4I9EwS/OT4p/ZHquXw7N HBZYoLFs/rsNSb1i0FXZkrMvsaPabJPvReKeMnAIB4Yienxhz/2nxQ6Zbr7FkzcVQjQ2 lOGJPyWC5kQuyktCh3THIungcnhkGFIt5kERbG8HgtzI7zgKPfkIVhypK0AcG/sm/ZnQ Ezdw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to:date :cc:to:from:subject:message-id; bh=SMqQpYZ846aQ/fm5/cxrIhj8alHdUQldll60axguQ30=; b=xtM7pcaFSDjIPMAMbYXmMC9d2y5u9u4Ii5Az3VJRpwbiRnR3godDUb4PQwp79QGxeG PaPaD24WJxzaW6RcgLkoZlv6qCdf9rdQXOQRLaBPWSoLSOZCzayQ6OeB2XlczmLc5xzV rU2JsLT3GRoDaJnHodmoYc95ygHuyV08Um2OKZFCxoYqdJKSs9b1W+qC0oeb8qe8N90w jVsgkKctWRZQ1k4Kk0/Qkh+ZgLYyIMb34zyV2D32s2OjO8OjESSjqUCUbEzTyDxMo/kr SKem4KRpJErSu3zRuVM7vmYW+X5clVi2d5pndpVzB1n25YCguIPiha1HGByInRHN+BVs YRqg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id bc1si32940460plb.55.2019.04.10.18.40.24; Wed, 10 Apr 2019 18:40:40 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726870AbfDKBh5 (ORCPT + 99 others); Wed, 10 Apr 2019 21:37:57 -0400 Received: from shelob.surriel.com ([96.67.55.147]:56308 "EHLO shelob.surriel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726558AbfDKBh5 (ORCPT ); Wed, 10 Apr 2019 21:37:57 -0400 Received: from imladris.surriel.com ([96.67.55.152]) by shelob.surriel.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.91) (envelope-from ) id 1hEOes-0004xg-7E; Wed, 10 Apr 2019 21:37:42 -0400 Message-ID: Subject: Re: crypto: Kernel memory overwrite attempt detected to spans multiple pages From: Rik van Riel To: Eric Biggers , Kees Cook Cc: Geert Uytterhoeven , Herbert Xu , linux-security-module , Linux ARM , Linux Crypto Mailing List , Linux Kernel Mailing List , Laura Abbott Date: Wed, 10 Apr 2019 21:37:41 -0400 In-Reply-To: <20190410231156.GB120258@gmail.com> References: <20190319170911.GB202956@gmail.com> <20190320185719.GB180195@gmail.com> <20190321175122.GA1587@sol.localdomain> <20190410031734.GB7140@sol.localdomain> <20190410190729.GA120258@gmail.com> <20190410231156.GB120258@gmail.com> Content-Type: multipart/signed; micalg="pgp-sha256"; protocol="application/pgp-signature"; boundary="=-I0iYs52hNxEw6RSke2FZ" X-Mailer: Evolution 3.28.5 (3.28.5-2.fc28) Mime-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --=-I0iYs52hNxEw6RSke2FZ Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, 2019-04-10 at 16:11 -0700, Eric Biggers wrote: > You've explained *what* it does again, but not *why*. *Why* do you > want > hardened usercopy to detect copies across page boundaries, when there > is no > actual buffer overflow? When some subsystem in the kernel allocates multiple pages without _GFP_COMP, there is no way afterwards to detect exactly how many pages it allocated. In other words, there is no way to see how large the buffer is, nor whether the copy operation in question would overflow it. --=20 All Rights Reversed. --=-I0iYs52hNxEw6RSke2FZ Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iQEzBAABCAAdFiEEKR73pCCtJ5Xj3yADznnekoTE3oMFAlyummUACgkQznnekoTE 3oN5Ogf+JB1+Q62gA3I1CjbG9J1N9Yo0SopCRnifEmRD5OOuHcTnKtJk9cDddftF JckxLVhf0YXgLZa78GQhNW74dTw/XBgB1tE59q7eYI3srERNjFc8G9cjLMEu0aKS wpv4wOL0AB7k1eFPvXkDbQ7mnzxb7s8+wGoH4F6Shs4ls9At//2kofAvES14Cfn8 c8lCTakBYcQ4lEhr7dxQ3v//NoD6/ZC6tacDN5A6mgcwM/VkdNgNskDVX25sTn1P Kvnes/43AAefodugVLVuXCtXhnBM1aJ1zn+J7VgyC5ZJAktdPSNixT6J7xlC16rZ U5Uf2fWdPx6UWgcs8agsp1NCrvu31w== =ewwZ -----END PGP SIGNATURE----- --=-I0iYs52hNxEw6RSke2FZ--