Description of problem: When a missing file is rlFileBackup-ed the security context of the backup path is not correctly saved which results in rlFileRestore to change the original context to that of the /tmp/ directory. This is causing many false fails, marking as urgent. Will provide a patch shortly. Please, deploy as soon as possible. Version-Release number of selected component (if applicable): beakerlib-1.3-3.el6.noarch Steps to Reproduce: mkdir /tmp/dir chcon --reference /home /tmp/dir ls -ldZ /tmp/dir rlFileBackup "/tmp/dir/missing" rlFileRestore ls -ldZ /tmp/dir Actual results: drwxr-xr-x. root root system_u:object_r:home_root_t:s0 /tmp/dir :: [10:28:21] :: [ ERROR ] :: rlFileBackup: Failed to copy /tmp/dir/missing to /tmp/beakerlib-KwxEtu4/backup/tmp/dir. drwxr-xr-x. root root unconfined_u:object_r:user_tmp_t:s0 /tmp/dir Expected results: drwxr-xr-x. root root system_u:object_r:home_root_t:s0 /tmp/dir :: [10:28:21] :: [ ERROR ] :: rlFileBackup: Failed to copy /tmp/dir/missing to /tmp/beakerlib-KwxEtu4/backup/tmp/dir. drwxr-xr-x. root root system_u:object_r:home_root_t:s0 /tmp/dir
Created attachment 434639 [details] patch for the selinux context issue + local variables Fixes the issue, test case included + bonus fix for missed local variables. Before: [ PASS ] Saving the new context 1c1 < drwxrwxr-x. psss psss unconfined_u:object_r:httpd_user_content_t:s0 subdir --- > drwxrwxr-x. psss psss unconfined_u:object_r:user_tmp_t:s0 subdir [ FAIL ] Checking security context (BZ#618269) After: [ PASS ] Saving the new context [ PASS ] Checking security context (BZ#618269)
Fix ready. Guys, can you someone review soon? Thanks.
Thanks for quick review! Pushed to git: http://git.fedorahosted.org/git/?p=beakerlib.git;a=commitdiff;h=dfb91c6b27bed1568863cd9adb4b6e6415910668
This bug appears to have been reported against 'rawhide' during the Fedora 14 development cycle. Changing version to '14'. More information and reason for this action is here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping
This is against beakerlib right? I don't have commit privs for beakerlib. pmuller, have you applied this to beakerlib?
It's in repo, but I haven't built any new packages recently. I'll create new builds today or tomorrow.