Find a file
Steve McIntyre 0dc3d4b521 Fix PE/COFF checksum calculation
Only count the cert_table header once when performing the calculation
and counting buffer sizes.

The problem entered because of a mismerge of multiple signature
support and "be1f3d8 Update the PE checksum field using the
somewhat-underdocumented algorithm, so that we match the Microsoft
implementation in our signature generation.".  Originally
image->cert_table held the full certificate table including the
Microsoft _WINH_CERTIFICATE header and image->sigbuf pointed to the
pkcs11 signature inside, so the two had to be checksummed separately.
After multiple signature support, image->sigbuf points to the full
certificate table because we now need the headers to decide where one
signature ends and the next begins, so the correct checksum only needs
to sum over the entire image->sigbuf.

Signed-off-by: Steve McIntyre <93sam@debian.org>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2019-07-27 15:20:49 -07:00
docs docs: Create man pages for sbvarsign & sbsiglist 2012-08-13 15:10:21 +08:00
lib autoconfiscate 2012-05-28 22:35:48 +08:00
src Fix PE/COFF checksum calculation 2019-07-27 15:20:49 -07:00
tests Fix Fedora Build 2018-02-20 15:36:19 -05:00
.gitmodules Move ccan submodule 2012-05-24 15:17:18 +08:00
autogen.sh Update the PE checksum field using the somewhat-underdocumented 2016-01-27 11:38:00 -08:00
configure.ac Version 0.9.2 2019-01-09 16:09:37 -08:00
COPYING license: Add OpenSSL exception to GPLv3 terms 2012-06-28 15:06:31 +08:00
LICENSE.GPLv3 license: Add OpenSSL exception to GPLv3 terms 2012-06-28 15:06:31 +08:00
Makefile.am Move sources to src/ subdirectory 2012-08-13 15:10:21 +08:00
NEWS sbkeysync: change default efivarfs mountpoint to /sys/.../efivars/ 2012-10-08 12:07:43 +08:00
README autoconfiscate 2012-05-28 22:35:48 +08:00

sbsigntool - Signing utility for UEFI secure boot

  Copyright (C) 2102 Jeremy Kerr <jeremy.kerr@canonical.com>

  Copying and distribution of this file, with or without modification,
  are permitted in any medium without royalty provided the copyright
  notice and this notice are preserved.

See file ./INSTALL for building and installation instructions.

Main git repository:
  git://kernel.ubuntu.com/jk/sbsigntool.git

sbsigntool is free software.  See the file COPYING for copying conditions.