compartments.4 (2011 09)

c
compartments(4) compartments(4)
NAME
compartments - HP-UX compartments files
DESCRIPTION
HP-UX compartments are defined by creating one or more ASCII files in the
/etc/cmpt directory. Only
file names ending with
.rules are parsed for compartment definitions. Collectively, these files define
compartments and compartment access rules for local system objects. System objects that have compart-
ment access controls defined include file system objects, inter-process communication objects, and net-
work objects.
The compartment specifications are pre-processed with the
cpp command before parsing (see cpp (1)).
You can use
cpp directives such as
#include, #define, #ifdef, and C/C++ style comments to organ-
ize and document the rules files.
CONFIGURATION RULES SYNTAX
A compartment consists of a name and a set of rules. Compartments use four kinds of configuration
rules:
file system rules,
inter-process communication (IPC) rules,
network rules, and
miscellaneous rules.
Rules can be either subject-centric or object-centric. Subject-centric rules control access by processes
(subjects) in a compartment to resources (objects) in other compartments. Object-centric rules control
access to resources (objects) in a compartment by processes (subjects) in other compartments.
Compartment definitions use the following format:
[
sealed][discover] compartment new_compartment_name
{rules }
If the HP-UX ContainmentPlus product (version B.11.31.02 or later) is installed on the system, compart-
ment definitions use the following format:
[
sealed][discover][system][blocked] compartment new_compartment_name
{rules }
where the values are defined as follows:
sealed Indicates that any process in this compartment can not change its compartment
as a side-effect of the exec() call, even if the binary being executed has
extended security attributes indicating that the process starts in a different com-
partment (see exec (2)). For security purposes, the minimum retained and
minimum permitted privileges of the binary are also ignored (and treated as
though both sets are empty sets).
discover Indicates that for all the processes in this compartment, the required mandatory
access rules would be generated at run time so that the process operations would
succeed. This is a development tool that enables developers to identify all the
required mandatory access rules for the given application by running it in a
compartment marked as discover.
system Indicates that this compartment shares the ownership of network interfaces with
default compartments such as, the init compartment, and other compartments
that are marked as system compartments. The ownership of network inter-
faces are typically specified by network interface rules (see the following Net-
work Interface Rules section).
When a compartment is marked as a
system compartment, all of the network
interfaces that are configured to belong to this compartment are also considered
as belonging to the init compartment and all other compartments that are
marked as system compartments. The init compartment will be in favor of
using these network interfaces for network communications, over using the other
network interfaces. When a compartment is marked as system compartment,
it also shares the connectivities through loopback interfaces with the init com-
partment.
The
system keyword is valid only if the HP-UX ContainmentPlus product (ver-
sion B.11.31.02 or later) is installed on the system.
HP-UX 11i Version 3: September 2011 1 Hewlett-Packard Company 1

Summary of content (10 pages)