selinux/policycoreutils
Caleb Case 031ee84821 semodule: add priority, enabled, and extended listing
This updates the semodule tool with the ability to set the priority for
commands, to enable/disable modules, and extended module listing options
for displaying extra module information (e.g., priority, enabled status,
and language extension).

[semodule priority]

-X --priority set the priority for following operations

Notes:

* This sets the priority for the following operations.

* It can be used any number of times with its effect continuing until
  the next priority is specified.

* The default priority is used if no priority has yet been specified.

Impact on current operations:

* Install module

  * Without priority - Install at default priority.

  * With priority - Install at specified priority.

  * New warning when overriding (issued by libsemanage).

* Upgrade module

  * Without priority - Upgrade at default priority (current upgrade
    semantics apply).

  * With priority - Upgrade at specified priority (current upgrade
    semantics apply).

  * New warning when overriding (issued by libsemanage).

* Remove module

  * Without priority - Remove a module at the default if exists.

  * With priority - Remove at that priority.

  * New info messages (issued by libsemanage):

    * If no modules exist at the given priority but do exist at other
      priorities, give an info message listing the modules and priority.

    * If a new module at a lower priority will become active print a
      message.

    * If the last module with this name is being removed print a
      message.

* Base

  * The name of base module on install is fixed to "_base" (performed by
    libsemanage).

  * Without priority - Install at default priority.

  * With priority - Install at specified priority.

  * New warning when overriding (issued by libsemanage).

* List modules

  * See listing changes below.

Examples:

semodule -i foo.pp

semodule -X 500 -i foo.pp

[semodule enable/disable]

Add enable/disable status:

-e   --enable   enable the module (at all priorities)
-d   --disable  disable the module (at all priorities)

Notes:

* Base modules are always enabled and cannot have their enabled/disabled
  status changed.

* New error when disabling a base module (from libsemanage).

* New warning when enabling a base module (from libsemanage).

Impact on current operations:

* Install module

  * If a module with that name is already installed, then the enabled
    status will remain the same after installing the new module.

  * New warning when installing a module which will be disabled by
    existing enabled status (from libsemanage).

* Upgrade module

  * If a module with that name is already installed, then the enabled
    status will remain the same after installing the new module.

  * New warning when installing a module which will be disabled by
    existing enabled status (from libsemanage).

* Remove module

  * When the last module with a given name is removed (no more exist at
    other priorities) then the enabled status is forgotten.

* Base

  * Base modules are always installed enabled and remain so (can't be
    disabled).

* List modules

  * See listing changes below.

Examples:

semodule -e foo

semodule -d foo

[semodule list]

-l		--list		list modules as if by -lstandard

-lstandard	--list=standard	list name and version of highest priority,
				enabled, non-base modules sorted alphabetical
				by name

-lfull		--list=full	list all fields of all modules columnated
				sorted high priority to low, within priority
				alphabetical by name

Impact on current operations:

* List modules

  * Default listing stays the same.

  * New long options for 'standard' and 'full'.

Examples:

semodule -l
semodule -lstandard
semodule --list=standard

alsa 1.7.1
apm 1.9.1
apt 1.5.2
authlogin 2.0.0
avahi 1.10.3
bluetooth 3.1.3
...

semodule -lfull
semodule --list=full

600 alsa      1.7.1 disabled pp
400 _base     1.0.0          pp
400 alsa      1.7.1 disabled pp
400 apm       1.9.1          pp
400 apt       1.5.2          pp
400 authlogin 2.0.0          pp
...
100 alsa      1.7.1 disabled pp

Signed-off-by: Chad Sellers <csellers@tresys.com>
2014-08-26 08:02:16 -04:00
..
.tx Update Translations 2013-10-24 13:58:39 -04:00
audit2allow selinux_current_policy_path will return none on a disabled SELinux system 2013-11-13 11:07:21 -05:00
gui Fix up desktop files to match current standards 2013-11-08 15:50:59 -05: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 Deprecate use of flask.h and av_permissions.h. 2014-07-09 13:49:18 -04:00
newrole Deprecate use of flask.h and av_permissions.h. 2014-07-09 13:49:18 -04:00
po Update Translations 2013-10-24 13:58:39 -04:00
restorecond Fix up desktop files to match current standards 2013-11-08 15:50:59 -05:00
run_init Merge branch 'fedora' into master-merge 2013-10-24 15:24:17 -04:00
sandbox seunshare: Try to use setcurrent before setexec 2014-05-12 14:14:45 -04:00
scripts Minor manpages improvements 2013-11-06 09:36:33 -05:00
secon Minor manpages improvements 2013-11-06 09:36:33 -05:00
semanage semanage: move permissive module creation to /tmp 2014-08-26 08:02:16 -04:00
semodule semodule: add priority, enabled, and extended listing 2014-08-26 08:02:16 -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 tree: Makefiles: syntax, convert all ${VAR} to $(VAR) 2011-11-02 15:37:08 -04:00
semodule_link tree: Makefiles: syntax, convert all ${VAR} to $(VAR) 2011-11-02 15:37:08 -04:00
semodule_package Laurent Bigonville patch to fix various minor manpage issues and correct section numbering. 2013-10-24 13:58:37 -04:00
sepolgen-ifgen tree: Makefiles: syntax, convert all ${VAR} to $(VAR) 2011-11-02 15:37:08 -04:00
sepolicy Add new icons for sepolicy gui 2013-11-13 11:07:17 -05:00
sestatus Laurent Bigonville patch to fix various minor manpage issues and correct section numbering. 2013-10-24 13:58:37 -04:00
setfiles Minor manpages improvements 2013-11-06 09:36:33 -05:00
setsebool Cleanup whitespace 2013-11-08 15:52:11 -05:00
.gitignore policycoreutils: add po file configuration information 2013-02-05 20:14:38 -05:00
ChangeLog Bump version and update ChangeLog for release. 2014-05-06 13:30:27 -04:00
COPYING initial import from svn trunk revision 2950 2008-08-19 15:30:36 -04:00
Makefile Handle audit2allow and audit2why with the same executable Remove audit2why directory and combine this into audit2allow directory 2013-10-24 13:58:39 -04:00
VERSION Bump version and update ChangeLog for release. 2014-05-06 13:30:27 -04:00