1

I am using Windows 7 Home Basic.

By mistake, while showing a student demonstration, I went to C drive security and permissions and denied all the permissions. I was logged on as an administrator.

How can I undo this action?

  1. I tried but I could not open the security permissions options again.

  2. Could not open Add Remove User accounts, from control panel, after stopping the services from command prompt.

  3. Could not open the safe mode for more time. It will automatically logging out.enter image description here

  4. I tried net user administrator /active:yes but after running this command also I tried to log in as 'real' administrator but still could not alter the permissions.

C-> Properties-> Security -> Permissions -> Continue

0

2 Answers 2

3

It can be done (without reinstall and without system restore).
You have at least three options, and the third is the easiest way to do it. But certainly not the only way.

  1. Restore from a backup.
  2. Use the backup to recover the old permission information.
  3. Reinstall windows.


1 Restore from a backup.

This obviously requires you to have a backup of your laptop. Since you posted here on [SU] I assume that this is not the case. In which case it is a hard learned lesson.


2 Use information

Either from a backup from your laptop or from another laptop.

If the harddisk is not encrypted then you can easily access it while booted from something else. E.g. from a windows iso on an USB pendrive using shiftF10. At this point you can use cacls to change the permissions.

Alternatively replace sethc.exe with cmd.exe. Then reboot and at the log in screen press Shift five times. This will open a command prompt with a NT authority token which you can use to issue those cacls commands.

Recovering access to the C: volume should be easy. The harder part is to set all permissions correctly. This is what you need the backup for. You want to list all permissions from the backup, place them in a file and modify that to issue relevant commands. Similar things have been done before, and there are several question on stack exchange where people did the same in a unix environment. A similar approach should also work for windows.

(Linux examples which should give you an idea on how to do this:


3 Reinstall

Well duh. Hopefully just a windows re-installation. With luck all important data can remain on D: (If you do not have a second volume yet then this is the time to consider an OS and a data partition.

4
  • I like your second option, that could sdolve using icacls commands, but I have one confusion. How to boot from another device If I have already OS installed in my harddisk. means how could it load different os , while I have os loaded in my hd. ?? pls clarify that how to do this. Commented May 15, 2015 at 15:23
  • The easiest way would be to take a live CD (en.wikipedia.org/wiki/List_of_live_CDs) either on a CD/DVD or on a pendrive. Insert the pen drive, start the computer and press the right key to select a boot device. (which key that is differs per manufacturer and per model. Quite often is it F12). Select the pendrive and let it boot. You will now be running an OS from the USB pendrive/Cd/DVD (at least until you reboot) and you are able to access all files on the harddisk, regardless of their security settings.
    – Hennes
    Commented May 16, 2015 at 15:50
  • Thanks Hennes,1) I have boot Windows 7 from CD, 2) I selected Repair PC. 3) I ran icalc commands in command propmt, but after that when I restrat my pc, still the permission did not change. So I REINSTALLED OS. And issue solved. Thanks for help Hennes. Commented May 22, 2015 at 12:23
  • I guess it depends a lot on the permission you give when booted from repair PC. I probably would have given full rights to everyone. (and later re-restricted that after successfully working from the original OS again).
    – Hennes
    Commented May 22, 2015 at 22:14
4

According to the Microsoft KB313222 article, you should ideally restore from a system backup. If that is not an option, try System Restore.

Finally, if the system remains too unstable to use, I would recommend a fresh install of Windows.

1
  • I have no restore backup, or restore point, but i future I will try, to create resore point. Commented May 13, 2015 at 15:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .