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

Side by Side Diff: src/platform/vboot_reference/vkernel/include/kernel_image.h

Issue 2283005: Modifying the kernel_utility tool to create our magic blob. (Closed) Base URL: ssh://git@chromiumos-git/chromeos
Patch Set: respond to feedback Created 10 years, 6 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 generating and manipulating verified boot kernel images . 5 * API definitions for a generating and manipulating verified boot kernel images .
6 * (Userland portion.) 6 * (Userland portion.)
7 */ 7 */
8 8
9 #ifndef VBOOT_REFERENCE_KERNEL_IMAGE_H_ 9 #ifndef VBOOT_REFERENCE_KERNEL_IMAGE_H_
10 #define VBOOT_REFERENCE_KERNEL_IMAGE_H_ 10 #define VBOOT_REFERENCE_KERNEL_IMAGE_H_
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 56
57 /* Write kernel data from [image] to a file named [input_file]. 57 /* Write kernel data from [image] to a file named [input_file].
58 * If [is_only_vblock] is non-zero, only the verification block is output. 58 * If [is_only_vblock] is non-zero, only the verification block is output.
59 * 59 *
60 * Return 1 on success, 0 on error. 60 * Return 1 on success, 0 on error.
61 */ 61 */
62 int WriteKernelImage(const char* input_file, 62 int WriteKernelImage(const char* input_file,
63 const KernelImage* image, 63 const KernelImage* image,
64 int is_only_vblock); 64 int is_only_vblock);
65 65
66 /* Create a kernel_data blob from its components and fill
67 * its length into blob_len, plus some information about the bootloader.
68 *
69 * Caller owns the returned pointer and must Free() it.
70 */
71 uint8_t* GenerateKernelBlob(const char* vmlinuz_file,
72 const char* config_file,
73 const char* bootloader_file,
74 uint64_t* blob_len,
75 uint64_t* bootloader_offset,
76 uint64_t* bootloader_size);
77
66 /* Pretty print the contents of [image]. Only headers and metadata information 78 /* Pretty print the contents of [image]. Only headers and metadata information
67 * is printed. 79 * is printed.
68 */ 80 */
69 void PrintKernelImage(const KernelImage* image); 81 void PrintKernelImage(const KernelImage* image);
70 82
71 /* Performs a chained verify of the kernel [image]. If [dev_mode] is 83 /* Performs a chained verify of the kernel [image]. If [dev_mode] is
72 * 0 (inactive), then the [firmware_signing_key] is used to verify the signature 84 * 0 (inactive), then the [firmware_signing_key] is used to verify the signature
73 * of the signing key, else the check is skipped. 85 * of the signing key, else the check is skipped.
74 * 86 *
75 * Returns 0 on success, error code on failure. 87 * Returns 0 on success, error code on failure.
(...skipping 17 matching lines...) Expand all
93 * using the private signing key in file [kernel_sigining_key_file]. 105 * using the private signing key in file [kernel_sigining_key_file].
94 * 106 *
95 * Return 1 on success, 0 on failure. 107 * Return 1 on success, 0 on failure.
96 */ 108 */
97 int AddKernelSignature(KernelImage* image, 109 int AddKernelSignature(KernelImage* image,
98 const char* kernel_sigining_key_file); 110 const char* kernel_sigining_key_file);
99 111
100 void PrintKernelEntry(kernel_entry* entry); 112 void PrintKernelEntry(kernel_entry* entry);
101 113
102 #endif /* VBOOT_REFERENCE_KERNEL_IMAGE_H_ */ 114 #endif /* VBOOT_REFERENCE_KERNEL_IMAGE_H_ */
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698