Hi Garey,

On Thu, May 31, 2012 at 3:37 PM, Garey Mills
<[email protected]> wrote:
> Hello -
>
>     I am trying to use TPM for random number generation to supply
> /dev/random. I have owned the TPM, shut off tcsd, and I try to run
>
> /sbin/rngd -r /dev/tpm0 -o /dev/random -t 1
>
> I get 'read error' two times and rngd exits.
>
>     Am I doing something wrong?

  /dev/tpm0 is the interface that the tcsd opens in order to send
specially crafted requests to the TPM for specific TPM actions.
Generating random numbers is just one of those actions.  To achieve
what you're trying to do, you need an application that talks either
directly to /dev/tpm0 (such as those included in the ibm software tpm
utils, from [1]), or an application that uses the TSS [2],  to read
random numbers from the tpm and send them to stdout.  Then you'd point
rngd to one of those apps.

Kent

[1] https://sourceforge.net/projects/ibmswtpm/
[2] 
http://trousers.git.sourceforge.net/git/gitweb.cgi?p=trousers/testsuite;a=blob;f=tcg/tpm/Tspi_TPM_GetRandom01.c

> --
> Garey Mills
> Library Systems Office
> UC Berkeley
>
>
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> TrouSerS-tech mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/trousers-tech



-- 
IBM LTC Security

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
TrouSerS-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/trousers-tech

Reply via email to