From mboxrd@z Thu Jan 1 00:00:00 1970 From: Casey Schaufler Subject: Re: [PATCH 00/16] Permit filesystem local caching [try #3] Date: Mon, 13 Aug 2007 09:58:08 -0700 (PDT) Message-ID: <959629.46851.qm@web36606.mail.mud.yahoo.com> References: <13221.1187022703@redhat.com> Reply-To: casey@schaufler-ca.com, Linux filesystem caching discussion list Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Cc: akpm@osdl.org, LSM List , linux-kernel@vger.kernel.org, nfsv4@linux-nfs.org, trond.myklebust@fys.uio.no, torvalds@osdl.org, linux-cachefs@redhat.com, selinux@tycho.nsa.gov, linux-fsdevel@vger.kernel.org, Stephen Smalley To: David Howells , casey@schaufler-ca.com Return-path: In-Reply-To: <13221.1187022703@redhat.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-cachefs-bounces@redhat.com Errors-To: linux-cachefs-bounces@redhat.com List-Id: linux-fsdevel.vger.kernel.org --- David Howells wrote: > Casey Schaufler wrote: >=20 > > > (1) int security_get_context(void **_context); > > >=20 > > > This allocates and gives the caller a blob that describes the curr= ent > > > context of all the LSM module states attached to the current task = and > > > stores a pointer to it in *_context. > >=20 > > Is this intended to be anything more than a copy of current->security= ? >=20 > It has to be sufficient to fully effect security_push(). Which is why it requires an LSM interface. Just checking. > > I assume that you're talking about the LSM specific data changing, > > not the LSM itself. >=20 > Yes. >=20 > > If you change the task->security information you are definitly going > > to change what other tasks can do to the calling task. >=20 > I dealt with that in my current act-as patch. Under SELinux a task has= two > primary labels. One with which it is labelled and is used to govern ef= fects > upon it, and one that is used to act upon things and follows changes to= the > former. The specification of your push interface that the push operation not affect how others access the process is OK for SELinux, but not for any other MAC scheme that I've dealt with, and I think that's most of them. Nuts. Smack, for example, uses exactly one label on the process for all purposes. Are you concerned about accesses other than signals? Signals could be staitforward to deal with in a pushed situation, but I'd hesitate to say that the solution would generalize without additional thought. > > > (5) int security_xfrm_to_kernel_context(void *from, void **_to); > >=20 > > Woof. What are you transforming from?=20 >=20 > In CacheFiles case, the cachefilesd daemon's security label into the la= bel > the > cache driver acts as on behalf of other processes. I'm not sure I understand what this is doing. Casey Schaufler casey@schaufler-ca.com