Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nodecon #38

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion src/network_statements.md
Original file line number Diff line number Diff line change
Expand Up @@ -174,14 +174,18 @@ labeling (see the
[***node* object class**](object_classes_permissions.md#network-object-classes)
that represent IPv4 or IPv6 IP addresses and network masks.

It is also possible to add SELinux these outside the policy using the
It is also possible to add these outside of the policy using the
***semanage**(8)* *node* command that will associate the node to a security
context.

Since ***checkpolicy**(8)* 3.7 the subnet and netmask can be specified together
by using the Classless Inter-Domain Routing (CIDR) notation.

**The statement definition is:**

```
nodecon subnet netmask node_context
nodecon cidr_address node_context
```

**Where:**
Expand All @@ -200,6 +204,11 @@ Note that the subnet and netmask values are used to ensure that the

The subnet mask in IPv4 or IPv6 format.

*cidr_address*

The IP address in CIDR notation, consisting of a IPv4 or IPv6 address, and the
netmask as a number of leading bits, joined by a slash ('/').

*node_context*

The security context for the node.
Expand All @@ -224,13 +233,15 @@ Conditional Policy Statements
# The MLS policy nodecon statement using an IPv4 address:

nodecon 127.0.0.1 255.255.255.255 system_u:object_r:lo_node_t:s0 - s15:c0.c255
nodecon 127.0.0.1/32 system_u:object_r:lo_node_t:s0 - s15:c0.c255
```

```
# The MLS policy nodecon statement for the multicast address
# using an IPv6 address:

nodecon ff00:: ff00:: system_u:object_r:multicast_node_t:s0 - s15:c0.c255
nodecon ff00::/8 system_u:object_r:multicast_node_t:s0 - s15:c0.c255
```

***semanage**(8)* **Command example:**
Expand Down
Loading