[fpc-pascal] Processing passwords etc.

Jonas Maebe jonas.maebe at elis.ugent.be
Fri Apr 11 09:42:07 CEST 2014


On 11 Apr 2014, at 09:36, Mark Morgan Lloyd wrote:

> Is my understanding correct that when a string or a dynamic array is extended it might result in its existing content being released to the heap?
> 
> If so, is it possible to ensure that this is zeroed or randomised first, without having to do it manually?

You can install a memory manager that does this for all (de)allocations and then calls through to the original memory manager. There is no way to only do this for strings and dynamic arrays, and I don't think it would be a good idea to do so. Not all passwords are strings, so that would probably mostly give a false sense of security.


Jonas


More information about the fpc-pascal mailing list