diff options
| author | beck <> | 2014-07-13 08:24:20 +0000 |
|---|---|---|
| committer | beck <> | 2014-07-13 08:24:20 +0000 |
| commit | 9dc40c4cb8a8d7a877ed1c8f5bc3cbc3f2ac2851 (patch) | |
| tree | cc700dd34961148aad099ecbd212e3b44328c09f /src/lib/libcrypto/crypto/getentropy_osx.c | |
| parent | dce9cb9c44c97b70cdffcdf4534a8db4b31f78ba (diff) | |
| download | openbsd-9dc40c4cb8a8d7a877ed1c8f5bc3cbc3f2ac2851.tar.gz openbsd-9dc40c4cb8a8d7a877ed1c8f5bc3cbc3f2ac2851.tar.bz2 openbsd-9dc40c4cb8a8d7a877ed1c8f5bc3cbc3f2ac2851.zip | |
Take away the use of the address of main as a source of entropy. Causes
distractions to people testing and seeing link errors in some setups.
This will come back in another form
ok deraadt@
Diffstat (limited to 'src/lib/libcrypto/crypto/getentropy_osx.c')
| -rw-r--r-- | src/lib/libcrypto/crypto/getentropy_osx.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lib/libcrypto/crypto/getentropy_osx.c b/src/lib/libcrypto/crypto/getentropy_osx.c index c7e09c78a5..3c4852e709 100644 --- a/src/lib/libcrypto/crypto/getentropy_osx.c +++ b/src/lib/libcrypto/crypto/getentropy_osx.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: getentropy_osx.c,v 1.4 2014/07/12 20:41:47 wouter Exp $ */ | 1 | /* $OpenBSD: getentropy_osx.c,v 1.5 2014/07/13 08:24:20 beck Exp $ */ |
| 2 | 2 | ||
| 3 | /* | 3 | /* |
| 4 | * Copyright (c) 2014 Theo de Raadt <deraadt@openbsd.org> | 4 | * Copyright (c) 2014 Theo de Raadt <deraadt@openbsd.org> |
| @@ -74,7 +74,9 @@ | |||
| 74 | 74 | ||
| 75 | int getentropy(void *buf, size_t len); | 75 | int getentropy(void *buf, size_t len); |
| 76 | 76 | ||
| 77 | #if 0 | ||
| 77 | extern int main(int, char *argv[]); | 78 | extern int main(int, char *argv[]); |
| 79 | #endif | ||
| 78 | static int gotdata(char *buf, size_t len); | 80 | static int gotdata(char *buf, size_t len); |
| 79 | static int getentropy_urandom(void *buf, size_t len); | 81 | static int getentropy_urandom(void *buf, size_t len); |
| 80 | static int getentropy_fallback(void *buf, size_t len); | 82 | static int getentropy_fallback(void *buf, size_t len); |
| @@ -292,7 +294,9 @@ getentropy_fallback(void *buf, size_t len) | |||
| 292 | HX(sigprocmask(SIG_BLOCK, NULL, &sigset) == -1, | 294 | HX(sigprocmask(SIG_BLOCK, NULL, &sigset) == -1, |
| 293 | sigset); | 295 | sigset); |
| 294 | 296 | ||
| 297 | #if 0 | ||
| 295 | HF(main); /* an addr in program */ | 298 | HF(main); /* an addr in program */ |
| 299 | #endif | ||
| 296 | HF(getentropy); /* an addr in this library */ | 300 | HF(getentropy); /* an addr in this library */ |
| 297 | HF(printf); /* an addr in libc */ | 301 | HF(printf); /* an addr in libc */ |
| 298 | p = (char *)&p; | 302 | p = (char *)&p; |
