From: Andreas Steffen Date: Fri, 20 Dec 2013 23:39:40 +0000 (+0100) Subject: Update PCR even if measurement does not equal reference value X-Git-Tag: 5.1.2dr3~15 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6810388064b9aaeb86fa22ce7684902cb0c53e25;p=thirdparty%2Fstrongswan.git Update PCR even if measurement does not equal reference value --- diff --git a/src/libpts/pts/components/ita/ita_comp_ima.c b/src/libpts/pts/components/ita/ita_comp_ima.c index 02470f5f5b..1531f7a580 100644 --- a/src/libpts/pts/components/ita/ita_comp_ima.c +++ b/src/libpts/pts/components/ita/ita_comp_ima.c @@ -683,7 +683,7 @@ METHOD(pts_component_t, verify, status_t, status = this->pts_db->check_comp_measurement(this->pts_db, measurement, this->bios_cid, this->kid, ++this->seq_no, pcr, algo); - if (status != SUCCESS) + if (status == FAILED) { return status; } @@ -803,7 +803,7 @@ METHOD(pts_component_t, verify, status_t, } if (pcrs->set(pcrs, pcr, pcr_after)) { - return SUCCESS; + return status; } } else @@ -811,7 +811,7 @@ METHOD(pts_component_t, verify, status_t, pcr_after = pcrs->extend(pcrs, pcr, measurement); if (pcr_after.ptr) { - return SUCCESS; + return status; } } return FAILED;