What exactly is sigtramp?

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

What exactly is sigtramp?

Berger Steffan
hello,

at [1], I read something about 'Sigtramp separation' within
the W^X transition.   I only know that this sigtramp-page (?) is
used to jump back into the kernel when a signal arrives.  

My question is, what exactly is this signal trampoline?  

Why do I need it?  

Why was it on the Stack (first page of the virtual memory)?  

And why must it be executable /  what does the code?  

Thank you for your help.


[1] http://www.openbsd.org/papers/ru13-deraadt/mgp00012.html

Reply | Threaded
Open this post in threaded view
|

Re: What exactly is sigtramp?

Philip Guenther-2
On Wed, Jan 14, 2015 at 3:10 PM, Stefan Berger
<[hidden email]> wrote:
> at [1], I read something about 'Sigtramp separation' within
> the W^X transition.   I only know that this sigtramp-page (?) is
> used to jump back into the kernel when a signal arrives.
>
> My question is, what exactly is this signal trampoline?

https://groups.google.com/d/msg/comp.unix.internals/10d55NxFs7E/MK0lmjLEdh8J

Reply | Threaded
Open this post in threaded view
|

Re: What exactly is sigtramp?

Theo de Raadt
In reply to this post by Berger Steffan
> at [1], I read something about 'Sigtramp separation' within
> the W^X transition.   I only know that this sigtramp-page (?) is
> used to jump back into the kernel when a signal arrives.  
>
> My question is, what exactly is this signal trampoline?  

That is not what the slides say.

> Why do I need it?  

To return from a signal handler.

> Why was it on the Stack (first page of the virtual memory)?  

Because it was.

> And why must it be executable /  what does the code?  

Because it is code.

> Thank you for your help.

You've got access to all this source code.  It is documented.
And there are books.  There are search engines which can answer
this.

But the modern way is to ask large mailing lists?

If you can't study the world around you, you will remain ignorant.

Reply | Threaded
Open this post in threaded view
|

Re: What exactly is sigtramp?

RichardET
See page 159 of the recent second edition of McKusick's book on the  BSD
kernel.  It's FreeBSD centric, but its the same concepts.
On Jan 14, 2015 6:31 PM, "Theo de Raadt" <[hidden email]> wrote:

> > at [1], I read something about 'Sigtramp separation' within
> > the W^X transition.   I only know that this sigtramp-page (?) is
> > used to jump back into the kernel when a signal arrives.
> >
> > My question is, what exactly is this signal trampoline?
>
> That is not what the slides say.
>
> > Why do I need it?
>
> To return from a signal handler.
>
> > Why was it on the Stack (first page of the virtual memory)?
>
> Because it was.
>
> > And why must it be executable /  what does the code?
>
> Because it is code.
>
> > Thank you for your help.
>
> You've got access to all this source code.  It is documented.
> And there are books.  There are search engines which can answer
> this.
>
> But the modern way is to ask large mailing lists?
>
> If you can't study the world around you, you will remain ignorant.