summaryrefslogtreecommitdiff
path: root/CryptoPkg/Private/Protocol
diff options
context:
space:
mode:
authorHao A Wu <hao.a.wu@intel.com>2019-06-28 14:15:55 +0800
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2020-02-07 07:58:35 +0000
commit322ac05f8bbc1bce066af1dabd1b70ccdbe28891 (patch)
tree13c75fa935dc890f8191f7f131c7683fb8065742 /CryptoPkg/Private/Protocol
parent1333d8c8d37ab8a8055c8da0d9ab79005225536b (diff)
downloadedk2-322ac05f8bbc1bce066af1dabd1b70ccdbe28891.zip
edk2-322ac05f8bbc1bce066af1dabd1b70ccdbe28891.tar.gz
edk2-322ac05f8bbc1bce066af1dabd1b70ccdbe28891.tar.bz2
MdeModulePkg/PiDxeS3BootScriptLib: Fix potential numeric truncation (CVE-2019-14563)
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2001 For S3BootScriptLib APIs: S3BootScriptSaveIoWrite S3BootScriptSaveMemWrite S3BootScriptSavePciCfgWrite S3BootScriptSavePciCfg2Write S3BootScriptSaveSmbusExecute S3BootScriptSaveInformation S3BootScriptSaveInformationAsciiString S3BootScriptLabel (happen in S3BootScriptLabelInternal()) possible numeric truncations will happen that may lead to S3 boot script entry with improper size being returned to store the boot script data. This commit will add checks to prevent this kind of issue. Please note that the remaining S3BootScriptLib APIs: S3BootScriptSaveIoReadWrite S3BootScriptSaveMemReadWrite S3BootScriptSavePciCfgReadWrite S3BootScriptSavePciCfg2ReadWrite S3BootScriptSaveStall S3BootScriptSaveDispatch2 S3BootScriptSaveDispatch S3BootScriptSaveMemPoll S3BootScriptSaveIoPoll S3BootScriptSavePciPoll S3BootScriptSavePci2Poll S3BootScriptCloseTable S3BootScriptExecute S3BootScriptMoveLastOpcode S3BootScriptCompare are not affected by such numeric truncation. Signed-off-by: Hao A Wu <hao.a.wu@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Eric Dong <eric.dong@intel.com> Acked-by: Jian J Wang <jian.j.wang@intel.com>
Diffstat (limited to 'CryptoPkg/Private/Protocol')
0 files changed, 0 insertions, 0 deletions