Windows Internals covering windows server 2008 and windows vista- P18
Số trang: 50
Loại file: pdf
Dung lượng: 928.20 KB
Lượt xem: 28
Lượt tải: 0
Xem trước 5 trang đầu tiên của tài liệu này:
Thông tin tài liệu:
Windows Internals covering windows server 2008 and windows vista- P18: In this chapter, we’ll introduce the key Microsoft Windows operating system concepts andterms we’ll be using throughout this book, such as the Windows API, processes, threads, virtualmemory, kernel mode and user mode, objects, handles, security, and the registry.
Nội dung trích xuất từ tài liệu:
Windows Internals covering windows server 2008 and windows vista- P18 Ntfs.sys is accessed through the directory symbolic link. File symbolic links work much the same way—you can think of them as shortcuts, except they are actually implemented on the file system instead of being .lnk files managed by Windows Explorer. Just like hard links, symbolic links can be created with the mklink utility (without the /H option) or through the CreateSymbolicLink API. Because certain legacy applications might not behave securely in the presence of symbolic links, especially across different machines, the creation of symbolic links requires the SeCreateSymbolicLink privilege, which is typically granted only to administrators. The file system also has a behavior option called SymLinkEvaluation that can be configured with the following command: 1. fsutil behavior set SymLinkEvaluation By default, the Windows default symbolic link evaluation policy allows only local-to-local and local-to-remote symbolic links but not the opposite, as shown here: 1. C:>fsutil behavior query SymLinkEvaluation 2. Local to local symbolic links are enabled 3. Local to remote symbolic links are enabled. 4. Remote to local symbolic links are disabled. 5. Remote to Remote symbolic links are disabled. Symbolic links are based on an NTFS mechanism called reparse points. (Reparse points are discussed further in the section “Reparse Points” later in this chapter.) A reparse point is a file or directory that has a block of data called reparse data associated with it. Reparse data is user-defined data about the file or directory, such as its state or location, that can be read from the reparse point by the application that created the data, a file system filter driver, or the I/O manager. When NTFS encounters a reparse point during a file or directory lookup, it returns a reparse status code, which signals file system filter drivers that are attached to the volume and the I/O manager to examine the reparse data. Each reparse point type has a unique reparse tag. The reparse tag allows the component responsible for interpreting the reparse point’s reparse data to recognize the reparse point without having to check the reparse data. A reparse tag owner, either a file system filter driver or the I/O manager, can choose one of the following options when it recognizes reparse data: ■ The reparse tag owner can manipulate the pathname specified in the file I/O operation that crosses the reparse point and let the I/O operation reissue with the altered pathname. Junctions (described shortly) take this approach to redirect a directory lookup, for example. ■ The reparse tag owner can remove the reparse point from the file, alter the file in some way, and then reissue the file I/O operation. There are no Windows functions for creating reparse points. Instead, processes must use the FSCTL_SET_REPARSE_POINT file system control code with the Windows DeviceIoControl function. A process can query a reparse point’s contents with the FSCTL_GET_REPARSE _POINT file system control code. The FILE_ATTRIBUTE_REPARSE_POINT flag is set in a reparse point’s file attributes, so applications can check for reparse points by using the Windows GetFileAttributes function. 840Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. Another type of reparse point that NTFS supports is the junction. Junctions are a legacy NTFS concept and work almost identically to directory symbolic links, except they can only be local to a volume. There is no advantage to using a junction instead of a directory symbolic link, except that junctions are compatible with older versions of Windows, while directory symbolic links are not. eXPeriMeNT: Creating a Symbolic link This experiment shows you the main difference between a symbolic link and a hard link, even when dealing with files on the same volume. Create a symbolic link called soft.txt as shown here, pointing to the test.txt file created in the previous experiment: 1. C:> ...
Nội dung trích xuất từ tài liệu:
Windows Internals covering windows server 2008 and windows vista- P18 Ntfs.sys is accessed through the directory symbolic link. File symbolic links work much the same way—you can think of them as shortcuts, except they are actually implemented on the file system instead of being .lnk files managed by Windows Explorer. Just like hard links, symbolic links can be created with the mklink utility (without the /H option) or through the CreateSymbolicLink API. Because certain legacy applications might not behave securely in the presence of symbolic links, especially across different machines, the creation of symbolic links requires the SeCreateSymbolicLink privilege, which is typically granted only to administrators. The file system also has a behavior option called SymLinkEvaluation that can be configured with the following command: 1. fsutil behavior set SymLinkEvaluation By default, the Windows default symbolic link evaluation policy allows only local-to-local and local-to-remote symbolic links but not the opposite, as shown here: 1. C:>fsutil behavior query SymLinkEvaluation 2. Local to local symbolic links are enabled 3. Local to remote symbolic links are enabled. 4. Remote to local symbolic links are disabled. 5. Remote to Remote symbolic links are disabled. Symbolic links are based on an NTFS mechanism called reparse points. (Reparse points are discussed further in the section “Reparse Points” later in this chapter.) A reparse point is a file or directory that has a block of data called reparse data associated with it. Reparse data is user-defined data about the file or directory, such as its state or location, that can be read from the reparse point by the application that created the data, a file system filter driver, or the I/O manager. When NTFS encounters a reparse point during a file or directory lookup, it returns a reparse status code, which signals file system filter drivers that are attached to the volume and the I/O manager to examine the reparse data. Each reparse point type has a unique reparse tag. The reparse tag allows the component responsible for interpreting the reparse point’s reparse data to recognize the reparse point without having to check the reparse data. A reparse tag owner, either a file system filter driver or the I/O manager, can choose one of the following options when it recognizes reparse data: ■ The reparse tag owner can manipulate the pathname specified in the file I/O operation that crosses the reparse point and let the I/O operation reissue with the altered pathname. Junctions (described shortly) take this approach to redirect a directory lookup, for example. ■ The reparse tag owner can remove the reparse point from the file, alter the file in some way, and then reissue the file I/O operation. There are no Windows functions for creating reparse points. Instead, processes must use the FSCTL_SET_REPARSE_POINT file system control code with the Windows DeviceIoControl function. A process can query a reparse point’s contents with the FSCTL_GET_REPARSE _POINT file system control code. The FILE_ATTRIBUTE_REPARSE_POINT flag is set in a reparse point’s file attributes, so applications can check for reparse points by using the Windows GetFileAttributes function. 840Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. Another type of reparse point that NTFS supports is the junction. Junctions are a legacy NTFS concept and work almost identically to directory symbolic links, except they can only be local to a volume. There is no advantage to using a junction instead of a directory symbolic link, except that junctions are compatible with older versions of Windows, while directory symbolic links are not. eXPeriMeNT: Creating a Symbolic link This experiment shows you the main difference between a symbolic link and a hard link, even when dealing with files on the same volume. Create a symbolic link called soft.txt as shown here, pointing to the test.txt file created in the previous experiment: 1. C:> ...
Tìm kiếm theo từ khóa liên quan:
hệ điều hành windows hệ điều hành Linux hệ điều hành Mac giáo trình hệ điều hành windows 7 cài đặt windows XPTài liệu có liên quan:
-
Nhập môn Tin học căn bản: Phần 1
106 trang 365 0 0 -
Làm việc với Read Only Domain Controllers
20 trang 348 0 0 -
183 trang 324 0 0
-
Thêm chức năng hữu dụng cho menu chuột phải trên Windows
4 trang 322 0 0 -
Giáo trình Tin học MOS 1: Phần 1
58 trang 288 0 0 -
80 trang 273 0 0
-
Giáo trình Hệ điều hành: Phần 2
53 trang 257 0 0 -
117 trang 253 1 0
-
12 trang 248 0 0
-
Giáo trình Hệ điều hành Linux (Ngành: Công nghệ thông tin) - CĐ Công nghiệp Hải Phòng
103 trang 227 0 0