Created attachment 1208068 [details]
Description of problem:
Users are unable to write to a file using 'kwrite', though they have ACL access.
Version-Release number of selected component (if applicable):
Provide acl access to file for a user. Login to that user and try accessing the file.
Steps to Reproduce:
 # setfacl -m u:test:rwx /etc/fstab
 Login by 'test' user
 Open 'kwrite' and try writing /etc/fstab
 Received a error saying "The document could not be saved as it was not possible to write to /etc/fstab. Check that you have write access to this file or that enough disk space is available".
kwrite doesn't allow the access provided for the user using ACLs
kwrite should allow the access provided for the user using ACLs
ACLs works fine for gedit
This seems to be caused by the approach that kwrite uses for saving changes to existing files. Instead of opening the existing file for writing (which you granted the ACL for), it writes the new contents to a temporary file and calls rename() to replace the existing file by the temporary file. For this to succeed, you would need to have write access to the _directory_ where the file resides.
In any case, ACLs work as designed. Switching the component to kate...
Fixed in kate-4.10.5-5.el7.
There is a problem with deleting text. I'm able to edit and add lines/text, but when I try to delete it, It deletes partially or not at all.
1) # setfacl -m "u:test:rw" /etc/fstab
2) open the file in kate
3) add line and save
5) delete the line and save
Ok, I managed to reproduce and also find a bug for this . I'll try to backport this fix as well so this is complete.
 - https://bugs.kde.org/show_bug.cgi?id=323693
I have the fix backported and verified locally, we just need the exception flag to be set so I can push it.
Fixed in kate-4.10.5-6.el7.
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.