Bug 389415 - PolicyKit-kde does not work with PackageKit
Summary: PolicyKit-kde does not work with PackageKit
Status: RESOLVED FIXED
: 396370 402504 (view as bug list)
Alias: None
Product: openSUSE 11.1
Classification: openSUSE
Component: KDE4 Workspace (show other bugs)
Version: Factory
Hardware: Other Other
: P1 - Urgent : Blocker (vote)
Target Milestone: ---
Assignee: Lubos Lunak
QA Contact: E-mail List
URL:
Whiteboard: packagekit_devel gnome-update
Keywords:
Depends on:
Blocks:
 
Reported: 2008-05-12 16:55 UTC by Stephan Binner
Modified: 2008-11-03 15:52 UTC (History)
5 users (show)

See Also:
Found By: Development
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---
coolo: SHIP_STOPPER-


Attachments
prompt for auth (171.53 KB, image/jpeg)
2008-10-02 04:45 UTC, Scott Reeves
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stephan Binner 2008-05-12 16:55:51 UTC
eg "pkcon install foo" doesn't seem to detect it as available AuthentificationAgent.
Comment 1 JP Rosevear 2008-05-14 00:39:59 UTC
Does this work with polkit-gnome-example (it does for me)?  I think actually its a bug in PackageKit because I see:

#define POLKIT_DBUS_SERVICE             "org.gnome.PolicyKit"
#define POLKIT_DBUS_PATH                "/org/gnome/PolicyKit/Manager"
#define POLKIT_DBUS_INTERFACE           "org.gnome.PolicyKit.Manager"

in pk-polkit-client.c

I think it can request the dbus interface more generically.
Comment 2 Scott Reeves 2008-05-23 04:37:59 UTC
I talked with Richard (PackageKit maintainer) about this and he agrees he should probably not be using PolicyKit-gnome in libpackagekit. He is talking with DavidZ about how to go forward with this...
Comment 3 Stephan Kulow 2008-05-26 14:53:46 UTC
now that we got the final "no PackageKit under KDE" decision, it's also no longer a blocker. I hoper we can get this fixed anyway
Comment 4 Martin Vidner 2008-06-04 08:17:48 UTC
FWIW, on my KDE3 system, o.f.DBus.ListActivatableNames includes "org.freedesktop.PolicyKit" (freedesktop instead of gnome):

http://hal.freedesktop.org/docs/PolicyKit-gnome/ref-auth-daemon.html
Comment 5 Scott Reeves 2008-06-06 20:53:46 UTC
This is now fixed in git master. Since this is no longer a blocker I assume we wait until after 11.0 is final before we update to this fix.
Comment 6 Martin Vidner 2008-06-09 07:05:52 UTC
*** Bug 396370 has been marked as a duplicate of this bug. ***
Comment 7 Dirk Mueller 2008-06-09 08:34:02 UTC
as long as it will be available as an online update, I guess thats okay
Comment 8 Scott Reeves 2008-07-02 17:21:58 UTC
*** Bug 402504 has been marked as a duplicate of this bug. ***
Comment 9 Scott Reeves 2008-08-12 20:31:12 UTC
This is now available in the online update repo. http://download.opensuse.org/update/11.0/
Comment 10 Forgotten User L03nYQvXe7 2008-08-14 18:33:57 UTC
Sorry to say this, but I have downloaded the updates, reboot and get  the same error after I try to update with packagekit:

"DBus error : org.freedesktop.PackageKit.Transaction.RefusedByPolicy : org.freedesktop.packagekit.update-package auth_admin_keep_always"

Comment 11 JP Rosevear 2008-09-24 20:26:37 UTC
Was PolicyKit-kde installed?
Comment 12 Forgotten User L03nYQvXe7 2008-09-25 06:46:48 UTC
I have it installed. I have downloaded the update from the repo, reboot but nothing has changed, I get the same error as before.

Comment 13 Forgotten User L03nYQvXe7 2008-09-25 06:47:24 UTC
I have it installed. I have downloaded the update from the repo, reboot but nothing has changed, I get the same error as before.

Comment 14 Scott Reeves 2008-10-02 04:45:57 UTC
Created attachment 242975 [details]
prompt for auth

Dirk - I tried this on 11.0 + updates and 11.1 Beta1 KDE 4.x installs and see the same behavior.  PackageKit now seems to generically request an AuthenticationAgent but it never returns successfully.

Running "pkcon -v install lynx" we call
   ret = polkit_auth_obtain (action_id, 0, getpid (), &error2);

We get a popup from the AuthenticationAgent (see attachment) asking to authenticate but regardless of what I type for the password it always returns false.
Comment 15 Thomas Göttlicher 2008-10-23 13:29:34 UTC
> We get a popup from the AuthenticationAgent (see attachment) asking to
> authenticate but regardless of what I type for the password it always returns
> false. 
Same problem on beta3 with kde4 and kupdateapplet. Is there any progress on this?
Comment 17 JP Rosevear 2008-10-23 16:00:36 UTC
Analysis has this looking like a PolicyKit-kde problem.
Comment 18 Lubos Lunak 2008-10-27 09:52:30 UTC
JPR: Please add this to your list of risks, if other parts depend on this. This is not a bugfix, this is a missing feature. PolicyKit-kde lacks a significant portion of code from PolicyKit-gnome (and it's a lot of code, for just showing a single dialog :-/ ).
Comment 19 JP Rosevear 2008-10-27 13:58:51 UTC
Ok, in the mean time PolicyKit-gnome could be installed to test the rest of the procedure.
Comment 20 Lubos Lunak 2008-10-29 20:09:31 UTC
I have submitted a version of PolicyKit-kde that can successfully authorize 'pkcon install foo'. I have some problems testing with kupdateapplet though and I'm not yet sure whose fault it is.
Comment 21 Thomas Göttlicher 2008-10-30 11:30:29 UTC
(In reply to comment #20 from Lubos Lunak)
> I have submitted a version of PolicyKit-kde that can successfully authorize
> 'pkcon install foo'.
Do you have packages for 11.0 or Factory of this PolicyKit-kde version?

> I have some problems testing with kupdateapplet though and
> I'm not yet sure whose fault it is.
Perhaps kupdateapplet does it in the wrong way. I have a bug report about a kupdatepplet crash when it tries to authorize via "PolicyKit-kde mechanism" (see: bug 439473).
Comment 22 Thomas Göttlicher 2008-10-30 14:56:01 UTC
I've compiled PolicyKit-kde-0.2 and improved kupdateapplet and it works on my machine now.
kde4-kupdateapplet version 0.8.16 will contain these improvements.
Comment 23 Lubos Lunak 2008-10-31 13:19:28 UTC
With kupdateapplet 0.8.17 it still does some things I consider strange (like with two consecutive updates the second one does not ask for password even though no password keeping was configured), but as far as I can say it works now the same with both the GNOME and KDE PolicyKit variants, so I consider this one fixed.
Comment 24 Thomas Göttlicher 2008-10-31 13:47:17 UTC
(In reply to comment #23 from Lubos Lunak)
> With kupdateapplet 0.8.17 it still does some things I consider strange (like
> with two consecutive updates the second one does not ask for password even
> though no password keeping was configured), but as far as I can say it works
> now the same with both the GNOME and KDE PolicyKit variants, so I consider this
> one fixed.
kupdateapplet asks PolicyKit for every update for permission. I guess it's deep in PackageKit or PolicyKit when gnome- and kde-policykit behaves similar.
Comment 25 Lubos Lunak 2008-11-03 15:52:24 UTC
PolicyKit-kde should be now hopefully good enough.