mounting weirdness

From: Curtis, Mark MA (Curtis.Mark.MA@bhp.com)
Date: Wed May 31 2000 - 18:26:58 EST


I realise this isn't a linux specific question, but I thought some people here may have some answers.
We have found an interesting "feature" in some unices, noteably Solaris, AIX and NetBSD (other *BSD's are possibly affected but we haven't tested that far yet).
The unaffected include Linux, Digital Unix and Sco. No common heritage in any that gives any clues.
The core of the problem is that the permissions on underlying mountpoints are referenced by the getwd() system call. The easiest way to demonstrate it is to find an unsed filesystem (or create a test one), when it is unmounted, set the permissisons on the mount point to 000, and then mount the filesystem. You can cd into it, make files according to the permissions set on it and everything.
Now try an ls -ld <full directory path>/..
if your directory it /testing then
ls -ld /testing/..
This will yield a permission denied error on affected systems. We have traced it as far as getwd() from tar error messages (we couldn't figure out why some backups were failing).
Now my question is this, what should be the expected behaviour at a mount point?
Surely the underlying permissions shouldn't come into play. But seeing as half the *nixes that I have tested come back with the error, it suggests that there mustn't be common agreement, or a "feature" some couldn't find a work-around for. If anyone has any ideas on this, please CC me in.
Cheers,
Mark Curtis
CSC (Today, BHP IT was sold yesterday.....)
curtis.mark.ma@bhp.com.au

EOM

NOTICE - This message contains information intended only for the use of the addressee named above. It may also be confidential and/or privileged. If you are not the intended recipient of this message you are hereby notified that you must not disseminate, copy or take any action in reliance on it. If you have received this message in error please notify postmaster@bhp.com.au.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Wed Jun 07 2000 - 21:00:11 EST