Reputation: 1455
I have an asp classic page that uses MSXML2.ServerXMLHTTP on Server 2008. It's been in production for over a decade. The same code runs on an exact copy of the 2008 server, a 2012 Server, a 2019 server, and Windows 10 without issue. This had to have changed recently as it's used almost daily and we just have reports of it today.
It doesn't give an error. I just calls MediaServiceRequest.Send and never comes back. I've tried other ways to create the object but they all do the same thing. The url is a web page on the same server as the caller.
Set MediaServiceRequest = Server.CreateObject("MSXML2.ServerXMLHTTP")
'Set MediaServiceRequest = Server.CreateObject("Msxml2.ServerXMLHTTP.6.0")
'Set MediaServiceRequest = Server.CreateObject("Msxml2.ServerXMLHTTP.3.0")
'Set MediaServiceRequest = Server.CreateObject("WinHttp.WinMediaServiceRequest.5.1")
'Set MediaServiceRequest = Server.CreateObject("MSXML2.XMLHTTP")
'Set MediaServiceRequest = Server.CreateObject("Microsoft.XMLHTTP")
f.writeline(now & " Error:" & Err.Number) --> Is 0 here
MediaServiceRequest.Open "POST", url, false
f.writeline(now & " Error:" & Err.Number) --> Is 0 here
MediaServiceRequest.Send s
f.writeline(now & " Error:" & Err.Number) --> Never gets here
I've re-registered MSXML3 and 6 but no change. Doesn't matter if it's http or https. When I put the url and s content into a browser, it responds properly. What else can I check?
EDIT: 8/6/19 8:17 am. I just found that it will work as long as the url is NOT on the same server! I tried another web site on the same server, same problem. I tried one of my other web on another server and it works! After reading a bit, one workaround was to set "Enable server-side debugging" to false in IIS but that's how it's set now.
It also appears that Microsoft doesn't recommend using MSXML2.ServerXMLHTTP on the same server. What is the option then??
EDIT: 8/6/19 7:21 pm. I've been trying to
'Set MediaServiceRequest = Server.CreateObject("Msxml2.ServerXMLHTTP.6.0")
Set MediaServiceRequest = Server.CreateObject("WinHttp.WinHTTPRequest.5.1")
'MediaServiceRequest.option(9) = 512 'and 128, 1024
MediaServiceRequest.Open "GET", "https://www.howsmyssl.com/a/check", false
MediaServiceRequest.Send
f.writeline(now & " sentObject")
s = MediaServiceRequest.ResponseText
f.writeline(now & " howmyssl:" & s)
I've switched the different types of objects and options but I just can't get a response from howsmyssl.com. I can't get WinHttp.WinHTTPRequest.5.1 to work as a replacement from the original issue. I'm still getting the Schannel errors in the event log no matter what I do with WinHttp.WinHTTPRequest.5.1. I just went to SSLlabs.com and we've gone from an A to a B!! I'll have to see how that happened.
Upvotes: 0
Views: 4223
Reputation: 1455
Ralpharama was on the right track with TLS and SSLlabs. When I checked the server with SSLlabs.com we were somehow back to a "B" rating. We ran the IIS Crypto tool and reapplied the security template to get every setting back where it should be. After rebooting, we had an "A" again and MSXML2.ServerXMLHTTP was working again!
Upvotes: 1