WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: TC 7.2 - /dev/input devices are in group root  (Read 890 times)

Offline bernhard

  • Jr. Member
  • **
  • Posts: 50
TC 7.2 - /dev/input devices are in group root
« on: October 26, 2016, 06:58:58 AM »
is this a deliberate feature or more a bug that /dev/Input/Event[0-4], /dev/input/mouse0 and /dev/input/mice are in in group root so only the super user can read from them or shouldn't they be in group staff.

Background: I have a framebuffer application, which needs to read from /dev/input/event4
and I can start it either as root or after I've done a chown :staff /dev/input/event4

regards
--
  Bernhard

Offline bernhard

  • Jr. Member
  • **
  • Posts: 50
Re: TC 7.2 - /dev/input devices are in group root
« Reply #1 on: October 26, 2016, 07:48:34 AM »
it should have been /dev/input/event[0-4] instead of  /dev/Input/Event[0-4] (I have no idea how to switch off auto-capitalization).

Offline patrikg

  • Full Member
  • ***
  • Posts: 234
Re: TC 7.2 - /dev/input devices are in group root
« Reply #2 on: October 26, 2016, 12:43:25 PM »
Have you tried to make a work around like symbol link ?

Offline bernhard

  • Jr. Member
  • **
  • Posts: 50
Re: TC 7.2 - /dev/input devices are in group root
« Reply #3 on: October 27, 2016, 12:35:34 AM »
no, but since /dev/fb0 has also root/staff as owner/group membership, I think the same would be preferable for the devices in /dev/input ...

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 9386
Re: TC 7.2 - /dev/input devices are in group root
« Reply #4 on: October 27, 2016, 01:39:11 AM »
I believe those are common Linux defaults, preventing users from reading each other's input. So a chown in bootsync.sh should be fine for your application.
The only barriers that can stop you are the ones you create yourself.

Offline bernhard

  • Jr. Member
  • **
  • Posts: 50
Re: TC 7.2 - /dev/input devices are in group root
« Reply #5 on: October 29, 2016, 02:28:11 AM »
thanks

Offline bernhard

  • Jr. Member
  • **
  • Posts: 50
Re: TC 7.2 - /dev/input devices are in group root
« Reply #6 on: October 31, 2016, 08:09:27 AM »
just a remark:
Raspbian puts these devices in a group named input and the default user pi ia member of that group. This looks to me very reasonable.