From: Samuel Thibault <samuel.thibault@eu.citrix.com>
To: Harald Roeck <hroeck@gmail.com>
Cc: xen-devel@lists.xensource.com
Subject: Re: stack protection in mini-os
Date: Thu, 31 Jul 2008 22:10:14 +0100 [thread overview]
Message-ID: <20080731211014.GU4565@implementation> (raw)
In-Reply-To: <9e53c8b90807311358udea192dl64815be5a1bd1a20@mail.gmail.com>
Hello,
For stubdomains, what I did is to add a check for ESP relative to the
bottom of the stack in a frequently called function, (think about
something like errno_location())
Harald Roeck, le Thu 31 Jul 2008 13:58:36 -0700, a écrit :
> If we overflow the stack and run into the
> mapped out stack page xen crashes and the machine reboots.
Uh, that's bad! Which version of Xen is this with? That is a bug of Xen,
can you reproduce it with a RC of 3.3?
> it looks like xen is trying to push the arguments for the page fault
> trap onto the mapped out page.
Most probably yes, but it should catch the error.
> rbp: 000000000007b120 rsp: 000000000007aff0 r8: 0000000000000010
> ...
>
> fyi: the read only page in this setup was 0x7a000.
So that's coherent indeed, but I guess you'd like to have the backtrace.
> so my question: is it possible to set an "alternate" trap stack?
I don't think the hypervisor provides this for kernel level.
> or the failsafe_callback?
failsafe_callback is only called when you get a fault during the
execution of callback, not during normal flow.
Samuel
next prev parent reply other threads:[~2008-07-31 21:10 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-07-31 20:58 stack protection in mini-os Harald Roeck
2008-07-31 21:10 ` Samuel Thibault [this message]
2008-07-31 21:40 ` Harald Roeck
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080731211014.GU4565@implementation \
--to=samuel.thibault@eu.citrix.com \
--cc=hroeck@gmail.com \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.