https://bugs.kde.org/show_bug.cgi?id=475892

            Bug ID: 475892
           Summary: KTextBuffer tries to authenticate as root to save a
                    file even if the file is owned by the user
    Classification: Frameworks and Libraries
           Product: frameworks-ktexteditor
           Version: 5.110.0
          Platform: Archlinux
                OS: Linux
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: general
          Assignee: kwrite-bugs-n...@kde.org
          Reporter: zocsfxljsgpmiua...@protonmail.com
  Target Milestone: ---

SUMMARY
When a file cannot be saved due to permission issues, KTextBuffer always tries
to use the KAuth action "org.kde.ktexteditor.katetextbuffer.savefile" to save
it as root. Even when the file is actually owned by the user and in a directory
controlled by the user, but the user doesn't have write permissions (which,
given that the file is theirs, is easy to change).


STEPS TO REPRODUCE
1. Remove the write permission of a text file owned by your user
2. Modify it with Kate, KWrite, or any application that uses KTextEditor
3. Try to save it

OBSERVED RESULT
A polkit dialog asking for authentication as root appears.

EXPECTED RESULT
Given that you can already change the permission without need of root,
KTextEditor should probably simply inform the user about it, change the
permission by itself, or something that doesn't involve unnecessary
authentication as root.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 5.27.8
KDE Frameworks Version: 5.110.0
Qt Version: 5.15.11

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to