NTFS file system tips

Source: Internet
Author: User

The NTFS system supports the hardlink technology. The so-called hardlink is actually to create a hard link for a file, the two files enjoy the same file content. Delete any one of them, and others still protect the original data. This is obviously an interesting feature. So how to create a file's hardlink?

First, create a file test.txt under the root directory of the C drive, and enter fsutil hardlink create c: \ 1.txt c: \ test.txt in the command console. Then press enter to create a hard link for the test.txt file, that is, 1.txt. When you open any file, you will find that the content of the file is the same. modify any file and change the content of the file.

You may not be aware of the features of this new technology. Many of the current security software determine the files to be protected based on the path method, which is similar to my article "process protection, they will determine whether the files need to be protected based on the file path. If yes, the modifications to the files will be filtered out. Here, you may already understand, that is, you can create a hard link for a protected file to modify the file, so using this mechanism to protect the file security software will become useless, this is also a security attack and defense.

Of course, we can also call the system API to create a hard link for a file.

BOOL CreateHardLink(  LPCTSTR lpFileName,  LPCTSTR lpExistingFileName,  LPSECURITY_ATTRIBUTES lpSecurityAttributes);

In fact, security defense depends on who can use some existing simple mechanisms to complete some non-simple functions. Programming is also true. But you often need to understand these simple mechanisms first.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.