1
0
Fork 0

pefile: Handle pesign using the wrong OID

The pesign utility had a bug where it was using OID_msIndividualSPKeyPurpose
instead of OID_msPeImageDataObjId - so allow both OIDs.

Signed-off-by: Vivek Goyal <vgoyal@redhat.com>
Acked-by: Vivek Goyal <vgoyal@redhat.com>
hifive-unleashed-5.1
Vivek Goyal 2014-07-08 18:10:46 +01:00 committed by David Howells
parent 4c0b4b1d1a
commit dd7d66f21b
1 changed files with 7 additions and 1 deletions

View File

@ -58,7 +58,13 @@ int mscode_note_content_type(void *context, size_t hdrlen,
return -EBADMSG;
}
if (oid != OID_msIndividualSPKeyPurpose) {
/*
* pesign utility had a bug where it was putting
* OID_msIndividualSPKeyPurpose instead of OID_msPeImageDataObjId
* So allow both OIDs.
*/
if (oid != OID_msPeImageDataObjId &&
oid != OID_msIndividualSPKeyPurpose) {
pr_err("Unexpected content type OID %u\n", oid);
return -EBADMSG;
}