Privacy and Security Add Unblock File Context Menu in Windows 11


  • Staff
Windows_Security_banner.png

This tutorial will show you how to add or remove an Unblock file context menu to files and folders for all users in Windows 10 and Windows 11.

When you download files from the Internet, Windows 11 shows you a security warning every time you try to open it by default. Some file types are blocked from opening.

The Attachment Manager is included in Windows to help protect your PC from unsafe attachments that you might receive with an e-mail message and from unsafe files that you might save from the Internet. If the Attachment Manager identifies an attachment that might be unsafe, the Attachment Manager prevents (blocks) you from opening the file, or it warns you before you open the file.

It uses the IAttachmentExecute application programming interface (API) to find the file type, to find the file association. When one of these applications saves a downloaded file on a disk formatted with NTFS, then it updates the metadata for the file with the zone it was downloaded from. The metadata is saved as an Alternate Data Stream (ADS). If you wish to unblock a downloaded file, you can do so by right-clicking it, selecting Properties and clicking on Unblock.

The following determine whether you are prevented from opening the file or whether you are warned before you open the file:
  • The type of program that you are using.
  • The file type that you are downloading or trying to open
  • The security settings of the Web content zone that you are downloading the file from.
    • Internet
    • Local intranet
    • Trusted sites
    • Restricted sites
The Attachment Manager classifies files that you receive or that you download based on the file type and the file name extension. Attachment Manager classifies files types as high risk, medium risk, and low risk.
  • High Risk – If the attachment is in the list of high risk file types and is from the restricted zone, Windows blocks the user from accessing the file. If the file is from the Internet zone, Windows prompts the user with a Windows Security Warning: Windows found that this file is potentially harmful. To help protect your computer, Windows has blocked access to this file.
  • Moderate Risk – If the attachment is in the list of moderate risk file types and is from the restricted or Internet zone, Windows prompts the user with a warning: "The publisher could not be verified. Are you sure you want to run this software?".
  • Low Risk – If the attachment is in the list of low risk file types, Windows will not prompt the user before accessing the file, regardless of the file’s zone information.
If you like, you can add Unblock to the context menu of files and folders to make unblocking files easier to do as needed.

When you click on Unblock in the context menu of a blocked file, you will be prompted by either a Open File - Security Warning or Windows Defender SmartScreen dialog to approve unblocking the file without opening or running the file.

When you click on Unblock in the context menu of a folder, you can select to Unblock files in folder or Unblock files in folder and subfolders. You will not get prompted by a Open File - Security Warning or Windows Defender SmartScreen dialog to approve.


While you must be signed in as an administrator to add and remove the "Unblock" context menu, all users can use the context menu when added.

If you do not have access rights (permissions) to a file, the Unblock context menu will not unblock the file for you.



EXAMPLE: Blocked file

blocked_file.png


EXAMPLE: Unblock context menu

When you right click on a file or folder, you will need to click/tap on Show more options first, then click/tap on Unblock.


Show_more_options.png
Unblock_file.png
Ublock_folder.png



Here's How:

1 Do step 2 (add) or step 3 (remove) below for what you would like to do.


2 To Add Right Click Unblock Context Menu

A) Click/tap on the Download button below to download the file below, and go to step 4 below.​

Add_Unblock_context_menu.reg


(Contents of REG file for reference)
Code:
Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\*\shell\unblock]
"MUIVerb"="Unblock"
"Extended"=-

[HKEY_CLASSES_ROOT\*\shell\unblock\command]
@="powershell.exe Unblock-File -LiteralPath '%L'"


[HKEY_CLASSES_ROOT\Directory\shell\unblock]
"MUIVerb"="Unblock"
"Extended"=-
"SubCommands"=""

[HKEY_CLASSES_ROOT\Directory\shell\unblock\shell\001flyout]
"MUIVerb"="Unblock files in folder"

[HKEY_CLASSES_ROOT\Directory\shell\unblock\shell\001flyout\command]
@="powershell.exe get-childitem -LiteralPath '%L' | Unblock-File"

[HKEY_CLASSES_ROOT\Directory\shell\unblock\shell\002flyout]
"MUIVerb"="Unblock files in folder and subfolders"

[HKEY_CLASSES_ROOT\Directory\shell\unblock\shell\002flyout\command]
@="powershell.exe get-childitem -LiteralPath '%L' -recurse | Unblock-File"

3 To Remove Unblock Context Menu

This is the default setting.


A) Click/tap on the Download button below to download the file below, and go to step 4 below.​

Remove_Unblock_context_menu.reg


(Contents of REG file for reference)
Code:
Windows Registry Editor Version 5.00

[-HKEY_CLASSES_ROOT\*\shell\unblock]

[-HKEY_CLASSES_ROOT\Directory\shell\unblock]

4 Save the .reg file to your desktop.

5 Double click/tap on the downloaded .reg file to merge it.

6 When prompted, click/tap on Run, Yes (UAC), Yes, and OK to approve the merge.

7 You can now delete the downloaded .reg file if you like.


That's it,
Shawn Brink


 

Attachments

  • Windows_Security.png
    Windows_Security.png
    6 KB · Views: 127
  • Add_Unblock_context_menu.reg
    967 bytes · Views: 324
  • Remove_Unblock_context_menu.reg
    283 bytes · Views: 332
Last edited:

Latest Support Threads

Back
Top Bottom