Subscribe to Windows IT Pro
February 20, 2002 12:00 AM

Remove Administrative Shares on a Win2K System

Windows IT Pro
InstantDoc ID #23782
Rating: (0)

Windows 2000 has administrative shares (i.e., shares that provide remote access directly to any C drive or logical, physical drive on your system) by default. The administrative shares are those shares that you can use \\computername_or_IPaddress\C$ to access. To manually disable the shares, right-click My Computer, select Map Network Drive, select the drive letter (i.e., C, D, or E), and enter

\\<ComputerName>_or_<Ipaddress><DriveLetter>$

Select Do not share this folder. Unfortunately, when you restart the system the shares will automatically recreate. This feature creates a security risk because anyone who knows the machine's IP address can try to use \\IPaddress\C$ , \\IPaddress\D$, or \\IPaddress\E$ to access the shares.

To remove administrative shares without letting Win2K recreate them every time you reboot the system, you need to edit the registry. Start regedit and go to the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\lanmanserver\parameters subkey. From the Edit menu, select New, DWORD Value to create the new values AutoShareServer and AutoShareWks; set each value's data to 0 (i.e., false). Next, go to each drive, right-click, and select Sharing. Then, select Do not share this folder.

To test the registry entries you added, restart your system and go to your physical or logical drive's Sharing option. Check whether C$, D$, or E$ appears (they shouldn't). To further ensure that the administrative shares are disabled, try to access \\IPaddress\C$, \\IPaddress\D$, or \\IPaddress\E$.

Related Content:

ARTICLE TOOLS

Comments
  • Raymon
    8 years ago
    Jun 30, 2004

    The comments posted by Phuoc Trong Ha on March 17, 2003 are incorrect.
    The above method will *NOT* disable all local sharing. It will disable the Administrative shares only. All existing or future shares are unaffected by theese registry changes.

    In windows XP, in order to remove the shares after the changes have been made to the registry, you need to go to "Windows Explorer" -> "Tools", "Folder Options" [View]
    and remove the check in "Use simple sharing (Recommended)"

    -that makes it possible to remove the shares.
    After the shares are removed, you can change the "Use simple sharing (Recommended)" setting back to enabled.

  • Phuoc Trong Ha
    9 years ago
    Mar 17, 2003

    keep in mind i am a complete idiot because this will disable all local sharing and not just the administrative share. If you wish to try this be absolutely sure you do not want to ever use local sharing.

You must log on before posting a comment.

Are you a new visitor? Register Here

advertisement

advertisement

Windows is a trademark of the Microsoft group of companies. Windows IT Pro is used by Penton Media Inc. under license from owner.