![]() |
![]() |
#1 |
Nov 2003
164448 Posts |
![]()
Does VC++ provide any kind of API or system call that allows
one to access the hardware RNG in an Intel i3/i5/i7 processor? Does one need the Microsoft Crypto API (CAPI) or the Next Generation API (CNG) to do this? |
![]() |
![]() |
![]() |
#2 |
(loop (#_fork))
Feb 2006
Cambridge, England
638210 Posts |
![]()
It looks as if CryptGenRandom from the cryptography API might do what you want ... the random number generator is only really accessible from kernel space (I've had a look at the Linux code for collecting random numbers, which does all sorts of weird PCI I/O operations).
http://msdn.microsoft.com/en-us/libr...(v=vs.85).aspx is the CryptAcquireContext call which you need to make in order to get a handle which you can pass to CryptGenRandom. |
![]() |
![]() |
![]() |
#3 | |
Undefined
"The unspeakable one"
Jun 2006
My evil lair
7×11×79 Posts |
![]() Quote:
http://spectrum.ieee.org/computing/h...er-generator/0 Last fiddled with by retina on 2011-09-15 at 16:27 Reason: Linkies are always nice |
|
![]() |
![]() |
![]() |
#4 | |
Nov 2003
164448 Posts |
![]() Quote:
the (yet to be released) Ivy Bridge processor. What about the intrinsic: _rdrand_u32() Is this available under VC++? What .dll or .lib needs to be linked? |
|
![]() |
![]() |
![]() |
#5 | |
Bamboozled!
"𒉺𒌌𒇷𒆷ð’€"
May 2003
Down not across
25·331 Posts |
![]() Quote:
What problem are you trying to solve? How good, according to appropriate metrics such as speed, portability, and estimated entropy, does your RNG need to be? Given the answers, we may be able to give more precisely targeted advice. Paul |
|
![]() |
![]() |
![]() |
#6 | |
Nov 2003
22·5·373 Posts |
![]() Quote:
issue in case I need to implement a Von-Neumann unbiaser. I will make as many calls as I need to get the require number of entropy bits. Of course I will not use them directly as a source of randomness; they will be passed through a non-linear filter before use. |
|
![]() |
![]() |
![]() |
#7 |
(loop (#_fork))
Feb 2006
Cambridge, England
2·3,191 Posts |
![]() |
![]() |
![]() |
![]() |
#8 | |
(loop (#_fork))
Feb 2006
Cambridge, England
2×3,191 Posts |
![]() Quote:
|
|
![]() |
![]() |
![]() |
#11 | ||
Aug 2006
2·29·103 Posts |
![]() Quote:
Quote:
Last fiddled with by CRGreathouse on 2011-09-15 at 21:44 |
||
![]() |
![]() |
![]() |
Thread Tools | |
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Unknown Intel | fidelitas | Information & Answers | 4 | 2014-08-20 18:36 |
AMD vs Intel | dtripp | Software | 3 | 2013-02-19 20:20 |
Intel NUC | nucleon | Hardware | 2 | 2012-05-10 23:53 |
AMD or Intel | mack | Information & Answers | 7 | 2009-09-13 01:48 |
Intel Mac? | penguain | NFSNET Discussion | 0 | 2006-06-12 01:31 |