J
JackC
Hi,
Say i have:
secureclass *secure = new secureclass(); // has sensitive stuff in
Now i want to securely delete the instance and all the classes member
variables, I take it the 'delete' keyword will just deallocate it and
not overwrite it.
I have read that the 'volatile' keyword will guarantee that the memory
will be overwritten, my question is will it overwrite it at the point
where I call delete? (im not closing the program at the point of
securing the memory)
If not whats the easiest (portable) way of doing this? I thought about
overwriting the memory with null bytes before deleting it, sort of
sizeof(secureclass) raw bytes being written, is that any good?
Theres also the additional problem that the class could get swapped to
the disk paging file, I don't suppose theres a nice portable way of
preventing this as well?
Many Thanks,
JackC
Say i have:
secureclass *secure = new secureclass(); // has sensitive stuff in
Now i want to securely delete the instance and all the classes member
variables, I take it the 'delete' keyword will just deallocate it and
not overwrite it.
I have read that the 'volatile' keyword will guarantee that the memory
will be overwritten, my question is will it overwrite it at the point
where I call delete? (im not closing the program at the point of
securing the memory)
If not whats the easiest (portable) way of doing this? I thought about
overwriting the memory with null bytes before deleting it, sort of
sizeof(secureclass) raw bytes being written, is that any good?
Theres also the additional problem that the class could get swapped to
the disk paging file, I don't suppose theres a nice portable way of
preventing this as well?
Many Thanks,
JackC