Skip to content

Install libselinux Package

An XCCDF Rule

Description

The libselinux package can be installed with the following command:
$ sudo zypper install libselinux

Rationale

Security-enhanced Linux is a feature of the Linux kernel and a number of utilities with enhanced security functionality designed to add mandatory access controls to Linux. The libselinux package contains the core library of the Security-enhanced Linux system.

ID
xccdf_org.ssgproject.content_rule_package_libselinux_installed
Severity
High
References
Updated

Remediation Templates

A Puppet Snippet

include install_libselinux1
class install_libselinux1 {
  package { 'libselinux1':
    ensure => 'installed',
  }
}

An Ansible Snippet

- name: Gather the package facts
  package_facts:
    manager: auto
  tags:
  - CCE-92490-2
  - PCI-DSSv4-1.2

OS Build Blueprint

[[packages]]
name = "libselinux1"
version = "*"

A Shell Script

# Remediation is applicable only in certain platforms
if rpm --quiet -q kernel-default; then
zypper install -y "libselinux1"

else
    >&2 echo 'Remediation is not applicable, nothing was done'
fi