mirror_edk2/BaseTools/Source/Python/Common
Kinney, Michael D 8b63877aca BaseTools/Capsule: Add Capsule Generation Tools
https://bugzilla.tianocore.org/show_bug.cgi?id=945

Based on content from the following branch

https://github.com/Microsoft/MS_UEFI/tree/share/beta/CapsuleTools

* Convert C tools to Python
* Add common python modules to:
    BaseTools/Source/Python/Common/Uefi/Capsule
    BaseTools/Source/Python/Common/Edk2/Capsule
* Add GenerateCapsule.py to BaseTools/Source/Python/Capsule
* Add Windows and Posix wrappers for GenerateCapsule.py

usage: GenerateCapsule [-h] [-o OUTPUTFILE] (-e | -d | --dump-info)
                       [--capflag {PersistAcrossReset,PopulateSystemTable,InitiateReset}]
                       [--capoemflag CAPSULEOEMFLAG] [--guid GUID]
                       [--hardware-instance HARDWAREINSTANCE]
                       [--monotonic-count MONOTONICCOUNT]
                       [--fw-version FWVERSION] [--lsv LOWESTSUPPORTEDVERSION]
                       [--pfx-file SIGNTOOLPFXFILE]
                       [--signer-private-cert OPENSSLSIGNERPRIVATECERTFILE]
                       [--other-public-cert OPENSSLOTHERPUBLICCERTFILE]
                       [--trusted-public-cert OPENSSLTRUSTEDPUBLICCERTFILE]
                       [--signing-tool-path SIGNINGTOOLPATH] [--version] [-v]
                       [-q] [--debug [0-9]]
                       InputFile

Generate a capsule. Copyright (c) 2018, Intel Corporation. All rights
reserved.

positional arguments:
  InputFile             Input binary payload filename.

optional arguments:
  -h, --help            show this help message and exit
  -o OUTPUTFILE, --output OUTPUTFILE
                        Output filename.
  -e, --encode          Encode file
  -d, --decode          Decode file
  --dump-info           Display FMP Payload Header information
  --capflag {PersistAcrossReset,PopulateSystemTable,InitiateReset}
                        Capsule flag can be PersistAcrossReset, or
                        PopulateSystemTable or InitiateReset or not set
  --capoemflag CAPSULEOEMFLAG
                        Capsule OEM Flag is an integer between 0x0000 and
                        0xffff.
  --guid GUID           The FMP/ESRT GUID in registry format. Required for
                        encode operations.
  --hardware-instance HARDWAREINSTANCE
                        The 64-bit hardware instance. The default is
                        0x0000000000000000
  --monotonic-count MONOTONICCOUNT
                        64-bit monotonic count value in header. Default is
                        0x0000000000000000.
  --fw-version FWVERSION
                        The 32-bit version of the binary payload (e.g.
                        0x11223344 or 5678).
  --lsv LOWESTSUPPORTEDVERSION
                        The 32-bit lowest supported version of the binary
                        payload (e.g. 0x11223344 or 5678).
  --pfx-file SIGNTOOLPFXFILE
                        signtool PFX certificate filename.
  --signer-private-cert OPENSSLSIGNERPRIVATECERTFILE
                        OpenSSL signer private certificate filename.
  --other-public-cert OPENSSLOTHERPUBLICCERTFILE
                        OpenSSL other public certificate filename.
  --trusted-public-cert OPENSSLTRUSTEDPUBLICCERTFILE
                        OpenSSL trusted public certificate filename.
  --signing-tool-path SIGNINGTOOLPATH
                        Path to signtool or OpenSSL tool. Optional if path to
                        tools are already in PATH.
  --version             show program's version number and exit
  -v, --verbose         Turn on verbose output with informational messages
                        printed, including capsule headers and warning
                        messages.
  -q, --quiet           Disable all messages except fatal errors.
  --debug [0-9]         Set debug level

Cc: Sean Brogan <sean.brogan@microsoft.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Yonghong Zhu <yonghong.zhu@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com>
Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
2018-08-02 14:35:20 -07:00
..
Edk2 BaseTools/Capsule: Add Capsule Generation Tools 2018-08-02 14:35:20 -07:00
Uefi BaseTools/Capsule: Add Capsule Generation Tools 2018-08-02 14:35:20 -07:00
__init__.py Sync EDKII BaseTools to BaseTools project r1971 2010-05-18 05:04:32 +00:00
BuildToolError.py BaseTools: introduce !error statement 2018-06-22 13:38:40 +08:00
BuildVersion.py BaseTools: Clean up source files 2018-07-09 10:25:47 +08:00
Database.py BaseTools: Use absolute import in Common 2018-07-16 11:22:16 +08:00
DataType.py BaseTools: Adjust the spaces around commas and colons 2018-06-27 16:33:25 +08:00
EdkLogger.py BaseTools: Use absolute import in Common 2018-07-16 11:22:16 +08:00
Expression.py BaseTools: Use absolute import in Common 2018-07-16 11:22:16 +08:00
GlobalData.py BaseTool: Add cache for the result of SkipAutogen. 2018-07-09 10:28:08 +08:00
Identification.py Sync EDKII BaseTools to BaseTools project r1971 2010-05-18 05:04:32 +00:00
LongFilePathOs.py BaseTools: Use absolute import in Common 2018-07-16 11:22:16 +08:00
LongFilePathOsPath.py BaseTools: Update Build tool to support multiple workspaces 2015-10-08 09:27:14 +00:00
LongFilePathSupport.py BaseTools/Ecc: Add a checkpoint for invalid UNI file. 2015-06-25 07:50:55 +00:00
Misc.py BaseTools: Use pickle to replace cPickle 2018-08-02 15:12:34 +08:00
MultipleWorkspace.py BaseTools: Clean up source files 2018-07-09 10:25:47 +08:00
Parsing.py BaseTools: Use absolute import in Common 2018-07-16 11:22:16 +08:00
PyUtility.pyd Sync BaseTool trunk (version r2599) into EDKII BaseTools. 2013-08-23 02:18:16 +00:00
RangeExpression.py BaseTools: Clean up source files 2018-07-09 10:25:47 +08:00
StringUtils.py BaseTools: Use absolute import in Common 2018-07-16 11:22:16 +08:00
TargetTxtClassObject.py BaseTools: Use absolute import in Common 2018-07-16 11:22:16 +08:00
ToolDefClassObject.py BaseTools: Use absolute import in Common 2018-07-16 11:22:16 +08:00
VariableAttributes.py BaseTools: Clean up source files 2018-07-09 10:25:47 +08:00
VpdInfoFile.py BaseTools: Clean up source files 2018-07-09 10:25:47 +08:00