CmdID

CmdID / Commands

setfiles

Set SELinux file security contexts based on policy rules. tldr-pages

On Linux

Opens CmdID with your command. It is read in your browser and sent nowhere.

Set SELinux file security contexts based on policy rules. Similar to restorecon but reads contexts from a file_contexts file.

Set file contexts according to the default policy file

sudo setfiles /etc/selinux/targeted/contexts/files/file_contexts path/to/directoryIdentify

Set file contexts recursively and show changes

sudo setfiles /etc/selinux/targeted/contexts/files/file_contexts path/to/directory --verboseIdentify

Preview what would be changed without actually modifying contexts

sudo setfiles /etc/selinux/targeted/contexts/files/file_contexts path/to/directory --nochangeIdentify

Set file contexts and verify them

sudo setfiles /etc/selinux/targeted/contexts/files/file_contexts path/to/directory --verbose --forceIdentify

Use a specific root path for context matching

sudo setfiles /etc/selinux/targeted/contexts/files/file_contexts path/to/new_directory --rootpath path/to/old_directoryIdentify