Print this page
7029 want per-process exploit mitigation features (secflags)
7030 want basic address space layout randomization (aslr)
7031 noexec_user_stack should be a secflag
7032 want a means to forbid mappings around NULL.

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/sun4/os/mlsetup.c
          +++ new/usr/src/uts/sun4/os/mlsetup.c
↓ open down ↓ 181 lines elided ↑ open up ↑
 182  182          p0.p_flag = SSYS;
 183  183          p0.p_tlist = &t0;
 184  184          p0.p_stksize = 2*PAGESIZE;
 185  185          p0.p_stkpageszc = 0;
 186  186          p0.p_as = &kas;
 187  187          p0.p_lockp = &p0lock;
 188  188          p0.p_utraps = NULL;
 189  189          p0.p_brkpageszc = 0;
 190  190          p0.p_t1_lgrpid = LGRP_NONE;
 191  191          p0.p_tr_lgrpid = LGRP_NONE;
      192 +        psecflags_default(&p0.p_secflags);
 192  193          sigorset(&p0.p_ignore, &ignoredefault);
 193  194  
      195 +
 194  196          CPU->cpu_thread = &t0;
 195  197          CPU->cpu_dispthread = &t0;
 196  198          bzero(&cpu0_disp, sizeof (disp_t));
 197  199          CPU->cpu_disp = &cpu0_disp;
 198  200          CPU->cpu_disp->disp_cpu = CPU;
 199  201          CPU->cpu_idle_thread = &t0;
 200  202          CPU->cpu_flags = CPU_RUNNING;
 201  203          CPU->cpu_id = getprocessorid();
 202  204          CPU->cpu_dispatch_pri = t0.t_pri;
 203  205  
↓ open down ↓ 342 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX