lkml.org 
[lkml]   [2023]   [Nov]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH RFC RFT v2 5/5] kselftest/clone3: Test shadow stack support
    On Fri, Nov 17, 2023 at 01:12:46PM -0800, Deepak Gupta wrote:
    > On Tue, Nov 14, 2023 at 11:11:58PM +0000, Edgecombe, Rick P wrote:

    > > It seems like there will be a need for some generic method of checking
    > > if shadow stack is enabled. Maybe a more generic compiler
    > > intrinsic/builtin or glibc API (something unrelated to SSP)?

    > Exposing a new file under procfs would be useful?
    > Something like "/proc/sys/vm/user_shadow_stack_supported"

    > `map_shadow_stack` can return MAP_FAILED for other reasons.
    > I think `kselftests` are fine but I don't want people to pick up this
    > as test code and run with it in production :-)

    > So kernel providing a way to indicate whether it supports shadow stack
    > mappings in user mode via procfs would be useful and arch agnostic.

    I can see that might be useful for some higher level code that wants to
    tune the size and nothing else. I'd be tempted to do it through adding
    a tuneable for the maximum default shadow stack size (x86 currently uses
    4G) just so it's *vaguely* useful rather than just a file. I question
    the utility of that but just a plain file doesn't feel quite idiomatic.

    In any case it feels like it's off topic for this series and should be
    done separately.
    [unhandled content-type:application/pgp-signature]
    \
     
     \ /
      Last update: 2023-11-20 16:49    [W:4.526 / U:0.020 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site