Added msxml3-FreeThreadedXMLHTTP60 patchset

This commit is contained in:
Alistair Leslie-Hughes 2020-09-09 12:37:05 +10:00
parent ec77bc9d66
commit d79463a8b3
7 changed files with 1479 additions and 0 deletions

View File

@ -0,0 +1,40 @@
From 1b9bde927b65e034acde1a3cdca1aac6afcab854 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Thu, 3 Sep 2020 17:58:53 +1000
Subject: [PATCH 1/5] msxml3: Use msxml6 header for defining GUIDs.
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
dlls/msxml3/factory.c | 2 +-
dlls/msxml3/uuid.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/msxml3/factory.c b/dlls/msxml3/factory.c
index 445cfbf730..3be974c58a 100644
--- a/dlls/msxml3/factory.c
+++ b/dlls/msxml3/factory.c
@@ -34,7 +34,7 @@
#include "winuser.h"
#include "ole2.h"
#include "msxml.h"
-#include "msxml2.h"
+#include "msxml6.h"
#include "xmlparser.h"
/* undef the #define in msxml2 so that we can access the v.2 version
diff --git a/dlls/msxml3/uuid.c b/dlls/msxml3/uuid.c
index 4abbe5e476..7403b27c72 100644
--- a/dlls/msxml3/uuid.c
+++ b/dlls/msxml3/uuid.c
@@ -39,7 +39,7 @@
/* Now we can initialize the rest of the uuids */
#include "initguid.h"
-#include "msxml2.h"
+#include "msxml6.h"
/*
* Note that because of a #define in msxml2.h, we end up initializing
--
2.28.0

View File

@ -0,0 +1,45 @@
From 904a06e52cb70dd9821b6aea99bc646f9c573d12 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Thu, 3 Sep 2020 17:59:01 +1000
Subject: [PATCH 2/5] msxml3/tests: Use msxml6.h where required
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
dlls/msxml3/tests/saxreader.c | 4 ++--
dlls/msxml3/tests/schema.c | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/dlls/msxml3/tests/saxreader.c b/dlls/msxml3/tests/saxreader.c
index 986f429cc1..5c5fa8075d 100644
--- a/dlls/msxml3/tests/saxreader.c
+++ b/dlls/msxml3/tests/saxreader.c
@@ -28,8 +28,8 @@
#include "windows.h"
#include "ole2.h"
-#include "msxml2.h"
-#include "msxml2did.h"
+#include "msxml6.h"
+#include "msxml6did.h"
#include "ocidl.h"
#include "dispex.h"
diff --git a/dlls/msxml3/tests/schema.c b/dlls/msxml3/tests/schema.c
index 4637d62f8b..fc0329bd10 100644
--- a/dlls/msxml3/tests/schema.c
+++ b/dlls/msxml3/tests/schema.c
@@ -26,9 +26,9 @@
#include "initguid.h"
#include "windows.h"
#include "ole2.h"
-#include "msxml2.h"
+#include "msxml6.h"
#undef CLSID_DOMDocument
-#include "msxml2did.h"
+#include "msxml6did.h"
#include "dispex.h"
#include "cguid.h"
--
2.28.0

View File

@ -0,0 +1,196 @@
From 87f6f9640a5590ae216c4f863d34826122e4914a Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Thu, 3 Sep 2020 17:59:06 +1000
Subject: [PATCH 3/5] include: Remove interfaces already define in msxml6.idl
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
include/msxml2.idl | 109 ---------------------------------------------
1 file changed, 109 deletions(-)
diff --git a/include/msxml2.idl b/include/msxml2.idl
index cfafc42133..a2d72d2063 100644
--- a/include/msxml2.idl
+++ b/include/msxml2.idl
@@ -1605,15 +1605,6 @@ coclass FreeThreadedDOMDocument40
[default, source] dispinterface XMLDOMDocumentEvents;
}
-[
- uuid(88d96a06-f192-11d4-a65f-0040963251e5),
-]
-coclass FreeThreadedDOMDocument60
-{
- [default] interface IXMLDOMDocument3;
- [default, source] dispinterface XMLDOMDocumentEvents;
-}
-
[
helpstring("Free threaded XML DOM Document"),
progid("Msxml2.FreeThreadedDOMDocument"),
@@ -1655,14 +1646,6 @@ coclass XMLHTTP40
[default] interface IXMLHTTPRequest;
}
-[
- uuid(88d96a0a-f192-11d4-a65f-0040963251e5)
-]
-coclass XMLHTTP60
-{
- [default] interface IXMLHTTPRequest;
-}
-
[
helpstring("XML HTTP"),
progid("Msxml2.XMLHTTP"),
@@ -1695,14 +1678,6 @@ coclass ServerXMLHTTP40
[default] interface IServerXMLHTTPRequest2;
}
-[
- uuid(88d96a0b-f192-11d4-a65f-0040963251e5)
-]
-coclass ServerXMLHTTP60
-{
- [default] interface IServerXMLHTTPRequest2;
-}
-
[
helpstring("Server XML HTTP"),
progid("Msxml2.ServerXMLHTTP"),
@@ -1743,14 +1718,6 @@ coclass XMLSchemaCache40
[default] interface IXMLDOMSchemaCollection2;
}
-[
- uuid(88d96a07-f192-11d4-a65f-0040963251e5)
-]
-coclass XMLSchemaCache60
-{
- [default] interface IXMLDOMSchemaCollection2;
-}
-
[
helpstring("XML Schema Cache"),
progid("Msxml2.XMLSchemaCache"),
@@ -1791,14 +1758,6 @@ coclass XSLTemplate40
[default] interface IXSLTemplate;
}
-[
- uuid(88d96a08-f192-11d4-a65f-0040963251e5)
-]
-coclass XSLTemplate60
-{
- [default] interface IXSLTemplate;
-}
-
[
helpstring("XSL Template"),
progid("Msxml2.XSLTemplate"),
@@ -3290,15 +3249,6 @@ coclass SAXXMLReader40
interface ISAXXMLReader;
}
-[
- uuid(88d96a0c-f192-11d4-a65f-0040963251e5)
-]
-coclass SAXXMLReader60
-{
- [default] interface IVBSAXXMLReader;
- interface ISAXXMLReader;
-}
-
[
helpstring("SAX XML Reader"),
progid("Msxml2.SAXXMLReader"),
@@ -3373,26 +3323,6 @@ coclass MXHTMLWriter40
interface IVBSAXLexicalHandler;
}
-[
- uuid(88d96a10-f192-11d4-a65f-0040963251e5)
-]
-coclass MXHTMLWriter60
-{
- [default] interface IMXWriter;
-
- interface ISAXContentHandler;
- interface ISAXDeclHandler;
- interface ISAXDTDHandler;
- interface ISAXErrorHandler;
- interface ISAXLexicalHandler;
-
- interface IVBSAXContentHandler;
- interface IVBSAXDeclHandler;
- interface IVBSAXDTDHandler;
- interface IVBSAXErrorHandler;
- interface IVBSAXLexicalHandler;
-}
-
[
helpstring("MXXMLWriter 3.0"),
progid("Msxml2.MXXMLWriter.3.0"),
@@ -3437,26 +3367,6 @@ coclass MXXMLWriter40
interface IVBSAXLexicalHandler;
}
-[
- uuid(88d96a0f-f192-11d4-a65f-0040963251e5)
-]
-coclass MXXMLWriter60
-{
- [default] interface IMXWriter;
-
- interface ISAXContentHandler;
- interface ISAXDeclHandler;
- interface ISAXDTDHandler;
- interface ISAXErrorHandler;
- interface ISAXLexicalHandler;
-
- interface IVBSAXContentHandler;
- interface IVBSAXDeclHandler;
- interface IVBSAXDTDHandler;
- interface IVBSAXErrorHandler;
- interface IVBSAXLexicalHandler;
-}
-
[
helpstring("MXXMLWriter"),
progid("Msxml2.MXXMLWriter"),
@@ -3499,15 +3409,6 @@ coclass MXNamespaceManager40
interface IMXNamespaceManager;
}
-[
- uuid(88d96a11-f192-11d4-a65f-0040963251e5)
-]
-coclass MXNamespaceManager60
-{
- [default] interface IVBMXNamespaceManager;
- interface IMXNamespaceManager;
-}
-
[
helpstring("SAXAttributes 3.0"),
progid("Msxml2.SAXAttributes.3.0"),
@@ -3532,16 +3433,6 @@ coclass SAXAttributes40
interface ISAXAttributes;
}
-[
- uuid(88d96a0e-f192-11d4-a65f-0040963251e5)
-]
-coclass SAXAttributes60
-{
- [default] interface IMXAttributes;
- interface IVBSAXAttributes;
- interface ISAXAttributes;
-}
-
[
helpstring("SAXAttributes"),
progid("Msxml2.SAXAttributes"),
--
2.28.0

View File

@ -0,0 +1,151 @@
From e46f6e920f9f41f7f5ab5b0bb5254dec7d0c0dc2 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Thu, 3 Sep 2020 17:59:10 +1000
Subject: [PATCH 4/5] include: Add IXMLHTTPRequest2/3 interfaces
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
include/msxml6.idl | 106 +++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 106 insertions(+)
diff --git a/include/msxml6.idl b/include/msxml6.idl
index 1f657a8cde..b837e42477 100644
--- a/include/msxml6.idl
+++ b/include/msxml6.idl
@@ -109,6 +109,8 @@ interface ISchemaAny;
interface ISchemaIdentityConstraint;
interface ISchemaNotation;
+interface IXMLHTTPRequest2Callback;
+interface IXMLHTTPRequest3Callback;
cpp_quote("#define DOMDocument DOMDocument2")
cpp_quote("#define CLSID_DOMDocument CLSID_DOMDocument2")
@@ -261,6 +263,35 @@ typedef enum _SCHEMATYPEVARIETY
SCHEMATYPEVARIETY_UNION = 2,
} SCHEMATYPEVARIETY;
+typedef struct tagXHR_COOKIE
+{
+ [ref, string] WCHAR *pwszUrl;
+ [ref, string] WCHAR *pwszName;
+ [unique, string] WCHAR *pwszValue;
+ [unique, string] WCHAR *pwszP3PPolicy;
+ FILETIME ftExpires;
+ DWORD dwFlags;
+} XHR_COOKIE;
+
+typedef [v1_enum] enum _XHR_PROPERTY
+{
+ XHR_PROP_NO_CRED_PROMPT = 0x0,
+ XHR_PROP_NO_AUTH = 0x1,
+ XHR_PROP_TIMEOUT = 0x2,
+ XHR_PROP_NO_DEFAULT_HEADERS = 0x3,
+ XHR_PROP_REPORT_REDIRECT_STATUS = 0x4,
+ XHR_PROP_NO_CACHE = 0x5,
+ XHR_PROP_EXTENDED_ERROR = 0x6,
+ XHR_PROP_QUERY_STRING_UTF8 = 0x7,
+ XHR_PROP_IGNORE_CERT_ERRORS = 0x8,
+} XHR_PROPERTY;
+
+typedef struct tagXHR_CERT
+{
+ DWORD cbCert;
+ [ref, size_is(cbCert)] BYTE *pbCert;
+} XHR_CERT;
+
[
local,
object,
@@ -1265,6 +1296,70 @@ interface IXMLHTTPRequest : IDispatch
HRESULT onreadystatechange([in] IDispatch *pReadyStateSink);
}
+[
+ object,
+ uuid(e5d37dc0-552a-4d52-9cc0-a14d546fbd04),
+ helpstring("IXMLHTTPRequest2 Interface")
+]
+interface IXMLHTTPRequest2 : IUnknown
+{
+ HRESULT Open([in, string, ref] const WCHAR *method, [in, string, ref] const WCHAR *url,
+ [in] IXMLHTTPRequest2Callback *callback,
+ [in, string, unique] const WCHAR *username, [in, string, unique] const WCHAR *password,
+ [in, string, unique] const WCHAR *proxy_username, [in, string, unique] const WCHAR *proxy_password);
+ HRESULT Send([in] ISequentialStream *body, [in] ULONGLONG body_size);
+ HRESULT Abort();
+ HRESULT SetCookie([in, ref] const XHR_COOKIE *cookie, [out] DWORD *state);
+ HRESULT SetCustomResponseStream([in] ISequentialStream *stream);
+ HRESULT SetProperty([in] XHR_PROPERTY property, [in] ULONGLONG value);
+ HRESULT SetRequestHeader([in, string, ref] const WCHAR *header, [in, string, unique] const WCHAR *value);
+ HRESULT GetAllResponseHeaders([out, string] WCHAR **headers);
+ HRESULT GetCookie([in, ref, string] const WCHAR *url, [in, unique, string] const WCHAR *name, [in] DWORD dwFlags,
+ [out] ULONG *cookies_count, [out, size_is(,*cookies_count)] XHR_COOKIE **cookies);
+ HRESULT GetResponseHeader([in, string, ref] const WCHAR *header, [out, string] WCHAR **value);
+}
+
+[
+ object,
+ uuid(a1c9feee-0617-4f23-9d58-8961ea43567c),
+ helpstring("IXMLHttpRequest3 Interface")
+]
+interface IXMLHTTPRequest3 : IXMLHTTPRequest2
+{
+ HRESULT SetClientCertificate([in] DWORD hash_size, [in, unique, size_is(hash_size)] const BYTE *hash,
+ [in, string, unique] const WCHAR *pin);
+}
+
+[
+ object,
+ uuid(a44a9299-e321-40de-8866-341b41669162),
+ helpstring("IXMLHTTPRequest2Callback Interface"),
+ pointer_default(ref)
+]
+interface IXMLHTTPRequest2Callback : IUnknown
+{
+ HRESULT OnRedirect([in] IXMLHTTPRequest2 *request, [in, string] const WCHAR* redirect_url);
+ HRESULT OnHeadersAvailable([in] IXMLHTTPRequest2 *request, [in] DWORD status, [in, string] const WCHAR *status_str);
+ HRESULT OnDataAvailable([in] IXMLHTTPRequest2 *request, [in] ISequentialStream *response);
+ HRESULT OnResponseReceived([in] IXMLHTTPRequest2 *request, [in] ISequentialStream *response);
+ HRESULT OnError([in] IXMLHTTPRequest2 *request, [in] HRESULT error);
+}
+
+[
+ object,
+ uuid(b9e57830-8c6c-4a6f-9c13-47772bb047bb),
+ helpstring("IXMLHttpRequest3Callback Interface")
+]
+interface IXMLHTTPRequest3Callback : IXMLHTTPRequest2Callback
+{
+ HRESULT OnServerCertificateReceived([in] IXMLHTTPRequest3 *request, [in] DWORD errors,
+ [in] DWORD chain_size,
+ [in, unique,size_is(chain_size)] const XHR_CERT *chain);
+ HRESULT OnClientCertificateRequested([in] IXMLHTTPRequest3 *request, [in] DWORD issuers_size,
+ [in, string, unique, size_is(issuers_size)] const WCHAR **issuers);
+};
+
+
[
object,
dual,
@@ -1554,6 +1649,17 @@ coclass XMLHTTP60
[default] interface IXMLHTTPRequest;
}
+[
+ helpstring("Free Threaded XML HTTP Request class 6.0"),
+ progid("Msxml2.FreeThreadedXMLHTTP60.6.0"),
+ threading(both),
+ uuid(88d96a09-f192-11d4-a65f-0040963251e5)
+]
+coclass FreeThreadedXMLHTTP60
+{
+ interface IXMLHTTPRequest2;
+}
+
[
uuid(afba6b42-5692-48ea-8141-dc517dcf0ef1)
]
--
2.28.0

View File

@ -0,0 +1 @@
Fixes: [49740] msxml3: Implement FreeThreadedXMLHTTP60.

View File

@ -157,6 +157,7 @@ patch_enable_all ()
enable_mshtml_TranslateAccelerator="$1"
enable_msi_msi_vcl_get_cost="$1"
enable_msvcrt_Math_Precision="$1"
enable_msxml3_FreeThreadedXMLHTTP60="$1"
enable_netutils_dll="$1"
enable_ntdll_APC_Performance="$1"
enable_ntdll_Activation_Context="$1"
@ -567,6 +568,9 @@ patch_enable ()
msvcrt-Math_Precision)
enable_msvcrt_Math_Precision="$2"
;;
msxml3-FreeThreadedXMLHTTP60)
enable_msxml3_FreeThreadedXMLHTTP60="$2"
;;
netutils-dll)
enable_netutils_dll="$2"
;;
@ -2858,6 +2862,24 @@ if test "$enable_msvcrt_Math_Precision" -eq 1; then
patch_apply msvcrt-Math_Precision/0001-msvcrt-Calculate-sinh-cosh-exp-pow-with-higher-preci.patch
fi
# Patchset msxml3-FreeThreadedXMLHTTP60
# |
# | This patchset fixes the following Wine bugs:
# | * [#49740] msxml3: Implement FreeThreadedXMLHTTP60.
# |
# | Modified files:
# | * dlls/msxml3/Makefile.in, dlls/msxml3/factory.c, dlls/msxml3/httprequest.c, dlls/msxml3/msxml_private.h,
# | dlls/msxml3/tests/httpreq.c, dlls/msxml3/tests/saxreader.c, dlls/msxml3/tests/schema.c, dlls/msxml3/uuid.c,
# | include/msxml2.idl, include/msxml6.idl
# |
if test "$enable_msxml3_FreeThreadedXMLHTTP60" -eq 1; then
patch_apply msxml3-FreeThreadedXMLHTTP60/0001-msxml3-Use-msxml6-header-for-defining-GUIDs.patch
patch_apply msxml3-FreeThreadedXMLHTTP60/0002-msxml3-tests-Use-msxml6.h-where-required.patch
patch_apply msxml3-FreeThreadedXMLHTTP60/0003-include-Remove-interfaces-already-define-in-msxml6.i.patch
patch_apply msxml3-FreeThreadedXMLHTTP60/0004-include-Add-IXMLHTTPRequest2-3-interfaces.patch
patch_apply msxml3-FreeThreadedXMLHTTP60/0005-msxml3-Implement-FreeThreadedXMLHTTP60.patch
fi
# Patchset netutils-dll
# |
# | This patchset fixes the following Wine bugs: