You are not logged in.
Pages: 1
Greetings Community,
I would like to know how I can grant some application access to a certain device? I just received my MX Master 3 and connected it via Bluetooth to my PC which so far works well. Now I also installed logid which delivers device support features. When I now start logid it puts out the warning "Failed to open /dev/hidraw0: open: Permission denied" which is my bluetooth device.
My problem is, that I don't know how I grant access to the device and what exactly is the one I address with the access? I know there are users and groups and for myself I am able to grant at least access to files and change permissions of them. But granting an application access to something and addressing the application correctly is something I am not aware of.
Offline
The program runs as your user:group, so you just need for your user to have the appropriate permissions for the device.
Ideally this is done by adding yourself to the appropriate group: what is the default permission/ownership of /dev/hidraw0?
If this is not an option, you can use a udev rule to change the permissions/ownership of /dev/hidraw0 appropriately.
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
Hi Trilby,
Ideally this is done by adding yourself to the appropriate group: what is the default permission/ownership of /dev/hidraw0?
Is there a way to determine this? Is it put into some group by default?
Offline
stat /dev/hidraw0
Offline
Thank you.
the output:
File: /dev/hidraw0
Size: 0 Blocks: 0 IO Block: 4096 character special file
Device: 6h/6d Inode: 1400115 Links: 1 Device type: ed,0
Access: (0600/crw-------) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2020-05-14 18:50:49.542881834 +0200
Modify: 2020-05-14 18:50:49.542881834 +0200
Change: 2020-05-14 18:50:49.542881834 +0200
Birth: -
Seems not to contain a group which probably means it is in no group yet.
So I most likely have to go with the udev rule. Where should I place such a rule and how will it look like?
I will try to follow this guide: https://www.thegeekdiary.com/beginners- … -in-linux/ but maybe you can help me with that too?
Offline
No. It belongs to user and group "root". You *don't* want to add your regular user to the root group, so yes: you want to alter the file permissions through a udev rule.
And no, you will follow this guide: https://wiki.archlinux.org/index.php/Udev
If you've questions regarding any step, feel free to ask back.
Offline
Pages: 1