diff options
| author | Gary Ching-Pang Lin <glin@suse.com> | 2013-07-04 16:12:30 +0800 |
|---|---|---|
| committer | Peter Jones <pjones@redhat.com> | 2013-09-26 11:58:02 -0400 |
| commit | 681082e6c4722bfbc4d8b4b651d62bf139c3df6b (patch) | |
| tree | 027d7165aa078acceafaf22357a314ee6015acc2 /Cryptlib/Rand/CryptRand.c | |
| parent | 9fd4e4a54e1642c9f1f45f6d68c176e92a7a1bfb (diff) | |
| download | efi-boot-shim-681082e6c4722bfbc4d8b4b651d62bf139c3df6b.tar.gz efi-boot-shim-681082e6c4722bfbc4d8b4b651d62bf139c3df6b.zip | |
Rand: check the status of the pseudorandom number generator
Diffstat (limited to 'Cryptlib/Rand/CryptRand.c')
| -rw-r--r-- | Cryptlib/Rand/CryptRand.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Cryptlib/Rand/CryptRand.c b/Cryptlib/Rand/CryptRand.c index 4b275951..a61c0c2a 100644 --- a/Cryptlib/Rand/CryptRand.c +++ b/Cryptlib/Rand/CryptRand.c @@ -53,7 +53,11 @@ RandomSeed ( RAND_seed (DefaultSeed, sizeof (DefaultSeed));
}
- return TRUE;
+ if (RAND_status () == 1) {
+ return TRUE;
+ }
+
+ return FALSE;
}
/**
|
