File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -10,6 +10,8 @@ use libkernel::proc::caps::CapabilitiesFlags;
1010
1111const PR_SET_PDEATHSIG : i32 = 1 ;
1212const PR_GET_PDEATHSIG : i32 = 2 ;
13+ const PR_GET_DUMPABLE : i32 = 3 ;
14+ const PR_SET_DUMPABLE : i32 = 4 ;
1315const PR_CAPBSET_READ : i32 = 23 ;
1416const PR_CAPBSET_DROP : i32 = 24 ;
1517const PR_SET_NAME : i32 = 15 ;
@@ -246,6 +248,11 @@ pub async fn sys_prctl(
246248 match op {
247249 PR_SET_PDEATHSIG => pr_set_pdeath_sig ( ctx, arg1 as i64 ) ,
248250 PR_GET_PDEATHSIG => pr_get_pdeath_sig ( ctx) ,
251+ PR_GET_DUMPABLE => Ok ( 1 ) ,
252+ PR_SET_DUMPABLE => match arg1 {
253+ 0 | 1 => Ok ( 0 ) ,
254+ _ => Err ( KernelError :: InvalidValue ) ,
255+ } ,
249256 PR_SET_NAME => pr_set_name ( ctx, TUA :: from_value ( arg1 as usize ) ) . await ,
250257 PR_GET_NAME => pr_get_name ( ctx, TUA :: from_value ( arg1 as usize ) ) . await ,
251258 PR_CAPBSET_READ => pr_read_capbset ( ctx, arg1 as usize ) ,
You can’t perform that action at this time.
0 commit comments