--- v25
+++ v27
@@ -101,10 +101,10 @@
DIR("smack", 0555,
proc_smack_attr_dir_inode_ops, proc_smack_attr_dir_ops),
diff --git a/include/linux/lsm_hooks.h b/include/linux/lsm_hooks.h
-index 5509e4ed9829..ab08da884b2f 100644
+index c61a16f0a5bc..d2c4bc94d47f 100644
--- a/include/linux/lsm_hooks.h
+++ b/include/linux/lsm_hooks.h
-@@ -1670,4 +1670,21 @@ static inline void security_delete_hooks(struct security_hook_list *hooks,
+@@ -1686,4 +1686,21 @@ static inline void security_delete_hooks(struct security_hook_list *hooks,
extern int lsm_inode_alloc(struct inode *inode);
@@ -142,7 +142,7 @@
/* Control parameters settable through module/boot flags */
extern enum audit_mode aa_g_audit;
diff --git a/security/apparmor/lsm.c b/security/apparmor/lsm.c
-index 7d5559b4c417..5bfd313a7cd5 100644
+index 392e25940d1f..4237536106aa 100644
--- a/security/apparmor/lsm.c
+++ b/security/apparmor/lsm.c
@@ -621,6 +621,25 @@ static int apparmor_getprocattr(struct task_struct *task, char *name,
@@ -192,7 +192,7 @@
if (args[size - 1] != '\0') {
/* null terminate */
diff --git a/security/security.c b/security/security.c
-index 0d9a4b50f252..df51140a4d93 100644
+index c2a5c50e913b..fe18c8d8bc22 100644
--- a/security/security.c
+++ b/security/security.c
@@ -77,7 +77,16 @@ static struct kmem_cache *lsm_file_cache;
@@ -213,7 +213,7 @@
/* Boot-time LSM user choice */
static __initdata const char *chosen_lsm_order;
-@@ -667,6 +676,8 @@ int lsm_inode_alloc(struct inode *inode)
+@@ -671,6 +680,8 @@ int lsm_inode_alloc(struct inode *inode)
*/
static int lsm_task_alloc(struct task_struct *task)
{
@@ -222,7 +222,7 @@
if (blob_sizes.lbs_task == 0) {
task->security = NULL;
return 0;
-@@ -675,6 +686,15 @@ static int lsm_task_alloc(struct task_struct *task)
+@@ -679,6 +690,15 @@ static int lsm_task_alloc(struct task_struct *task)
task->security = kzalloc(blob_sizes.lbs_task, GFP_KERNEL);
if (task->security == NULL)
return -ENOMEM;
@@ -238,7 +238,7 @@
return 0;
}
-@@ -1688,14 +1708,26 @@ int security_file_open(struct file *file)
+@@ -1734,14 +1754,26 @@ int security_file_open(struct file *file)
int security_task_alloc(struct task_struct *task, unsigned long clone_flags)
{
@@ -268,7 +268,7 @@
}
void security_task_free(struct task_struct *task)
-@@ -2113,23 +2145,110 @@ int security_getprocattr(struct task_struct *p, const char *lsm, char *name,
+@@ -2173,23 +2205,110 @@ int security_getprocattr(struct task_struct *p, const char *lsm, char *name,
char **value)
{
struct security_hook_list *hp;
@@ -379,7 +379,7 @@
return hp->hook.setprocattr(name, value, size);
}
return LSM_RET_DEFAULT(setprocattr);
-@@ -2149,15 +2268,15 @@ EXPORT_SYMBOL(security_ismaclabel);
+@@ -2209,15 +2328,15 @@ EXPORT_SYMBOL(security_ismaclabel);
int security_secid_to_secctx(struct lsmblob *blob, char **secdata, u32 *seclen)
{
struct security_hook_list *hp;
@@ -400,7 +400,7 @@
}
return LSM_RET_DEFAULT(secid_to_secctx);
-@@ -2168,16 +2287,15 @@ int security_secctx_to_secid(const char *secdata, u32 seclen,
+@@ -2228,16 +2347,15 @@ int security_secctx_to_secid(const char *secdata, u32 seclen,
struct lsmblob *blob)
{
struct security_hook_list *hp;
@@ -421,7 +421,7 @@
}
return 0;
}
-@@ -2185,7 +2303,14 @@ EXPORT_SYMBOL(security_secctx_to_secid);
+@@ -2245,7 +2363,14 @@ EXPORT_SYMBOL(security_secctx_to_secid);
void security_release_secctx(char *secdata, u32 seclen)
{
@@ -437,7 +437,7 @@
}
EXPORT_SYMBOL(security_release_secctx);
-@@ -2326,8 +2451,15 @@ EXPORT_SYMBOL(security_sock_rcv_skb);
+@@ -2386,8 +2511,15 @@ EXPORT_SYMBOL(security_sock_rcv_skb);
int security_socket_getpeersec_stream(struct socket *sock, char __user *optval,
int __user *optlen, unsigned len)
{
@@ -456,10 +456,10 @@
int security_socket_getpeersec_dgram(struct socket *sock, struct sk_buff *skb,
diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c
-index 96c560760c4c..3141ed8544de 100644
+index 0133b142e938..dba867721336 100644
--- a/security/selinux/hooks.c
+++ b/security/selinux/hooks.c
-@@ -6434,6 +6434,17 @@ static int selinux_setprocattr(const char *name, void *value, size_t size)
+@@ -6510,6 +6510,17 @@ static int selinux_setprocattr(const char *name, void *value, size_t size)
/*
* Basic control over ability to set these attributes at all.
*/
@@ -478,7 +478,7 @@
error = avc_has_perm(&selinux_state,
mysid, mysid, SECCLASS_PROCESS,
diff --git a/security/selinux/include/classmap.h b/security/selinux/include/classmap.h
-index ba2e01a6955c..1b4a42150871 100644
+index 62d19bccf3de..8f4b0dd6dd78 100644
--- a/security/selinux/include/classmap.h
+++ b/security/selinux/include/classmap.h
@@ -53,7 +53,7 @@ struct security_class_mapping secclass_map[] = {
@@ -491,10 +491,10 @@
{ "ipc_info", "syslog_read", "syslog_mod",
"syslog_console", "module_request", "module_load", NULL } },
diff --git a/security/smack/smack_lsm.c b/security/smack/smack_lsm.c
-index 023876c3f3a3..576f412b8616 100644
+index 5c10ad27be37..7aa7ea38f627 100644
--- a/security/smack/smack_lsm.c
+++ b/security/smack/smack_lsm.c
-@@ -3511,6 +3511,13 @@ static int smack_setprocattr(const char *name, void *value, size_t size)
+@@ -3508,6 +3508,13 @@ static int smack_setprocattr(const char *name, void *value, size_t size)
struct smack_known_list_elem *sklep;
int rc;