diff --git a/recipes-openxt/openxt-measuredlaunch/openxt-measuredlaunch/ml-functions b/recipes-openxt/openxt-measuredlaunch/openxt-measuredlaunch/ml-functions index e47be7292..1ed8af87b 100755 --- a/recipes-openxt/openxt-measuredlaunch/openxt-measuredlaunch/ml-functions +++ b/recipes-openxt/openxt-measuredlaunch/openxt-measuredlaunch/ml-functions @@ -164,6 +164,10 @@ hash_extend() { rm $buffer } +is_sinit_module() { + acminfo "${1}" >/dev/null 2>&1 +} + # Function to calculate PCR 17 # return 0 on success # return 1 on failure @@ -262,13 +266,9 @@ pcr19() { cmdline="" fi - # ACMs have a binary fingerprint, hash first 8 bytes of every .bin file - # and if it matches hash of fingerprint, skip. - if $(echo ${module} | egrep -q -e '\.bin$|\.BIN$'); then - finger=$(head -c 8 ${root}/${module}|sha1sum|head -c 7) - if [ "$finger" = "c22c443" ]; then - continue - fi + # skip SINIT modules + if is_sinit_module ${module}; then + continue fi case ${mod_num} in @@ -331,14 +331,11 @@ hash_modules() { cmdline="" fi - # ACMs have a binary fingerprint, hash first 8 bytes of every .bin file - # and if it matches hash of fingerprint, skip. - if $(echo ${module} | egrep -q -e '\.bin$|\.BIN$'); then - finger=$(head -c 8 ${root}/${module}|sha1sum|head -c 7) - [ "$finger" = "c22c443" ] && continue + # skip SINIT modules + if is_sinit_module ${module}; then + continue fi - if [[ ${mod_num} -eq 0 ]]; then cmdline=$(echo ${cmdline} | sed -e 's/FIXME\s*//') hash_list=$(lcp2_mlehash --create --alg $hashalg \