Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re^3: Secure delete ie shred a file

by fluffyvoidwarrior (Monk)
on Jan 26, 2006 at 17:01 UTC ( #525774=note: print w/ replies, xml ) Need Help??


in reply to Re^2: Secure delete ie shred a file
in thread Secure delete ie shred a file

So won't a sequence like this actually write to the same disk sectors (ntfs hard drive)
step1 - set file pointer position,
step2 - sysread lump of data,
step3 - encrypt lump of data,
step4 - reset pointer to original posn,
step5 - syswrite lump of data in same file posn,

or is it just a case of probably , sometimes.


Comment on Re^3: Secure delete ie shred a file
Re^4: Secure delete ie shred a file
by tirwhan (Abbot) on Jan 26, 2006 at 17:57 UTC

    Probably, sometimes :-). Without information on how the file system, device driver and device firmware allocate space at that particular point in time you have no way of knowing. sysread is too far removed from the actual disk operation to make a guarantee on how one impacts the other. In general this may work, however, there are some cases where it definitely won't (e.g. Flash drive, different sized data, remapped bad sectors/clusters) and AFAIK the behaviour in other cases is undefined.


    There are ten types of people: those that understand binary and those that don't.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://525774]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (12)
As of 2014-10-30 13:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (208 votes), past polls