Results 1 to 2 of 2

Thread: Policykit and permission for user to mount

  1. #1

    Default Policykit and permission for user to mount

    Hello, how should I set a policy that user can use command mount?

    I guess the rules should be set in etc/polkit-default-privs.local.

    I have tried to put:

    Code:
    [Password-less mounting of local partitions]
    Identity=unix-users:*
    Action=org.freedesktop.udisks2.filesystem-mount-system
    ResultAny=yes
    ResultInactive=yes
    ResultActive=yes
    But no effect.

    Thank you.

    Martin

  2. #2
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    23,711
    Blog Entries
    1

    Default Re: Policykit and permission for user to mount

    Quote Originally Posted by atilius View Post
    Hello, how should I set a policy that user can use command mount?

    I guess the rules should be set in etc/polkit-default-privs.local.

    I have tried to put:

    Code:
    [Password-less mounting of local partitions]
    Identity=unix-users:*
    Action=org.freedesktop.udisks2.filesystem-mount-system
    ResultAny=yes
    ResultInactive=yes
    ResultActive=yes
    But no effect.

    Thank you.

    Martin
    You need to edit /etc/polkit-default-privs.local with the following format
    Code:
    # Format:
    # <privilege> <any>:<inactive>:<active>
    #
    org.freedesktop.udisks2.filesystem-mount-system auh_admin:auth_admin:yes
    or if you really want to relax the restrictions (it is your system)
    Code:
    org.freedesktop.udisks2.filesystem-mount-system yes:yes:ye
    then run
    Code:
    set_polkit_default_privs
    * Note that polkit is used for graphical environments. The mount command does not use this framework.

Posting Permissions

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