9 Jul
2024
9 Jul
'24
8 p.m.
On 09.07.24 18:18, Richard Hodges via Boost wrote:
just a thought :
It would be nice if this worked:
#include <string> #include <algorithm>
struct secure_string : std::basic_string<volatile char> {
~secure_string() { std::fill(begin(), end(), '\0'); } };
That wouldn't be secure even if it did work. Consider what happens when std::string is forced to reallocate. -- Rainer Deyke (rainerd@eldwood.com)