All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel J Walsh <dwalsh@redhat.com>
To: Ted X Toth <txtoth@gmail.com>
Cc: selinux@tycho.nsa.gov
Subject: Re: api for getting setrans information
Date: Fri, 30 Mar 2007 06:16:49 -0400	[thread overview]
Message-ID: <460CE391.6090100@redhat.com> (raw)
In-Reply-To: <460C3195.1020505@gmail.com>

Ted X Toth wrote:
> Are there apis to retrieve all of the categories and sensitivity 
> levels and to convert them into a human readable form?
No, Not really,  you either read the setrans.conf file directly, but 
this would break if you used a different translation library (mitre).

Or you could attempt to exhaustively search the namespace using:

        extern int selinux_raw_to_trans_context(security_context_t raw,,
                                                security_context_t * 
transp);

Which would have 16 * 1024! (Factorial) combinations.  IE It would take 
a long time.

If you call the functions and (raw == transp ) no translation.



--
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:[~2007-03-30 10:17 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-29 21:37 api for getting setrans information Ted X Toth
2007-03-30 10:16 ` Daniel J Walsh [this message]
2007-03-30 11:46 ` Stephen Smalley
2007-03-30 13:06   ` Ted X Toth

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=460CE391.6090100@redhat.com \
    --to=dwalsh@redhat.com \
    --cc=selinux@tycho.nsa.gov \
    --cc=txtoth@gmail.com \
    /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.