From: Dr. Stephen Henson Date: Tue, 9 Mar 1999 03:01:48 +0000 (+0000) Subject: Comment out two unimplemented functions from bio.h. Attempt to get the X-Git-Tag: OpenSSL_0_9_2b~46 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=d4d2f98c59a8553781d49b06576774db2929d671;p=oweals%2Fopenssl.git Comment out two unimplemented functions from bio.h. Attempt to get the Win32 test batch file going again. --- diff --git a/CHANGES b/CHANGES index db6c2bedd2..4eefb6bfcd 100644 --- a/CHANGES +++ b/CHANGES @@ -5,10 +5,16 @@ Changes between 0.9.1c and 0.9.2 + *) Comment out two functions in bio.h that aren't implemented. Fix up the + Win32 test batch file so it (might) work again. The Win32 test batch file + is horrible: I feel ill.... + [Steve Henson] + *) Move various #ifdefs around so NO_SYSLOG, NO_DIRENT etc are now selected in e_os.h. Audit of header files to check ANSI and non ANSI sections: 10 functions were absent from non ANSI section and not exported from Windows DLLs. Fixed up libeay.num for new functions. + [Steve Henson] *) Make `openssl version' output lines consistent. [Ralf S. Engelschall] @@ -39,6 +45,7 @@ *) Permit extensions to be added to CRLs using crl_section in openssl.cnf. Currently only issuerAltName and AuthorityKeyIdentifier make any sense in CRLs. + [Steve Henson] *) Add a useful kludge to allow package maintainers to specify compiler and other platforms details on the command line without having to patch the diff --git a/INSTALL.W32 b/INSTALL.W32 index 75dc7dbb83..8aa40023c5 100644 --- a/INSTALL.W32 +++ b/INSTALL.W32 @@ -32,7 +32,8 @@ then from the VC++ environment at a prompt do: nmake -f ms\ntdll.mak you may get a warning about too many rules but if all is well it should all -compile and you will have some DLLs and executables in out32dll. +compile and you will have some DLLs and executables in out32dll. If you want +to try the tests then cd to out32dll and run ..\ms\test Troubleshooting. @@ -68,14 +69,20 @@ environments this can happen. The best fix is to edit the file with the warning in and fix it. Alternatively you can turn off the halt on warnings by editing the CFLAG line in the Makefile and deleting the /WX option. -Finally you might get compilation errors. Again you will have to fix these or +You might get compilation errors. Again you will have to fix these or report them. +One final comment about compiling applications linked to the OpenSSL library. +If you don't use the multithreaded DLL runtime library (/MD option) your +program will almost certainly crash: see the original SSLeay description below +for more details. + Tweaks. There are various changes you can make to the Win32 compile environment. If you have the MASM assembler 'ml' then you can try the assembly language code. To -do this remove the 'no-asm' part from do_ms.bat. +do this remove the 'no-asm' part from do_ms.bat. You can also add 'debug' here +to make a debugging version of the library. If you want to enable the NT specific features of OpenSSL (currently only the logging BIO) follow the instructions above but call the batch file diff --git a/STATUS b/STATUS index 4ab468c15c..3d938cce20 100644 --- a/STATUS +++ b/STATUS @@ -1,6 +1,6 @@ OpenSSL STATUS Last modified at - ______________ $Date: 1999/03/08 21:56:46 $ + ______________ $Date: 1999/03/09 03:01:42 $ DEVELOPMENT STATE @@ -11,6 +11,7 @@ o FreeBSD 2.2.7 Ben Laurie OK o FreeBSD 3.1 Ralf S. Engelschall all silent o Solaris 2.6 Ralf S. Engelschall ctype-related warnings, test fails + o Linux RH 5.1 Steve Henson OK Proposed release time: Monday, March 15th 1999 diff --git a/crypto/bio/bio.h b/crypto/bio/bio.h index 06e57b9486..ec75860220 100644 --- a/crypto/bio/bio.h +++ b/crypto/bio/bio.h @@ -463,10 +463,11 @@ BIO *BIO_new_fp(FILE *stream, int close_flag); # endif /* FP_API */ #else -int BIO_get_ex_num(); +/* These two aren't currently implemented */ +/*int BIO_get_ex_num();*/ +/*void BIO_set_ex_free_func();*/ int BIO_set_ex_data(); char *BIO_get_ex_data(); -void BIO_set_ex_free_func(); int BIO_get_ex_new_index(); # if defined(WIN16) && defined(_WINDLL) diff --git a/ms/tenc.bat b/ms/tenc.bat index a4fa7f3652..466fdfccbf 100755 --- a/ms/tenc.bat +++ b/ms/tenc.bat @@ -1,14 +1,14 @@ -rem called by testenc - -echo test %1 %2 %3 %4 %5 %6 -%ssleay% %1 %2 %3 %4 %5 %6 -e -bufsize 113 -k test -in %input% -out %tmp1% -%ssleay% %1 %2 %3 %4 %5 %6 -d -bufsize 157 -k test -in %tmp1% -out %out1% -%cmp% %input% %out1% -if errorlevel 1 goto err - -echo test base64 %1 %2 %3 %4 %5 %6 -%ssleay% %1 %2 %3 %4 %5 %6 -a -e -bufsize 113 -k test -in %input% -out %tmp1% -%ssleay% %1 %2 %3 %4 %5 %6 -a -d -bufsize 157 -k test -in %tmp1% -out %out1% -%cmp% %input% %out1% - -:err +rem called by testenc + +echo test %1 %2 %3 %4 %5 %6 +%ssleay% %1 %2 %3 %4 %5 %6 -e -bufsize 113 -k test -in %input% -out %tmp1% +%ssleay% %1 %2 %3 %4 %5 %6 -d -bufsize 157 -k test -in %tmp1% -out %out1% +%cmp% %input% %out1% +if errorlevel 1 goto err + +echo test base64 %1 %2 %3 %4 %5 %6 +%ssleay% %1 %2 %3 %4 %5 %6 -a -e -bufsize 113 -k test -in %input% -out %tmp1% +%ssleay% %1 %2 %3 %4 %5 %6 -a -d -bufsize 157 -k test -in %tmp1% -out %out1% +%cmp% %input% %out1% + +:err diff --git a/ms/test.bat b/ms/test.bat index 277602c56f..aa2f5df6d4 100755 --- a/ms/test.bat +++ b/ms/test.bat @@ -1,8 +1,9 @@ @echo=off -set test=p:\work\ssleay\ms +set test=..\ms set opath=%PATH% -PATH=%1;%PATH% +PATH=..\ms;%PATH% +set OPENSSL_CONF=..\apps\openssl.cnf rem run this from inside the bin directory @@ -63,19 +64,19 @@ dsatest if errorlevel 1 goto done echo testenc -call %test%\testenc ssleay +call %test%\testenc openssl if errorlevel 1 goto done echo testpem -call %test%\testpem ssleay +call %test%\testpem openssl if errorlevel 1 goto done echo verify copy ..\certs\*.pem cert.tmp >nul -ssleay verify -CAfile cert.tmp ..\certs\*.pem +openssl verify -CAfile cert.tmp ..\certs\*.pem echo testss -call %test%\testss ssleay +call %test%\testss openssl if errorlevel 1 goto done echo test sslv2 diff --git a/ms/testenc.bat b/ms/testenc.bat index a33fbd5ed6..12098d5ad5 100755 --- a/ms/testenc.bat +++ b/ms/testenc.bat @@ -1,11 +1,12 @@ echo start testenc -path=p:\work\ssleay\ms;%path% +echo=off +path=d:\openssl\ms;%path% set ssleay=%1% -set input=p:\work\ssleay\ms\testenc.bat -set tmp1=p:\work\ssleay\ms\cipher.out -set out1=p:\work\ssleay\ms\clear.out -set cmp=perl p:\work\ssleay\ms\cmp.pl +set input=d:\openssl\ms\testenc.bat +set tmp1=d:\openssl\ms\cipher.out +set out1=d:\openssl\ms\clear.out +set cmp=perl d:\openssl\ms\cmp.pl cd call tenc.bat enc diff --git a/ms/testpem.bat b/ms/testpem.bat index 8f6cdd4d04..203c6cabe6 100755 --- a/ms/testpem.bat +++ b/ms/testpem.bat @@ -1,36 +1,35 @@ -echo=off -set ssleay=%1% -set tmp1=pem.out -set cmp=perl ..\ms\cmp.pl - -call tpem.bat crl ..\test\testcrl.pem -if errorlevel 1 goto err - -call tpem.bat pkcs7 ..\test\testp7.pem -if errorlevel 1 goto err - -call tpem.bat req ..\test\testreq.pem -if errorlevel 1 goto err - -call tpem.bat req ..\test\testreq2.pem -if errorlevel 1 goto err - -call tpem.bat rsa ..\test\testrsa.pem -if errorlevel 1 goto err - -call tpem.bat x509 ..\test\testx509.pem -if errorlevel 1 goto err - -call tpem.bat x509 ..\test\v3-cert1.pem -if errorlevel 1 goto err - -call tpem.bat x509 ..\test\v3-cert1.pem -if errorlevel 1 goto err - -call tpem.bat sess_id ..\test\testsid.pem -if errorlevel 1 goto err - -echo OK -del %tmp1% -:err - +echo=off +set ssleay=%1% +set tmp1=pem.out +set cmp=perl ..\ms\cmp.pl + +call tpem.bat crl ..\test\testcrl.pem +if errorlevel 1 goto err + +call tpem.bat pkcs7 ..\test\testp7.pem +if errorlevel 1 goto err + +call tpem.bat req ..\test\testreq.pem +if errorlevel 1 goto err + +call tpem.bat req ..\test\testreq2.pem +if errorlevel 1 goto err + +call tpem.bat rsa ..\test\testrsa.pem +if errorlevel 1 goto err + +call tpem.bat x509 ..\test\testx509.pem +if errorlevel 1 goto err + +call tpem.bat x509 ..\test\v3-cert1.pem +if errorlevel 1 goto err + +call tpem.bat x509 ..\test\v3-cert1.pem +if errorlevel 1 goto err + +call tpem.bat sess_id ..\test\testsid.pem +if errorlevel 1 goto err + +echo OK +del %tmp1% +:err diff --git a/ms/testss.bat b/ms/testss.bat index 9a3bf428ce..11cbbc62f9 100755 --- a/ms/testss.bat +++ b/ms/testss.bat @@ -1,98 +1,98 @@ -echo=off - -rem set ssleay=..\out\ssleay -set ssleay=%1 - -set reqcmd=%ssleay% req -set x509cmd=%ssleay% x509 -set verifycmd=%ssleay% verify - -set CAkey=keyCA.ss -set CAcert=certCA.ss -set CAserial=certCA.srl -set CAreq=reqCA.ss -set CAconf=..\test\CAss.cnf -set CAreq2=req2CA.ss - -set Uconf=..\test\Uss.cnf -set Ukey=keyU.ss -set Ureq=reqU.ss -set Ucert=certU.ss - -echo make a certificate request using 'req' -%reqcmd% -config %CAconf% -out %CAreq% -keyout %CAkey% -new -if errorlevel 1 goto err_req - -echo convert the certificate request into a self signed certificate using 'x509' -%x509cmd% -CAcreateserial -in %CAreq% -days 30 -req -out %CAcert% -signkey %CAkey% >err.ss -if errorlevel 1 goto err_x509 - -echo -- -echo convert a certificate into a certificate request using 'x509' -%x509cmd% -in %CAcert% -x509toreq -signkey %CAkey% -out %CAreq2% >err.ss -if errorlevel 1 goto err_x509_2 - -%reqcmd% -verify -in %CAreq% -noout -if errorlevel 1 goto err_verify_1 - -%reqcmd% -verify -in %CAreq2% -noout -if errorlevel 1 goto err_verify_2 - -%verifycmd% -CAfile %CAcert% %CAcert% -if errorlevel 1 goto err_verify_3 - -echo -- -echo make another certificate request using 'req' -%reqcmd% -config %Uconf% -out %Ureq% -keyout %Ukey% -new >err.ss -if errorlevel 1 goto err_req_gen - -echo -- -echo sign certificate request with the just created CA via 'x509' -%x509cmd% -CAcreateserial -in %Ureq% -days 30 -req -out %Ucert% -CA %CAcert% -CAkey %CAkey% -CAserial %CAserial% -if errorlevel 1 goto err_x509_sign - -%verifycmd% -CAfile %CAcert% %Ucert% -echo -- -echo Certificate details -%x509cmd% -subject -issuer -startdate -enddate -noout -in %Ucert% - -echo Everything appeared to work -echo -- -echo The generated CA certificate is %CAcert% -echo The generated CA private key is %CAkey% -echo The current CA signing serial number is in %CAserial% - -echo The generated user certificate is %Ucert% -echo The generated user private key is %Ukey% -echo -- - -del err.ss - -goto end - -:err_req -echo error using 'req' to generate a certificate request -goto end -:err_x509 -echo error using 'x509' to self sign a certificate request -goto end -:err_x509_2 -echo error using 'x509' convert a certificate to a certificate request -goto end -:err_verify_1 -echo first generated request is invalid -goto end -:err_verify_2 -echo second generated request is invalid -goto end -:err_verify_3 -echo first generated cert is invalid -goto end -:err_req_gen -echo error using 'req' to generate a certificate request -goto end -:err_x509_sign -echo error using 'x509' to sign a certificate request -goto end - -:end +echo=on + +rem set ssleay=..\out\ssleay +set ssleay=%1 + +set reqcmd=%ssleay% req +set x509cmd=%ssleay% x509 +set verifycmd=%ssleay% verify + +set CAkey=keyCA.ss +set CAcert=certCA.ss +set CAserial=certCA.srl +set CAreq=reqCA.ss +set CAconf=..\test\CAss.cnf +set CAreq2=req2CA.ss + +set Uconf=..\test\Uss.cnf +set Ukey=keyU.ss +set Ureq=reqU.ss +set Ucert=certU.ss + +echo make a certificate request using 'req' +%reqcmd% -config %CAconf% -out %CAreq% -keyout %CAkey% -new +if errorlevel 1 goto err_req + +echo convert the certificate request into a self signed certificate using 'x509' +%x509cmd% -CAcreateserial -in %CAreq% -days 30 -req -out %CAcert% -signkey %CAkey% >err.ss +if errorlevel 1 goto err_x509 + +echo -- +echo convert a certificate into a certificate request using 'x509' +%x509cmd% -in %CAcert% -x509toreq -signkey %CAkey% -out %CAreq2% >err.ss +if errorlevel 1 goto err_x509_2 + +%reqcmd% -verify -in %CAreq% -noout +if errorlevel 1 goto err_verify_1 + +%reqcmd% -verify -in %CAreq2% -noout +if errorlevel 1 goto err_verify_2 + +%verifycmd% -CAfile %CAcert% %CAcert% +if errorlevel 1 goto err_verify_3 + +echo -- +echo make another certificate request using 'req' +%reqcmd% -config %Uconf% -out %Ureq% -keyout %Ukey% -new >err.ss +if errorlevel 1 goto err_req_gen + +echo -- +echo sign certificate request with the just created CA via 'x509' +%x509cmd% -CAcreateserial -in %Ureq% -days 30 -req -out %Ucert% -CA %CAcert% -CAkey %CAkey% -CAserial %CAserial% +if errorlevel 1 goto err_x509_sign + +%verifycmd% -CAfile %CAcert% %Ucert% +echo -- +echo Certificate details +%x509cmd% -subject -issuer -startdate -enddate -noout -in %Ucert% + +echo Everything appeared to work +echo -- +echo The generated CA certificate is %CAcert% +echo The generated CA private key is %CAkey% +echo The current CA signing serial number is in %CAserial% + +echo The generated user certificate is %Ucert% +echo The generated user private key is %Ukey% +echo -- + +del err.ss + +goto end + +:err_req +echo error using 'req' to generate a certificate request +goto end +:err_x509 +echo error using 'x509' to self sign a certificate request +goto end +:err_x509_2 +echo error using 'x509' convert a certificate to a certificate request +goto end +:err_verify_1 +echo first generated request is invalid +goto end +:err_verify_2 +echo second generated request is invalid +goto end +:err_verify_3 +echo first generated cert is invalid +goto end +:err_req_gen +echo error using 'req' to generate a certificate request +goto end +:err_x509_sign +echo error using 'x509' to sign a certificate request +goto end + +:end diff --git a/ms/tpem.bat b/ms/tpem.bat index cd01792e9f..7fc7a83279 100755 --- a/ms/tpem.bat +++ b/ms/tpem.bat @@ -1,6 +1,6 @@ -rem called by testpem - -echo test %1 %2 -%ssleay% %1 -in %2 -out %tmp1% -%cmp% %2 %tmp1% - +rem called by testpem + +echo test %1 %2 +%ssleay% %1 -in %2 -out %tmp1% +%cmp% %2 %tmp1% + diff --git a/test/testreq.pem b/test/testreq.pem new file mode 100644 index 0000000000..b20137b6e3 --- /dev/null +++ b/test/testreq.pem @@ -0,0 +1,9 @@ +-----BEGIN CERTIFICATE REQUEST----- +MIIBQjCB7QIBADCBhzELMAkGA1UEBhMCQVUxEzARBgNVBAgTClF1ZWVuc2xhbmQx +ETAPBgNVBAcTCEJyaXNiYW5lMRowGAYDVQQKExFDcnlwdFNvZnQgUHR5IEx0ZDET +MBEGA1UEAxMKRXJpYyBZb3VuZzEfMB0GCSqGSIb3DQEJARYQZWF5QG1pbmNvbS5v +ei5hdTBcMA0GCSqGSIb3DQEBAQUAA0sAMEgCQQDCLwdDF7Fu4DSiae/+3045nf73 +V5OdRnICMXq4M0td4upwgC/ve7w+3q1OzObOpFgpuP1PEOsHGO48GrolDu4lAgMB +AAGgADANBgkqhkiG9w0BAQQFAANBAItCGg8qCPSoASvm3QUx/6PpreQclDO0bM2l +eacLlzSHBUvaSqapR/pHfHG2r9l6PuEr/rrYHo+ZrAraSyPhEBc= +-----END CERTIFICATE REQUEST-----