- (dtucker) [openbsd-compat/arc4random.c] Use explicit_bzero instead of an

assigment that might get optimized out.  ok djm@
This commit is contained in:
Darren Tucker 2014-06-11 13:10:00 +10:00
parent b9609fd86c
commit eb012ac581
2 changed files with 3 additions and 1 deletions

View File

@ -17,6 +17,8 @@
"doesn't bother me" deraadt@
- (dtucker) [sshbuf.h] Only declare ECC functions if building without
OpenSSL or if OpenSSL has ECC.
- (dtucker) [openbsd-compat/arc4random.c] Use explicit_bzero instead of an
assigment that might get optimized out. ok djm@
20140527
- (djm) [cipher.c] Fix merge botch.

View File

@ -229,7 +229,7 @@ arc4random_buf(void *_buf, size_t n)
buf[i] = r & 0xff;
r >>= 8;
}
i = r = 0;
explicit_bzero(&r, sizeof(r));
}
#endif /* !defined(HAVE_ARC4RANDOM_BUF) && defined(HAVE_ARC4RANDOM) */