get security_class_t for objects

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

 



Hi,
as an userspace object manager which uses libselinux, I am trying to use avc_has_perm(3) for determining access decisions. when I open a file, I can get its security context and change it to SID by using fgetfilecon(3) and avc_context_to_sid(3), respectively. but when I want to have access decision by calling avc_has_perm(3), I am not sure what to pass as the third argument,that is security_class_t. I would like to know if there is any API by which I can determine an already opened file`s class. may some one direct me to a sample code please

Best regards.

[Index of Archives]     [Selinux Refpolicy]     [Linux SGX]     [Fedora Users]     [Fedora Desktop]     [Yosemite Photos]     [Yosemite Camping]     [Yosemite Campsites]     [KDE Users]     [Gnome Users]

  Powered by Linux