summaryrefslogtreecommitdiffstats
path: root/src/include/usr/secureboot
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/usr/secureboot')
-rw-r--r--src/include/usr/secureboot/containerheader.H16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/include/usr/secureboot/containerheader.H b/src/include/usr/secureboot/containerheader.H
index 5a554f0fc..49ecc9223 100644
--- a/src/include/usr/secureboot/containerheader.H
+++ b/src/include/usr/secureboot/containerheader.H
@@ -58,6 +58,7 @@ class ContainerHeader
iv_pHdrStart = reinterpret_cast<const uint8_t*>(i_header);
memset(&iv_headerInfo, 0x00, sizeof(iv_headerInfo));
memset(iv_hwKeyHash, 0, sizeof(SHA512_t));
+ memset(iv_componentId,0x00,sizeof(iv_componentId));
parse_header(i_header);
};
@@ -142,6 +143,14 @@ class ContainerHeader
*/
bool isValid() const;
+ /**
+ * @brief Returns the container's component ID as an invariant
+ * character string, or an empty string if none provided.
+ *
+ * @return const char* Component ID string
+ */
+ const char* componentId() const;
+
private:
/**
* @brief Default Constructor in private to prevent being instantiated
@@ -161,6 +170,13 @@ class ContainerHeader
ROM_sw_sig_raw sw_sig;
};
+ /**
+ * @brief Container's component ID (one byte larger than associated
+ * container header field to allow for a NULL terminator)
+ */
+ char iv_componentId[ sizeof(ROM_sw_header_raw::component_id)
+ + sizeof(uint8_t) ];
+
// Entire cached container header content
SecureHeaderInfo iv_headerInfo;
OpenPOWER on IntegriCloud