VOGONS

Common searches


First post, by Kahenraz

User metadata
Rank l33t
Rank
l33t

I've created a custom SELinux policy that allows a special dosbox_exec_t context with execheap permission to allow the dynamic cpu core to run without having to enter permissive mode or allow heap execution across all processes.

This has stopped the crashing I've been experiencing, as well as reports to the audit log.

It should "just work" by installing the RPM. It's built for Fedora 30 but is noarch and is a basic SELinux policy so it will probably work on others.

There are some included scripts build_rpm, add_policy, and remove_policy. You don't have to run these unless you want to experiment with the policy. Simply install the RPM with your package manager as described below.

This will allow you to install the policy through the package manager (recommended):

# dnf install dosbox_selinux*noarch.rpm

Alternatively, you can add the policy manually:

# semodule -i dosbox.pp
# restorecon -F -R -v /usr/bin/dosbox

This RPM has been build for Fedora. Your mileage may vary depending on your distribution. If you want to try it elsewhere then use the provided add_policy script instead.

If you experience any problems then you can remove the package with:

# dnf remove dosbox_selinux

Disable the module:

# semodule -d dosbox
# restorecon /usr/bin/dosbox

Or remove the policy explicitly:

# semodule -X 400 -r dosbox
# restorecon /usr/bin/dosbox

Attachments

Last edited by Kahenraz on 2019-09-17, 07:38. Edited 2 times in total.