selinux/policycoreutils
Petr Lautrbach 7a728e46a5 libsemanage: Use pp module name instead of filename
When a user installs a module, the filename is used as the module name.
This change was introduced with CIL language where a module name is not
stored in the module itself. It means that when a pp module has
different filename and stored module name, the filename is used instead
of the stored module name. It brings problems with compatibility for
scripts and modules which were built and used on older system and were
migrated to the new userspace.

This patch changes the behavior of semanage_direct_install_file() which
is used by 'semodule -i' so that when a module with pp language
extension is installed, it tries to get and use a stored module name
instead of a filename. A warning message is provided.

The warning message in policycoreutils/hll/pp is updated to reflect this
change:

$ semodule -X 400 -i /root/testfile.pp
Warning: SELinux userspace will refer to the module from /root/testfile.pp as testmod rather than testfile

$ /usr/libexec/selinux/hll/pp /root/testfile.pp testfile.cil
Warning: SELinux userspace will refer to the module from /root/testfile.pp as testmod rather than testfile

Signed-off-by: Petr Lautrbach <plautrba@redhat.com>
2016-09-26 11:38:45 -04:00
..
.tx Update Translations 2013-10-24 13:58:39 -04:00
audit2allow audit2allow: tests should use local copy not system 2016-08-19 08:45:10 -04:00
gui policycoreutils/gui: py3 support for modules that changed name 2016-08-05 12:57:08 -04:00
hll libsemanage: Use pp module name instead of filename 2016-09-26 11:38:45 -04:00
load_policy Minor manpages improvements 2013-11-06 09:36:33 -05:00
man Merge branch 'fedora' into master-merge 2013-10-24 15:24:17 -04:00
mcstrans policycoreutils: Fix PEP8 issues 2015-07-24 16:07:13 +08:00
newrole policycoreutils: Remove LDFLAGS from CFLAGS 2016-09-26 11:02:40 -04:00
po sepolicy: update setup.py to remove C module 2016-09-23 16:33:49 -04:00
restorecond libselinux: add support for pcre2 2016-09-15 13:49:14 -04:00
run_init open_init_pty: Do not error on EINTR 2016-07-12 15:35:23 -04:00
sandbox policycoreutils: Remove LDFLAGS from CFLAGS 2016-09-26 11:02:40 -04:00
scripts policycoreutils: 'fixfiles check' should not change anything 2016-08-09 15:55:26 -04:00
secon Added missing descriptions for --*-key params in secon man page. 2016-01-12 08:39:14 -05:00
semanage sepolicy: info() and search() will return generators 2016-09-23 16:33:49 -04:00
semodule policycoreutils: semodule - remove 'q' from getopt string 2016-08-04 08:42:15 -04:00
semodule_deps Laurent Bigonville patch to fix various minor manpage issues and correct section numbering. 2013-10-24 13:58:37 -04:00
semodule_expand
semodule_link
semodule_package libselinux, policycoreutils: Man page warning fixes 2015-11-24 16:32:13 -05:00
sepolgen-ifgen
sepolicy sepolicy: update setup.py to remove C module 2016-09-23 16:33:49 -04:00
sestatus Laurent Bigonville patch to fix various minor manpage issues and correct section numbering. 2013-10-24 13:58:37 -04:00
setfiles policycoreutils: setfiles - Modify to use selinux_restorecon 2016-08-11 14:33:58 -04:00
setsebool libselinux, policycoreutils: Man page warning fixes 2015-11-24 16:32:13 -05:00
.gitignore policycoreutils: add a HLL compiler to convert policy packages (.pp) to CIL 2014-08-26 08:03:31 -04:00
COPYING
ChangeLog Updated ChangeLogs 2016-09-26 11:03:33 -04:00
Makefile policycoreutils: add a HLL compiler to convert policy packages (.pp) to CIL 2014-08-26 08:03:31 -04:00
VERSION Update ChangeLog and VERSION for final release 2016-02-23 11:31:41 -05:00