All of lore.kernel.org
 help / color / mirror / Atom feed
* File Context problem
@ 2007-08-06 14:11 Daniel J Walsh
  2007-08-06 14:41 ` Stephen Smalley
  0 siblings, 1 reply; 2+ messages in thread
From: Daniel J Walsh @ 2007-08-06 14:11 UTC (permalink / raw)
  To: Stephen Smalley, Joshua Brindle, Karl MacMillan, SE Linux

https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=251001	

As this bugzilla points out, we are somewhat inconsistant on the handling of file context.  Currently we treat homedirs differently then we do file_context generated by a policy module.  So the sort order seems to go

semanage fcontext -a : Highest 
genhomedircon   : Second
semodule -i : third

So the question is should the context of genhomedircon and semodule -i be treated the same.

/etc/selinux/TYPE/context/files/file_contexts
/etc/selinux/TYPE/context/files/file_contexts.homedirs

I think local should override everything else.


--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to majordomo@tycho.nsa.gov with
the words "unsubscribe selinux" without quotes as the message.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: File Context problem
  2007-08-06 14:11 File Context problem Daniel J Walsh
@ 2007-08-06 14:41 ` Stephen Smalley
  0 siblings, 0 replies; 2+ messages in thread
From: Stephen Smalley @ 2007-08-06 14:41 UTC (permalink / raw)
  To: Daniel J Walsh; +Cc: Joshua Brindle, Karl MacMillan, SE Linux

On Mon, 2007-08-06 at 10:11 -0400, Daniel J Walsh wrote:
> https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=251001	
> 
> As this bugzilla points out, we are somewhat inconsistant on the handling of file context.  Currently we treat homedirs differently then we do file_context generated by a policy module.  So the sort order seems to go
> 
> semanage fcontext -a : Highest 
> genhomedircon   : Second
> semodule -i : third

That ordering is applied by libselinux matchpathcon (now the label_file
back-end).

The bug report isn't quite right; if they had specified a pathname with
no regex characters (i.e. escaped the "." as "\."), then it would have
taken precedence over any regex expression.  libselinux moves exact
pathname specs to the end to give them precedence over any regex
expression.

> So the question is should the context of genhomedircon and semodule -i be treated the same.
> 
> /etc/selinux/TYPE/context/files/file_contexts
> /etc/selinux/TYPE/context/files/file_contexts.homedirs
> 
> I think local should override everything else.

-- 
Stephen Smalley
National Security Agency


--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to majordomo@tycho.nsa.gov with
the words "unsubscribe selinux" without quotes as the message.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2007-08-06 14:41 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-06 14:11 File Context problem Daniel J Walsh
2007-08-06 14:41 ` Stephen Smalley

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.