Page MenuHome GnuPG

[libgcrypt] NetBSD support explicit_memset
AbandonedPublic

Authored by jukivili on Apr 7 2019, 10:55 AM.

Details

Summary

Somewhat similar as explicit_bzero as non optimisable in compiler point of view.

Test Plan

N/A

Diff Detail

Lint
Lint Skipped
Unit
Unit Tests Skipped

Event Timeline

_gcry_fast_wipememory2 should be changed to always just use explicit_memset when available:

#ifdef HAVE_EXPLICIT_MEMSET
explicit_memset (ptr, set, len);
#else
#ifdef HAVE_EXPLICIT_BZERO
if (set == 0)
    {
      explicit_bzero (ptr, len);
      return;
    }
#endif 

memset_ptr (ptr, set, len);
#endif

I'm not actually sure how workflow should be on the 'patches' interface at dev.gnupg.org.

Could you post this patch and your DCO to libgcrypt mailing-list?

src/misc.c
531

Passing zero here instead of 'set'.

src/misc.c
531

Good catch ... lazy c/p.

jukivili edited reviewers, added: devnexen; removed: jukivili.

Email did not get through (should use plain old text email), so I prepared patch myself. See D477, https://dev.gnupg.org/D477

This change has been pushed to repository.