2

We are currently having big problems with all wordpress.com servers returning invalid data. This is probably related to the servers returning incorrect HTTP-headers.

This error is easy to reproduce by using the following VB/ASP code:

Set http = Server.CreateObject("Msxml2.ServerXMLHTTP.6.0")
http.Open "GET", "http://www.wordpress.com", False
http.Send

The error message will be:

msxml6.dll error '80072f78': The server returned an invalid or unrecognized response

Any insights?

Blackbam
  • 17,496
  • 26
  • 97
  • 150
Kalle
  • 610
  • 7
  • 14

2 Answers2

4

The solution is to set a user agent:

http.setRequestHeader "User-Agent", "Mozilla/4.0+(compatible;+MSIE+7.0;+Windows+NT+5.1)"
Kalle
  • 610
  • 7
  • 14
1

I had the same issue. I solved it by doing the following:

Set xml2 = Server.CreateObject("MSXML2.ServerXMLHTTP.4.0") xml2.Open "POST", "http://wordpress.com/feed/", False xml2.setRequestHeader "User-Agent", "Mozilla/4.0+(compatible;+MSIE+7.0;+Windows+NT+5.1)" xml2.setOption 2, 13056 xml2.Send

After setting the User-Agent header I got a "The certificate authority is invalid or incorrect" error which was resolved with the SetOption command.

Adam Birr
  • 41
  • 3
  • I found that extra code to ignore SSL errors was required as well, and some other code I found had the `setOption` before the `Open` which didn't work, it has to be after like your example. – PeterJ May 17 '15 at 09:09