Print this page
uts: Allow for address space randomisation.
Randomise the base addresses of shared objects, non-fixed mappings, the
stack and the heap. Introduce a service, svc:/system/process-security,
and a tool psecflags(1) to control and observe it
*** 22,33 ****
/*
* Copyright 2006 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
- #pragma ident "%Z%%M% %I% %E% SMI"
-
#include <sys/types.h>
#include <sys/mkdev.h>
#include <sys/regset.h>
#include <string.h>
--- 22,31 ----
*** 369,378 ****
--- 367,378 ----
dst->pr_flttrace = src->pr_flttrace;
dst->pr_sysentry = src->pr_sysentry;
dst->pr_sysexit = src->pr_sysexit;
dst->pr_dmodel = src->pr_dmodel;
+ (void) memcpy(&dst->pr_secflags, &src->pr_secflags, sizeof (psecflags_t));
+
lwpstatus_32_to_n(&src->pr_lwp, &dst->pr_lwp);
}
void
lwpsinfo_32_to_n(const lwpsinfo32_t *src, lwpsinfo_t *dst)
*** 742,751 ****
--- 742,753 ----
dst->pr_flttrace = src->pr_flttrace;
dst->pr_sysentry = src->pr_sysentry;
dst->pr_sysexit = src->pr_sysexit;
dst->pr_dmodel = src->pr_dmodel;
+ (void) memcpy(&dst->pr_secflags, &src->pr_secflags, sizeof (psecflags_t));
+
lwpstatus_n_to_32(&src->pr_lwp, &dst->pr_lwp);
}
void
lwpsinfo_n_to_32(const lwpsinfo_t *src, lwpsinfo32_t *dst)