Page 2 of 2 FirstFirst 12
Results 11 to 15 of 15

Thread: How do I kick hal in the backside?

  1. #11
    Join Date
    Jun 2008
    Location
    Kln, Deutschland
    Posts
    1,054

    Default Re: How do I kick hal in the backside?

    Hello FM

    Looks like my user is only allowed to dial out!

    Code:
    polkit-auth --user fred --show-obtainable
    org.opensuse.smpppd.connect
    I tried that command (while under su) as simply polkit-auth --user fred and got nothing in return!
    HP dv6645, Nvidia 8400m-gs, KDE 4.

  2. #12
    Join Date
    Jun 2008
    Location
    Kln, Deutschland
    Posts
    1,054

    Default Re: How do I kick hal in the backside?

    WOOHOO!!!! Sussed it

    I did a search through Yast2 -> Software for any occurrences of the word policy.

    That threw out the PolicyKit package (among other things). Closer examination of the package's file list gave me a clue, it contains the file - /etc/PolicyKit/PolicyKit.conf.

    I edited that file, and the default content (on my server) is only -

    Code:
    <?xml version="1.0" encoding="UTF-8"?> <!-- -*- XML -*- -->
    
    <!DOCTYPE pkconfig PUBLIC "-//freedesktop//DTD PolicyKit Configuration 1.0//EN"
    "http://hal.freedesktop.org/releases/PolicyKit/1.0/config.dtd">
    
    <!-- See the manual page PolicyKit.conf(5) for file format -->
    
    <config version="0.1">
    </config>
    On reading that file, it says to consult the manual, and running man policykit.conf gave me some very useful info and ideas.

    So I edited /etc/PolicyKit/PolicyKit.conf and added the following with my required username (in this example - fred) -

    Code:
    <?xml version="1.0" encoding="UTF-8"?> <!-- -*- XML -*- -->
    
    <!DOCTYPE pkconfig PUBLIC "-//freedesktop//DTD PolicyKit Configuration 1.0//EN"
    "http://hal.freedesktop.org/releases/PolicyKit/1.0/config.dtd">
    
    <!-- See the manual page PolicyKit.conf(5) for file format -->
    
    <config version="0.1">
    
      <match action="org.freedesktop.hal.storage.mount-fixed">
       <match user="fred">
        <return result="yes"/>
       </match>
      </match>
    
      <match action="org.freedesktop.hal.storage.mount-removable">
       <match user="fred">
        <return result="yes"/>
       </match>
      </match>
    
    </config>
    ...saved, restarted hal with /etc/init.d/haldaemon restart and hey presto, as if by magic - it WORKED!

    I can now mount my USB stick's FAT partitions simply by clicking on them through dolphin. This also works when I run dolphin remotely through an ssh connection.

    My USB hard drive (containing the LUKS partition) still gives me the same error message (when trying to mount it through a remote dolphin, NOT a local one), but I assume that adding another section to /etc/PolicyKit/PolicyKit.conf especially for encrypted volumes will yield the same (fixed) result. I'll try that next .

    This is exactly what I wanted, the root source of overriding HAL's default settings! I can feel the beardos starting to froth at the mouth already for my blasphemy .

    .
    HP dv6645, Nvidia 8400m-gs, KDE 4.

  3. #13

    Default Re: How do I kick hal in the backside?

    Glad you sussed it, I have this way in one distro for shutdown and suspend and use polkit-auth on Suse.

    So both seem to achieve the same.

    I suspect now they'll show up for the user strange you couldn't run it as user but I suspect it is an overzealous default.

    I suspect your other rules will be based around
    org.freedesktop.hal.storage.crypto-setup-fixed
    org.freedesktop.hal.storage.crypto-setup-removable
    Man first, have a try at Info, have a look at Wiki, if all that fails Scroogle!!!!!
    If I've helped click on the Rep button I don't know what it does but it sounds cool.

  4. #14
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    20,840
    Blog Entries
    1

    Default Re: How do I kick hal in the backside?

    Nice to see the progress @growbag. That was one of the suggestions outlined in the link I gave you and quoted in post post #7. Although strangely, it did not appear to work for the OP in that situation. I have played with the polkit-auth commands a few times, vut they don't seem to have any affect on my system, hence I didn't bother mentioning them to you either.

  5. #15
    Join Date
    Jun 2008
    Location
    Kln, Deutschland
    Posts
    1,054

    Default Re: How do I kick hal in the backside?

    Quote Originally Posted by deano_ferrari View Post
    Nice to see the progress @growbag. That was one of the suggestions outlined in the link I gave you and quoted in post post #7......
    lol, I must have skipped right over that one! The page format was a bit odd (for me) and I got lost somewhere in the responses! .

    It did work exactly the same when I added entries for the encrypted filesystems too.

    Thanks for all the help lads .
    HP dv6645, Nvidia 8400m-gs, KDE 4.

Page 2 of 2 FirstFirst 12

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •