Skip to content

RFC pid: changes to support audit

Richard Guy Briggs linux-audit lkml stable 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest7 patches 18 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/7pid: change task_struct::pid to read-onlyarch/x86/kernel/process.c fs/exec.c include/linux/sched.h +1 more+11 -50 replies
2/7compiler: CONST_CAST makes writing const vars easier and obviousinclude/linux/compiler.h+8 -00 replies
3/7pid: use the CONST_CAST macro instead to write to const task_struct::pidfs/exec.c kernel/fork.c+2 -70 replies
4/7pid: modify task_tgid_nr to work without task->tgid.include/linux/sched.h+1 -13 replies
5/7pid: rewrite task helper function is_global_init() avoiding task->pidinclude/linux/sched.h+1 -12 replies
6/7pid: mark struct task const in helper functionsinclude/linux/sched.h kernel/pid.c+20 -200 replies
7/7pid: get pid_t ppid of task in init_pid_nsinclude/linux/sched.h+18 -05 replies

Reviews trailers per patch

None of the 7 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchPeter Zijlstra
SeriesA-b
1/7
2/7
3/7
4/7
5/7
6/7
7/7

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/7][RFC] pid: changes to support audit

These are a number of patches inspired by ebiederman's container work that were included by me 2013-08-20 as the patchset:
RFC: steps to make audit pid namespace-safe

They have been seperated out for the pid maintainer since there are no direct dependencies from the audit pid namespace patchset with the exception of:
pid: get pid_t ppid of task in init_pid_ns

Andrew, are you willing to adopt these?

In particular, there is discussion around read-only task_struct::pid here:

	https://lkml.org/lkml/2013/12/16/552

Richard Guy Briggs (7):
pid: change task_struct::pid to read-only
compiler: CONST_CAST makes writing const vars easier and obvious
pid: use the CONST_CAST macro instead to write to const
task_struct::pid
pid: modify task_tgid_nr to work without task->tgid.
pid: rewrite task helper function is_global_init() avoiding task->pid
pid: mark struct task const in helper functions
pid: get pid_t ppid of task in init_pid_ns

 arch/x86/kernel/process.c |    2 +-
 fs/exec.c                 |    2 +-
 include/linux/compiler.h  |    8 ++++++
 include/linux/sched.h     |   60 +++++++++++++++++++++++++++++---------------
 kernel/fork.c             |    5 ++-
 kernel/pid.c              |    4 +-
 6 files changed, 54 insertions(+), 27 deletions(-)