To disable the administrative shares in Windows, (default shares like C$, ADMIN$, etc.) follow these steps:
-
Run the Registry Editor and go to the following key:
HKEY\_LOCAL\_MACHINE\SYSTEM\CurrentControlSet \Services\LanmanServer\Parameters -
Create a new
DWORD, name itAutoShareWks, and leave the default value of0. -
Reboot Windows.
This will disable things like C$ and ADMIN$.
I am not sure how to also delete print$ and IPC$. (net share ipc$ /delete appears to work temporarily, but the share automagically re-appears after the next reboot.)