Quantcast
Channel: Classic ASP
Viewing all articles
Browse latest Browse all 488

asp page works fine on IIS 10, but not on IIS 7.5

$
0
0

Hello. First thread and i would like to ask the question that is already mentioned on the subject. Here' s the code snippet:

<% Response.Charset="UTF-8"%>
<%
Function Stream_StringToBinary(Text)
Const adTypeText = 2
Const adTypeBinary = 1
'Create Stream object
Dim BinaryStream 'As New Stream
Set BinaryStream = CreateObject("ADODB.Stream")
'Specify stream type - we want To save text/string data.
BinaryStream.Type = adTypeText
'Specify charset For the source text (unicode) data.
BinaryStream.CharSet = "us-ascii"
'Open the stream And write text/string data To the object
BinaryStream.Open
BinaryStream.WriteText Text
'Change stream type To binary
BinaryStream.Position = 0
BinaryStream.Type = adTypeBinary
'Ignore first two bytes - sign of
BinaryStream.Position = 0
'Open the stream And get binary data from the object
Stream_StringToBinary = BinaryStream.Read
Set BinaryStream = Nothing
End Function

Dim oXML, oNode
Set oXML = CreateObject("Msxml2.DOMDocument.6.0")
Set oNode = oXML.CreateElement("base64")
oNode.dataType = "bin.base64"
credentials="username:password"
oNode.nodeTypedValue =Stream_StringToBinary(credentials)
Base64Encode = oNode.text
Set oNode = Nothing
Set oXML = Nothing

Set objRequest = Server.createobject("MSXML2.XMLHTTP.6.0")
With objRequest
.open "GET", "https://A_WEB_SITE/", False
.setRequestHeader "Authorization", "Basic " & Base64Encode
.send
End With

It's basiicaly a rest web server and i' m calling its methods. It needed some certificates, i installed them allright, but on iis 7.5, which runs on win server 2008r2 64bit, it brings the foolowing error:

msxml6.dll error '80004004'

Operation aborted

/test3.asp, line 40 (this is the line where the .send takes place).

I looked at the browser's tools and it shows an internal server error 500, which means that the .send command never actually leaves the server. I can't seem to find the cause of the error. Any help would be appreciated. I didn't have to do anything actually on iis 10, but iis 7.5 keeps on aborting.


Viewing all articles
Browse latest Browse all 488

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>