mirror of
https://codeberg.org/scip/pcp.git
synced 2025-12-18 04:10:57 +01:00
added fuzz unittests, trying to import invalid binary keys using mangle.c by Ilja van Sprundel
This commit is contained in:
@@ -20,11 +20,12 @@
|
||||
# You can contact me by mail: <tlinden AT cpan DOT org>.
|
||||
#
|
||||
|
||||
pcp = ../src/pcp1
|
||||
vault = v1
|
||||
pcp = ../src/pcp1
|
||||
vault = v1
|
||||
passwd = xxx
|
||||
md5msg = 66b8c4ca9e5d2a7e3c0559c3cdea3d50
|
||||
|
||||
md5msg = 66b8c4ca9e5d2a7e3c0559c3cdea3d50
|
||||
mangle = ./mangle
|
||||
verbose = 1
|
||||
include keys.cfg
|
||||
|
||||
<test check-dependencies>
|
||||
@@ -523,6 +524,38 @@ temporarily disabled
|
||||
expect = /Generated new secret key/
|
||||
</test>
|
||||
|
||||
#
|
||||
# fuzz tests
|
||||
<test check-fuzz>
|
||||
prepare = (echo F; echo F) | $pcp -V vfz -k -x a; \
|
||||
$pcp -V vfz -p -O testfuzzP.orig -x a; \
|
||||
$pcp -V vfz -s -O testfuzzS.orig -x a;
|
||||
<test check-fuzz-binary-pubkey>
|
||||
loop = 30
|
||||
prepare = while :; do \
|
||||
cp testfuzzP.orig testfuzzP.pub; \
|
||||
$mangle testfuzzP.pub; \
|
||||
if ! diff testfuzzP.* > /dev/null 2>&1; then \
|
||||
break; \
|
||||
fi; \
|
||||
done
|
||||
cmd = echo no | $pcp -V vf -K -I testfuzzP.pub -x a
|
||||
expect = !/added/
|
||||
</test>
|
||||
<test check-fuzz-binary-seckey>
|
||||
loop = 30
|
||||
prepare = while :; do \
|
||||
cp testfuzzS.orig testfuzzS.sec; \
|
||||
$mangle testfuzzS.sec; \
|
||||
if ! diff testfuzzS.* > /dev/null 2>&1; then \
|
||||
break; \
|
||||
fi; \
|
||||
done
|
||||
cmd = echo no | $pcp -V vf -K -I testfuzzS.sec -x a
|
||||
expect = !/added/
|
||||
</test>
|
||||
</test>
|
||||
|
||||
|
||||
#
|
||||
# test the c++ api
|
||||
|
||||
Reference in New Issue
Block a user