Bug 338875 - Attempting to alter kwalletmanager settings results in "Sorry, the system security policy didn't allow you to save the changes" error
Summary: Attempting to alter kwalletmanager settings results in "Sorry, the system sec...
Status: REOPENED
Alias: None
Product: kwalletmanager
Classification: Applications
Component: general (show other bugs)
Version: 2.0
Platform: Kubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Valentin Rusu
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-09-07 09:58 UTC by Chris Samuel
Modified: 2015-09-23 11:54 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Samuel 2014-09-07 09:58:04 UTC
With KDE 4.14 under Kubuntu 14.04 whenever I try and change a setting in kwalletmanager (such as enable "Show manager in system tray") I get the dreaded "Sorry, the system security policy didn't allow you to save the changes." message.

I've looked at bug #326126 and can confirm that it's not the same as I do have both the file /etc/dbus-1/system.d/org.kde.kcontrol.kcmkwallet.conf and the package polkit-kde-1 installed and yet I am still hitting this issue.

My work laptop with Kubuntu 14.04 and KDE 4.13.x (can't find the exact version as it's at work and I'm not) seems to be fine.

I've tried running kwalletmanager from the command line and then starting the configuration from there, but all I get logged is:

$ kwalletmanager 
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString)
chris@quad:~/Downloads/Linux/Kernel/linux$ Bus::open: Can not get ibus-daemon's address. 
IBusInputContext::createInputContext: no connection to ibus-daemon 

when kwalletmanager first starts up and no extra messages when the configuration dialogue is selected and started.



Reproducible: Always

Steps to Reproduce:
1. Run kwalletmanager by hand (as it's not in the system tray)
2. Select Settings->Configure Wallet
3. Select "Show manager in System tray" option
4. Press either OK or Apply


Actual Results:  
Get a pop-up error box saying "Sorry, the system security policy didn't allow you to save the changes."

Expected Results:  
Settings should be changed.

The dbus config file (/etc/dbus-1/system.d/org.kde.kcontrol.kcmkwallet.conf) is this:

<!DOCTYPE busconfig PUBLIC
 "-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN"
 "http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
<busconfig>
 
  <!-- Only user root can own the foo helper -->
  <policy user="root">
    <allow own="org.kde.kcontrol.kcmkwallet"/>
  </policy>
 
</busconfig>
Comment 1 Chris Samuel 2014-09-07 10:08:24 UTC
After looking at that dbus config file again I wondered if I was being locked out because of not being root (which seemed like an odd thing).

I took a gamble and did "sudo kwalletmanager" and whilst it didn't open the wallet I was able to change the setting to enable the "Show manager in System tray" option and now when I start it as me it appears there, and if I quit it and start it again it it still appears.

So why should I need to be root for this to be possible?

I've taken a look at the git repo for kwalletmanager and I don't see this file there even though it is owned by the kwalletmanager package from the Kubuntu PPA - is that usually provided by the distro rather than KDE?
Comment 2 Lutze 2015-01-08 20:52:01 UTC
I have the same problem, after submitting changes of the kwalletmanager configuration, a password prompt appears and after entering  the password the same message is shown (here in german: "Leider erlauben es Ihnen die Sicherheitsregeln des Systems nicht, die Änderungen zu speichern.")

This is with kwalletmanager version 2.0 under KDE 4.14.3 and openSUSE 13.2
Comment 3 Valentin Rusu 2015-02-15 19:42:37 UTC
You need to be root or member of the wheel group or otherwise prove you're the admin of the system to change the settings. That was requested by other users here on bugs.kde.org (I don't have the precise BUG n° though to point you to). So closing this.
Comment 4 Alex 2015-07-07 08:53:07 UTC
Valentin,
i have the same with although my user is member of wheel. You closed the bug, but you didn'd give a solution to enable kwalletmanager configuration for users. How i should enable kwalletmanager in system tray par example? No answer, bug closed, good job!!!
Comment 5 Valentin Rusu 2015-07-07 11:34:26 UTC
(In reply to Alex from comment #4)
> Valentin,
> i have the same with although my user is member of wheel. You closed the
> bug, but you didn'd give a solution to enable kwalletmanager configuration
> for users. How i should enable kwalletmanager in system par example? No
> answer, bug closed, good job!!!

Well, even if you start being non-constructive, I'll just answer you here that the original question was not about the system tray. What if I also started inventing examples just to insult your work here?

Now, to restore constructive approach, you should check with KUbuntu and their packagers as this won't reproduce on my system, where I use the kwallet compiled from sources.
Comment 6 rskdebugs2012 2015-07-30 07:16:07 UTC
I've hit the same problem on Slackware-current after recent update of the system (which brought me KDE 4.14.3).

(In reply to Valentin Rusu from comment #5)
> Well, even if you start being non-constructive, I'll just answer you here
> that the original question was not about the system tray. 

Yes, it was. The original question said: 
   .. whenever I try and change a setting in kwalletmanager (such as enable "Show manager in system tray") ...

Now to restore constructive approach can you please tell use whether the file /etc/dbus-1/system.d/org.kde.kcontrol.kcmkwallet.conf, as shown above, is indeed the reason why the saving of KDE Wallet Manager configuration saving may fail? And if yes, could you provide an example of the D-BUS configuration that would allow saving of the configuration to non-root user? I'm not asking to change the application, or modify the distributions defaults. I just want to configure it on my own system. I assume that would be sufficient solution also for other people that reported this problem.

I'll add output of dbus-monitor; perhaps that can be useful: 

method call sender=:1.103 -> dest=org.freedesktop.DBus serial=26 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=NameHasOwner
   string "org.kde.Polkit1AuthAgent"
method call sender=:1.103 -> dest=org.kde.Polkit1AuthAgent serial=27 path=/org/kde/Polkit1AuthAgent; interface=org.kde.Polkit1AuthAgent; member=setWIdForAction
   string "org.kde.kcontrol.kcmkwallet.save"
   uint64 115343485
method return sender=:1.76 -> dest=:1.103 reply_serial=27
method call sender=:1.103 -> dest=org.kde.knotify serial=28 path=/Notify; interface=org.kde.KNotify; member=event
   string "messageCritical"
   string "kde"
   array [
   ]
   string ""
   string "Sorry, the system security policy didn't allow you to save the changes."
   array [
   ]
   array [
   ]
   int32 -1
   int64 115343506
method return sender=:1.84 -> dest=:1.103 reply_serial=28
   int32 21
signal sender=:1.84 -> dest=(null destination) serial=85 path=/Notify; interface=org.kde.KNotify; member=notificationClosed
   int32 21
Comment 7 Valentin Rusu 2015-07-30 08:45:12 UTC
Oh, somewhat it stopped working on my system also. Something must have changed in the manner these settings should be handled. I'll fix it right away.
Comment 8 g11120889 2015-09-23 11:54:50 UTC
It would be nice if the error message would state that you have to be root to change settings.