All of lore.kernel.org
 help / color / mirror / Atom feed
From: Joshua Brindle <jbrindle@tresys.com>
To: selinux@tycho.nsa.gov
Subject: getfilecon() and friends in libselinux
Date: Wed, 08 Dec 2004 12:13:04 -0500	[thread overview]
Message-ID: <41B73620.6050905@tresys.com> (raw)

Some applications in setools, namely findcon, replcon and indexcon walk 
the filesystem and get the file context off files. Previously it was 
fairly known what filesystems supported labeling so they were defined 
during the build process but now that other filesystems (reiser, jfs and 
tmpfs) support labeling but aren't necessarilly widespread we can't 
reliably define the supported filesystems during the build process and 
expect it to work across systems.

The idea is to iterate the filesystem mount points and do a getfilecon() 
or similar on a file in it, then examine the error code returned to 
decide if the filesystem supports xattr and also supports the security 
namespace. Is this a stable API to rely on for this? Will the error 
codes remain stable?

Further, if there is ever support for contexts via psids or something 
that isn't xattr will getfilecon() also be a supported method for 
accessing those?

Joshua Brindle
Tresys Technology

--
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.

             reply	other threads:[~2004-12-08 17:11 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-08 17:13 Joshua Brindle [this message]
2004-12-08 17:20 ` getfilecon() and friends in libselinux Stephen Smalley
2004-12-08 19:36   ` Casey Schaufler
2004-12-08 20:17     ` Stephen Smalley

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=41B73620.6050905@tresys.com \
    --to=jbrindle@tresys.com \
    --cc=selinux@tycho.nsa.gov \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.