Source-Changes-HG archive

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

[src/trunk]: src/sys/dev Use explicit_memset to zero key material.



details:   https://anonhg.NetBSD.org/src/rev/e148039449a2
branches:  trunk
changeset: 337726:e148039449a2
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Sat Apr 25 13:06:11 2015 +0000

description:
Use explicit_memset to zero key material.

diffstat:

 sys/dev/cgd.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r e93798d31318 -r e148039449a2 sys/dev/cgd.c
--- a/sys/dev/cgd.c     Sat Apr 25 12:55:04 2015 +0000
+++ b/sys/dev/cgd.c     Sat Apr 25 13:06:11 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cgd.c,v 1.96 2015/01/02 19:42:06 christos Exp $ */
+/* $NetBSD: cgd.c,v 1.97 2015/04/25 13:06:11 riastradh Exp $ */
 
 /*-
  * Copyright (c) 2002 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cgd.c,v 1.96 2015/01/02 19:42:06 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cgd.c,v 1.97 2015/04/25 13:06:11 riastradh Exp $");
 
 #include <sys/types.h>
 #include <sys/param.h>
@@ -705,7 +705,7 @@
         * and encblkno8.
         */
        cs->sc_cdata.cf_blocksize /= encblkno[i].d;
-       (void)memset(inbuf, 0, MAX_KEYSIZE);
+       (void)explicit_memset(inbuf, 0, MAX_KEYSIZE);
        if (!cs->sc_cdata.cf_priv) {
                ret = EINVAL;           /* XXX is this the right error? */
                goto bail;



Home | Main Index | Thread Index | Old Index