Skip to contentSkip to conversation

what is the default context of a program without selinux-aware

DISCUSSION bigclouds 2 participants 3 messages Jan 9, 2014 – Jan 10, 2014 1 message not in the archive SELinux security module

lore
Share & tools
lore

bigclouds

author
#0 lore raw

hi,all
1.
what is the default context of a program without selinux-aware?

2.
any advantagement for a program to implement selinux-aware?

thanks

maintainer
#1 lore raw
Quoted 1 line · bigclouds

1. what is the default context of a program without selinux-aware?

The SELinux context of a running process is determined by the security policy.

Quoted 1 line

2. any advantagement for a program to implement selinux-aware?

Could you be more specific about what you mean by "selinux-aware"?

Signature · 2 lines
paul moore
www.paul-moore.com
maintainer
#3 lore raw
In reply to a message not in the archive

[NOTE: re-adding the SELinux mailing list]

Quoted 3 lines · bigclouds

1. a program with selinux-aware means the program call libselinux api. what is the advantage? is it same as defining security policy for the program?

Typically people use the libselinux API to accomplish specific goals that were not possible otherwise, e.g. affecting the label assigned to newly created sockets. I suggest looking at the libselinux API to better understand what advantages it offers.

Quoted 2 lines

2. if a program is writen by myself, when i launch it, what is its context? inherit from user? or bash?

It is dependent on your security policy. You can use the '-Z' option with the 'ps' command to view the SELinux label of running processes.

Quoted 10 lines
Quoted 9 lines · At 2014-01-10 02:18:45,"Paul Moore" <[email protected]> wrote:
Quoted 1 line · bigclouds

1. what is the default context of a program without selinux-aware?

The SELinux context of a running process is determined by the security policy.

Quoted 1 line

2. any advantagement for a program to implement selinux-aware?

Could you be more specific about what you mean by "selinux-aware"?

Signature · 2 lines
paul moore
www.paul-moore.com