title: Is it faster to wipe on delete than to wipe on create when maintaining data security?
body: <p>Inspired by this question:</p>
  
  <p><a href="https://security.stackexchange.com/questions/110734/why-didnt-oses-securely-delete-files-right-from-the-beginning-and-why-do-they">https://security.stackexchange.com/questions/110734/why-didnt-oses-securely-delete-files-right-from-the-beginning-and-why-do-they</a></p>
  
  <p>I'm proposing a multi-user scenario, especially where users are not to be trusted with each other's data, such as a cloud where disk space is reallocated, particularly to another user.</p>
  
  <p>If the first user deletes a file, and the disk space is then reallocated to a second user, I presume that the physical area is wiped before handing it to the second user.  (Otherwise, we'd be inadvertently leaking information.)</p>
  
  <p><strong>My question is, technically, is it faster to wipe:</strong></p>
  
  <ol>
  <li>immediately after the delete</li>
  <li>immediately before allocating it to the second user</li>
  <li>by having a special "hook" that the program can flag the data as potentially sensitive</li>
  <li>by running some garbage collection process in between
  (in which case, how do you cope with low disk space situations)</li>
  </ol>
  
  <p>Also, I'm aware that this doesn't always happen in non-secure OSs.  <strong>What's the term for ensuring that user's don't accidentally get allocated another user's unlinked data?</strong></p>