How to Disable Administrative hidden share

As system administrator we are aware that in windows by default administrative sharing is ON.

As security administrator its better to disable all not required sharing folders or drive in following example.

if we open run and type command
(Local PC C$ is C Drive)

We can see that we can access C drive of PC in network Lan area is like accessaing some other PC which you know the IP or hostname in to there C drive or windows drive.

Its better to disable the folder access as extra security measure.
to disable the hidden administrative share we can perform following method.

open run type regedit

go to the key : HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesLanManServer
RightClick and Create new String Value
Set name AutoShareWks
give 0 parameter

This procedure stop auto start now we need to disable the sharing using commands.
right click on start menu
Click on the run command prompt as (Admin)

now in command prompt, you can see what is the option available for net share
just type net share /? hit enter

as per our requisite we can use DELETE Command to stop sharing use following command as an example i want to stop C drive to be shared as Administrative access so i can use command.
net share C$ /delete

The same command can be repetitvily perfom on other hiden drives also.

Note : IPC$ is used by RPC services if you are in domain enviroment ill suggest dont disable IPC$ as it can be used for Group policy execution.

Now if we try to open a hidden folder using “\$” we can see its shows Windows cannot access.

The following command can be perform windows Desktop and all windows servers.

Leave a Comment