Skip to content

Commit

Permalink
Fix double login authentication (#628)
Browse files Browse the repository at this point in the history
Co-authored-by: Danielle Foré <danielle@elementary.io>
  • Loading branch information
meisenzahl and danirabbit committed Nov 25, 2022
1 parent a4e8f6f commit 1eceae3
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 0 deletions.
21 changes: 21 additions & 0 deletions data/io.elementary.greeter.policy.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE policyconfig PUBLIC
"-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
"http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">
<policyconfig>
<vendor>elementary</vendor>
<vendor_url>https://elementary.io/</vendor_url>

<action id="io.elementary.greeter.restart">
<description>Restart the Login &amp; Lock screen</description>
<message>Permission is needed to restart the Login &amp; Lock Screen</message>
<icon_name>preferences-system</icon_name>
<defaults>
<allow_any>auth_admin</allow_any>
<allow_inactive>auth_admin</allow_inactive>
<allow_active>yes</allow_active>
</defaults>
<annotate key="org.freedesktop.policykit.imply">org.freedesktop.systemd1.manage-units</annotate>
</action>

</policyconfig>
8 changes: 8 additions & 0 deletions data/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,14 @@ i18n.merge_file(
install_dir: join_paths(get_option('datadir'), 'metainfo'),
)

i18n.merge_file(
input: 'io.elementary.greeter.policy.in',
output: 'io.elementary.greeter.policy',
po_dir: join_paths(meson.source_root (), 'po', 'extra'),
install_dir: join_paths(get_option('datadir'), 'polkit-1', 'actions'),
install: true
)

install_data(
meson.project_name() + '.conf',
install_dir: join_paths(get_option('sysconfdir'), 'lightdm')
Expand Down

0 comments on commit 1eceae3

Please sign in to comment.