1

I want to play a video in a way that the only way to close it is shutting down the computer forcefully. Meaning: I'd like it so that interacting with the video playing is impossible.

Is that even possible? If so, how should I do it? I've been thinking of making the video play when it's shutting off, that way, you shouldn't be able to close it. However, I do not know the dependencies needed for a video player to work and, as such, it would be difficult to set up. Is there a better solution than this?

ulovah
  • 119

2 Answers2

3

There is no way to do that except to:

  1. Build an Ubuntu Kiosk PC that is physically completely locked down inside steel casing.
  2. Ensure it has no keyboard and mouse
  3. Ensure it has wireless power, so it cannot be unplugged
  4. the video is the only thing running full-screen in an endless loop.

Now that i think of it, even that won't do the trick, as the most simple of tools will still be able to turn off the screen! ;-)

Fabby
  • 34,259
  • 1
    Don't take the question too literally, Fabby ;-) Kiosk mode should do. – Jos Jul 22 '17 at 10:45
  • 1
    Yeah, but an answer involving an axe is always better and if the OP stops at #1, he'll be fine! – Fabby Jul 22 '17 at 11:33
  • Well, It's not exactly what I am looking for, however, it is true that to completely (or almost completely) disable interaction you would probably need this :P – ulovah Jul 22 '17 at 15:57
  • @ulovah: bullet-proof glass would protect you from an axe, but not from a Kalashnikov... Just depends how secure you want to make it. ;-) :D Just building a Kiosk PC will be good enough to protect you for 99.99% of all users. (just not me and a few other people here, is all) – Fabby Jul 22 '17 at 20:25
2

If you use a laptop with a battery, you can disable both the touchpad and the keyboard:

disable the keyboard and TouchPad.

you can use the xinput command to list and disable all input devices.

to list your input devices, use xinput list.

xinput output

then notice the line that says ↳ AT Translated Set 2 keyboard, the id=?? here next to this is the id of your keyboard input device in xinput. you will use this to disable and enable your keyboard and also your TouchPad.

in my case, my keyboard has the id 10 and my TouchPad 11.

so to disable my keyboard and touchpad respectively:

xinput float 10
xinput float 11

to restore functionality you also need the master pointer i.e. the number right next to the string slave pointer (?) on the line of the particular input device you wish to disable. Here notice that to reattach my keyboard, I need another keyboard because I have alread disabled the builtin keyboard. Maybe a USB keyboard. so to reattach your keyboard and mouse:

xinput reattach 10 3
xinput reattach 11 2

Moreover, you can even disable the power button by using the same method, so the only way to stop the playback is to:

  • cut the power and take the battery out of the laptop.
  • press and hold the power button for more then 3 seconds as this behaviour cannot be changed by software)
Fabby
  • 34,259
endrias
  • 597