Disable Administrative Shares – How to

By | June 17, 2019

How to disable administrative shares from the command prompt. You must know and learn these command, normally windows automatically share certain folders over the network, like as C drive, C:\Windows & IPC$.

Now, used below command net share to delete the system/hidden shares.

net share sharedFolder /delete

You can run a separate command to delete each of the system shares.

net share C$ /delete
net share IPC$ /delete
net share ADMIN$ /delete

Example: (It’s showing below results)

Disable Administrative Shares - How to

C:\>net share
Share name   Resource                        Remark
C$           C:\                             Default share
IPC$                                         Remote IPC
ADMIN$       C:\WINDOWS                      Remote Admin
The command completed successfully.

You need to run the commands prompt to disable the shares.

c:\>net share C$ /delete
C$ was deleted successfully.
c:\>net share  IPC$ /delete
IPC$ was deleted successfully.
c:\>net share ADMIN$ /delete
ADMIN$ was deleted successfully.
c:\>net share
There are no entries in the list.

The alternative command prompt to delete system shares-

Now, need to use for loop, we just run the one command that iterates over all administrative shares and issues delete command.

for %i in (C$ IPC$ ADMIN$) do net share %i /delete

Last Updated on 4 years by Max

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.