tromey at sourceware dot org
2018-07-03 16:33:52 UTC
https://sourceware.org/bugzilla/show_bug.cgi?id=23365
Bug ID: 23365
Summary: macOS does not disable ASLR
Product: gdb
Version: HEAD
Status: NEW
Severity: normal
Priority: P2
Component: cli
Assignee: unassigned at sourceware dot org
Reporter: tromey at sourceware dot org
Target Milestone: ---
darwin_nat_target doesn't override supports_disable_randomization,
but it could.
lldb uses a special Darwin posix_spawn flag for this:
#ifndef _POSIX_SPAWN_DISABLE_ASLR
#define _POSIX_SPAWN_DISABLE_ASLR 0x0100
#endif
...
short flags = POSIX_SPAWN_START_SUSPENDED | POSIX_SPAWN_SETEXEC |
POSIX_SPAWN_SETSIGDEF | POSIX_SPAWN_SETSIGMASK;
// Disable ASLR if we were asked to
if (disable_aslr)
flags |= _POSIX_SPAWN_DISABLE_ASLR;
Bug ID: 23365
Summary: macOS does not disable ASLR
Product: gdb
Version: HEAD
Status: NEW
Severity: normal
Priority: P2
Component: cli
Assignee: unassigned at sourceware dot org
Reporter: tromey at sourceware dot org
Target Milestone: ---
darwin_nat_target doesn't override supports_disable_randomization,
but it could.
lldb uses a special Darwin posix_spawn flag for this:
#ifndef _POSIX_SPAWN_DISABLE_ASLR
#define _POSIX_SPAWN_DISABLE_ASLR 0x0100
#endif
...
short flags = POSIX_SPAWN_START_SUSPENDED | POSIX_SPAWN_SETEXEC |
POSIX_SPAWN_SETSIGDEF | POSIX_SPAWN_SETSIGMASK;
// Disable ASLR if we were asked to
if (disable_aslr)
flags |= _POSIX_SPAWN_DISABLE_ASLR;
--
You are receiving this mail because:
You are on the CC list for the bug.
You are receiving this mail because:
You are on the CC list for the bug.