Re: User Access to I/O ports

Alan Cox (alan@lxorguk.ukuu.org.uk)
Tue, 3 Jun 1997 22:16:16 +0100 (BST)


> I/O port access to program motor controllers, counter/timers, etc. We do
> not want these programs to run with super-user privilege, however,
> because of all the other things that they do.

So don't

> The ioperm() system call could still be used to modify a single process's
> bitmap for compatibility with existing Linux code, such as the VGA
> library.

Indeed

> In the meantime, we just comment out the "if (suser())" check in
> the ioperm() code in the kernel in order to run our software.

Why ?

Just write small secure setuid wrapper that runs programs you name with
the ioperm set - the ioperm is inherited across an execve() call.