#include #include #include #include #include #include grub_err_t grub_tpm_measure (unsigned char *buf, grub_size_t size, grub_uint8_t pcr, const char *kind, const char *description) { grub_err_t ret; char *desc = grub_xasprintf("%s %s", kind, description); if (!desc) return GRUB_ERR_OUT_OF_MEMORY; ret = grub_tpm_log_event(buf, size, pcr, desc); grub_free(desc); return ret; }