updated platform cert setup

This commit is contained in:
lareine 2022-02-02 10:53:46 -05:00
parent 8186f21b3b
commit 9069521841
4 changed files with 25 additions and 7 deletions

View File

@ -1,15 +1,17 @@
#!/bin/bash
#########################################################################################
# Setup for platform certificate tests
#
# Setup for platform certificates for testing
# Copies platform certs (Base and Delta) to the tcg directory
#########################################################################################
profile=$1
test=$2
compscript="$profile"_"$test"_allcomponents.sh
hwlist="$profile"_"$test"_hw.json
mkdir -p /boot/tcg/cert/platform/; # Create the platform cert folder if its not there
rm -f /boot/tcg/cert/platform/*; # clear out any previous data
# Current TCG folder for platform certs, likely to change with release of the next FIM specification
tcgDir=/boot/tcg/cert/platform/
mkdir -p $tcgDir; # Create the platform cert folder if its not there
rm -f $tcgDir*; # Clear out any previous data
echo "Test is using platform cert(s) from $profile : $test"
@ -33,10 +35,10 @@ cp -f $allCompJson /opt/paccor/scripts/$hwlist ;
# Step 3: Copy the platform cert to tcg folder on boot drive
pushd /HIRS/.ci/system-tests/profiles/$profile/$test/platformcerts/ > /dev/null
#skip copy of platform cert if .gitigore exists (empty profile)
# Skip copy of platform cert if .gitigore exists (empty profile)
if [[ ! -f ".gitignore" ]]; then
for cert in * ; do
cp -f $cert /boot/tcg/cert/platform/$cert;
cp -f $cert $tcgDir$cert;
done
fi

View File

@ -0,0 +1,8 @@
HIRS system test:
Category: Platform Certificate
Test Description: Test for a delta platform certificate illustrating a certificate that contains a component that does not match a component on the device.
Expected Test result: fail

View File

@ -0,0 +1,8 @@
HIRS system test:
Category: Platform Certificate
Test Description: Basice Test for a valid Platform Certificate and RIM bundle.
Expected Test result: pass

View File

@ -2,5 +2,5 @@ HIRS system test:
Category: Platform Certificate
Test Description: Test for a delta platform certificate illustrating a memory component addition (1 add)
Test Description: Test for a Delta Platform Certificate illustrating a delta certificate with one memory component addition (1 add)