Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. General talk
  3. The Lounge
  4. Writing hard disk with zeros
QtWS25 Last Chance

Writing hard disk with zeros

Scheduled Pinned Locked Moved The Lounge
6 Posts 4 Posters 4.5k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    L Offline
    l.v.p
    wrote on last edited by
    #1

    I was just net-surfing and on this site ("click":http://www.oo-software.com/home/en/products/oosafeerase/index.html) I read:

    bq. Overwriting with zeros (for very fast deletion)

    And I had blink! in my head: I heard that when you write disc with zeros, yes you erase data for sure, but also, you can't write there anything in future.
    But I'm not sure right now. If it's true, the only one and best way to use this programm, is only when you know that you will never use your hard disk again....

    So? what is the real story with 0 and hdd?

    1 Reply Last reply
    0
    • A Offline
      A Offline
      aep_
      wrote on last edited by
      #2

      no promises for that specific product, but overwring files with 0 does not damage your harddisk at all.

      The general idea is that deleting files usually just marks the disk space as "free", so it can be reused by other files. That leaves the actual data still on disk, although inacessible. Those "secure deleters" open the file, and fill it with zeros, so it cannot be recovered anymore. The process is something along the lines of

      @ QFile f("secret.doc"); f.open(write); f.write(0,f.size()); ... @

      1 Reply Last reply
      0
      • T Offline
        T Offline
        tobias.hunger
        wrote on last edited by
        #3

        Writting zeros onto your disk does not damage it. It is just some kind of data after all.

        If you overwrite metadata stored on the disk (partition tables, data used by the filesystems to find your contents, etc.), then you can no longer get to your files anymore, but the disk itself is not damaged: You can just reformat it and it will work again.

        aep_: Yeap, but that approach is pretty simplistic and might or might not work, depending on the filesystem used to store the file as well as the hardware of the drive: Some filesystems never overwrite data when they can avoid it and drives remap sectors transparently when they think they are getting damaged. So your overwriter might or might not overwrite all the data in the file.

        1 Reply Last reply
        0
        • I Offline
          I Offline
          ivan
          wrote on last edited by
          #4

          Tobias is right, but it goes even further - even if you really succeed to overwrite the part of the disk (as in the real physical part) where the file in question is, there is always a residue on the 'sides' of the data track.

          Equipment that can read those exists. Expensive, but it exists.

          Most programs do the overwriting a couple of times which messes with the residue, and not with zeros, but some random values, or some pattern like F0F0... This provides more security, but whether it is enough, it can't be guarantied.

          Ivan Čukić | ivan.cukic(at)kde.org | KDE e.V.
          Qt Ambassador (from the old Nokia days)

          1 Reply Last reply
          0
          • T Offline
            T Offline
            tobias.hunger
            wrote on last edited by
            #5

            Ivan: I recently found a paper stating that due to the drives capacity rising all the time residue is no longer a problem: The area used to store a single bit is so small nowadays, that there is just not enough space for it. It concluded that overwritting data once was enough for a secure deletion of data. Maybe that research was sponsored by secret services though;-)

            The problem that remains is of actually overwriting all the areas on the harddrive used to ever hold the file in question. Since the drives themselves may remap sectors not even the filesystems can be 100% sure to know all the places on the disc! Overwritting the complete disk does not necessarily erase all traces either since most harddrives keep a some space for themselves that they use to map over failing blocks on the drive.

            If you want to be sure nobody can recover your data then you need to either shred the drive or make sure to encrypt everything that ever gets stored on it. With encryption you only need to delete the key... which might be tricky if it is stored on the device itself. The linux-based full disk encryption named LUKS does jump through quite a few hoops to make sure that it can guarantee deletion of most of the key (not necessarily all of it!).

            1 Reply Last reply
            0
            • I Offline
              I Offline
              ivan
              wrote on last edited by
              #6

              @Tobias: That's nice to know (as you said, if true). :)

              Ivan Čukić | ivan.cukic(at)kde.org | KDE e.V.
              Qt Ambassador (from the old Nokia days)

              1 Reply Last reply
              0

              • Login

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups
              • Search
              • Get Qt Extensions
              • Unsolved