forked from wolfSSL/wolfssl
fix pre-push calling fips-check with unimplemented option
This commit is contained in:
@ -79,13 +79,13 @@ linux)
|
|||||||
esac
|
esac
|
||||||
|
|
||||||
git clone . $TEST_DIR
|
git clone . $TEST_DIR
|
||||||
[ $? -ne 0 ] && echo -e "\n\nCouldn't duplicate current working directory.\n\n" && exit 1
|
[ $? -ne 0 ] && echo "\n\nCouldn't duplicate current working directory.\n\n" && exit 1
|
||||||
|
|
||||||
pushd $TEST_DIR
|
pushd $TEST_DIR
|
||||||
|
|
||||||
# make a clone of the last FIPS release tag
|
# make a clone of the last FIPS release tag
|
||||||
git clone -b $CTAO_VERSION $CTAO_REPO old-tree
|
git clone -b $CTAO_VERSION $CTAO_REPO old-tree
|
||||||
[ $? -ne 0 ] && echo -e "\n\nCouldn't checkout the FIPS release.\n\n" && exit 1
|
[ $? -ne 0 ] && echo "\n\nCouldn't checkout the FIPS release.\n\n" && exit 1
|
||||||
|
|
||||||
for MOD in ${WC_MODS[@]}
|
for MOD in ${WC_MODS[@]}
|
||||||
do
|
do
|
||||||
@ -102,7 +102,7 @@ cp old-tree/$WC_INC_PATH/random.h $WC_INC_PATH
|
|||||||
|
|
||||||
# clone the FIPS repository
|
# clone the FIPS repository
|
||||||
git clone -b $FIPS_VERSION $FIPS_REPO fips
|
git clone -b $FIPS_VERSION $FIPS_REPO fips
|
||||||
[ $? -ne 0 ] && echo -e "\n\nCouldn't checkout the FIPS repository.\n\n" && exit 1
|
[ $? -ne 0 ] && echo "\n\nCouldn't checkout the FIPS repository.\n\n" && exit 1
|
||||||
|
|
||||||
for SRC in ${FIPS_SRCS[@]}
|
for SRC in ${FIPS_SRCS[@]}
|
||||||
do
|
do
|
||||||
@ -113,7 +113,7 @@ done
|
|||||||
./autogen.sh
|
./autogen.sh
|
||||||
./configure --enable-fips
|
./configure --enable-fips
|
||||||
make
|
make
|
||||||
[ $? -ne 0 ] && echo -e "\n\nMake failed. Debris left for analysis." && exit 1
|
[ $? -ne 0 ] && echo "\n\nMake failed. Debris left for analysis." && exit 1
|
||||||
|
|
||||||
NEWHASH=`./wolfcrypt/test/testwolfcrypt | sed -n 's/hash = \(.*\)/\1/p'`
|
NEWHASH=`./wolfcrypt/test/testwolfcrypt | sed -n 's/hash = \(.*\)/\1/p'`
|
||||||
if [ -n "$NEWHASH" ]; then
|
if [ -n "$NEWHASH" ]; then
|
||||||
@ -122,7 +122,7 @@ if [ -n "$NEWHASH" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
make test
|
make test
|
||||||
[ $? -ne 0 ] && echo -e "\n\nTest failed. Debris left for analysis." && exit 1
|
[ $? -ne 0 ] && echo "\n\nTest failed. Debris left for analysis." && exit 1
|
||||||
|
|
||||||
# Clean up
|
# Clean up
|
||||||
popd
|
popd
|
||||||
|
@ -7,8 +7,8 @@ RESULT=0
|
|||||||
|
|
||||||
if [ -n "$HAVE_FIPS_SOURCE" ];
|
if [ -n "$HAVE_FIPS_SOURCE" ];
|
||||||
then
|
then
|
||||||
echo -e "\n\nTesting with FIPS release code...\n\n"
|
echo "\n\nTesting with FIPS release code...\n\n"
|
||||||
./fips-check.sh --no-keep
|
./fips-check.sh
|
||||||
RESULT=$?
|
RESULT=$?
|
||||||
[ $RESULT -ne 0 ] && echo -e "\n\nFIPS build test failed" && exit 1
|
[ $RESULT -ne 0 ] && echo -e "\n\nFIPS build test failed" && exit 1
|
||||||
fi
|
fi
|
||||||
|
Reference in New Issue
Block a user