Theo de Raadt wrote in <61139.1597087...@cvs.openbsd.org>: |Philipp Klaus Krause <p...@spth.de> wrote: |> Am 10.08.20 um 17:00 schrieb Theo de Raadt: |>> Philipp Klaus Krause <p...@spth.de> wrote: |>> |>>> OpenBSD has the explicit_bzero function to reliably (i.e. even if not |>>> observable in the C abstract machine) overwrite memory with zeroes. |>>> |>>> WG14 is currently considering adding similar functionality to C2X. |>> |>> Then perhaps in the interests of the public they should use the same |>> name, but I suspect they won't. |> |> The functionality (i.e. some way to reliably overwrite memory) already |> exists under different names: explicit_bzero in OpenBSD | |This one was first.
If i recall correctly others had already started using volatile pointers to memset(3) before. 'Kind of strange that bcopy etc. all were thrown away, just to bring back a bzero to circumvent overoptimization of compilers. That "reliably overwrite memory" .. bugs me, i know that ship has sailed, but if the programmer calls a function then for a reason. Sorry, the topic concerns me. --steffen | |Der Kragenbaer, The moon bear, |der holt sich munter he cheerfully and one by one |einen nach dem anderen runter wa.ks himself off |(By Robert Gernhardt)