added SELINUX patches

This commit is contained in:
csmall
2002-09-27 13:48:00 +00:00
parent 6aa17b562a
commit cd2727983c
16 changed files with 360 additions and 72 deletions

View File

@ -12,6 +12,9 @@
#define SIGNAL_STRING
#ifdef FLASK_LINUX
#include <fs_secure.h>
#endif
/*
ld cutime, cstime, priority, nice, timeout, it_real_value, rss,
@ -121,6 +124,9 @@ typedef struct proc_t {
pcpu; /* %CPU usage (is not filled in by readproc!!!) */
char
state; /* single-char code for process state (S=sleeping) */
#ifdef FLASK_LINUX
security_id_t sid;
#endif
} proc_t;
/* PROCTAB: data structure holding the persistent information readproc needs
@ -138,6 +144,9 @@ typedef struct PROCTAB {
uid_t* uids; /* uids of procs */
int nuid; /* cannot really sentinel-terminate unsigned short[] */
char* stats; /* status chars (actually output into /proc//stat) */
#ifdef FLASK_LINUX
security_id_t* sids; /* SIDs of the procs */
#endif
} PROCTAB;
/* initialize a PROCTAB structure holding needed call-to-call persistent data
@ -197,5 +206,9 @@ extern void freeproc(proc_t* p);
#define PROC_UID 0x0400 /* user id numbers ( length needed ) */
#define PROC_STAT 0x0800 /* status fields ('\0' terminated) */
#define PROC_ANYTTY 0x1000 /* proc must have a controlling terminal */
#ifdef FLASK_LINUX
#define PROC_SID 0x2000
#define PROC_CONTEXT 0x2000 /* synonym: SID gets converted to string if PROC_CONTEXT */
#endif
#endif