Add Secure Delete to Recycle Bin Context Menu in Windows 10  

Page 1 of 8 123 ... LastLast
    Add Secure Delete to Recycle Bin Context Menu in Windows 10

    Add Secure Delete to Recycle Bin Context Menu in Windows 10

    How to Add Secure Delete to Recycle Bin Context Menu in Windows 10
    Published by Category: Customization
    30 Aug 2021
    Designer Media Ltd

    How to Add Secure Delete to Recycle Bin Context Menu in Windows 10

    The Recycle Bin provides a safety net when deleting files or folders. When you delete any of these items from your hard disk, Windows places it in the Recycle Bin and the Recycle Bin icon changes from empty to full.

    If you have multiple hard drives, partitions, or an external hard drive connected to your PC, each location will have its own $Recycle.Bin and Recycle Bin settings. Removable drives, such as USB flash drives and memory cards, will not have a Recycle Bin. Files deleted from removable drives are permanently deleted.

    When you delete a file or folder in Windows, the item(s) get placed in the Recycle Bin by default until you empty the Recycle Bin to permanently delete them if you didn't want to restore them.

    However, permanently deleting a file or folder doesn't secure delete them.

    Secure Delete will delete and overwrite a file or folder to securely erase any data that exists in the unallocated portions of a disk for the deleted file or folder so it gone forever and cannot be recovered.

    If you like, you can add Secure Delete to the Recycle Bin context menu that will secure erase all items (files and folders) in the Recycle Bin deleted from the "C:" drive for the current user.

    The Secure Delete context menu will perform 3 passes to securely erase only the items in the Recycle Bin deleted from the "C:" drive for the current user, and will restart explorer to refresh the Recycle Bin icon. If you would prefer to have more passes, then please post a reply in this tutorial requesting it, and I'll post an updated .reg file for it. If you would like to have the Recycle Bin of other drive letters included, then please post a reply in this tutorial requesting it, and I'll post an updated .reg file for it.

    This tutorial will show you how to add Secure Delete to the Recycle Bin context menu for all users in Windows 7, Windows 8, and Windows 10.

    While you must be signed in as an administrator to add or remove the context menu, all users will be able to use the context menu.

    The first time you use the context menu, SDelete may prompt you to Agree to the license terms before continuing. You will not see the prompt again afterwards.



    Contents

    • Option One: Add "Secure Delete" to Recycle Bin Context Menu
    • Option Two: Remove "Secure Delete" from Recycle Bin Context Menu
    • Option Three: Add or Remove "Secure Delete" with Confirmation Recycle Bin Context Menu



    EXAMPLE: "Secure Delete" context menu for Recycle Bin
    Add Secure Delete to Recycle Bin Context Menu in Windows 10-secure_delete_recycle_bin_context_menu-2.jpg Add Secure Delete to Recycle Bin Context Menu in Windows 10-secure_delete_recycle_bin_context_menu-1.jpg






    OPTION ONE

    Add "Secure Delete" to Recycle Bin Context Menu


    1 Download the latest version of SDelete by Mark Russinovich from Microsoft Sysinternals below.
    2 Save the SDelete.zip file to your desktop.

    3 Unblock the downloaded SDelete.zip file.

    4 Open the SDelete.zip file.

    5 Open the C:\Windows\System32 folder in a separate File Explorer (Win+E) window.

    6 Copy and paste (drag and drop) the sdelete.exe file from the SDelete.zip file into the C:\Windows\System32 folder. (see screenshots below)

    Add Secure Delete to Recycle Bin Context Menu in Windows 10-sdelete_zip.jpg Add Secure Delete to Recycle Bin Context Menu in Windows 10-system32.jpg

    7 When prompted, click/tap on Continue to approve. (see screenshot below)

    Add Secure Delete to Recycle Bin Context Menu in Windows 10-approve.png

    8 You can now close the ZIP and File Explorer windows if you like.

    9 Click/tap on the Download button below to download the file below.

    Add_Secure_Delete_to_Recycle_Bin_context_menu.reg

    Download

    (Contents of REG file for reference)
    Code:
    Windows Registry Editor Version 5.00
    
    [HKEY_CLASSES_ROOT\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\shell\SecureDelete]
    @="Secure Delete"
    "NoWorkingDirectory"=""
    "Position"="top"
    "Icon"="imageres.dll,-5305"
    
    [HKEY_CLASSES_ROOT\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\shell\SecureDelete\command]
    @="cmd /v /c \"sdelete -p 3 -s \"!SystemDrive!\\$Recycle.Bin\\*\" && powershell -NoLogo -NoProfile -WindowStyle Hidden -Command \"& {Add-Type shell32 '[DllImport(\\\"shell32.dll\\\")] public static extern int SHUpdateRecycleBinIcon();' -Namespace System; [shell32]::SHUpdateRecycleBinIcon(); Start-Sleep 1}\"\""

    10 Save the .reg file to your desktop.

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

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

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






    OPTION TWO

    Remove "Secure Delete" from Recycle Bin Context Menu


    This is the default setting.


    1 Click/tap on the Download button below to download the file below.

    Remove_Secure_Delete_from_Recycle_Bin_context_menu.reg

    Download

    (Contents of REG file for reference)
    Code:
    Windows Registry Editor Version 5.00
    
    [-HKEY_CLASSES_ROOT\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\shell\SecureDelete]

    2 Save the .reg file to your desktop.

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

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

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






    OPTION THREE

    Add or Remove "Secure Delete" with Confirmation Recycle Bin Context Menu


    Special thank you to our member Matthew for providing this option.


    1 Click/tap on the Download button below to download the BAT file below.

    Add_or_remove_Secure_Delete.bat

    Download

    2 Save the .bat file to your desktop.

    3 Unblock and run the downloaded .bat file.

    4 If prompted by (UAC), click/tap on Yes to approve.

    5 Press the number 1, 2, or 3 for what you want when prompted by the command prompt. (see screenshot below)

    Add Secure Delete to Recycle Bin Context Menu in Windows 10-1_addition.jpg

    6 If you added the "Secure Delete" context menu to the Recycle Bin, users will see the confirmation prompt below whenever the "Secure Delete" context menu is used. (see screenshot below)

    Add Secure Delete to Recycle Bin Context Menu in Windows 10-2_confirmation.jpg


    That's it,
    Shawn Brink






  1. Posts : 17,838
    Windows 10
       #1

    @Brink
    Another good tutorial Shawn!!!

    However, I have to ditch the Restart Explorer part, it screws up QTTabBar every time Explorer restarts, (or crashes, for that matter!).

    What do I have to modify?...


    Code:
    Windows Registry Editor Version 5.00
    
    ; Created by: Shawn Brink
    ; Created on: December 29th 2018
    ; Tutorial: https://www.tenforums.com/tutorials/124353-add-secure-delete-recycle-bin-context-menu-windows-10-a.html
    
    
    [HKEY_CLASSES_ROOT\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\shell\SecureDelete]
    @="Secure Delete"
    "NoWorkingDirectory"=""
    "Position"="top"
    "Icon"="imageres.dll,-5305"
    
    [HKEY_CLASSES_ROOT\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\shell\SecureDelete\command]
    @="cmd /c \"sdelete -p 3 -s \"C:\\$Recycle.Bin\\*\" && taskkill /f /im explorer.exe & start explorer.exe\""
      My Computer


  2. Posts : 68,894
    64-bit Windows 11 Pro for Workstations
    Thread Starter
       #2

    @Edwin,

    No problem. Here's a modified .reg without the restart bit included in it. The Recycle Bin icon will only update the next time you open it without the restart bit.

    Add_Secure_Delete_to_Recycle_Bin_context_menu.reg

    The bit in red below is what's removed.

    Code:
    Windows Registry Editor Version 5.00
    
    ; Created by: Shawn Brink
    ; Created on: December 29th 2018
    ; Tutorial: https://www.tenforums.com/tutorials/124353-add-secure-delete-recycle-bin-context-menu-windows-10-a.html
    
    
    [HKEY_CLASSES_ROOT\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\shell\SecureDelete]
    @="Secure Delete"
    "NoWorkingDirectory"=""
    "Position"="top"
    "Icon"="imageres.dll,-5305"
    
    [HKEY_CLASSES_ROOT\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\shell\SecureDelete\command]
    @="cmd /c \"sdelete -p 3 -s \"C:\\$Recycle.Bin\\*\" && taskkill /f /im explorer.exe & start explorer.exe\""
      My Computers


  3. Posts : 17,838
    Windows 10
       #3

    Brink said:
    @Edwin,

    No problem. Here's a modified .reg without the restart bit included in it. The Recycle Bin icon will only update the next time you open it without the restart bit.

    Add_Secure_Delete_to_Recycle_Bin_context_menu.reg

    The bit in red below is what's removed.

    Code:
    Windows Registry Editor Version 5.00
    
    ; Created by: Shawn Brink
    ; Created on: December 29th 2018
    ; Tutorial: https://www.tenforums.com/tutorials/124353-add-secure-delete-recycle-bin-context-menu-windows-10-a.html
    
    
    [HKEY_CLASSES_ROOT\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\shell\SecureDelete]
    @="Secure Delete"
    "NoWorkingDirectory"=""
    "Position"="top"
    "Icon"="imageres.dll,-5305"
    
    [HKEY_CLASSES_ROOT\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\shell\SecureDelete\command]
    @="cmd /c \"sdelete -p 3 -s \"C:\\$Recycle.Bin\\*\" && taskkill /f /im explorer.exe & start explorer.exe\""
    Perfect Shawn! Thank You!

    Also works for fully functional Recycle Bin on the Taskbar!

    Pin Recycle Bin to Taskbar in Windows 10 | Tutorials

    Add Secure Delete to Recycle Bin Context Menu in Windows 10-001672.png
      My Computer


  4. Posts : 68,894
    64-bit Windows 11 Pro for Workstations
    Thread Starter
       #4

    Even better.
      My Computers


  5. Posts : 17,838
    Windows 10
       #5

    This is interesting:

    If I right select a single item (1), by way of a jump list or within the Recycle Bin itself, I can't secure delete it, but, if I right select an item in a folder, (2), in the Bin, I can!

    Add Secure Delete to Recycle Bin Context Menu in Windows 10-001668.png
      My Computer


  6. Posts : 68,894
    64-bit Windows 11 Pro for Workstations
    Thread Starter
       #6

    That may be from this below instead. I'm not sure why it would be on the context menu of anything inside the Recycle Bin though. It shouldn't be.

    How are you opening it in your screenshot?

    Add Secure Delete to Context Menu in Windows 10 | Tutorials
      My Computers


  7. Posts : 17,838
    Windows 10
       #7

    Brink said:
    That may be from this below instead. I'm not sure why it would be on the context menu of anything inside the Recycle Bin though. It shouldn't be.

    How are you opening it in your screenshot?

    Add Secure Delete to Context Menu in Windows 10 | Tutorials
    Yup, that's what it is!

    The little blue arrow is a QTTabBar jumplist allowing you to expand a folder's contents anywhere...

    Add Secure Delete to Recycle Bin Context Menu in Windows 10-001674.png
      My Computer


  8. Posts : 17,838
    Windows 10
       #8

    @Brink

    Only thing missing is the sound!

    Add Secure Delete to Recycle Bin Context Menu in Windows 10-001676.png
      My Computer


  9. Posts : 68,894
    64-bit Windows 11 Pro for Workstations
    Thread Starter
       #9

    Ah, ok. QTTabBar was how it opened. I was about to say, that didn't look native.

    LOL, yeah sound would be nice to have with it.
      My Computers


 

Tutorial Categories

Add Secure Delete to Recycle Bin Context Menu in Windows 10 Tutorial Index Network & Sharing Instalation and Upgrade Browsers and Email General Tips Gaming Customization Apps and Features Virtualization BSOD System Security User Accounts Hardware and Drivers Updates and Activation Backup and Restore Performance and Maintenance Mixed Reality Phone


  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 21:28.
Find Us




Windows 10 Forums