This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH RFC] explicit_bzero, again


On Tue, Sep 15, 2015 at 01:08:44PM -0300, Adhemerval Zanella wrote:
> >> Also this can be enabled project by project in a very easy way if it decides
> >> that is worth to implement.
> > 
> > This has already happened.  codesearch.debian.net reports 597 mentions
> > of explicit_bzero, 645 mentions of OPENSSL_cleanse, 6 mentions of
> > explicit_memset, 721 mentions of memset_s, 328 mentions of
> > memzero_explicit, 216 mentions of memwipe, 295 mentions of wipememory.
> > We wouldn't be having this conversation at all if there weren't a
> > demonstrated demand from the application side.
> 
> And as for str{l}cpy it does not really mean they are using the better
> approach to fix its issues it is proposing to fix. Or even, if using
> the API is indeed implement the security fixes they are aiming for.

Neither explicit_bzero in glibc nor something similar in GCC can ever
produce this hoped-for security: there always will remain cases where
data escapes.  But it is good for defense-in-depth, as long as the
documentation makes it very clear that there are no promises that every
trace of the secret data will be gone.  Although of course many people
will just ignore such warnings and use this as snake oil, as faerie dust
that you sprinkle over your code.


Segher


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]