Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow relabeling of files/directories under /usr prefix #180

Merged
merged 1 commit into from Sep 26, 2022

Commits on Sep 23, 2022

  1. Allow relabeling of files/directories under /usr prefix

    We already check to make sure users do not accidentily relabel these
    excluded paths:
    
    	exclude_paths := map[string]bool{
    		"/":           true,
    		"/bin":        true,
    		"/boot":       true,
    		"/dev":        true,
    		"/etc":        true,
    		"/etc/passwd": true,
    		"/etc/pki":    true,
    		"/etc/shadow": true,
    		"/home":       true,
    		"/lib":        true,
    		"/lib64":      true,
    		"/media":      true,
    		"/opt":        true,
    		"/proc":       true,
    		"/root":       true,
    		"/run":        true,
    		"/sbin":       true,
    		"/srv":        true,
    		"/sys":        true,
    		"/tmp":        true,
    		"/usr":        true,
    		"/var":        true,
    		"/var/lib":    true,
    		"/var/log":    true,
    	}
    
    But some users put homedirectories under /usr, and I see no
    reason to block them from relabeling.
    
    At a certain point if users do something dumb with relableing we
    can not stop them.
    
    Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
    rhatdan committed Sep 23, 2022
    Configuration menu
    Copy the full SHA
    d3ccb69 View commit details
    Browse the repository at this point in the history