We have some applications in various subdirectories that we limit access to by unix group, and we want them to be execute only. So, for example, if we want members of the "chem" group to have execute-only access to a.out, we have:
$ ll -d /tmp/dir1 drwx--x--- 2 root chem 18 Oct 20 07:50 /tmp/dir1/ $ ll /tmp/dir1/a.out -rwx--x--- 1 root chem 8728 Oct 20 07:50 /tmp/dir1/a.out
Now from the bash shell I (a member of the "chem" group) can add this directory to my path and execute a.out:
$ export PATH=/tmp/dir1:$PATH $ a.out This is a test. . .
From tcsh, however, I can't:
$ set path = ( /tmp/dir1 $path ) $ a.out a.out: Command not found.
I have to add group read permission to the parent directory for a tcsh user to be able to run a.out (bash works in both cases):
$ ll -d /tmp/dir1 drwxr-x--- 2 root chem 18 Oct 20 07:50 /tmp/dir1/
After the chmod I log out and back in (under tcsh), then:
$ set path = ( /tmp/dir1 $path ) $ a.out This is a test. . .
We expected that read permission on the parent directory would not be needed. I've looked all over for documentation that would explain the apparent in difference in behavior between bash and tcsh in this case, but no luck. Can anyone explain this? By the way, I did these tests under SLES 12 and CentOS 7, and the behavior was the same in both cases.