Messages in this thread Patch in this message | | | Date | Wed, 27 Jul 2005 13:26:06 -0500 | From | serue@us ... | Subject | [patch 9/15] lsm stacking v0.3: selinux: update ->security structs |
| |
Add the struct security_list lsm_list; to each structure which SELinux will be appending to a kernel object.
Signed-off-by: Serge Hallyn <serue@us.ibm.com> -- objsec.h | 19 +++++++++++-------- 1 files changed, 11 insertions(+), 8 deletions(-)
Index: linux-2.6.13-rc3/security/selinux/include/objsec.h =================================================================== --- linux-2.6.13-rc3.orig/security/selinux/include/objsec.h 2005-06-17 14:48:29.000000000 -0500 +++ linux-2.6.13-rc3/security/selinux/include/objsec.h 2005-07-25 14:55:34.000000000 -0500 @@ -23,11 +23,14 @@ #include <linux/fs.h> #include <linux/binfmts.h> #include <linux/in.h> +#include <linux/security.h> #include "flask.h" #include "avc.h" +#define SELINUX_LSM_ID 0xB65 + struct task_security_struct { - unsigned long magic; /* magic number for this module */ + struct security_list lsm_list; /* chained security objects */ struct task_struct *task; /* back pointer to task object */ u32 osid; /* SID prior to last execve */ u32 sid; /* current SID */ @@ -37,7 +40,7 @@ struct task_security_struct { }; struct inode_security_struct { - unsigned long magic; /* magic number for this module */ + struct security_list lsm_list; /* chained security objects */ struct inode *inode; /* back pointer to inode object */ struct list_head list; /* list of inode_security_struct */ u32 task_sid; /* SID of creating task */ @@ -49,14 +52,14 @@ struct inode_security_struct { }; struct file_security_struct { - unsigned long magic; /* magic number for this module */ + struct security_list lsm_list; /* chained security objects */ struct file *file; /* back pointer to file object */ u32 sid; /* SID of open file description */ u32 fown_sid; /* SID of file owner (for SIGIO) */ }; struct superblock_security_struct { - unsigned long magic; /* magic number for this module */ + struct security_list lsm_list; /* chained security objects */ struct super_block *sb; /* back pointer to sb object */ struct list_head list; /* list of superblock_security_struct */ u32 sid; /* SID of file system */ @@ -70,20 +73,20 @@ struct superblock_security_struct { }; struct msg_security_struct { - unsigned long magic; /* magic number for this module */ + struct security_list lsm_list; /* chained security objects */ struct msg_msg *msg; /* back pointer */ u32 sid; /* SID of message */ }; struct ipc_security_struct { - unsigned long magic; /* magic number for this module */ + struct security_list lsm_list; /* chained security objects */ struct kern_ipc_perm *ipc_perm; /* back pointer */ u16 sclass; /* security class of this object */ u32 sid; /* SID of IPC resource */ }; struct bprm_security_struct { - unsigned long magic; /* magic number for this module */ + struct security_list lsm_list; /* chained security objects */ struct linux_binprm *bprm; /* back pointer to bprm object */ u32 sid; /* SID for transformed process */ unsigned char set; @@ -102,7 +105,7 @@ struct netif_security_struct { }; struct sk_security_struct { - unsigned long magic; /* magic number for this module */ + struct security_list lsm_list; /* chained security objects */ struct sock *sk; /* back pointer to sk object */ u32 peer_sid; /* SID of peer */ }; - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |