Hello again!
My gsoc project proceed very well. I’m happy to announce that the new kde authorization library is feature-complete and has been moved in kdereview. I’ve mailed kde-core-devel to ask feedback.
Now you can find the library at trunk/kdereview/libkauth.
Since the last blog post, I’ve added some new APIs and refined the existing. Now the API is completely documented (with doxygen).
I’ve added the cmake macros to help you create actions policies in a cross-platform way.
Now everything’s ready for the next step: extending KAction, KPushButton and other GUI elements to let developers to easily use the new API.
Bye bye
GNU/Linux, Unix world Planet KDE
Hello!!
The summer of code midterm evaluations arrived and so It’s time to blog about what I’ve done so far.
The new library implements an easy way to use the caller/helper pattern to perform privileged tasks without having to run the GUI as root. The authorization library is currently working well on Linux with the PolicyKit backend and the OS X backend is in progress.
The main features are:
- Cross-platform design
- Nice and clean API to ask the helper to execute actions.
- Nice and clean API to write the helper.
- The application can provide custom data (a QVariantMap) to the helper
- The helper can return custom data to the application when the action has been executed or in the meanwhile.
- Long running actions can report the execution progress back to the application. A progressStep() signal is provided to easily connect to a progress bar.
- The application can ask the helper to stop execute an action.
- The helper’s debug output from qDebug() & co. are automatically redirected to the application’s output.
You can download the code from the kde repository at playground/base/libkauth and to compile it you need Qt (of course) and polkit-qt, which is available from the repository at kdesupport/polkit-qt.
In the example/ subdirectory you’ll find some code that use the library. It’s a very stupid text editor that can open and save files to protected locations using the helper. I also provided a long-running action to show the use of asynchronous actions and actions termination.
An overview of the API follows, looking at the example application included.
Prosegui la lettura…
GNU/Linux, Generale, Unix world Planet KDE