summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Optionally add 0x to the start of the output string, in hashkeys.cDave Heller2018-01-161-0/+9
| | | | Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Fix regression from commit fb29954Dave Heller2018-01-121-1/+1
| | | | | | | In the mmap() bugfix patch, I reduced the scope of a variable below its required range. Reverting to the previous definition Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Merge pull request #19 from hellerda/add-get_date_stringhellerda2018-01-111-2/+14
|\ | | | | Add get_date_string() function to crtSignedContainer.sh
| * Add get_date_string() function to crtSignedContainer.shDave Heller2017-12-281-2/+14
| | | | | | | | | | | | | | On some systems (AIX) the date command does not support the '-d' option and there is no facility to convert numeric time to presentation format. The new function uses Perl as a fallback in this case. Thanks to Matt Vaught (mtvaught-ibm) for the suggestion.
* | Fix a few clang and cppcheck warningsDave Heller2018-01-102-1/+7
| | | | | | | | Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* | Adjust sig finding behavior in indpendent modeDave Heller2018-01-101-8/+29
|/ | | | | | | | In indpendent mode, there are cases where we want to look for signatures elsewhere in the cache, if not found in the local cache, that were not covered previously. Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Add basic support for independent signing modeDave Heller2017-12-271-10/+16
| | | | Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Nonzero value is the default test operationDave Heller2017-12-271-40/+40
| | | | | | | | Test for nonzero value is the default test operation in shell, so it's not necessary to use -n explicitly in tests. Removing them makes the code a bit more compact. Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Fix mmap() offset bug and mmap() error detection.Dave Heller2017-12-263-38/+69
| | | | | | | | | | | | Calls to mmap() with offset are problematic since offset must be on an even page boundary, which may vary between systems. Rather than adding code to handle this, it's easier to not use offset in this case. Also, the code should use MAP_FAILED instead of NULL, when chekcing mmap() rc. Also, this patch allows input payload to be omitted, in create-container.c Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Close all file descriptors on error exitDave Heller2017-12-261-1/+16
| | | | | | | | | When die() is called, close all open fd > 2 prior to exit. To keep it fast, only the first sixteen fds are checked, since there would unlikely be more than that. A more robust approach would be to check all up to FD_SETSIZE, as defined in select.h or typesizes.h Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Check return code from executables and fail on errorDave Heller2017-12-214-9/+33
| | | | Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Simplify checkKeys() and remove unused codeDave Heller2017-12-211-38/+22
| | | | Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Allow input payload and output image file to be omittedDave Heller2017-12-171-11/+10
| | | | | | | | | | In cases where input payload or output imagefile are not needed, we previously required __none to be specified for these properties. But really they can be omitted, and we can treat it as if __none were specified. Also, fix a shellcheck warning from a previous commit. Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Check availability of required programs before executionDave Heller2017-12-151-0/+13
| | | | | | | | Add a simple check to crtSignedContainer.sh to make sure basic tools, openssl commands, and other signtool and signframework executables are found in PATH, before proceeding. Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Fix some shellcheck warningsDave Heller2017-12-151-44/+55
| | | | | | | Fix some warnings from shellcheck static analyzer tool, in crtSignedContainer.sh, mostly regarding double-quoting Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Fix relative path handling for --archiveInDave Heller2017-12-081-4/+12
| | | | Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Adjust previous patch to reorganize includesDave Heller2017-12-053-0/+6
| | | | | | | | | | I was unclear on this previously, but apparently the right way is to include config.h in all files (ref: https://sourceware.org/autobook/autobook/ autobook_66.html#Installing-Header-Files) as the first entry, before any other header file (ref: https://www.gnu.org/software/autoconf/manual/ autoconf-2.66/html_node/Configuration-Headers.html). Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Cleanup, reorganize includesDave Heller2017-12-025-62/+61
| | | | Signed-off-by: Dave Heller <hellerda@linux.vnet.ibm.com>
* Make SB_VERBOSE, SB_DEBUG, SB_WRAP settable by environmentDave Heller2017-10-291-11/+8
| | | | | | Helpful for execution under op-build, where command line options are not exposed. Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* start of 0.4Dave Heller2017-10-221-1/+1
|
* prep for 0.3 releasev0.3Dave Heller2017-10-221-1/+1
|
* Remove all implicit initializationsDave Heller2017-10-213-5/+5
| | | | | | To quash warnings from very picky compilers Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Handle filepaths with spaces for make install liteDave Heller2017-10-181-4/+4
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Use eval instead of declare in bashDave Heller2017-10-181-1/+1
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Fix behavior of __getkeyDave Heller2017-10-131-2/+2
| | | | | | | On __getkey, the behavior should be to integrate a signature if found, but skip the request if not found. Currently it skips both. Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Fix careless setting of IFSDave Heller2017-10-131-0/+1
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Merge branch 'hellerda-archveIn-support-comma-delimted-list'Dave Heller2017-10-111-8/+16
|\
| * Support comma delimted list for --archiveInDave Heller2017-10-111-8/+16
|/ | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Change cmdline options --hwPrivKeyX to --hwKeyX (part 1)Dave Heller2017-10-101-6/+12
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Add hashkeys.c utility programDave Heller2017-10-104-11/+317
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Merge pull request #11 from hellerda/container-header-outhellerda2017-10-102-24/+47
|\ | | | | Add --contrHdrOut option to crtSignedContainer.sh
| * Add --contrHdrOut option to crtSignedContainer.shDave Heller2017-10-082-24/+47
| | | | | | | | Adds option to dump the container header (first 4k) without the payload.
* | Merge pull request #10 from hellerda/make-signproject-names-configurablehellerda2017-10-101-16/+33
|\ \ | |/ |/| Make signproject base names configurable via env or INI
| * Make signproject base names configurable via env or INIDave Heller2017-10-061-16/+33
| | | | | | | | | | | | | | | | | | | | This patch allows signframework project basenames to be settable via env or INI. There are three new env properties: SF_HW_SIGNING_PROJECT_BASE, SF_FW_SIGNING_PROJECT_BASE and SF_GETPUBKEY_PROJECT_BASE. In the INI, there are three new properties under a new section [signproject]. The defaults are the values that were previously hardcoded. Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* | Fixup previous commitDave Heller2017-10-071-2/+1
| | | | | | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* | Allow input payload and output image file to be emptyDave Heller2017-10-061-1/+12
| | | | | | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* | Fix validator handling of null keysDave Heller2017-10-061-17/+43
|/ | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Add --archiveIn and --archiveOut options to crtSignedContainer.shDave Heller2017-09-301-3/+97
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Fix handling of filepaths containing spacesDave Heller2017-09-291-44/+50
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Support special input key value: __getsigDave Heller2017-09-291-2/+4
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Support special input key values: __skip, __get, __getkeyDave Heller2017-09-231-21/+114
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Make --scratchDir a configurable optionDave Heller2017-09-211-10/+15
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Simplify config property processingDave Heller2017-09-191-66/+75
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Add INI file supportDave Heller2017-09-071-27/+89
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Add simple make install/uninstall to lite method of buildingDave Heller2017-08-302-0/+33
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Add basic support for Production mode in op-buildDave Heller2017-08-291-78/+231
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Add support for input of signatures in RAW format to create-container.cDave Heller2017-08-262-20/+34
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Allow (and truncate) labels longer than 8 charsDave Heller2017-08-243-3/+4
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Add support for Component ID (container label)Dave Heller2017-08-244-20/+77
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
* Add support for input of pubkeys in RAW format to create-container.cDave Heller2017-08-161-31/+68
| | | | Signed-off-by: Dave Heller <hellerda@us.ibm.com>
OpenPOWER on IntegriCloud