5

Is there a shell extension for Windows Explorer that adds a new context menu item, which allows to unblock the downloaded file? It should work exactly as I would open the file properties and click the Unblock button.

Ideally, such a shell extension should also display an overlay icon to indicate that the file is still blocked.

Toro
  • 1,135

8 Answers8

8

There's a tool from Sysinternals called streams.

This page describes how to use it. It doesn't add an option to the context menu, but does allow you to unblock a number of files at once.

I've also found this post which gives a registry file that will do the trick:

Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\*\shell\runas]
@="Take Ownership"
"NoWorkingDirectory"=""

[HKEY_CLASSES_ROOT\*\shell\runas\command]
@="cmd.exe /c takeown /f \"%1\" && icacls \"%1\" /grant administrators:F"
"IsolatedCommand"="cmd.exe /c takeown /f \"%1\" && icacls \"%1\" /grant administrators:F"

[HKEY_CLASSES_ROOT\Directory\shell\runas]
@="Take Ownership"
"NoWorkingDirectory"=""

[HKEY_CLASSES_ROOT\Directory\shell\runas\command]
@="cmd.exe /c takeown /f \"%1\" /r /d y && icacls \"%1\" /grant administrators:F /t"
"IsolatedCommand"="cmd.exe /c takeown /f \"%1\" /r /d y && icacls \"%1\" /grant administrators:F /t"

which is probably closer to what you want. Copy it into Notepad, save it as something.reg on your desktop, and double click to add it to your registry.

ChrisF
  • 41,540
7

Download NTFSext.exe described in this Microsoft article.
This is a zipped executable. Execute it to extract the files, then extract from the StrmExt.zip the dll named StrmExt.dll. Copy the dll to C:\Windows\System32 and execute the following command:

regsvr32 C:\Windows\System32\StrmExt.dll

You now you have a new tab in the file Properties of Windows Explorer that shows you a file's streams and allows their deletion:

image

Just a little remark: There's a bug in the program in that answering No to the delete dialog will still delete stream. Another bug is that the contents of the stream are not well displayed. If you're feeling adventurous, and as the source is included, you can correct the bug (and re-post the dll).

Gareth
  • 19,080
harrymc
  • 498,455
2

You'll need streams.exe from Sysinternals (mentioned above by @ChrisF). I put mine in the c:\Windows folder so if you want it elsewhere, you'll need to change the registry fragment below accordingly.

In your favorite Notepad-like editor, create a file and call it (something like) Unblock.reg. It should contain:

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\*\shell\Unblock File]
"Icon"="C:\\Windows\\System32\\Shell32.dll,109"

[HKEY_CLASSES_ROOT\*\shell\Unblock File\Command]
@="\"C:\\windows\\streams.exe\" -d \"%1\""

Once you have it, double-click on the .reg file and click "Yes" when asked if you want to continue.

That's it.

N.B. I've tested and am using this with Windows 7. YMMV.

BillP3rd
  • 6,599
1

Here's another alternative (open notepad, paste this text, save it as .reg and then double click the new file):

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\*\shell\powershell]
@="Unblock Files"

[HKEY_CLASSES_ROOT\*\shell\powershell\command]
@="C:\\\\Windows\\\\system32\\\\WindowsPowerShell\\\\v1.0\\\\powershell.exe Unblock-File  -LiteralPath \"%1\""

This one doesn't need additional tools installed, as PowerShell is part of Windows (at least in recent versions), although it provides no overlay icon.

Note: credit.

Uwe Keim
  • 2,112
mprost
  • 131
0

Winaero tweaker has options both to have a context menu unlock them or to disable the blocking behavior to begin with.

-1

Do you want to cofigure the Setting for "Data Execution Prevention" I never heard of a tool to configure this directly from the context menu, but perhaps a serach for DEP would help you.

Crujach
  • 364
-1

Sysinternals is good. You can get the source using web.archive.org, and let somebody develop the internet explorer context-menu for you on rentacoder.com

Quandary
  • 2,193
-1

Someone has written it but no x64 version available yet: http://www.benf.org/other/alternatestreamoverlay/index.html