Saturday, June 11, 2016

Suppressing special folder views from networked machines

Some folders in Windows have a special entry in their desktop.ini that tells Explorer to treat them differently than a directory with a bunch of files. The Fonts folder is like that; so is the Recycle Bin. When such folders are examined from across the network, Explorer sees the same desktop.ini, but the special folder views are usually not aware of the remoteness of the machine. Therefore, Explorer ends up displaying the corresponding information for the local machine, no matter which computer's files are being browsed.

To avoid that problem and make the folder show up as a standard holder of files, you can deny permissions on desktop.ini to network users:

icacls desktop.ini /deny NETWORK:F

(Command prompt required, since you can't see the raw files if there's a special view!) That rule will apply only when accessing the file remotely; local use of it will be unaffected. The special folder view will apply to the local machine, while remote machines will see the raw directory listing. The rule can be removed with:

icacls desktop.ini /remove NETWORK

Based on my Super User answer.

No comments:

Post a Comment