Cipher Command - Overwrite Deleted Data in Windows

    Cipher Command - Overwrite Deleted Data in Windows

    Cipher Command - Overwrite Deleted Data in Windows

    How to Overwrite Deleted Data using the "Cipher" Command in Windows
    Published by
    Designer Media Ltd


    How to Overwrite Deleted Data using the "Cipher" Command in Windows

       Information
    The Windows cipher command line tool is predominantly used to manage the encryption status of NTFS volumes. A lesser known function of this command is the ability to securely overwrite free disk space.

    Files deleted on a volume are only marked for deletion and can still be recovered. By using the cipher command, the free space occupied by the deleted files are securely overwritten resulting in a more secure system in which the previously deleted files cannot be recovered.

    The advantage of using the cipher command is that it ONLY overwrites free disk space - the remainder of the volume is untouched. The cipher command can be run from a booted system without the need to dismount volumes/partitions/disks, or to resort to more complex tools.

    This tutorial will show you how to securely wipe or overwrite free disk space on any partition or disk using the inbuilt cipher command in Windows.



    Steps:

    1. Open an elevated command prompt.

    2. Type the command below, and press Enter.

    The syntax required is:
    Code:
    cipher /w:[drive]:\[folder]
    where [drive] = drive letter, [folder] = folder name

    In the example below, I wish to wipe all free disk space on my F drive (a logical partition on a physical disk). Thus, I use the following syntax:

    Code:
    cipher /w:F:\
    The output from the cipher command is shown below. The free space is overwritten 3 times:
    • once with a series of 0's (zero)
    • once with a series of 255's
    • once with a series of random numbers

    Cipher Command - Overwrite Deleted Data in Windows-cip1.png
       Note
    Disks with large amounts of free space will take some time to be overwritten - on my system, wiping 25 GB of free space takes approximately 10 minutes.

    Regards,
    Golden





  1. Posts : 3,133
    Windows 7 Home Premium 64bit SP 1
       #1

    Thanks Golden! I just learned something new.
      My Computer


  2. Posts : 19,383
    Windows 10 Pro x64 ; Xubuntu x64
    Thread Starter
       #2

    No worries mate - glad you found it useful.
      My Computer


  3. Posts : 20,583
    Win-7-Pro64bit 7-H-Prem-64bit
       #3

    Very nice :)
      My Computer


  4. Posts : 4,566
    Windows 10 Pro
       #4

    Great tutorial. Thank you.
      My Computer


  5. Posts : 2
    windows 7 pro 64 bit
       #5

    Wiping areas of a disk with no partition


    One of my disks is a backup disk with one partition of 100gb, 400gb remains un-partitioned i was wondering if theirs a way to cipher this disk as it has previously had data on it. Or if theirs a way to select a whole disk to cipher.

    Thanks
    Toby
      My Computer


  6. Posts : 19,383
    Windows 10 Pro x64 ; Xubuntu x64
    Thread Starter
       #6

    No, since no partition exists, there is nothing to overwrite.

    You need to create an empty partition, run cipher on it, then remove the partition again if you feel you need to overwrite any historical data that was there.
      My Computer


  7. Posts : 2
    windows 7 pro 64 bit
       #7

    Thanks
      My Computer


  8. Posts : 194
    Windows 7 Home Premium 64 bit
       #8

    Thank you for this information. Never too old to learn......
      My Computer


 

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

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