Re: capable open_port() check wrong for kmem

From: carbonated beverage (
Date: Wed Dec 11 2002 - 17:38:57 EST

On Tue, Dec 10, 2002 at 12:33:04PM +0100, Olaf Dietsche wrote:
> You may want to look at this thread:
> <>


Okay, which approach is generally accpetible for inclusion into the kernel?
1) Nuke CAP_SYS_RAWIO check. If the permissions on /dev/kmem is wrong,
tough. It shouldn't be root:root 0666 in the first place anyways.
2) Add CAP_SYS_KMEM for read-only access, check for CAP_SYS_RAWIO for
the write case.
3) Special case /dev/kmem in open_port.


4) Even if an application doesn't need write access to /dev/kmem, require
it to open /dev/kmem O_RDWR, as it makes life easier for many people,
especially when modifying the kernel at run-time to hijack sysca... um, do
creative updates. :)

I'd prefer #1 or #2, but the discussion seems to have ended during the last
time the issue was brought up.

-- DN
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

This archive was generated by hypermail 2b29 : Sun Dec 15 2002 - 22:00:23 EST