[apparmor] [PATCH] Check expect profiles are present after load/replace

Steve Beattie steve at nxnw.org
Tue Aug 10 16:44:27 BST 2010


On Tue, Aug 10, 2010 at 09:28:29AM -0400, John Johansen wrote:
> On 08/10/2010 12:31 AM, Kees Cook wrote:
> > On Sun, Aug 08, 2010 at 03:47:32AM -0700, John Johansen wrote:
> >> This admittedly hackish bit of bash ensures that the profiles that the
> >> test suite just loaded are in fact listed as being present in the kernel.
> >> I don't think this is ready to commit yet as I think it can be improved,
> >> and am looking for feedback or alternate patches to clean it up.
> > 
> > This looks fine for the regression test hardness, IMO.
> > 
> >> +	#check to see if the profiles are actually loaded
> >> +	for f in `cat $profilenames` ; do
> >> +		grep -q "^${f} \(.*\)$" ${sys_profiles}
> > 
> > Maybe improve the grep to:
> >     grep -Eq ^"$f"' \([^)]+\)$' ${sys_profiles}
> > 
> done, and I took this as an ack and checked it in.

That's fine, though I was going to ask if the added uservars.inc entry
was really necessary. Do you have experimental patches planned that will
have apparmor profile listings reported in alternate locations?

-- 
Steve Beattie
<sbeattie at ubuntu.com>
http://NxNW.org/~steve/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
Url : https://lists.ubuntu.com/archives/apparmor/attachments/20100810/1200558c/attachment.pgp 


More information about the AppArmor mailing list