Netdev List
 help / color / mirror / Atom feed
From: James Morris <jmorris@namei.org>
To: Catherine Zhang <cxzhang@watson.ibm.com>
Cc: netdev@vger.kernel.org, "David S. Miller" <davem@davemloft.net>,
	chrisw@osdl.org, Herbert Xu <herbert@gondor.apana.org.au>,
	Stephen Smalley <sds@tycho.nsa.gov>,
	tjaeger@cse.psu.edu, Andrew Morton <akpm@osdl.org>,
	latten@austin.ibm.com, sergeh@us.ibm.com, gcwilson@us.ibm.com,
	czhang.us@gmail.com
Subject: Re: [Patch 1/1] AF_UNIX Datagram getpeersec (with latest updates)
Date: Tue, 27 Jun 2006 21:33:17 -0400 (EDT)	[thread overview]
Message-ID: <Pine.LNX.4.64.0606272130080.6477@d.namei> (raw)
In-Reply-To: <20060628013428.GA31240@jiayuguan.watson.ibm.com>

On Tue, 27 Jun 2006, Catherine Zhang wrote:

> diff -puN security/selinux/exports.c~lsm-secpeer-unix security/selinux/exports.c
> --- linux-2.6.17-rc6-mm2-JM/security/selinux/exports.c~lsm-secpeer-unix	2006-06-27 18:15:10.914669944 -0400
> +++ linux-2.6.17-rc6-mm2-JM-cxzhang/security/selinux/exports.c	2006-06-27 18:16:31.502418744 -0400
> @@ -17,6 +17,7 @@
>  #include <linux/selinux.h>
>  #include <linux/fs.h>
>  #include <linux/ipc.h>
> +#include <net/sock.h>
>  
>  #include "security.h"
>  #include "objsec.h"
> @@ -72,6 +73,16 @@ void selinux_get_task_sid(struct task_st
>  	*sid = 0;
>  }
>  
> +void selinux_get_sock_sid(struct socket *sock, u32 *sid)
> +{
> +	if (selinux_enabled) {
> +		const struct inode *inode = SOCK_INODE(sock);
> +		selinux_get_inode_sid(inode, sid);
> +		return;
> +	}
> +	*sid = 0;
> +}
> +


Just one more thing, we don't need to export this function now.



- James
-- 
James Morris
<jmorris@namei.org>

  reply	other threads:[~2006-06-28  1:33 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-28  1:34 [Patch 1/1] AF_UNIX Datagram getpeersec (with latest updates) Catherine Zhang
2006-06-28  1:33 ` James Morris [this message]
2006-06-28  1:52   ` Xiaolan Zhang
2006-06-28  2:13     ` James Morris
2006-06-28  2:23       ` James Morris
2006-06-28  2:45       ` Xiaolan Zhang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Pine.LNX.4.64.0606272130080.6477@d.namei \
    --to=jmorris@namei.org \
    --cc=akpm@osdl.org \
    --cc=chrisw@osdl.org \
    --cc=cxzhang@watson.ibm.com \
    --cc=czhang.us@gmail.com \
    --cc=davem@davemloft.net \
    --cc=gcwilson@us.ibm.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=latten@austin.ibm.com \
    --cc=netdev@vger.kernel.org \
    --cc=sds@tycho.nsa.gov \
    --cc=sergeh@us.ibm.com \
    --cc=tjaeger@cse.psu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox