diff --git a/CHANGES b/CHANGES index d3ef033f329d8499b4be6f67674fba71b4dac8d0..5e66651b7d1e4e02b436a00a36e694dfa5420655 100644 --- a/CHANGES +++ b/CHANGES @@ -11,6 +11,18 @@ *) applies to 0.9.6a (/0.9.6b) and 0.9.7 +) applies to 0.9.7 only + + +) Windows apparently can't transparently handle global + variables defined in DLLs. Initialisations such as: + + const ASN1_ITEM *it = &ASN1_INTEGER_it; + + wont compile. This is used by the any applications that need to + delcare their own ASN1 modules. This was fixed by adding the option + EXPORT_VAR_AS_FN to all Win32 platforms, although this isn't strictly + needed for static libraries under Win32. + [Steve Henson] + +) New functions X509_PURPOSE_set() and X509_TRUST_set() to handle setting of purpose and trust fields. New X509_STORE trust and purpose functions and tidy up setting in other SSL functions. diff --git a/Configure b/Configure index a5e2ced4df853148c2e94066e70c699156454231..c7cee4b2564d7a6b74cbe413ce9f781dd60b338a 100755 --- a/Configure +++ b/Configure @@ -411,8 +411,8 @@ my %table=( # Windows NT, Microsoft Visual C++ 4.0 -"VC-NT","cl::::WINNT::BN_LLONG RC4_INDEX ${x86_gcc_opts}::::::::::win32", -"VC-WIN32","cl::::WIN32::BN_LLONG RC4_INDEX ${x86_gcc_opts}::::::::::win32", +"VC-NT","cl::::WINNT::BN_LLONG RC4_INDEX EXPORT_VAR_AS_FN ${x86_gcc_opts}::::::::::win32", +"VC-WIN32","cl::::WIN32::BN_LLONG RC4_INDEX EXPORT_VAR_AS_FN ${x86_gcc_opts}::::::::::win32", "VC-WIN16","cl:::(unknown):WIN16::MD2_CHAR DES_UNROLL DES_PTR RC4_INDEX THIRTY_TWO_BIT:::", "VC-W31-16","cl:::(unknown):WIN16::BN_LLONG MD2_CHAR DES_UNROLL DES_PTR RC4_INDEX SIXTEEN_BIT:::", "VC-W31-32","cl::::WIN16::BN_LLONG MD2_CHAR DES_UNROLL DES_PTR RC4_INDEX THIRTY_TWO_BIT:::", diff --git a/TABLE b/TABLE index e07418575602f9177ee0a275d78ba6f20801f064..8577baa4d6707d3ec3678a7a50e03197b2f1c336 100644 --- a/TABLE +++ b/TABLE @@ -467,7 +467,7 @@ $unistd = $thread_cflag = $sys_id = WINNT $lflags = -$bn_ops = BN_LLONG RC4_INDEX RC4_INDEX MD2_INT +$bn_ops = BN_LLONG RC4_INDEX EXPORT_VAR_AS_FN RC4_INDEX MD2_INT $bn_obj = $des_obj = $bf_obj = @@ -559,7 +559,7 @@ $unistd = $thread_cflag = $sys_id = WIN32 $lflags = -$bn_ops = BN_LLONG RC4_INDEX RC4_INDEX MD2_INT +$bn_ops = BN_LLONG RC4_INDEX EXPORT_VAR_AS_FN RC4_INDEX MD2_INT $bn_obj = $des_obj = $bf_obj = diff --git a/crypto/x509/Makefile.ssl b/crypto/x509/Makefile.ssl index 863b204fb1da023c7486282da026b10638fb3c42..ea4959912aba0a137c2f62f496dc4993b2e44b02 100644 --- a/crypto/x509/Makefile.ssl +++ b/crypto/x509/Makefile.ssl @@ -254,22 +254,23 @@ x509_ext.o: ../cryptlib.h x509_ext.c x509_lu.o: ../../e_os.h ../../include/openssl/asn1.h x509_lu.o: ../../include/openssl/bio.h ../../include/openssl/blowfish.h x509_lu.o: ../../include/openssl/bn.h ../../include/openssl/buffer.h -x509_lu.o: ../../include/openssl/cast.h ../../include/openssl/crypto.h -x509_lu.o: ../../include/openssl/des.h ../../include/openssl/dh.h -x509_lu.o: ../../include/openssl/dsa.h ../../include/openssl/e_os2.h -x509_lu.o: ../../include/openssl/err.h ../../include/openssl/evp.h -x509_lu.o: ../../include/openssl/idea.h ../../include/openssl/lhash.h -x509_lu.o: ../../include/openssl/md2.h ../../include/openssl/md4.h -x509_lu.o: ../../include/openssl/md5.h ../../include/openssl/mdc2.h -x509_lu.o: ../../include/openssl/obj_mac.h ../../include/openssl/objects.h -x509_lu.o: ../../include/openssl/opensslconf.h ../../include/openssl/opensslv.h -x509_lu.o: ../../include/openssl/pkcs7.h ../../include/openssl/rc2.h -x509_lu.o: ../../include/openssl/rc4.h ../../include/openssl/rc5.h -x509_lu.o: ../../include/openssl/rd_fst.h ../../include/openssl/rijndael.h -x509_lu.o: ../../include/openssl/ripemd.h ../../include/openssl/rsa.h -x509_lu.o: ../../include/openssl/safestack.h ../../include/openssl/sha.h -x509_lu.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h -x509_lu.o: ../../include/openssl/x509.h ../../include/openssl/x509_vfy.h +x509_lu.o: ../../include/openssl/cast.h ../../include/openssl/conf.h +x509_lu.o: ../../include/openssl/crypto.h ../../include/openssl/des.h +x509_lu.o: ../../include/openssl/dh.h ../../include/openssl/dsa.h +x509_lu.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h +x509_lu.o: ../../include/openssl/evp.h ../../include/openssl/idea.h +x509_lu.o: ../../include/openssl/lhash.h ../../include/openssl/md2.h +x509_lu.o: ../../include/openssl/md4.h ../../include/openssl/md5.h +x509_lu.o: ../../include/openssl/mdc2.h ../../include/openssl/obj_mac.h +x509_lu.o: ../../include/openssl/objects.h ../../include/openssl/opensslconf.h +x509_lu.o: ../../include/openssl/opensslv.h ../../include/openssl/pkcs7.h +x509_lu.o: ../../include/openssl/rc2.h ../../include/openssl/rc4.h +x509_lu.o: ../../include/openssl/rc5.h ../../include/openssl/rd_fst.h +x509_lu.o: ../../include/openssl/rijndael.h ../../include/openssl/ripemd.h +x509_lu.o: ../../include/openssl/rsa.h ../../include/openssl/safestack.h +x509_lu.o: ../../include/openssl/sha.h ../../include/openssl/stack.h +x509_lu.o: ../../include/openssl/symhacks.h ../../include/openssl/x509.h +x509_lu.o: ../../include/openssl/x509_vfy.h ../../include/openssl/x509v3.h x509_lu.o: ../cryptlib.h x509_lu.c x509_obj.o: ../../e_os.h ../../include/openssl/asn1.h x509_obj.o: ../../include/openssl/bio.h ../../include/openssl/blowfish.h diff --git a/e_os2.h b/e_os2.h index 272faad39cc0ba3579e405176e55eb3b59aab099..5ebd7481ee7260123cb57c64cb3084ccf55aff7c 100644 --- a/e_os2.h +++ b/e_os2.h @@ -223,8 +223,8 @@ extern "C" { #define foobar OPENSSL_GLOBAL_REF(foobar) */ #ifdef OPENSSL_EXPORT_VAR_AS_FUNCTION -# define OPENSSL_IMPLEMENT_GLOBAL(type,name) extern static type _hide_##name; \ - type *_shadow_##name(void) { static type local_var; return &local_var; } \ +# define OPENSSL_IMPLEMENT_GLOBAL(type,name) static type _hide_##name; \ + type *_shadow_##name(void) { return &_hide_##name; } \ static type _hide_##name # define OPENSSL_DECLARE_GLOBAL(type,name) type *_shadow_##name(void) # define OPENSSL_GLOBAL_REF(name) (*(_shadow_##name())) diff --git a/util/libeay.num b/util/libeay.num index 0323374c1a51299da82e40ae45a7f7142ac5588f..eaf9e152bcef7b32fce515b1143d665cd815fcc0 100755 --- a/util/libeay.num +++ b/util/libeay.num @@ -2516,3 +2516,8 @@ UI_add_info_string 2978 EXIST::FUNCTION: UI_get_result_minsize 2979 EXIST::FUNCTION: UI_new 2980 EXIST::FUNCTION: UI_method_set_reader 2981 EXIST::FUNCTION: +X509_STORE_set_flags 2982 EXIST::FUNCTION: +X509_PURPOSE_set 2983 EXIST::FUNCTION: +X509_TRUST_set 2984 EXIST::FUNCTION: +X509_STORE_set_purpose 2985 EXIST::FUNCTION: +X509_STORE_set_trust 2986 EXIST::FUNCTION: diff --git a/util/mkdef.pl b/util/mkdef.pl index deb02a903603ecddf51934057e055e070ae3b31e..2c003c4b23a3d5bbb4754c860b817adfbaaad976 100755 --- a/util/mkdef.pl +++ b/util/mkdef.pl @@ -994,7 +994,7 @@ sub is_valid # EXPORT_VAR_AS_FUNCTION means that global variables # will be represented as functions. This currently # only happens on VMS-VAX. - if ($keyword eq "EXPORT_VAR_AS_FUNCTION" && $VMSVAX) { + if ($keyword eq "EXPORT_VAR_AS_FUNCTION" && ($VMSVAX || $W32)) { return 1; } return 0;