Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CryptoPkg: Fix integer overflow #3456

Merged
merged 1 commit into from
Oct 10, 2022
Merged

CryptoPkg: Fix integer overflow #3456

merged 1 commit into from
Oct 10, 2022

Conversation

jyao1
Copy link
Contributor

@jyao1 jyao1 commented Oct 10, 2022

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

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>
@jyao1 jyao1 added the push Auto push patch series in PR if all checks pass label Oct 10, 2022
@mergify mergify bot merged commit 3c9e2f2 into tianocore:master Oct 10, 2022
@jyao1 jyao1 deleted the patch branch October 10, 2022 01:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
push Auto push patch series in PR if all checks pass
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants