Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
mok: Avoid underflow in maximum variable size calculation
The code that mirrors MOK database to EFI variables gets the remaining variable storage size from the firmware and subtracts the size needed for any overhead to see if there is enough space to create a new entry. However these calculations are on unsigned integer types, they can underflow and result in huge values when the firmware is about to run out of usable variable space. Explicitly check against this. Signed-off-by: Alper Nebi Yasak <[email protected]>
- Loading branch information