cups_brf_selinux(8)

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

πŸ’– SELinux Policy cups_brf β€” the cups_brf_selinux(8) manual πŸ’–

✨ NAME ✨

cups_brf_selinux β€” Security Enhanced Linux Policy for the cups_brf processes. 🫢

πŸ¦‹ DESCRIPTION πŸ¦‹

Okay so Security-Enhanced Linux secures the cups_brf processes via flexible mandatory access control. No cap.

The cups_brf processes execute with the cups_brf_t SELinux type. Wanna check if you’ve got these processes running? Run the ps command with the -Z qualifier, like:

ps -eZ | grep cups_brf_t

That’s the vibe check. πŸ’…

πŸŽ€ ENTRYPOINTS πŸŽ€

The cups_brf_t SELinux type can be entered via the cups_brf_exec_t file type. Iconic.

The default entrypoint paths for the cups_brf_t domain are literally:

  • /usr/lib/cups/backend/cups-brf

🌈 PROCESS TYPES 🌈

SELinux defines process types (domains) for each process running on the system. Periodt.

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

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

The following process types are defined for cups_brf:

  • cups_brf_t
Note: semanage permissive -a cups_brf_t can be used to make the process type cups_brf_t permissive. SELinux does not deny access to permissive process types, but the AVC (SELinux denials) messages are still generated. So like, permissive doesn’t mean invisible, bestie. πŸ‘€

πŸ“ BOOLEANS πŸ“

SELinux policy is customizable based on least access required. The cups_brf policy is extremely flexible and has several booleans that allow you to manipulate the policy and run cups_brf with the tightest access possible. Obsessed with least privilege.

If you want to allow all domains to execute in fips_mode, you must turn on the fips_mode boolean. Enabled by default.

setsebool -P fips_mode 1

🌸 MANAGED FILES 🌸

The SELinux process type cups_brf_t can manage files labeled with the following file types. The paths listed are the default paths for these file types. Note: the process’s UID still needs to have DAC permissions. Fr fr, SELinux is not out here doing DAC’s job.

  • admin_home_t
    • /root(/.*)?
  • print_spool_t
    • /var/spool/lpd(/.*)?
    • /var/spool/cups(/.*)?
    • /var/spool/cups-pdf(/.*)?
  • user_home_t
    • /home/[^/]+/.+

πŸ’œ FILE CONTEXTS πŸ’œ

SELinux requires files to have an extended attribute to define the file type. That’s just how it is.

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

Policy governs the access confined processes have to these files. The SELinux cups_brf policy is very flexible, allowing users to set up their cups_brf processes in as secure a method as possible. Same energy as above, but for files this time. ✨

πŸŽ€ STANDARD FILE CONTEXT πŸŽ€

SELinux defines the file context types for cups_brf. If you want to store files with these types in a different path, you need to execute the semanage command to specify alternate labeling and then use restorecon to put the labels on disk. Like this:

semanage fcontext -a -t cups_brf_exec_t '/srv/cups_brf/content(/.*)?'
restorecon -R -v /srv/mycups_brf_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 cups_brf:

  • cups_brf_exec_t β€” Set files with the cups_brf_exec_t type if you want to transition an executable to the cups_brf_t domain.
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. Temporary vs permanent is giving main character plot twist. 😭

πŸ”₯ 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. Cute.

⭐ SEE ALSO ⭐

Check out selinux(8), cups_brf(8), semanage(8), restorecon(8), chcon(1), sepolicy(8), and setsebool(8). Iykyk. πŸ’–


Okay bestie, signing off from source/version cups_brf, dated 26-10-06, living in cups_brf_selinux(8). Stay secure, stay iconic. 🫢✨

πŸ“¦ where this page comes from