selinux_r...t_sehandle(3)
π selinux_restorecon_set_sehandle β bestie edition π
okay so this is page selinux_r...t_sehandle(3) from the SELinux API documentation manual, and it's short but it's mighty, no cap. let's get into it π«Ά
β¨ NAME β¨
selinux_restorecon_set_sehandle β set a labeling handle for use by selinux_restorecon(3) π
β¨ SYNOPSIS β¨
#include <selinux/restorecon.h>
#include <selinux/label.h>
void selinux_restorecon_set_sehandle(struct selabel_handle *handle);
like. that's it. that's the whole thing. two includes and one function. she's lowkey minimalist πΈ
β¨ DESCRIPTION β¨
selinux_restorecon_set_sehandle() sets the handle to be used by selinux_restorecon(3) when relabeling files. it's giving pass the aux cord but for label handles π
so why would you even do this?? bestie, here's the tea: selinux_restorecon_set_sehandle() is generally used when you need customised selabel_open(3) parameters to do your relabeling operations with selinux_restorecon(3). translation: when the default handle just isn't serving, you build your own and hand it over π
π¦ not me handing selinux_restorecon(3) a fully customised handle like "here girl, i made this for you" π₯Ή
β¨ SEE ALSO β¨
the whole squad, go read these too, fr fr:
selinux_restorecon(3)selinux_restorecon_set_exclude_list(3)selinux_restorecon_default_handle(3)selinux_restorecon_set_alt_rootpath(3)selinux_restorecon_xattr(3)
and that's the page!! π Security Enhanced Linux wrote this one back on 20 Oct 2015 (a vintage icon honestly π), and yes bestie, that's the source, the version and the date all rolled into one cute lil sign-off. now go set that handle. slay. π β¨π¦
π¦ where this page comes from
- alpine 3.24: libselinux-doc 3.10-r1 Β· Public-Domain
- centos-stream 10: libselinux-devel 3.11-3.el10 Β· LicenseRef-Fedora-Public-Domain
- centos-stream 9: libselinux-devel 3.6-5.el9 Β· Public Domain
- centos-stream 9: libselinux-devel 3.6-5.el9 Β· Public Domain
- debian bookworm: libselinux1-dev 3.4-1+b6
- debian trixie: libselinux1-dev 3.8.1-1 Β· LicenseRef-public-domain
- fedora 43: libselinux-devel 3.9-5.fc43 Β· LicenseRef-Fedora-Public-Domain
- fedora 43: libselinux-devel 3.9-5.fc43 Β· LicenseRef-Fedora-Public-Domain
- fedora 44: libselinux-devel 3.10-1.fc44 Β· LicenseRef-Fedora-Public-Domain
- fedora 44: libselinux-devel 3.10-1.fc44 Β· LicenseRef-Fedora-Public-Domain
- fedora 44: libselinux-devel 3.11-2.fc44 Β· LicenseRef-Fedora-Public-Domain
- fedora 44: libselinux-devel 3.11-2.fc44 Β· LicenseRef-Fedora-Public-Domain
- nixos 26.05: libselinux 3.10
- nixpkgs unstable: libselinux 3.11
- opensuse-leap 16.0: libselinux-devel 3.8.1-160000.4.1 Β· SUSE-Public-Domain
- opensuse-leap 16.0: libselinux-devel 3.8.1-160000.4.1 Β· SUSE-Public-Domain
- opensuse-leap 16.0: libselinux-devel 3.8.1-160000.4.1 Β· SUSE-Public-Domain
- opensuse-leap 16.0: libselinux-devel 3.8.1-160000.4.1 Β· SUSE-Public-Domain
- ubuntu jammy: libselinux1-dev 3.3-1build2
- ubuntu noble: libselinux1-dev 3.5-2ubuntu2 Β· LicenseRef-public-domain
- ubuntu noble: libselinux1-dev 3.5-2ubuntu2.1 Β· LicenseRef-public-domain
- ubuntu questing: libselinux1-dev 3.8.1-1build1
- ubuntu resolute: libselinux-dev 3.9-4build1 Β· LicenseRef-public-domain
- ubuntu stonking: libselinux-dev 3.11-2.1 Β· LicenseRef-public-domain
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms