Question : WinHTTP 5.1 Error...

Hello everyone.  I'm trying to accomplish an HTTP POST over SSL from an IIS web server to another 3rd party IIS web server, using WinHTTP 5.1.  We have 4 different web servers in our environment, from which this code is executed: DEV, TST, STG, and PRD.

- code is non-MTS, COM component, VB6, called from ASP page
- firewall rules are in place and have been tested for all four servers
- all of our servers are running Windows 2000 Advanced Server SP3
- don't know the IIS version or OS of the server we're calling

Here's the code:

~~~~~~~~~~
    Dim objHTTP As New WinHttp.WinHttpRequest
    Dim strDataToSend As String
   
    ' create an http post command
    objHTTP.open "POST", "http://www.whateverserveriwant.com/path", False
   
    ' tell the target page what type of data we're sending it
    objHTTP.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
   
    ' create the URLEncoded form data string
    strDataToSend = "?test=" & UrlEncode("testdata")
   
    objHTTP.send strDataToSend

    Set objHTTP = Nothing
~~~~~~~~~

RESULT:
The same code works on DEV, TST, but fails in the other two:
"-2147012851: The certificate authority is invalid or incorrect"

We've verified that all the server certs are valid and current (Entrust), and the IIS configurations of all 4 of our servers appear to be the same.

Googling the error message and error number doesn't reveal anything useful.

This is frustrating -- does anyone have any suggestions?

Thanks,
Chris

Answer : WinHTTP 5.1 Error...

PAQed with points refunded (250)

modulo
Community Support Moderator
Random Solutions  
 
programming4us programming4us