Fix signature checking

We could potentially find a valid signature and then fail to validate it
due to not breaking out of the outer while loop.
This commit is contained in:
Matthew Garrett 2012-11-01 10:31:14 -04:00
parent 6f16162653
commit 058c0368ad

3
shim.c
View File

@ -237,6 +237,9 @@ static CHECK_STATUS check_db_cert_in_ram(EFI_SIGNATURE_LIST *CertList,
Cert = (EFI_SIGNATURE_DATA *) ((UINT8 *) Cert + CertList->SignatureSize);
}
if (IsFound)
break;
dbsize -= CertList->SignatureListSize;
CertList = (EFI_SIGNATURE_LIST *) ((UINT8 *) CertList + CertList->SignatureListSize);
}