rpmdb_selinux(8)

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

✨ rpmdb_selinux(8) β€” the SELinux tea for rpmdb ✨

okay so this is the rpmdb_selinux page from the SELinux Policy rpmdb collection, and it's basically the whole vibe check for how SELinux treats your rpmdb processes. grab a snack, bestie πŸ“


πŸ’… NAME

rpmdb_selinux β€” Security Enhanced Linux Policy for the rpmdb processes. that's it, that's the name, and it ate. πŸ‘‘


🌸 DESCRIPTION

Security-Enhanced Linux secures the rpmdb processes via flexible mandatory access control. yes ma'am, mandatory β€” not the "haha maybe" kind of access control, the mandatory kind. πŸ”₯

The rpmdb processes execute with the rpmdb_t SELinux type. wanna check if you've got these processes running? literally just execute the ps command with the -Z qualifier. easy.

For example:

ps -eZ | grep rpmdb_t
ngl this one-liner is iconic and you will use it constantly. iykyk 🫢

πŸ¦‹ ENTRYPOINTS

The rpmdb_t SELinux type can be entered via the rpmdb_exec_t file type. that's the door, that's the key, that's the entrypoint. ✨

The default entrypoint paths for the rpmdb_t domain are the following:

  • /usr/bin/rpmdb
  • /usr/lib/rpm/rpmdb_migrate

πŸŽ€ PROCESS TYPES

SELinux defines process types (domains) for each process running on the system. very main character energy of it, honestly.

You can see the context of a process using the -Z option to ps.

Policy governs the access confined processes have to files. SELinux rpmdb policy is very flexible, allowing users to setup their rpmdb processes in as secure a method as possible. flexible and secure? we love a multihyphenate. πŸ’…

The following process types are defined for rpmdb:

  • rpmdb_t
Note: semanage permissive -a rpmdb_t can be used to make the process type rpmdb_t permissive. SELinux does not deny access to permissive process types, but the AVC (SELinux denials) messages are still generated. so like, it stops blocking but it 100% keeps receipts. 😭

🌈 BOOLEANS

SELinux policy is customizable based on least access required. rpmdb policy is extremely flexible and has several booleans that allow you to manipulate the policy and run rpmdb with the tightest access possible. tightest access possible is the goal, bestie. 🎯

If you want to allow all domains to execute in fips_mode, you must turn on the fips_mode boolean. Enabled by default. (yes, it's already on, don't panic 🌸)

setsebool -P fips_mode 1

🧚 FILE CONTEXTS

SELinux requires files to have an extended attribute to define the file type. it's giving "files with paperwork" and honestly, valid. πŸ“‹

You can see the context of a file using the -Z option to ls.

Policy governs the access confined processes have to these files. SELinux rpmdb policy is very flexible, allowing users to setup their rpmdb processes in as secure a method as possible. (yes, same line as before β€” the manpage said it twice and so did i, keeping the lore intact 🫢)

⭐ STANDARD FILE CONTEXT

SELinux defines the file context types for the rpmdb. if you wanted to store files with these types in a different paths, you need to execute the semanage command to specify alternate labeling and then use restorecon to put the labels on disk. two-step process, no skipping steps. πŸ™ˆ

semanage fcontext -a -t rpmdb_exec_t '/srv/rpmdb/content(/.*)?'
restorecon -R -v /srv/myrpmdb_content
Note: SELinux often uses regular expressions to specify labels that match multiple files. regex girlies stay winning. πŸ’œ

The following file types are defined for rpmdb:

πŸ”₯ rpmdb_exec_t

  • Set files with the rpmdb_exec_t type if you want to transition an executable to the rpmdb_t domain.

Paths:

  • /usr/bin/rpmdb
  • /usr/lib/rpm/rpmdb_migrate

πŸ“ rpmdb_tmp_t

  • Set files with the rpmdb_tmp_t type if you want to store rpmdb temporary files in the /tmp directories.
Note: File context can be temporarily modified with the chcon command. If you want to permanently change the file context you need to use the semanage fcontext command. This will modify the SELinux labeling database. You will need to use restorecon to apply the labels. so chcon is the "just for tonight" of file labeling and semanage fcontext + restorecon is the whole committed relationship. πŸ’€ don't mix them up!!

πŸ‘‘ 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. (the booleans!! our faves!!)

system-config-selinux is a GUI tool available to customize SELinux policy settings. a GUI!! for the besties who like buttons instead of typing πŸ–±οΈβœ¨


πŸ’– AUTHOR

This manual page was auto-generated using sepolicy manpage. a robot wrote it and i simply gave it a glow-up. πŸ’…


🌟 SEE ALSO

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


and that's the page, bestie 🫢 this was rpmdb version 26-10-06 (dated 26-10-06), brought to you straight from the rpmdb manual β€” go forth and label responsibly. πŸŒˆπŸ’œ

πŸ“¦ where this page comes from