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

Side by Side Diff: src/platform/vboot_reference/vfirmware/include/firmware_image.h

Issue 2366004: Add --subkey_in and --subkey_out options to firmware signing utility. (Closed) Base URL: ssh://git@gitrw.chromium.org/chromiumos
Patch Set: Created 10 years, 7 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 unified diff | Download patch
OLDNEW
1 /* Copyright (c) 2010 The Chromium OS Authors. All rights reserved. 1 /* Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
2 * Use of this source code is governed by a BSD-style license that can be 2 * Use of this source code is governed by a BSD-style license that can be
3 * found in the LICENSE file. 3 * found in the LICENSE file.
4 * 4 *
5 * API definitions for a verified boot firmware image. 5 * API definitions for a verified boot firmware image.
6 * (Userland Portion) 6 * (Userland Portion)
7 */ 7 */
8 8
9 #ifndef VBOOT_REFERENCE_FIRMWARE_IMAGE_H_ 9 #ifndef VBOOT_REFERENCE_FIRMWARE_IMAGE_H_
10 #define VBOOT_REFERENCE_FIRMWARE_IMAGE_H_ 10 #define VBOOT_REFERENCE_FIRMWARE_IMAGE_H_
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 49
50 /* Get a verified firmware binary blob from an [image] and fill its 50 /* Get a verified firmware binary blob from an [image] and fill its
51 * length into blob_len. 51 * length into blob_len.
52 * 52 *
53 * Caller owns the returned pointer and must Free() it. 53 * Caller owns the returned pointer and must Free() it.
54 */ 54 */
55 uint8_t* GetFirmwareBlob(const FirmwareImage* image, uint64_t* blob_len); 55 uint8_t* GetFirmwareBlob(const FirmwareImage* image, uint64_t* blob_len);
56 56
57 /* Write firmware data from [image] into a file named [input_file]. 57 /* Write firmware data from [image] into a file named [input_file].
58 * 58 *
59 * If [is_just_vblock] is 1, only the verification block (excluding the 59 * If [is_just_vblock] is non-zero, only the verification block (excluding the
60 * actual firmware_data) is written. 60 * actual firmware_data) is output.
61 * if [is_subkey_out] is non-zero, only the firmware key verification (subkey)
62 * header is output.
63 *
61 * Return 1 on success, 0 on failure. 64 * Return 1 on success, 0 on failure.
62 */ 65 */
63 int WriteFirmwareImage(const char* input_file, 66 int WriteFirmwareImage(const char* input_file,
64 const FirmwareImage* image, 67 const FirmwareImage* image,
65 int is_only_vblock); 68 int is_only_vblock,
69 int is_subkey_out);
66 70
67 /* Pretty print the contents of [image]. Only headers and metadata information 71 /* Pretty print the contents of [image]. Only headers and metadata information
68 * is printed. 72 * is printed.
69 */ 73 */
70 void PrintFirmwareImage(const FirmwareImage* image); 74 void PrintFirmwareImage(const FirmwareImage* image);
71 75
72 /* Performs a chained verify of the firmware [image]. 76 /* Performs a chained verify of the firmware [image].
73 * 77 *
74 * Returns 0 on success, error code on failure. 78 * Returns 0 on success, error code on failure.
75 */ 79 */
(...skipping 11 matching lines...) Expand all
87 int AddFirmwareKeySignature(FirmwareImage* image, const char* root_key_file); 91 int AddFirmwareKeySignature(FirmwareImage* image, const char* root_key_file);
88 92
89 /* Add firmware and preamble signature to a firmware image [image] 93 /* Add firmware and preamble signature to a firmware image [image]
90 * using the private signing key in file [signing_key_file]. 94 * using the private signing key in file [signing_key_file].
91 * 95 *
92 * Return 1 on success, 0 on failure. 96 * Return 1 on success, 0 on failure.
93 */ 97 */
94 int AddFirmwareSignature(FirmwareImage* image, const char* signing_key_file); 98 int AddFirmwareSignature(FirmwareImage* image, const char* signing_key_file);
95 99
96 #endif /* VBOOT_REFERENCE_FIRMWARE_IMAGE_H_ */ 100 #endif /* VBOOT_REFERENCE_FIRMWARE_IMAGE_H_ */
OLDNEW
« no previous file with comments | « src/platform/vboot_reference/vfirmware/firmware_image.c ('k') | src/platform/vboot_reference/vkernel/include/kernel_image.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698