After Win32/Dorkbot.D worm
the folders become hidden and have system attributes (marked as critical system files). Cannot unhide folders using standard File Option dialog window. How to restore previous folders' attributes?
-
3Reinstall from your backup?– ZoredacheJun 19, 2012 at 23:57
-
That's is the backup HDD, which is infected– J.OlufsenJun 20, 2012 at 8:47
4 Answers
You cannot uncheck the Hidden attribute because the affected files/folders also have the System attribute enabled.
Steps to fix
- Right click in the root folder/drive of the affected items while holding the Shift key and click Open Command Window Here
- Enter the following command in the command prompt:
for /f %F in ('dir /a:hs /b') do attrib -h -s %F
When the command finishes executing, your files should be restored and the Hidden attribute checkbox will also be enabled.
You may also try this simple windows script for unhiding files and directories. It only prompts the user to input the drive letter then executes the vbscript.
Run your notepad, copy the code below, then save it as unhide.vbs
pc_drive = InputBox("Input drive letter" & vbnewline & "example: E:\", "Drive","E:\")
ryt = Right(pc_drive,2)
If Len(pc_drive) <> 3 or ryt <> ":\" Then
Call MsgBox("Either your input was invalid or the drive you specified doesn'texist",vbokonly,"Error")
End If
Set FSO = CreateObject("Scripting.FileSystemObject")
ShowSubfolders FSO.GetFolder(pc_drive)
Sub ShowSubFolders(Folder)
str =""
For Each Subfolder in Folder.SubFolders
str =str & " " & Subfolder.Path
subFolder.Attributes = 0
ShowSubFolders Subfolder
Next
End Sub
You could save it in your USB drive for more accessibility. Instruction how to use it can be found in the link below.
The following command line executed on the affected folder works:
for /f %F in ('dir /a:hs /b') do attrib -h -s %F
...but this is not unhiding any folders with space in folder name e.g. "All Music" folder.
-
What if you'll have "%F" instead of %F? Also, be sure to re-read your text when you'll post and format it a little. It will be much easier to read. I did it for you, though. May 1, 2013 at 7:36
Go to the Command Prompt, then type attrib -s -h /s /d
x
:\*.*
Then presto!! 100% fixed :)
-
-
-
@Ramhound: I'm not asking because I want to know. But thanks anyway :) Oct 15, 2012 at 11:13