Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
* Problem with mode on symbolic links
@ 1996-01-26  5:00 Blair Phillips
  1996-01-28  5:00 ` Steve Strange USG
  0 siblings, 1 reply; 2+ messages in thread
From: Blair Phillips @ 1996-01-26  5:00 UTC (permalink / raw)


In the course of adding some entries to /sbin/rc3.d, I noticed that
any symbolic links I added had the protection rwxrwxrwx.

chmod og-w or chmod 755 had no effect on this. I tried with umask 0 
as well as the normal umask 022, as I have a vague recollection that
umask affects chmod.

I noted that most of the standard entries in rc3.d had rwxr-xr-x
protection, but some of them (e.g. nsr) had rwxrwxrwx.

I'm not sure what security implication this has, but it doesn't do
anything for my peace of mind.

Can anyone provide enlightenment??

btw it's Digital UNIX 3.2C on an AlphaStation 250 4/266
-- 
Blair Phillips, Email: BlairP@spirit.com.au
Phone: +61 411189724



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Problem with mode on symbolic links
  1996-01-26  5:00 Problem with mode on symbolic links Blair Phillips
@ 1996-01-28  5:00 ` Steve Strange USG
  0 siblings, 0 replies; 2+ messages in thread
From: Steve Strange USG @ 1996-01-28  5:00 UTC (permalink / raw)


In article <3108CCD8.1546@spirit.com.au> Blair Phillips <Blairp@spirit.com.au> writes:

>   In the course of adding some entries to /sbin/rc3.d, I noticed that
>   any symbolic links I added had the protection rwxrwxrwx.
>
>   chmod og-w or chmod 755 had no effect on this. I tried with umask 0 
>   as well as the normal umask 022, as I have a vague recollection that
>   umask affects chmod.
>
>   I noted that most of the standard entries in rc3.d had rwxr-xr-x
>   protection, but some of them (e.g. nsr) had rwxrwxrwx.
>
>   I'm not sure what security implication this has, but it doesn't do
>   anything for my peace of mind.
>
>   Can anyone provide enlightenment??

It's the mode bits of the target of the symbolic link that are checked
for file access, not the mode bits of the symlink itself.  The
symlink's mode bits are always ignored, so they are always created
with mode 777.  I'm not really sure why some of the symlinks in
/sbin/rc3.d ended up with non-777 settings, but there is no reason for
concern because the mode bits are never checked for file accesses
anyway.  I just checked a Digital UNIX T4.0 system, and all the
symlinks in /sbin/rc3.d are 777, as they really should be.

The only time the mode bits on a symlink would be potentially
interesting is if you have a dangling symlink (target has been
deleted), and you want to remove the symlink.  In that case, you must
be the owner of the symlink (or root) to be able to delete it.

The one exception to symlink mode bits being ignored is DFS mount
points.  DFS mount are actually symlinks with a specific mode bit
setting to distinguish them from regular symlinks.  But they aren't
used for file access checking in any case.

	Steve
--
Steve Strange						strange@zk3.dec.com
Digital Equipment Corporation, Nashua, NH		     (603) 881-0595
Digital UNIX DCE DFS Development



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1996-01-28  5:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1996-01-26  5:00 Problem with mode on symbolic links Blair Phillips
1996-01-28  5:00 ` Steve Strange USG

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox