Re: [PATCH 1/3] x86/shstk: ban ia32 sigreturn when shadow stack is enabled

From: Richard Patel

Date: Fri Oct 09 2026 - 07:42:24 EST


On Thu, Oct 08, 2026 at 11:11:41PM +0000, Edgecombe, Rick P wrote:
> On Thu, 2026-10-08 at 22:47 +0000, Richard Patel wrote:
> > > But today setting EIP to an arbitrary point is fairly easy. But even in a
> > > future
> > > case of IBT enabled, shadow stack would still need enhancements for the
> > > normal
> > > 64 bit runtime to prevent this.
> >
> > What do you think of creating a shadow stack frame on signal delivery
> > and popping that on sigreturn? I suppose that would need siglongjmp
> > modifications and probably break CRIU. :(
>
> Yes I didn't know they did not parse the shadow stack signal frame
> appropriately. That is unfortunate. But we can still evolve the shadow stack ABI
> by adding new modes to the enable prctl if we want.

In the case of CRIU, they are not only parsing, but crafting their own
frames on the shadow stack. I suppose we can keep the kernel's parser
lenient so it works with older CRIU frames even after IBT enablement.