rpm_script_selinux(8)

πŸ“¦
version 20250627+git412.dbf877ab7 Β· 7 versions
, in opensuse-leap 16.0

πŸ’… NAME

rpm_script_selinux β€” the Security Enhanced Linux Policy page for the rpm_script processes, and yes bestie we're reading the whole thing together 🫢


✨ DESCRIPTION

So, Security-Enhanced Linux secures the rpm_script processes via flexible mandatory access control. That's the whole vibe β€” SELinux is the bouncer at the club and it checks everyone's label before letting them touch files 😌

The rpm_script processes execute with the rpm_script_t SELinux type. Wanna check if you've got these processes running? Just run the ps command with the -Z qualifier. iykyk πŸ’…

Like this, for example:

ps -eZ | grep rpm_script_t

πŸšͺ ENTRYPOINTS

The rpm_script_t SELinux type can be entered via the usr_t, bin_t, shell_exec_t, and ldconfig_exec_t file types. Those are the doors into the domain, no cap πŸ¦‹

The default entrypoint paths for the rpm_script_t domain are literally the following (copying these exactly, don't @ me):

All executables with the default executable label, usually stored in
/usr/bin and /usr/sbin.  /opt/.*, /usr/.*, /hana(/.*)?, /emul/.*,
/export(/.*)?, /ostree(/.*)?, /usr/doc(/.*)?/lib(/.*)?,
/usr/inclu.e(/.*)?, /usr/share/rpm(/.*)?, /usr/share/doc(/.*)?/README.*,
/usr/lib/modules(/.*)/vmlinuz, /usr/lib/modules(/.*)/sysctl.conf,
/usr/lib/modules(/.*)/initramfs.img, /usr/lib/sysimage(/.*)?,
/usr/lib/ostree-boot(/.*)?, /opt, /usr, /emul, /usr/bin/d?ash,
/usr/bin/ksh.*, /usr/bin/zsh.*, /usr/bin/esh, /usr/bin/bash,
/usr/bin/fish, /usr/bin/mksh, /usr/bin/sash, /usr/bin/sesh,
/usr/bin/tcsh, /usr/bin/yash, /usr/bin/bash2, /usr/bin/smrsh,
/usr/bin/nologin, /usr/bin/scponly, /usr/bin/scponlyc,
/usr/libexec/sesh, /usr/bin/git-shell, /usr/libexec/sudo/sesh,
/usr/bin/cockpit-bridge, /usr/libexec/cockpit-agent, /usr/libexec/git-core/git-shell,
/usr/bin/sln, /usr/bin/ldconfig
Not the /usr/inclu.e(/.*)? entry β€” that's wild, but it's in the source and it's staying exactly as-is. Slay for accuracy πŸŽ€

πŸ‘‘ PROCESS TYPES

SELinux defines process types (aka domains) for each process running on the system. Iconic behaviour honestly.

You can see the context of a process using the -Z option to ps. Peep the labels, bestie πŸ‘€

Policy governs the access confined processes have to files. The SELinux rpm_script policy is very flexible, allowing users to set up their rpm_script processes in as secure a method as possible.

The following process types are defined for rpm_script:

  • rpm_script_t
Note: semanage permissive -a rpm_script_t can be used to make the process type rpm_script_t permissive. SELinux does not deny access to permissive process types, but the AVC (SELinux denials) messages are still generated. So like, it's not a free pass β€” it's just a "we're taking notes but not stopping you" pass 😭

πŸ”˜ BOOLEANS

SELinux policy is customizable based on least access required. The rpm_script policy is extremely flexible and has several booleans that allow you to manipulate the policy and run rpm_script with the tightest access possible. Little toggles, huge power πŸ’…

If you want to control the ability to mmap a low area of the address space, as configured by /proc/sys/vm/mmap_min_addr, you must turn on the mmap_low_allowed boolean. Disabled by default.

setsebool -P mmap_low_allowed 1

If you want to allow system to run with NIS, you must turn on the nis_enabled boolean. Disabled by default.

setsebool -P nis_enabled 1

If you want to disable kernel module loading, you must turn on the secure_mode_insmod boolean. Disabled by default.

setsebool -P secure_mode_insmod 1

If you want to allow unconfined executables to make their heap memory executable, you must turn on the selinuxuser_execheap boolean. Doing this is a really bad idea. Probably indicates a badly coded executable, but could indicate an attack. This executable should be reported in bugzilla. Disabled by default.

setsebool -P selinuxuser_execheap 1
🚨 Fr fr bestie, that last one β€” making heap memory executable is genuinely a bad idea. Not a vibe. If something needs it, that's a red flag and it should go straight to bugzilla. Periodt.

πŸ“ MANAGED FILES

The SELinux process type rpm_script_t can manage files labeled with the following file types. The paths listed are the default paths for these file types. Watch out though β€” the processes UID still needs to have DAC permissions, so SELinux saying yes isn't the whole story 🫢

file_type

  • all files on the system

Like. All of them. Main character energy honestly 🌈


πŸ› οΈ COMMANDS

  • semanage fcontext can also be used to manipulate default file context mappings.
  • semanage permissive can also be used to manipulate whether or not a process type is permissive.
  • semanage module can also be used to enable/disable/install/remove policy modules.
  • semanage boolean can also be used to manipulate the booleans.
  • system-config-selinux is a GUI tool available to customize SELinux policy settings.

✍️ AUTHOR

This manual page was auto-generated using sepolicy manpage. Machine-written but make it cute πŸ’œ


πŸ‘€ SEE ALSO

selinux(8), rpm_script(8), semanage(8), restorecon(8), chcon(1), sepolicy(8), setsebool(8)


That's the whole page bestie, you ate that πŸ“ This was rpm_script from rpm_script_selinux(8), dated 26-10-06 β€” go forth and be secure, mwah πŸ’‹βœ¨

πŸ“¦ where this page comes from