Source-Changes-D archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: CVS commit: src



In article <20120830121650.56952175D0%cvs.netbsd.org@localhost>,
Matthias Drochner <source-changes-d%NetBSD.org@localhost> wrote:
>-=-=-=-=-=-
>
>Module Name:   src
>Committed By:  drochner
>Date:          Thu Aug 30 12:16:49 UTC 2012
>
>Modified Files:
>       src/include: string.h
>       src/lib/libc/string: Makefile.inc
>       src/lib/libcrypt: bcrypt.c crypt-sha1.c md5crypt.c
>       src/sys/dev: cgd_crypto.c
>       src/sys/lib/libkern: Makefile.libkern libkern.h
>       src/sys/netipsec: key.c xform_ah.c xform_esp.c
>       src/sys/opencrypto: cryptosoft.c
>Added Files:
>       src/common/lib/libc/string: consttime_bcmp.c explicit_bzero.c
>
>Log Message:
>Add "consttime_bcmp" and "explicit_bzero" functions for both kernel
>abd userland, as proposed on tech-security, with explicit_bzero using
>a volatile function pointer as suggested by Alan Barrett.
>Both do what the name says. For userland, both are prefixed by "__"
>to keep them out of the user namespace.
>Change some memset/memcmp uses to the new functions where it makes
>sense -- these are just some examples, more to come.

I would prefer not to proliferate the b* function names in the future.
Why not explicit_memset() consttime_memcmp()? It is not like the old
b* functions have clear semantics or consistent prototypes!

christos



Home | Main Index | Thread Index | Old Index