This is a discussion on Accessing serial port information in privilege restricted directory within the Linux Security forums, part of the System Security and Security Related category; Hi, I am writing an application that needs to access information stored in files /proc/tty/device/*, but the directory /...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Hi,
I am writing an application that needs to access information stored in files /proc/tty/device/*, but the directory /proc/tty/device only allows root access. The directory contains files that indicate the serial ports available for use on the system, both traditional and USB adapter types. Has anyone got an idea why the /proc/tty/device directory is restricted to root? Basically, I'm trying to work out what the best approach to take with my application, which runs with user privileges. Thanks, Paul. -- Remove _rem_ before replying by email. |
|
|||
|
On Mon, 04 Jul 2005 18:54:40 +0100, Paul Taylor wrote:
> Hi, > > I am writing an application that needs to access information stored in > files /proc/tty/device/*, but the directory /proc/tty/device only > allows root access. The directory contains files that indicate the serial > ports available for use on the system, both traditional and USB adapter > types. > > Has anyone got an idea why the /proc/tty/device directory is restricted > to root? Basically, I'm trying to work out what the best approach to take > with my application, which runs with user privileges. > I guess the directory is restricted for similar reasons that the ttySx and ttyUSBx device nodes are restricted. If an application needs to use a serial port then the sysadmin needs to make changes to allow serial port access. I guess the sysadmin would need to make changes in the same vein to allow a user program to access the files indicating which ports are available for use. -- Remove _rem_ before replying by email. |