29 lines
1.1 KiB
Text
29 lines
1.1 KiB
Text
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
|
//
|
|
// DO NOT EDIT THIS FILE, it will be overwritten on update.
|
|
//
|
|
// Allow the gnome-initial-setup user to do certain actions without
|
|
// being interrupted by password dialogs
|
|
|
|
polkit.addRule(function(action, subject) {
|
|
if (subject.user !== 'gnome-initial-setup')
|
|
return undefined;
|
|
|
|
var actionMatches = (action.id.indexOf('org.freedesktop.hostname1.') === 0 ||
|
|
action.id.indexOf('org.freedesktop.NetworkManager.') === 0 ||
|
|
action.id.indexOf('org.freedesktop.locale1.') === 0 ||
|
|
action.id.indexOf('org.freedesktop.accounts.') === 0 ||
|
|
action.id.indexOf('org.freedesktop.timedate1.') === 0 ||
|
|
action.id.indexOf('org.freedesktop.realmd.') === 0 ||
|
|
action.id.indexOf('com.endlessm.ParentalControls.') === 0 ||
|
|
action.id.indexOf('org.fedoraproject.thirdparty.') === 0);
|
|
|
|
if (actionMatches) {
|
|
if (subject.local)
|
|
return 'yes';
|
|
else
|
|
return 'auth_admin';
|
|
}
|
|
|
|
return undefined;
|
|
});
|