Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 67680 - usbfs: scanners have wrong group (should be scanner, not root)
Summary: usbfs: scanners have wrong group (should be scanner, not root)
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High major (vote)
Assignee: Greg Kroah-Hartman (RETIRED)
Depends on:
Reported: 2004-10-15 09:58 UTC by Jure Repinc
Modified: 2008-12-06 09:30 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Note You need to log in before you can comment on or make changes to this bug.
Description Jure Repinc 2004-10-15 09:58:15 UTC
I can't use my USB scanner as normal user. I can only use it as root. I found out that there is a group created on my system named scanner, which I suppose is for users that are allowed to scan. I added myself to that group but I still couldn't scan. Then I checked out the permissions on scanner device and it was set to user root an group root. I guess the group should be scanner.

Reproducible: Always
Steps to Reproduce:
1. Run Kooka as root
2. Scanner is detected and works just fine
3. Run Kooka as normal user, which is in scanner group

Actual Results:  
Scanner is not detected and you can't scan.

Expected Results:  
Scanner should be available to all users in scanner group

I also noticed that scanner is set to group root everytime I restart my
computer. If I unplug the scanner and then plug it back the scanner has group
set to scanner. I also noticed that in
/etc/udev/permissions.d/50-udev.permissions there is:

# scanner devices

Shouldn't this be:

# scanner devices
Comment 1 Jure Repinc 2004-10-15 10:09:30 UTC
I also noticed that hotplug script /etc/hotplug/usb/libusbscanner sets permissions to 0660 but udev sets them to 0600. I'm not sure which one is more correct but I gues that would be 0660.
Comment 2 Greg Kroah-Hartman (RETIRED) gentoo-dev 2004-10-15 14:16:34 UTC
There is no 2.6 kernel scanner driver.  So I don't see how udev has anything to do with
Comment 3 Jure Repinc 2004-10-15 14:55:38 UTC
Then where do the group and user an permission for scanner get set. Because they are always automatically set wrong. It still has to be a problem somwhere. If not udev then it is something else.
Comment 4 Greg Kroah-Hartman (RETIRED) gentoo-dev 2004-10-15 15:35:24 UTC
usbfs is in control of that, not udev.
Comment 5 Greg Kroah-Hartman (RETIRED) gentoo-dev 2004-10-15 15:36:26 UTC
To clarify, it's a mount option for usbfs as to what to set the 
ownership of the usb file descriptors to.  See the documentation somewhere (sorry,
can't remember where right now) for details on how to set this up for your
Comment 6 Jure Repinc 2004-10-15 23:41:10 UTC
So this bug is still valid. Only the problem is the default settings for usbfs instead of udev. I'll change the summary.
Comment 7 Greg Kroah-Hartman (RETIRED) gentoo-dev 2004-10-18 09:54:45 UTC
No, it's up to you to change the default setting of usbfs in your /etc/fstab file.

There is no gentoo package that can do this for you, sorry.
Comment 8 Navid Zamani 2008-12-03 16:50:57 UTC

I have a working usbfs and I never had a line about usbfs in the fstab. So what are you talking about??

First get your facts straight. Where is the place to configure the usbfs mount options? Because it clearly is *not* inside fstab.
Comment 9 Greg Kroah-Hartman (RETIRED) gentoo-dev 2008-12-06 02:59:46 UTC
Then add such an entry, it's not hard :)

If you don't have an entry for it in your fstab, I don't know what is mounting
it for you, perhaps /etc/init.d/procfs?  
Comment 10 Navid Zamani 2008-12-06 09:30:05 UTC
Hey, (In reply to comment #9)
> perhaps /etc/init.d/procfs? 

Yes, it is. i looked inside.

> Then add such an entry, it's not hard :)

The problem is, that then I would have two mount commands trying to mount it, won't there? To me, this sounds like a very bad idea. The proper solution would be, if /etc/init.d/procfs had a /etc/conf.d/procfs, to set this. Unfortunately it hasn't. Maybe it would be a good idea to add one. What do you think?

(Oh, and I notice that this is very much off-topic for the bug now. Should we create a new bug?)