Many common operating systems such as Windows and UNIX support file links including hard links, symbolic (soft) links, and virtual drives. Hard links can be created in UNIX with the ln command , or in Windows operating systems by calling the CreateHardLink() function. Symbolic links can be created in UNIX using the ln -s command or in Windows by using directory junctions in NTFS or the Linkd.exe (Win 2K resource kit) or "junction" freeware. Virtual drives can also be created in Windows using the subst command.
...
Compliant Solution (lstat-fopen-fstat)
This compliant solution uses the lstat-fopen-fstat idiom illustrated in FIO05-C. Identify files using multiple file attributes.
...
Note that this code does not check for hard links, .
Hard Links
Hard links can be insidiousare problematic, because if a file has multiple hard links, it is impossible to distinguish which link came first. Likewise, it is impossible to distinguish which link might have originated from a malicious attacker.
...