summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--command/payload_cmds.cpp6
-rw-r--r--command/payload_cmds.hpp1
2 files changed, 7 insertions, 0 deletions
diff --git a/command/payload_cmds.cpp b/command/payload_cmds.cpp
index 3b5b4f8..c32a510 100644
--- a/command/payload_cmds.cpp
+++ b/command/payload_cmds.cpp
@@ -101,6 +101,12 @@ std::vector<uint8_t> deactivatePayload(const std::vector<uint8_t>& inPayload,
response->completionCode = IPMI_CC_OK;
+ if (inPayload.size() != sizeof(DeactivatePayloadRequest))
+ {
+ response->completionCode = IPMI_CC_REQ_DATA_LEN_INVALID;
+ return outPayload;
+ }
+
// SOL is the payload currently supported for deactivation
if (static_cast<uint8_t>(message::PayloadType::SOL) != request->payloadType)
{
diff --git a/command/payload_cmds.hpp b/command/payload_cmds.hpp
index f916c11..b28392b 100644
--- a/command/payload_cmds.hpp
+++ b/command/payload_cmds.hpp
@@ -144,6 +144,7 @@ struct DeactivatePayloadRequest
uint8_t auxData1; //!< Auxiliary data 1
uint8_t auxData2; //!< Auxiliary data 2
uint8_t auxData3; //!< Auxiliary data 3
+ uint8_t auxData4; //!< Auxiliary data 4
} __attribute__((packed));
/** @struct DeactivatePayloadResponse
OpenPOWER on IntegriCloud