Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 926487 Details for
Bug 786837
rngd does not check status when communicating with the TPM
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
patch to check tpm return code
rngd.patch (text/plain), 972 bytes, created by
Neil Horman
on 2014-08-13 15:30:49 UTC
(
hide
)
Description:
patch to check tpm return code
Filename:
MIME Type:
Creator:
Neil Horman
Created:
2014-08-13 15:30:49 UTC
Size:
972 bytes
patch
obsolete
>diff -up ./rngd_entsource.c.tpm ./rngd_entsource.c >--- ./rngd_entsource.c.tpm 2014-08-13 11:20:34.908788976 -0400 >+++ ./rngd_entsource.c 2014-08-13 11:27:37.350769043 -0400 >@@ -85,6 +85,7 @@ int xread_tpm(void *buf, size_t size, st > 0, 0, 0, 0, /* number of bytes to return */ > }; > char *offset; >+ int *tpm_return = NULL; > > ent_src->rng_fd = open(ent_src->rng_name, O_RDWR); > if (ent_src->rng_fd == -1) { >@@ -125,6 +126,16 @@ int xread_tpm(void *buf, size_t size, st > goto error_out; > } > r = read(ent_src->rng_fd, temp_buf,size); >+ /* >+ * check the return code of the command to make sure >+ * the rng is working properly >+ * The return code is 6 bytes into the output header >+ */ >+ tpm_return = (int *)(temp_buf + 6); >+ retval = *tpm_return; >+ if (retval) >+ goto error_out; >+ > r = (r - TPM_GET_RNG_OVERHEAD); > bytes_read = bytes_read + r; > if (bytes_read > size) {
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 786837
: 926487