proc perms don't change with file

Solution Verified - Updated -

Issue

  • Shouldn't the perms change with the executable?
  • Executable with execute only permissions (111) disallows reading process stats from /proc by user that initiated the executable.
  • Changes the permissions on the file on disk have no effect, the running binary stays with its original permissions at time of initiation.
  • Theory : The permissions are stored in an inode and the running binary and therefore  the reference to it in proc should be references to the on disk inode.
  • Assumption : Looks like the kind of thing that might have been done that way to close a security hole.
  • Assumption : Copy rather than reference might be done that was to close a subtle security hole.
  • Is this a bug?
  • Is this an optimization that has some unfortunate side effects?
  • Is this something that was done for some non-obvious reason burried within either the VFS or the procfs code?

Environment

  • Red Hat Enterprise Linux 5
  • Red Hat Enterprise Linux 6

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content