Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1470)

Unified Diff: utility/vbutil_firmware.c

Issue 3027009: Added size param to VerifyData() (Closed) Base URL: ssh://gitrw.chromium.org/vboot_reference.git
Patch Set: Created 10 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/vboot_common3_tests.c ('k') | utility/vbutil_kernel.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utility/vbutil_firmware.c
diff --git a/utility/vbutil_firmware.c b/utility/vbutil_firmware.c
index cdeed265ce229810aca8f0388250ecde9e694eac..3992a3a8b6d9d61c43819070b169d47d3eab1f41 100644
--- a/utility/vbutil_firmware.c
+++ b/utility/vbutil_firmware.c
@@ -224,7 +224,7 @@ static int Verify(const char* infile, const char* signpubkey,
/* Verify preamble */
preamble = (VbFirmwarePreambleHeader*)(blob + now);
- if (0 != VerifyFirmwarePreamble2(preamble, blob_size - now, rsa)) {
+ if (0 != VerifyFirmwarePreamble(preamble, blob_size - now, rsa)) {
error("Error verifying preamble.\n");
return 1;
}
@@ -247,7 +247,7 @@ static int Verify(const char* infile, const char* signpubkey,
/* TODO: verify body size same as signature size */
/* Verify body */
- if (0 != VerifyData(fv_data, &preamble->body_signature, rsa)) {
+ if (0 != VerifyData(fv_data, fv_size, &preamble->body_signature, rsa)) {
error("Error verifying firmware body.\n");
return 1;
}
« no previous file with comments | « tests/vboot_common3_tests.c ('k') | utility/vbutil_kernel.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698