Score:0

Disallow/remove shutdown/restart options on Xfce4

us flag

I am using a RHEL8 server system as jumphost - connection to it from the windows-world with tls 1.2/rdp and then Xcfe4 as X11 base for applications in need of X-windows.

My questions are about the poweroff-button on the upper right corner of Xfce4.

  1. How to I inhibt users from powering off / reboot when there is only one logged in user?
  2. How do I replace that button with a logout-button?

xfce is version 4.16, polkit is version 0.115

With CentOS/RHEL7 this was no problem - you just had to create a kioskrc: /etc/xdg/xfce/kiosk/kioskrc:

[xfce4-session]
Shutdown=root

I assume that 1. has to do with polkit (some findings from 2012 go into that direction), so I included its version.

us flag
#1 is solved via polkit.
Score:0
us flag

The solution for question #1 is via polkit:

/usr/share/polkit-1/actions/ set all items corresponding to hybernate/shutdown/reboot to "no" in these two files:

  • org.xfce.power.policy
  • org.freedesktop.login1.policy
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.