Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150417055500.GW6817@brightrain.aerifal.cx>
Date: Fri, 17 Apr 2015 01:55:00 -0400
From: Rich Felker <dalias@...c.org>
To: musl@...ts.openwall.com
Subject: Re: [PATCH] replace 'hlt' by 'ud2' in i386/x32/x86_64 a_crash
 implementations

On Thu, Apr 16, 2015 at 08:58:59PM +0300, Alexander Monakov wrote:
> ---
> ud2 is also what GCC and Clang use to implement __builtin_trap()
> 
> ud2 causes SIGILL rather than SIGSEGV; SIGSEGV is more likely to have a custom
> signal handler installed

I've pondered instead using:

	push $-1
	mov $175,%eax
	xor %ebx,%ebx
	mov %esp,%ecx
	int $128
	hlt // or ud2?

This should be uncatchable but it's moderately larger. 

Rich

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.