Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
udisksctl not working without root auth
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2  
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
cloc3
Advocate
Advocate


Joined: 13 Jan 2004
Posts: 4657
Location: http://www.gentoo-users.org/user/cloc3/

PostPosted: Tue Jan 07, 2014 2:28 am    Post subject: Reply with quote

VoidMage wrote:
:sigh: 'udisksctl dump' != 'udisksctl monitor'

ops.
all pastebin in last post was taken with the custom rule commented.
anyway:
dell ~ # udisksctl dump|pastebinit
http://pastebin.com/raw.php?i=4EdbFhMU
dell ~ # udevadm info --export-db |pastebinit
http://pastebin.com/raw.php?i=5CqTAf2b
_________________
vu vu vu
gentù
mi piaci tu
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6193

PostPosted: Tue Jan 07, 2014 5:00 pm    Post subject: Reply with quote

I'm baffled.
To recap:
- by ck-list-sessions, your session is registered and active
- by pkaction, org.freedesktop.udisks2.filesystem-mount is at its default policy (implicit_active: yes)
- yet for some reason, the action is invoked as if the session wasn't active

...

OK, I think the final idea: if polkit is built with systemd useflag, rebuild without it, logout, retry.
Back to top
View user's profile Send private message
ppurka
Advocate
Advocate


Joined: 26 Dec 2004
Posts: 3256

PostPosted: Tue Jan 07, 2014 5:07 pm    Post subject: Reply with quote

I have been through all this before. Try to look at ssuominen advice in this thread:
https://forums.gentoo.org/viewtopic-t-922708-highlight-pkexec.html
_________________
emerge --quiet redefined | E17 vids: I, II | Now using kde5 | e is unstable :-/
Back to top
View user's profile Send private message
cloc3
Advocate
Advocate


Joined: 13 Jan 2004
Posts: 4657
Location: http://www.gentoo-users.org/user/cloc3/

PostPosted: Wed Jan 08, 2014 9:02 pm    Post subject: Reply with quote

ppurka wrote:
I have been through all this before. Try to look at ssuominen advice in this thread:
https://forums.gentoo.org/viewtopic-t-922708-highlight-pkexec.html

enjoy, for not being alone in my trouble anymore. :wink:

anyway, I don't understand if ppurka found a solution to its problem.
in the last topic, ssuominen suggest to try thi link:
https://wiki.archlinux.org/index.php/PolicyKit#Workaround_to_mount_filesytems_by_user_in_group_storage_without_password

but the anchor linked seems no more existent in this location.
on the botton of the archilinux howto, I find this script:
Code:

#/etc/polkit-1/rules.d/10-enable-mount.rules

polkit.addRule(function(action, subject) {
    if (action.id == "org.freedesktop.udisks2.filesystem-mount-system" && subject.isInGroup("storage")) {
        return polkit.Result.YES;
    }
});

it's similar to the previuos polkit rule I try above, and it doesn't work in same way.

I cannot think my problem has no easy solution.
:?
_________________
vu vu vu
gentù
mi piaci tu
Back to top
View user's profile Send private message
cloc3
Advocate
Advocate


Joined: 13 Jan 2004
Posts: 4657
Location: http://www.gentoo-users.org/user/cloc3/

PostPosted: Wed Jan 08, 2014 9:27 pm    Post subject: Reply with quote

update:

I had a success changing directly /usr/share/polkit-1/actions/org.freedesktop.udisks2.policy in such way:
Code:

dell rules.d # diff -u /usr/share/polkit-1/actions/org.freedesktop.udisks2.policy.orig /usr/share/polkit-1/actions/org.freedesktop.udisks2.policy
--- /usr/share/polkit-1/actions/org.freedesktop.udisks2.policy.orig     2014-01-08 22:15:28.578914130 +0100
+++ /usr/share/polkit-1/actions/org.freedesktop.udisks2.policy  2014-01-08 22:16:40.823912551 +0100
@@ -18,7 +18,7 @@
     <message xml:lang="en_GB">Authentication is required to mount the filesystem</message>
     <message xml:lang="it">È richiesto autenticarsi per montare il file system</message>
     <defaults>
-      <allow_any>auth_admin</allow_any>
+      <allow_any>yes</allow_any>
       <allow_inactive>auth_admin</allow_inactive>
       <allow_active>yes</allow_active>
     </defaults>

I think this is not a good solution, because this means that default actions are too much restrictive and because I've not found a way to override default actions using /etc/ configurations.
_________________
vu vu vu
gentù
mi piaci tu
Back to top
View user's profile Send private message
ppurka
Advocate
Advocate


Joined: 26 Dec 2004
Posts: 3256

PostPosted: Thu Jan 09, 2014 1:58 am    Post subject: Reply with quote

cloc3 wrote:
update:

I had a success changing directly /usr/share/polkit-1/actions/org.freedesktop.udisks2.policy in such way:
Welcome to the mess called polkit. I never found the solution to my issue. I have been immensely satisfied after moving to udevil.

To make sure your change sticks around across system updates, add that polkit file to the CONFIG_PROTECT in make.conf.
_________________
emerge --quiet redefined | E17 vids: I, II | Now using kde5 | e is unstable :-/
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6193

PostPosted: Thu Jan 09, 2014 9:32 am    Post subject: Reply with quote

Did you at least check my final note ?
Cause going by configure.ac, systemd and consolekit are either/or for polkit, so if you built it with systemd, it would explain why is it not working.
Back to top
View user's profile Send private message
cloc3
Advocate
Advocate


Joined: 13 Jan 2004
Posts: 4657
Location: http://www.gentoo-users.org/user/cloc3/

PostPosted: Thu Jan 09, 2014 12:30 pm    Post subject: Reply with quote

VoidMage wrote:
Did you at least check my final note ?
Cause going by configure.ac, systemd and consolekit are either/or for polkit, so if you built it with systemd, it would explain why is it not working.

may it be, but this can't be acceptable.
If I want switch booting from openrc to systemd, I need to recompile polkit and kdm?

that makes no sense for me.
(and seems out from man polkit documentation).
is really so difficult to make some kind of wrapper to solve this issue?

@ppurka. sorry if I've not understand all your hints (I understand a bit of english, but I also hate it as any proprietary language :)).

are you able or not to completly substitute udisks with udevil in kde?
my guess is that's not possible.
_________________
vu vu vu
gentù
mi piaci tu
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6193

PostPosted: Thu Jan 09, 2014 1:32 pm    Post subject: Reply with quote

cloc3 wrote:
VoidMage wrote:
Did you at least check my final note ?
Cause going by configure.ac, systemd and consolekit are either/or for polkit, so if you built it with systemd, it would explain why is it not working.

may it be, but this can't be acceptable..


It's a case of "sucks to be you", then. :roll:

While I have my own set of dislikes about systemd approach, the bottom line is that it was written as a replacement, not something you could just install for optional use.
I'd say it's good enough that polkit upstream still preserves the consolekit path of code, instead doing what Gnome did.
Back to top
View user's profile Send private message
ppurka
Advocate
Advocate


Joined: 26 Dec 2004
Posts: 3256

PostPosted: Thu Jan 09, 2014 2:28 pm    Post subject: Reply with quote

cloc3 wrote:
@ppurka. sorry if I've not understand all your hints (I understand a bit of english, but I also hate it as any proprietary language :)).
that's ok. :-)
Quote:

are you able or not to completly substitute udisks with udevil in kde?
my guess is that's not possible.
no. It is not possible to substitute udisks with udevil in kde. Currently, I would say that the best thing for you is to keep that modification in the polkit file in /usr and add that file to CONFIG_PROTECT in make.conf. That way, both kde and command line will work.

I didn't remember about my own post (more than 2 years old!) until you started describing your symptoms in detail. For me the only thing that actually worked was that ugly modification in /usr. I used that workaround until some kind soul wrote udevil! :-)
_________________
emerge --quiet redefined | E17 vids: I, II | Now using kde5 | e is unstable :-/
Back to top
View user's profile Send private message
cloc3
Advocate
Advocate


Joined: 13 Jan 2004
Posts: 4657
Location: http://www.gentoo-users.org/user/cloc3/

PostPosted: Thu Jan 09, 2014 4:43 pm    Post subject: Reply with quote

ok.
I've understood my problem (not solved).

thank's a lot to all you guys.
I've learnt a lot of things from you.
:)
_________________
vu vu vu
gentù
mi piaci tu
Back to top
View user's profile Send private message
mhogomchungu
n00b
n00b


Joined: 18 May 2013
Posts: 19

PostPosted: Sun Jan 26, 2014 3:24 am    Post subject: Reply with quote

To the original poster,
it should be possible for you to mount your dvds from CLI or GUI without using polkit or udisks or entering root's password by using zuluMount from http://code.google.com/p/zulucrypt/

ps:

I am the person who founded and currently maintains the project
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum