Closed steven-bellock closed 3 months ago
In addition
if (spdm_request->header.spdm_version >= SPDM_MESSAGE_VERSION_13) {
/*And the bit[0~3] of request_attribute must be 0.*/
if ((request_attribute & SPDM_SET_CERTIFICATE_REQUEST_SLOT_ID_MASK) != 0) {
return LIBSPDM_STATUS_INVALID_PARAMETER;
}
is incorrect as the send buffer has already been acquired. This check needs to be before the send buffer has been acquired.
Param1
is set in https://github.com/DMTF/libspdm/blob/883c31e794ea49b8d4203012e9b1e88d9873e82d/library/spdm_requester_lib/libspdm_req_set_certificate.c#L118-L139 It does not handle the case whenErase
is not set. In such a caseParam1
is just the slot ID, which ignores the certificate model field.