Results 1 to 6 of 6
Hi all,
Can any one give me examples of user processes that are given direct access to I/O ports ?
The only example which I know is X-server ,is there ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 10-01-2010 #1Just Joined!
- Join Date
- Sep 2010
- Posts
- 6
user processes given direct access to I/O ports
Hi all,
Can any one give me examples of user processes that are given direct access to I/O ports ?
The only example which I know is X-server ,is there any other process ?
- 10-01-2010 #2Just Joined!
- Join Date
- Sep 2010
- Posts
- 2
nagios configuration
hai,
can any one help me about nagios configuration.At the end of the nagios configuration error will occur the following command /usr/local/nagios/etc/nagios.cfg.
error:unexpected EOF while looking for matching `"'
- 10-01-2010 #3
- 10-01-2010 #4Linux Guru
- Join Date
- Apr 2009
- Location
- I can be found either 40 miles west of Chicago, or in a galaxy far, far away.
- Posts
- 10,156
A program that accesses hardware I/O ports has to have root privileges. This is required by the operating system. You can do this if the application (not script) is owned by root and has the setuid bit set. Then, when it is run, it will be as a root process. This is not to be done without careful consideration as it leaves the system vulnerable to malware or just simple coding errors. You will note that the X server, /usr/bin/Xorg, is such an application, owned by root and has the setuid bit enabled.
Sometimes, real fast is almost as good as real time.
Just remember, Semper Gumbi - always be flexible!
- 10-05-2010 #5Just Joined!
- Join Date
- Sep 2010
- Posts
- 6
normally all I/O goes through the kernel so that it can schedule the operations and prevent processes from stepping on each other isn't it ?.
Does that mean that all programs with setuid bit set are allowed to slide around the kernel ???
- 10-05-2010 #6Linux Guru
- Join Date
- Apr 2009
- Location
- I can be found either 40 miles west of Chicago, or in a galaxy far, far away.
- Posts
- 10,156
A setuid bit with root permissions only allows the application, in user space, to access kernel functions via system calls that can potentially harm the system. Free access to I/O ports is one of those situations. As for "sliding around in the kernel", no this does not allow that. You would need to write a kernel module to do that, and only root has the privileges to add a module to the kernel. However, I suspect that if you enabled the setuid bit on modprobe, then you would be allowing anyone to link any module into the kernel, though I haven't tried that. From the security analysis perspective, it would be an interesting experiment.
Sometimes, real fast is almost as good as real time.
Just remember, Semper Gumbi - always be flexible!


Reply With Quote

