]> git.proxmox.com Git - mirror_edk2.git/commit
CryptoPkg: Fix integer overflow
authorYuan Yu <yuanyu@google.com>
Wed, 28 Sep 2022 07:49:24 +0000 (15:49 +0800)
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Mon, 10 Oct 2022 00:58:26 +0000 (00:58 +0000)
commit3c9e2f239a38590b4e3a8c1ec2304227f2af0103
tree8bd495b5f9bf941cf620f32e9fb235118735fb8f
parentde103f1981cfca90dd19296d4b20449a2b93dc26
CryptoPkg: Fix integer overflow

SECSPERDAY is 86400 which exceeds the limit of a UINT16 which is 65536.
Therefore DayRemainder cannot use UINT16. This patch makes it UINT32.

Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Cc: Anthony Perard <anthony.perard@citrix.com>
Cc: Julien Grall <julien@xen.org>
Signed-off-by: Yuan Yu <yuanyu@google.com>
Reviewed-by: Ard Biesheuvel <ardb+tianocore@kernel.org>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
CryptoPkg/Library/BaseCryptLib/SysCall/TimerWrapper.c