Re: [PATCH -v7 -rc3] Security: Introduce security= boot parameter

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Casey Schaufler <casey@...>
Cc: Chris Wright <chrisw@...>, Stephen Smalley <sds@...>, James Morris <jmorris@...>, Eric Paris <eparis@...>, Paul Moore <paul.moore@...>, Alexey Dobriyan <adobriyan@...>, Andrew Morton <akpm@...>, Linus <torvalds@...>, LKML <linux-kernel@...>, LSM-ML <linux-security-module@...>
Date: Wednesday, March 5, 2008 - 12:55 pm

Hi Casey,

On Wed, Mar 05, 2008 at 08:33:34AM -0800, Casey Schaufler wrote:
...

Beside the locking initialization issue, there's the current->security
issue. smackfs init code code access current->security in 
smk_unlbl_ambient().

As you know current->security may equal Null (Oops), or point to 
another LSM structure that preceeded us in registration. 

The locking argument can't be applied here since we may override
the other LSM tsk->security pointer this time.

Ofcourse all of the above points can be handleded by various
if(current->security) checks + rechecking the read/write methods
of each smackfs inode, but below only two lines will fix the 
problem from its roots ;):

+	if (!security_module_enable(&smack_ops))
+		return 0;

Is there a problem in the current approach that I'm not aware of ?

You have your veto in this issue at the end ;)

Thank you,

-- 

"Better to light a candle, than curse the darkness"

Ahmed S. Darwish
Homepage: http://darwish.07.googlepages.com
Blog: http://darwish-07.blogspot.com

--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH -rc3] Security: Introduce security= boot parameter, Ahmed S. Darwish, (Tue Mar 4, 9:58 am)
[PATCH -v7 -rc3] Security: Introduce security= boot parameter, Ahmed S. Darwish, (Wed Mar 5, 11:29 am)
Re: [PATCH -v7 -rc3] Security: Introduce security= boot para..., Ahmed S. Darwish, (Wed Mar 5, 12:55 pm)