verifiers: File type for fine-grained signature-verification controlling
Let's provide file type info to the I/O layer. This way verifiers framework and its users will be able to differentiate files and verify only required ones. This is preparatory patch. Signed-off-by: Vladimir Serbinenko <phcoder@gmail.com> Signed-off-by: Daniel Kiper <daniel.kiper@oracle.com> Reviewed-by: Ross Philipson <ross.philipson@oracle.com>
This commit is contained in:
parent
e1bc2b23f1
commit
aebe31c375
70 changed files with 292 additions and 221 deletions
|
@ -648,7 +648,7 @@ grub_cmd_xen (grub_command_t cmd __attribute__ ((unused)),
|
|||
(char *) xen_state.next_start.cmd_line,
|
||||
sizeof (xen_state.next_start.cmd_line) - 1);
|
||||
|
||||
file = grub_file_open (argv[0]);
|
||||
file = grub_file_open (argv[0], GRUB_FILE_TYPE_LINUX_KERNEL);
|
||||
if (!file)
|
||||
return grub_errno;
|
||||
|
||||
|
@ -895,9 +895,8 @@ grub_cmd_module (grub_command_t cmd __attribute__ ((unused)),
|
|||
|
||||
xen_state.max_addr = ALIGN_UP (xen_state.max_addr, PAGE_SIZE);
|
||||
|
||||
if (nounzip)
|
||||
grub_file_filter_disable_compression ();
|
||||
file = grub_file_open (argv[0]);
|
||||
file = grub_file_open (argv[0], GRUB_FILE_TYPE_LINUX_INITRD |
|
||||
(nounzip ? GRUB_FILE_TYPE_NO_DECOMPRESS : GRUB_FILE_TYPE_NONE));
|
||||
if (!file)
|
||||
return grub_errno;
|
||||
size = grub_file_size (file);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue