Apache OpenOffice (AOO) Bugzilla – Issue 33927
NT: cannot register xsec_xmlsec.dll
Last modified: 2004-10-08 12:38:51 UTC
xsec_xmlsec.dll is linked against xmlsec-mscrypto.dll out of module libxmlsec. xmlsec-mscrypto.dll uses two functions (CryptContextAddRef and CryptDuplicateKey) out of advapi43.lib which are available in Windows 2000 and later and Windows 98 and later, but not in NT 4. As our windows baseline is WIN98 and WIN NT4, this is a P1 issue.
Setting Kurt on CC.
Andrew...
I don't know what will happened if I disable the codes with CryptContextAddRef and CryptDuplicateKey, even I don't think it is possible. Is it possible to add the advapi32.dll( from win 2k or win xp ) to staroffice program directory?
I strongly doubt that we may redistribute that windows library. We have a clear baseline for all our major platforms and every developer has to ensure that his code is compatible with this baseline. In this case that means you must not use any windows API not available on NT4.
The CryptoContextAddRef and CryptoDuplicateKey have been replaced with some similar private functions( I also afraid that it will cause some problems unexpected ). And the securityenvironment component also have some changes, without the two APIs, the methods( setCryptoProvider, adoptSymKey, adoptPubKey, adoptPriKey ) of securityenvironment have some limitation comparing with previous implementation. 1. After calling those methods, any action should not do over the provider/symkey/pubkey/prikey, because it has been adopted into securityenvironment component, its lifecyle will be managed by securityenvironment. 2. The current applications do not use the above methods. Notes: WINNT 4.0 with SP6 support certificate management APIs. SP3 declared support certificate management APIs.
The bug has been fixed.
Sorry, the changed source/xmlsec/mscrypt/securityenvironment_mscryptimpl.cxx does not fix this bug. Library wntmsci10.pro/bin/xsec_xmlsec.dll still gets linked against xmlsec-mscrypto.dll (see xmlsecurity/util/makefile.mk, line 134: .IF "$(CRYPTO_ENGINE)" == "mscrypto" SHL2STDLIBS+= $(MSCRYPTOLIBS) ( $(MSCRYPTOLIBS) is defined in solenv/inc/libs.mk as MSCRYPTOLIBS=$(LIBXML2LIB) $(XMLSECLIB) $(XMLSECLIB-MS) $(LIBPRE) crypt32.lib $(LIBPRE) advapi32.lib with XMLSECLIB-MS=$(LIBPRE) xmlsec-mscrypto.lib ) I cannot just remove XMLSECLIB-MS from that macro, this would lead to quite some unresolved external symbols. Therefore 'depends xsec_xmlsec.dll ' still tells me about unresolved imports CryptContextAddRef and CryptDuplicateKey from advapi32.dll So, what to do now?
Not fixed. Smoketest on NT4 machines failes, we cannot release wntmsci10 for m54.
Do you have recheck out, rebuild and redeliver the external/libxmlsec? Any result, let me know as soon as possible.
Sorry, no. No one told me that there was more involved than just that one file in xmlsecurity. I'll try immediately.
What happened then?
I do not have a new install set yet, but according to 'depends' now it's OK. Thank you, Andrew. Rüdiger
Yes, now setup runs successfull on NT4 machines, everything can be registered.
Verified on master.
Closing.