Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp1100914pxb; Tue, 8 Feb 2022 09:15:39 -0800 (PST) X-Google-Smtp-Source: ABdhPJxmMGJy6ifDUrw+/q/793UrVVUz3OVnHXZZS6UkL7hkUhRu1Ut01zxxErOfxVppggJWvObx X-Received: by 2002:a05:6a00:1588:: with SMTP id u8mr5313164pfk.4.1644340539416; Tue, 08 Feb 2022 09:15:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1644340539; cv=none; d=google.com; s=arc-20160816; b=jbF82h4jFLFryhVo04QgAP6DLqlRfpCKmA6O3ON3I9ggOQL2+7GUV7m2lF/noQvxub ja7Lgp2+7e4H8b0DcrZdO879ksQQ+KafHjnPHNvDQ3PTUDP4M9U1iXWwYceah6NT/3Wt KCkwbNlviqUv4Ijq3IdX/UghOwciV5hNA4J/RTmvBdtTserdRqUGM0wLieuO7KHS0430 sZGWcqj8okE7hmzQTwNdrVhwV6m0SNEBWssDVj8jeJUtjtUXaEm/o/qSdj/J9PpvOUEH XvHIGlBIiXz0ly8xB9+ns1JWqn/psN+3vizJT1VTwTY9Rae7T9f54QXVU4e/r9ryLNJU IPMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=9jFgBcCwyw+JzDYCLTCZj7IYtY0O/7Fz6FpDwFz3WSA=; b=BXssXssiSmykqrdxaWbXmmQGcQUbMz7DWpImZI3In19Cno7lBjfBNiy9rlUUWKfyEQ tEAnh+gKi7TroVMw+siaPSGPYRza/k6RjuGok7s6/tLz2I1jlBc1/0UHB/P7AidZdAD9 CQu8hwx5il4CErH5itiRE/fcAXjjo6UbT9Jhd0JLWYTgiPBTOLVcYXR/gajZIAU0xBpp a1rU/y6iIZSfNxZwOz3CnQMP0CdhDgHN991GybQtxeOes0hUlC7PI/jx4eLRYUpFIn0z 09ElitK9+DjFhIUbcJvyH00AihHEDs0mABr2ZqGLw0QjtkNvORI2Gd4NWiV3E+5ujx5e kfNA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=Cxuiov0o; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 67si13603180pga.632.2022.02.08.09.15.26; Tue, 08 Feb 2022 09:15:39 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=Cxuiov0o; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1354716AbiBHJ31 (ORCPT + 99 others); Tue, 8 Feb 2022 04:29:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38214 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237653AbiBHJ3X (ORCPT ); Tue, 8 Feb 2022 04:29:23 -0500 Received: from mail-lj1-x22c.google.com (mail-lj1-x22c.google.com [IPv6:2a00:1450:4864:20::22c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4D52AC03FEC1; Tue, 8 Feb 2022 01:29:22 -0800 (PST) Received: by mail-lj1-x22c.google.com with SMTP id j14so23571624lja.3; Tue, 08 Feb 2022 01:29:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=9jFgBcCwyw+JzDYCLTCZj7IYtY0O/7Fz6FpDwFz3WSA=; b=Cxuiov0oEhEhABwISaLLYTLHN3tzQ6PF+RTizCxpWY8feQ6Sz2x+TM3jmZxxWmNjv0 q28EFyaFYTlAbN1maWEM6RERHZTjoR/WE4mgvNqHUPt7F6oC+sNYeL39cBMJkac7Rt4k kUBoOyjvcvD5l4yg9lsDUOOVNrISyrJwp9TnBNmBymRYU5g+xMtxKKXGdSLwIbGt40Xr 9xIN01VqwKLFRMjcCZqZdmBpwPLLHoO8truWxbF68Q80kAncmQE0NdLHt8zNjFWP7x3c bFBayng/aXL7nLzKIHE6ncR/BwiQDML3zbzzfgLrBoV66II6hhCr/WvsDuz+OaCQo3Nv Uy9g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=9jFgBcCwyw+JzDYCLTCZj7IYtY0O/7Fz6FpDwFz3WSA=; b=L79+gecAXd+TkUFcY1fbPB9uM7A0iR5Oo0eh13n0QIo4HoEhYzAO/t+DQBv4HGYQIP LZeSF8q/t70KJ30pByt0cqk/OulCBwbWVxbw/Hy2YjrLQZ82Pz91AFD+N2XmH1zaFYmp 42u6DiQfWgzTe6+pPymFeWTYFJEyuFOtri3FxinlEmXojzYCkcC4tgVD/t+EEo4/n8ER yZEibR6dfJGVEdPSq5JYr113YG9FH86IZopaEe/7WlWRzueTT5gesf/EUGbJ4CS+J+6P +4S35uWOt4KwgyIs3rIJ/q5QkAlCpDgnQGcPNFrSmJHEhmKB1p8tnqHB8UtsJLDMjfus ddUQ== X-Gm-Message-State: AOAM532MZkSEdK7rmsE8WqPdmVej+E/mxiTcPVaTH+9tkz75HKuQIFz+ jOdNmQG8wl5JE8907/OemHw= X-Received: by 2002:a2e:8751:: with SMTP id q17mr2240779ljj.65.1644312560537; Tue, 08 Feb 2022 01:29:20 -0800 (PST) Received: from grain.localdomain ([5.18.251.97]) by smtp.gmail.com with ESMTPSA id p16sm1958258ljc.86.2022.02.08.01.29.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Feb 2022 01:29:19 -0800 (PST) Received: by grain.localdomain (Postfix, from userid 1000) id C01F55A0020; Tue, 8 Feb 2022 12:29:18 +0300 (MSK) Date: Tue, 8 Feb 2022 12:29:18 +0300 From: Cyrill Gorcunov To: Mike Rapoport Cc: Dave Hansen , Adrian Reber , Rick Edgecombe , x86@kernel.org, "H . Peter Anvin" , Thomas Gleixner , Ingo Molnar , linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, linux-mm@kvack.org, linux-arch@vger.kernel.org, linux-api@vger.kernel.org, Arnd Bergmann , Andy Lutomirski , Balbir Singh , Borislav Petkov , Dave Hansen , Eugene Syromiatnikov , Florian Weimer , "H . J . Lu" , Jann Horn , Jonathan Corbet , Kees Cook , Mike Kravetz , Nadav Amit , Oleg Nesterov , Pavel Machek , Peter Zijlstra , Randy Dunlap , "Ravi V . Shankar" , Dave Martin , Weijiang Yang , "Kirill A . Shutemov" , joao.moreira@intel.com, John Allen , kcc@google.com, eranian@google.com, Andrei Vagin , Dmitry Safonov <0x7f454c46@gmail.com> Subject: Re: [PATCH 00/35] Shadow stacks for userspace Message-ID: References: <20220130211838.8382-1-rick.p.edgecombe@intel.com> <8f96c2a6-9c03-f97a-df52-73ffc1d87957@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/2.0.7 (2021-05-04) X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Feb 08, 2022 at 11:16:51AM +0200, Mike Rapoport wrote: > > > Any thoughts on how you would _like_ to see this resolved? > > Ideally, CRIU will need a knob that will tell the kernel/CET machinery > where the next RET will jump, along the lines of > restore_signal_shadow_stack() AFAIU. > > But such a knob will immediately reduce the security value of the entire > thing, and I don't have good ideas how to deal with it :( Probably a kind of latch in the task_struct which would trigger off once returt to a different address happened, thus we would be able to jump inside paratite code. Of course such trigger should be available under proper capability only.