Skip to content

Commit

Permalink
Merge branch 'stable-3.14' of git://git.infradead.org/users/pcmoore/s…
Browse files Browse the repository at this point in the history
…elinux into for-linus
  • Loading branch information
James Morris committed Feb 10, 2014
2 parents 9c1db77 + 2172fa7 commit f743166
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions security/selinux/nlmsgtab.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
#include <linux/inet_diag.h>
#include <linux/xfrm.h>
#include <linux/audit.h>
#include <linux/sock_diag.h>

#include "flask.h"
#include "av_permissions.h"
Expand Down Expand Up @@ -78,6 +79,7 @@ static struct nlmsg_perm nlmsg_tcpdiag_perms[] =
{
{ TCPDIAG_GETSOCK, NETLINK_TCPDIAG_SOCKET__NLMSG_READ },
{ DCCPDIAG_GETSOCK, NETLINK_TCPDIAG_SOCKET__NLMSG_READ },
{ SOCK_DIAG_BY_FAMILY, NETLINK_TCPDIAG_SOCKET__NLMSG_READ },
};

static struct nlmsg_perm nlmsg_xfrm_perms[] =
Expand Down
4 changes: 4 additions & 0 deletions security/selinux/ss/services.c
Original file line number Diff line number Diff line change
Expand Up @@ -1232,6 +1232,10 @@ static int security_context_to_sid_core(const char *scontext, u32 scontext_len,
struct context context;
int rc = 0;

/* An empty security context is never valid. */
if (!scontext_len)
return -EINVAL;

if (!ss_initialized) {
int i;

Expand Down

0 comments on commit f743166

Please sign in to comment.