X-Git-Url: https://git.openssl.org/?a=blobdiff_plain;f=test%2Ftestss;h=8d3557f356d9a1697d874e105eb87c3d5c36e41b;hb=95189389b0a53bc56e028230bfa0f0b8b89105a2;hp=36c792251e259f4d747f499aa356c44240c1260d;hpb=288370ea264fd81c5837a4b70604dc23636c0fea;p=openssl.git diff --git a/test/testss b/test/testss index 36c792251e..8d3557f356 100644 --- a/test/testss +++ b/test/testss @@ -1,9 +1,10 @@ #!/bin/sh -digest='-mdc2' +digest='-md5' reqcmd="../apps/openssl req" x509cmd="../apps/openssl x509 $digest" verifycmd="../apps/openssl verify" +dummycnf="../apps/openssl.cnf" CAkey="keyCA.ss" CAcert="certCA.ss" @@ -18,7 +19,16 @@ Ucert="certU.ss" echo echo "make a certificate request using 'req'" -$reqcmd -config $CAconf -out $CAreq -keyout $CAkey -new #>err.ss + +echo "string to make the random number generator think it has entropy" >> ./.rnd + +if ../apps/openssl no-rsa; then + req_new='-newkey dsa:../apps/dsa512.pem' +else + req_new='-new' +fi + +$reqcmd -config $CAconf -out $CAreq -keyout $CAkey $req_new #>err.ss if [ $? != 0 ]; then echo "error using 'req' to generate a certificate request" exit 1 @@ -39,13 +49,13 @@ if [ $? != 0 ]; then exit 1 fi -$reqcmd -verify -in $CAreq -noout +$reqcmd -config $dummycnf -verify -in $CAreq -noout if [ $? != 0 ]; then echo first generated request is invalid exit 1 fi -$reqcmd -verify -in $CAreq2 -noout +$reqcmd -config $dummycnf -verify -in $CAreq2 -noout if [ $? != 0 ]; then echo second generated request is invalid exit 1 @@ -59,7 +69,7 @@ fi echo echo "make another certificate request using 'req'" -$reqcmd -config $Uconf -out $Ureq -keyout $Ukey -new >err.ss +$reqcmd -config $Uconf -out $Ureq -keyout $Ukey $req_new >err.ss if [ $? != 0 ]; then echo "error using 'req' to generate a certificate request" exit 1