> The possibility to hardlink directories is about as old as UNIX itself.
> [ ... ]
> Anyway, afaik the reason why later Unices dropped hardlinked directories
> was that the semantics of ``..'' were very unobvious and [ ... ]
The V7 mkdir(1) command was a suid binary that did the mknod()'s and
the link()'s for "." and "..". (Who needs the kernel to be bloated
with a complicated mkdir(2) system call when it could be done
perfectly well in user space?)
Well, the problem was that there were a lot of race conditions between
the mknod and the link's that are basically impossible to get around
and you can crack root on any v7 system with a simple shell script in
a matter of minutes.
You could royally screw up your file system with the ln command as
root, I don't even recall if ln checked for directories or if you had
to add a flag to force it.
-wayne
-- Wayne Schlitt can not assert the truth of all statements in this article and still be consistent.- 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/