Q: How can I ensure that Windows doesn't automatically create administrative shares, such as C$, D$, and Admin$, on my Windows servers?

 

A: To remove administrative shares and prevent them from being automatically created, you must make the following registry change on your Windows servers: In the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters registry container, create a new REG_DWORD entry called AutoShareServer and set its value to 0. Note that this setting doesn't apply to the IPC$, NETLOGON, and SYSVOL shares or the shares that you create manually, so those shares will still be available after you've created and enabled the AutoShareServer setting.