All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ivan Gyurdiev <ivg2@cornell.edu>
To: Daniel J Walsh <dwalsh@redhat.com>
Cc: Joshua Brindle <jbrindle@tresys.com>,
	Stephen Smalley <sds@tycho.nsa.gov>,
	SE Linux <selinux@tycho.nsa.gov>
Subject: Re: Latest policycoreutils patch
Date: Wed, 18 Jan 2006 11:00:46 -0700	[thread overview]
Message-ID: <43CE824E.6010904@cornell.edu> (raw)
In-Reply-To: <43CE6261.8030204@redhat.com>


> python chcat -L -l dwalsh
> libsemanage.semanage_create_store: Could not access module store at 
> /etc/selinux/targeted/modules, or it is not a directory.
> libsemanage.assert_init: A direct or server connection is needed to 
> use this function - please call the corresponding connect() method
> libsemanage.enter_ro: could not enter read-only section
> Traceback (most recent call last):
>  File "chcat", line 366, in ?
>    sys.exit(listusercats(cmds))
>  File "chcat", line 303, in listusercats
>    seusers = seobject.loginRecords().get_all()
>  File "/usr/lib/python2.4/site-packages/seobject.py", line 175, in 
> get_all
>    raise ValueError("Could not list login mappings")
> ValueError: Could not list login mappings
>
>
> This needs to be legal.  What is happening to cause this problem?  Or 
> do I need to code around this by reading the seusers file?
It's a permissions problem - you have to be root to create the store, 
because you're writing to /etc/selinux/targeted/modules (or reading from 
it, it doesn't really matter), and at least on my machine all folders 
and files under that folder are owned by root, and not writable/readable 
by anyone else. Of course, it should fail on connect  and stop there, 
but you're still not checking rc values where necessary.

Btw, it seems that handle_create can also fail in a variety of ways, 
while that is undocumented in the headers - should change the headers. 
It returns NULL on failure.




--
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:[~2006-01-18 18:00 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-01-17 20:34 Latest policycoreutils patch Daniel J Walsh
2006-01-18  1:36 ` Joshua Brindle
2006-01-18  1:37 ` Joshua Brindle
2006-01-18  3:40   ` Daniel J Walsh
2006-01-18  3:41     ` Joshua Brindle
2006-01-18  3:48       ` Daniel J Walsh
2006-01-18  3:51         ` Joshua Brindle
2006-01-18  7:02           ` Ivan Gyurdiev
2006-01-18 15:44             ` Daniel J Walsh
2006-01-18 18:00               ` Ivan Gyurdiev [this message]
2006-01-18 18:12                 ` Ivan Gyurdiev
2006-01-18 18:30                   ` Stephen Smalley
2006-01-18 18:36                     ` Ivan Gyurdiev
2006-01-18 18:52                       ` Stephen Smalley
2006-01-18 19:04                         ` Ivan Gyurdiev
2006-01-18 19:32                           ` Stephen Smalley
2006-01-18 19:07                         ` Daniel J Walsh
2006-01-18 19:15                           ` Ivan Gyurdiev
2006-01-18 19:19                             ` Daniel J Walsh
2006-01-18 19:59                               ` Stephen Smalley
2006-01-18 20:01                                 ` Ivan Gyurdiev
2006-01-19 14:27                                   ` Daniel J Walsh
2006-01-18 16:13 ` Stephen Smalley
  -- strict thread matches above, loose matches on Subject: below --
2006-09-07 13:31 Daniel J Walsh
2006-09-08 14:00 ` Karl MacMillan
2006-09-08 14:33 ` Joshua Brindle
2006-09-08 14:55   ` Karl MacMillan
2006-09-08 14:35 ` Stephen Smalley
2006-09-08 16:37   ` Daniel J Walsh
2006-09-08 20:25     ` Stephen Smalley
2006-09-11 12:25       ` Joshua Brindle
2006-09-12 12:45         ` Karl MacMillan
2006-09-13 15:14       ` Joshua Brindle
2006-11-06 15:25 Daniel J Walsh

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=43CE824E.6010904@cornell.edu \
    --to=ivg2@cornell.edu \
    --cc=dwalsh@redhat.com \
    --cc=jbrindle@tresys.com \
    --cc=sds@tycho.nsa.gov \
    --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.