> pre-2.1.126-2-no-follow.patch
>
> This adds O_NOFOLLOW to the kernel (and hence libc5). I'm not
> sure this is the best way to do this, but it works for me so
> far.
>
> The error returned is ELOOP when someone specifies O_NOFOLLOW
> on a target that is a symlink - I chose this because this is
> what FreeBSD uses.
>
> I'm not sure if the arch. specific stuff is OK, it might be
> one of the other ABIs already has O_NOFOLLOW, in which case
> it should probably use that.
Colin Plumb pointed out this patch is broken. I'll post a new one
which is along the lines of Colin's suggestion on how to do it
`right'.
When doing the original one, I was under the assumption LOOKUP_FOLLOW
applied to all of the path, not just the last bit, hence
open("/proc/self/cwd/some.file",O_RDONLY|O_NOFOLLOW) will succeed.
-cw
-
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/