semanage_node(3)
โจ NAME โจ
semanage_node โ the SELinux Network Nodes Management API, aka the whole entire toolkit for talking about network nodes in SELinux, bestie ๐
๐ SYNOPSIS ๐
#include <semanage/node_record.h>
#include <semanage/nodes_policy.h>
#include <semanage/nodes_local.h>
Okay so picture this: this object holds all the properties that are associated with a network node. That's it, that's the vibe. ๐ฆ
And if you wanna know the tea on one specific function? Each one has its own manual page, so go read that one. iykyk ๐
๐ Record API Overview
semanage_node_create(3)โ makes you a node, brand new, fresh out the box โจsemanage_node_free(3)โ lets this node go, releases all its resources ๐ซถsemanage_node_key_create(3)โ creates a key, which you can use to identify a node ๐semanage_node_key_free(3)โ releases the resources for this node key, bye bestie ๐semanage_node_key_extract(3)โ pulls out a key that matches this node ๐ฏsemanage_node_clone(3)โ makes an identical node, a deep-copy clone, twin behavior fr fr ๐ฏsemanage_node_compare(3)โ compares this node against the key you hand it ๐semanage_node_compare2(3)โ compares this node against another node, head to head ๐ค
๐ Properties API Overview
semanage_node_get_addr(3)โ returns this node's IP address, as a string ๐semanage_node_set_addr(3)โ sets this node's IP address from the string representation and protocol you provide โ๏ธsemanage_node_get_addr_bytes(3)โ returns this node's IP address as a byte array in network byte order ๐งฎsemanage_node_set_addr_bytes(3)โ sets this node's IP address from the byte array you provide, in network byte order ๐ฅsemanage_node_get_mask(3)โ returns this node's IP mask as a string ๐ญsemanage_node_set_mask(3)โ sets this node's IP mask from the string representation and protocol version you provide ๐๏ธsemanage_node_get_mask_bytes(3)โ returns this node's IP mask as a byte array in network byte order ๐ขsemanage_node_set_mask_bytes(3)โ sets this node's IP mask from the byte array you provide, in network byte order ๐ฆsemanage_node_get_proto(3)โ returns the IP protocol version for this node ๐กsemanage_node_get_proto_str(3)โ returns a string representation of whatever protocol that node is on ๐คsemanage_node_set_proto(3)โ sets the IP protocol version for this node ๐ ๏ธsemanage_node_get_con(3)โ returns the SELinux context associated with this node ๐ท๏ธsemanage_node_set_con(3)โ sets the SELinux context associated with this node ๐พ
๐๏ธ Record Store API Overview
semanage_node_modify_local(3)โ adds or updates an interface in the local store โ๏ธsemanage_node_del_local(3)โ deletes an interface from the local store ๐๏ธsemanage_node_exists(3)โ checks if an interface is defined in the persistent policy ๐semanage_node_exists_local(3)โ checks if an interface is defined in the local store ๐semanage_node_query(3)โ queries an interface in the persistent policy โsemanage_node_query_local(3)โ queries an interface in the local store ๐semanage_node_count(3)โ counts how many nodes are defined in the persistent policy ๐งฎsemanage_node_count_local(3)โ counts how many nodes are defined in the local store ๐ขsemanage_node_iterate(3)โ runs a callback for each interface in the persistent policy ๐semanage_node_iterate_local(3)โ runs a callback for each interface in the local store ๐semanage_node_list(3)โ returns an array containing every node in the persistent policy ๐semanage_node_list_local(3)โ returns an array containing every node in the local store ๐
Okay that's the whole page, you ate that ๐
This lil gem lives in the Libsemanage API documentation, it was written by ivg2@cornell.edu, and it's dated 16 March 2006 โ an icon, an absolute legend, still serving the girls network node management realness to this very day. periodt. ๐๐๐ฆ
๐ฆ where this page comes from
- centos-stream 10: libsemanage-devel 3.11-3.el10 ยท LGPL-2.1-or-later
- debian trixie: libsemanage-dev 3.8.1-1 ยท LGPL-2.1-or-later
- fedora 43: libsemanage-devel 3.9-4.fc43 ยท LGPL-2.1-or-later
- fedora 43: libsemanage-devel 3.9-4.fc43 ยท LGPL-2.1-or-later
- fedora 44: libsemanage-devel 3.10-1.fc44 ยท LGPL-2.1-or-later
- fedora 44: libsemanage-devel 3.10-1.fc44 ยท LGPL-2.1-or-later
- fedora 44: libsemanage-devel 3.11-1.fc44 ยท LGPL-2.1-or-later
- fedora 44: libsemanage-devel 3.11-1.fc44 ยท LGPL-2.1-or-later
- nixos 26.05: libsemanage 3.10
- nixpkgs unstable: libsemanage 3.11
- opensuse-leap 16.0: libsemanage-devel 3.8.1-160000.3.1 ยท LGPL-2.1-or-later
- opensuse-leap 16.0: libsemanage-devel 3.8.1-160000.3.1 ยท LGPL-2.1-or-later
- opensuse-leap 16.0: libsemanage-devel 3.8.1-160000.3.1 ยท LGPL-2.1-or-later
- opensuse-leap 16.0: libsemanage-devel 3.8.1-160000.3.1 ยท LGPL-2.1-or-later
- ubuntu questing: libsemanage-dev 3.8.1-1
- ubuntu resolute: libsemanage-dev 3.9-1build1 ยท LGPL-2.1-or-later
- ubuntu stonking: libsemanage-dev 3.11-1 ยท LGPL-2.1-or-later
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms