bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How can i change high level of a file in the target security context


From: Jim Meyering
Subject: Re: How can i change high level of a file in the target security context
Date: Sat, 19 Jul 2008 16:18:47 +0200

Cai Xianchao <address@hidden> wrote:
> I run as root and used chcon -l to set range of a file, but it failed and
> there was error message output.
>
>
> I did as follows:
> #uname -r
> 2.6.18-92.el5
>
> #sestatus
> SELinux status:                 enabled
> SELinuxfs mount:                /selinux
> Current mode:                   enforcing
> Mode from config file:          enforcing
> Policy version:                 21
> Policy from config file:        targeted
>
> #chcon -l s0:c1 test
>
> #ls -Z
> -rw-r--r--  root root root:object_r:user_home_t:s0:c1  test
>
> #chcon -l s0:c0-s0:c0.c100 test
> chcon: failed to change context of test to
> root:object_r:user_home_t:s0:c0-s0:c0.c100: Permission denied
>
> How can i change high level of a file when SELINUX is open and the policy
> is targeted?

Thanks for the report, but I don't understand what you'd like to do.
What would you like "ls -Z test" to print after you've adjusted the
context of that file?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]