diff options
Diffstat (limited to 'openssl/test')
-rw-r--r-- | openssl/test/Makefile | 28 | ||||
-rw-r--r-- | openssl/test/cms-test.pl | 20 | ||||
-rw-r--r-- | openssl/test/evp_extra_test.c | 1 |
3 files changed, 39 insertions, 10 deletions
diff --git a/openssl/test/Makefile b/openssl/test/Makefile index bc4a9200a..338867952 100644 --- a/openssl/test/Makefile +++ b/openssl/test/Makefile @@ -60,6 +60,7 @@ SSLTEST= ssltest RSATEST= rsa_test ENGINETEST= enginetest EVPTEST= evp_test +EVPEXTRATEST=evp_extra_test IGETEST= igetest JPAKETEST= jpaketest SRPTEST= srptest @@ -77,7 +78,7 @@ EXE= $(BNTEST)$(EXE_EXT) $(ECTEST)$(EXE_EXT) $(ECDSATEST)$(EXE_EXT) $(ECDHTEST) $(MDC2TEST)$(EXE_EXT) $(RMDTEST)$(EXE_EXT) \ $(RANDTEST)$(EXE_EXT) $(DHTEST)$(EXE_EXT) $(ENGINETEST)$(EXE_EXT) \ $(BFTEST)$(EXE_EXT) $(CASTTEST)$(EXE_EXT) $(SSLTEST)$(EXE_EXT) $(EXPTEST)$(EXE_EXT) $(DSATEST)$(EXE_EXT) $(RSATEST)$(EXE_EXT) \ - $(EVPTEST)$(EXE_EXT) $(IGETEST)$(EXE_EXT) $(JPAKETEST)$(EXE_EXT) $(SRPTEST)$(EXE_EXT) \ + $(EVPTEST)$(EXE_EXT) $(EVPEXTRATEST)$(EXE_EXT) $(IGETEST)$(EXE_EXT) $(JPAKETEST)$(EXE_EXT) $(SRPTEST)$(EXE_EXT) \ $(ASN1TEST)$(EXE_EXT) $(V3NAMETEST)$(EXE_EXT) $(HEARTBEATTEST)$(EXE_EXT) \ $(CONSTTIMETEST)$(EXE_EXT) @@ -91,7 +92,7 @@ OBJ= $(BNTEST).o $(ECTEST).o $(ECDSATEST).o $(ECDHTEST).o $(IDEATEST).o \ $(MDC2TEST).o $(RMDTEST).o \ $(RANDTEST).o $(DHTEST).o $(ENGINETEST).o $(CASTTEST).o \ $(BFTEST).o $(SSLTEST).o $(DSATEST).o $(EXPTEST).o $(RSATEST).o \ - $(EVPTEST).o $(IGETEST).o $(JPAKETEST).o $(ASN1TEST).o $(V3NAMETEST).o \ + $(EVPTEST).o $(EVPEXTRATEST).o $(IGETEST).o $(JPAKETEST).o $(ASN1TEST).o $(V3NAMETEST).o \ $(HEARTBEATTEST).o $(CONSTTIMETEST).o SRC= $(BNTEST).c $(ECTEST).c $(ECDSATEST).c $(ECDHTEST).c $(IDEATEST).c \ @@ -101,7 +102,7 @@ SRC= $(BNTEST).c $(ECTEST).c $(ECDSATEST).c $(ECDHTEST).c $(IDEATEST).c \ $(DESTEST).c $(SHATEST).c $(SHA1TEST).c $(MDC2TEST).c $(RMDTEST).c \ $(RANDTEST).c $(DHTEST).c $(ENGINETEST).c $(CASTTEST).c \ $(BFTEST).c $(SSLTEST).c $(DSATEST).c $(EXPTEST).c $(RSATEST).c \ - $(EVPTEST).c $(IGETEST).c $(JPAKETEST).c $(SRPTEST).c $(ASN1TEST).c \ + $(EVPTEST).c $(EVPEXTRATEST).c $(IGETEST).c $(JPAKETEST).c $(SRPTEST).c $(ASN1TEST).c \ $(V3NAMETEST).c $(HEARTBEATTEST).c $(CONSTTIMETEST).c EXHEADER= @@ -144,13 +145,16 @@ alltests: \ test_rand test_bn test_ec test_ecdsa test_ecdh \ test_enc test_x509 test_rsa test_crl test_sid \ test_gen test_req test_pkcs7 test_verify test_dh test_dsa \ - test_ss test_ca test_engine test_evp test_ssl test_tsa test_ige \ + test_ss test_ca test_engine test_evp test_evp_extra test_ssl test_tsa test_ige \ test_jpake test_srp test_cms test_ocsp test_v3name test_heartbeat \ test_constant_time test_evp: $(EVPTEST)$(EXE_EXT) evptests.txt ../util/shlib_wrap.sh ./$(EVPTEST) evptests.txt +test_evp_extra: $(EVPEXTRATEST)$(EXE_EXT) + ../util/shlib_wrap.sh ./$(EVPEXTRATEST) + test_des: $(DESTEST)$(EXE_EXT) ../util/shlib_wrap.sh ./$(DESTEST) @@ -484,6 +488,9 @@ $(ENGINETEST)$(EXE_EXT): $(ENGINETEST).o $(DLIBCRYPTO) $(EVPTEST)$(EXE_EXT): $(EVPTEST).o $(DLIBCRYPTO) @target=$(EVPTEST); $(BUILD_CMD) +$(EVPEXTRATEST)$(EXE_EXT): $(EVPEXTRATEST).o $(DLIBCRYPTO) + @target=$(EVPEXTRATEST); $(BUILD_CMD) + $(ECDSATEST)$(EXE_EXT): $(ECDSATEST).o $(DLIBCRYPTO) @target=$(ECDSATEST); $(BUILD_CMD) @@ -629,6 +636,19 @@ enginetest.o: ../include/openssl/safestack.h ../include/openssl/sha.h enginetest.o: ../include/openssl/stack.h ../include/openssl/symhacks.h enginetest.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h enginetest.o: enginetest.c +evp_extra_test.o: ../include/openssl/asn1.h ../include/openssl/bio.h +evp_extra_test.o: ../include/openssl/buffer.h ../include/openssl/crypto.h +evp_extra_test.o: ../include/openssl/e_os2.h ../include/openssl/ec.h +evp_extra_test.o: ../include/openssl/ecdh.h ../include/openssl/ecdsa.h +evp_extra_test.o: ../include/openssl/err.h ../include/openssl/evp.h +evp_extra_test.o: ../include/openssl/lhash.h ../include/openssl/obj_mac.h +evp_extra_test.o: ../include/openssl/objects.h ../include/openssl/opensslconf.h +evp_extra_test.o: ../include/openssl/opensslv.h ../include/openssl/ossl_typ.h +evp_extra_test.o: ../include/openssl/pkcs7.h ../include/openssl/rsa.h +evp_extra_test.o: ../include/openssl/safestack.h ../include/openssl/sha.h +evp_extra_test.o: ../include/openssl/stack.h ../include/openssl/symhacks.h +evp_extra_test.o: ../include/openssl/x509.h ../include/openssl/x509_vfy.h +evp_extra_test.o: evp_extra_test.c evp_test.o: ../e_os.h ../include/openssl/asn1.h ../include/openssl/bio.h evp_test.o: ../include/openssl/buffer.h ../include/openssl/conf.h evp_test.o: ../include/openssl/crypto.h ../include/openssl/e_os2.h diff --git a/openssl/test/cms-test.pl b/openssl/test/cms-test.pl index f55fd69ce..51abeef2c 100644 --- a/openssl/test/cms-test.pl +++ b/openssl/test/cms-test.pl @@ -59,23 +59,31 @@ my $redir = " 2> cms.err > cms.out"; if ( $^O eq "VMS" && -f "OSSLX:openssl.exe" ) { $ossl_path = "pipe mcr OSSLX:openssl"; $null_path = "NL:"; + # On VMS, the lowest 3 bits of the exit code indicates severity + # 1 is success (perl translates it to 0 for $?), 2 is error + # (perl doesn't translate it) + $failure_code = 512; # 2 << 8 = 512 } # Make MSYS work elsif ( $^O eq "MSWin32" && -f "../apps/openssl.exe" ) { $ossl_path = "cmd /c ..\\apps\\openssl"; - $null_path = "/dev/null"; + $null_path = "NUL"; + $failure_code = 256; } elsif ( -f "../apps/openssl$ENV{EXE_EXT}" ) { $ossl_path = "../util/shlib_wrap.sh ../apps/openssl"; $null_path = "/dev/null"; + $failure_code = 256; } elsif ( -f "..\\out32dll\\openssl.exe" ) { $ossl_path = "..\\out32dll\\openssl.exe"; - $null_path = "/dev/null"; + $null_path = "NUL"; + $failure_code = 256; } elsif ( -f "..\\out32\\openssl.exe" ) { $ossl_path = "..\\out32\\openssl.exe"; - $null_path = "/dev/null"; + $null_path = "NUL"; + $failure_code = 256; } else { die "Can't find OpenSSL executable"; @@ -97,7 +105,7 @@ if ($? == 0) { $no_ec = 1; } -elsif ($^O eq "VMS" ? $? == 512 : $? == 256) +elsif ($? == $failure_code) { $no_ec = 0; } @@ -111,7 +119,7 @@ if ($? == 0) { $no_ec2m = 1; } -elsif ($? == 256) +elsif ($? == $failure_code) { $no_ec2m = 0; } @@ -125,7 +133,7 @@ if ($? == 0) { $no_ecdh = 1; } -elsif ($? == 256) +elsif ($? == $failure_code) { $no_ecdh = 0; } diff --git a/openssl/test/evp_extra_test.c b/openssl/test/evp_extra_test.c new file mode 100644 index 000000000..2f2a8f7b0 --- /dev/null +++ b/openssl/test/evp_extra_test.c @@ -0,0 +1 @@ +../crypto/evp/evp_extra_test.c
\ No newline at end of file |