chinmoyr created this revision. Restricted Application added a project: Frameworks.
REVISION SUMMARY Some methods in file ioslave, `FileProtocol::copy` and FileProtocol::put to be precise, use file descriptor of source and destination files. So performing any these operations as root user using kauth's helper requires the source or destination file to be opened inside the helper and sending the file descriptor back to ioslave using a suitable IPC mechanism. My patch does the task using unix local domain socket. In principal dbus can also be used. The sequence would be, registering service in ioslave, setting `euid` of the helper process and sending the file descriptor over user's session bus. I tried it but the code turned out messy. In the end it was somewhat a personal preference. There are certain things I would like to know regarding this patch, In this patch I used the abstract namespace. It will work with linux but I don't know about mac os or bsd. So what to use for them? In place of unix sockets, dbus can also be used. So shall i use it ? I am aware there are security issues with both the approaches but using which one of them is less riskier? REPOSITORY R241 KIO REVISION DETAIL https://phabricator.kde.org/D6709 AFFECTED FILES src/ioslaves/file/CMakeLists.txt src/ioslaves/file/sharefd.cpp src/ioslaves/file/sharefd.h To: chinmoyr, thiago, #frameworks Cc: elvisangelaccio, shortstheory