From: Emmanuel Fleury <emmanuel.fleury@labri.fr>
To: linux-kernel@vger.kernel.org
Subject: [ASLR] Better control on Randomization
Date: Mon, 30 Jan 2006 21:03:27 +0100 [thread overview]
Message-ID: <43DE710F.9020408@labri.fr> (raw)
Hi all,
I would like to have a way to enable/disable randomization of the stack
independently of the randomization of the dynamic library loading.
I mean, in recent Linux kernel, thanks to the ASLR, we have a
randomization of the stack:
[fleury@carioca programs]$ ./testASLR
str= 0xbf8e3a3c (/bin/sh), envp= 0xbf8e18ec, argv= 0xbf8e18e4
[fleury@carioca programs]$ ./testASLR
str= 0xbfedda3c (/bin/sh), envp= 0xbfedd75c, argv= 0xbfedd754
[fleury@carioca programs]$ ./testASLR
str= 0xbfe3ba3c (/bin/sh), envp= 0xbfe3a10c, argv= 0xbfe3a104
(testASLR just output the address of the envp and the argv variables).
And randomization of the dynamic library:
[fleury@carioca programs]$ cat /proc/self/maps | grep libc
b7e01000-b7f2e000 r-xp 00000000 03:02 328183 /lib/tls/libc-2.3.5.so
b7f2e000-b7f33000 r--p 0012d000 03:02 328183 /lib/tls/libc-2.3.5.so
b7f33000-b7f36000 rw-p 00132000 03:02 328183 /lib/tls/libc-2.3.5.so
[fleury@carioca programs]$ cat /proc/self/maps | grep libc
b7e59000-b7f86000 r-xp 00000000 03:02 328183 /lib/tls/libc-2.3.5.so
b7f86000-b7f8b000 r--p 0012d000 03:02 328183 /lib/tls/libc-2.3.5.so
b7f8b000-b7f8e000 rw-p 00132000 03:02 328183 /lib/tls/libc-2.3.5.so
[fleury@carioca programs]$ cat /proc/self/maps | grep libc
b7de4000-b7f11000 r-xp 00000000 03:02 328183 /lib/tls/libc-2.3.5.so
b7f11000-b7f16000 r--p 0012d000 03:02 328183 /lib/tls/libc-2.3.5.so
b7f16000-b7f19000 rw-p 00132000 03:02 328183 /lib/tls/libc-2.3.5.so
When setting /proc/sys/kernel/randomize_va_space to 0, both
randomization stop (see in linux/arch/i386/kernel/process.c).
Would it be possible to tweak them independently from each other ?
(still via procfs)
Regards
--
Emmanuel Fleury
The highest goal of computer science is to automate that
which can be automated.
-- D. L. VerLee
next reply other threads:[~2006-01-30 20:04 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-30 20:03 Emmanuel Fleury [this message]
2006-01-30 22:38 ` [ASLR] Better control on Randomization Nix
2006-01-31 9:15 ` Emmanuel Fleury
2006-01-31 13:14 ` Emmanuel Fleury
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=43DE710F.9020408@labri.fr \
--to=emmanuel.fleury@labri.fr \
--cc=linux-kernel@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox