XMLHTTP problem [Answered]RSS

1 reply

Last post Jul 02, 2012 10:49 AM by dmcdivitt

  • XMLHTTP problem

    Jun 26, 2012 11:55 AM|dmcdivitt|LINK

    A classic ASP application was patched to call a soap web service. The Microsoft.XMLHTTP object would not work for a secure (https) address so MSXML2.ServerXMLHTTP.4.0 was used. Because of the message "access denied", the following code was found and used:

    SXH_OPTION_IGNORE_SERVER_SSL_CERT_ERROR_FLAGS = 2
    SXH_SERVER_CERT_IGNORE_ALL_SERVER_ERRORS = 13056
    set req = createobject("MSXML2.ServerXMLHTTP.4.0")
    if len(adobe_service) > 0 and len(adobe_template) > 0 then
      req.open "POST", adobe_service, false
      req.setoption SXH_OPTION_IGNORE_SERVER_SSL_CERT_ERROR_FLAGS, SXH_SERVER_CERT_IGNORE_ALL_SERVER_ERRORS
      req.setrequestheader "Content-Type", "application/soap+xml; charset=UTF-8"
      req.setrequestheader "SOAPAction","invoke"
    

    This worked excellent on the development server and UAT server but works intermittently on the production server. At first it did not work at all in production. It kept giving the "access denied" error. There are two servers in the cluster and each has MSXML SP2. When the technician who deployed the application displayed the pages on a server console, it started working, and it worked for all clients everywhere. Next day it was giving the "access denied" error again. Both servers in the cluster give the same problem. The web address is secure (https) behind a login portal. The login portal writes a server variable containing the user's login ID, so it is not necessary to do any authentication with the app, but this prevents accessing servers in the cluster directly using the IP address. This same portal strategy is used for UAT also. We need to see why this won't work in production and how production differs from UAT in this regard.

    I'm willing to use a different Microsoft XMLHTTP object, but I could find no examples other than MSXML2.ServerXMLHTTP.4.0.

    Please help!!

  • Re: XMLHTTP problem

    Jul 02, 2012 10:49 AM|dmcdivitt|LINK

     We began using MSXML2.ServerXMLHTTP.6.0. and that solved the problem.