Solved

msxml3.dll - Access is denied.

Posted on 2011-09-13
11
3,442 Views
Last Modified: 2012-05-12
msxml3.dll

 error '80070005'

Access is denied.

Just started to get the above error since anabling SSL on my local machine.


My Code is

Dim objXMLHTTP, xml
	
	  ' Create an xmlhttp object:
	  Set xml = Server.CreateObject("Microsoft.XMLHTTP")
	  ' Or, for version 3.0 of XMLHTTP, use:
	  ' Set xml = Server.CreateObject("MSXML2.ServerXMLHTTP")
	
	  ' Opens the connection to the remote server.
	  xml.Open "GET", theurl, False
		
	  ' Actually Sends the request and returns the data:
	  xml.Send       'Line 50

Open in new window


the error is occuring on the xml.Send line
Why is this happening?
0
Comment
Question by:harris9999
  • 5
  • 5
11 Comments
 
LVL 17

Expert Comment

by:Shanmuga Sundaram
ID: 36528410
did you check here
0
 
LVL 17

Expert Comment

by:Shanmuga Sundaram
ID: 36528417
if you are using like
Set xml = Server.CreateObject("Microsoft.XMLHTTP")

then try replacing it similar to given below and check whether it helps

Set xml = Server.CreateObject("MSXML2.ServerXMLHTTP.4.0")
0
 
LVL 3

Author Comment

by:harris9999
ID: 36528438
Ah when I change it to that line I get:

msxml4.dll

 error '80072f06'

The host name in the certificate is invalid or does not match
0
 
LVL 9

Expert Comment

by:djpazza
ID: 36528471
Can you post the full code of the example above as I can not see the url you are trying to read?

'theurl ' should be set to the url of the remote page
Dim objXMLHTTP, xml
	
	  ' Create an xmlhttp object:
	  Set xml = Server.CreateObject("Microsoft.XMLHTTP")
	  ' Or, for version 3.0 of XMLHTTP, use:
	  ' Set xml = Server.CreateObject("MSXML2.ServerXMLHTTP")
	
          theurl = "http://www.yahoo.com"
	  ' Opens the connection to the remote server.
	  xml.Open "GET", theurl, False
		
	  ' Actually Sends the request and returns the data:
	  xml.Send       'Line 50

Toggle HighlightingOpen in New WindowSelect All

Open in new window

0
 
LVL 17

Expert Comment

by:Shanmuga Sundaram
ID: 36528490
For this error "The host name in the certificate is invalid or does not match" did you check the below given url.

http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/XML/Q_20980045.html
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 3

Author Comment

by:harris9999
ID: 36528498
theurl is set to the url of the remote page

It was all working fine until I enabled SSL. Is there any way to get IIS on my local PC to accept the self signed certificate.

		remoteurl=rsD("RemoteURL")
	
	urlvar="?un=" & username & "&p=" & password & "&ver=0"
	urlvar=EncryptString(urlvar)
	
	theurl=remoteurl & "?v=" & urlvar
	
	  Dim objXMLHTTP, xml
	
	  ' Create an xmlhttp object:
	  'Set xml = Server.CreateObject("Microsoft.XMLHTTP")
	  Set xml = Server.CreateObject("MSXML2.ServerXMLHTTP.4.0") 
	  ' Or, for version 3.0 of XMLHTTP, use:
	  ' Set xml = Server.CreateObject("MSXML2.ServerXMLHTTP")
	
	  ' Opens the connection to the remote server.
	  xml.Open "GET", theurl, False
		
	  ' Actually Sends the request and returns the data:
	  xml.Send
	
	  'Display the HTML both as HTML and as text
	'  Response.Write "<h1>The HTML text</h1><xmp>"
	'  Response.Write xml.responseText
	'  Response.Write "</xmp><p><hr><p><h1>The HTML Output</h1>"
	
	  remoteresult= xml.responseText
	  'response.Write("Remote Results=" & remoteresult)
	  
	  Set xml = Nothing

Open in new window

0
 
LVL 3

Author Comment

by:harris9999
ID: 36528537
shasunder,
Where exactly do I apply that line in my code?

tried as below but I get the error:


Microsoft VBScript compilation

error '800a0414'

Cannot use parentheses when calling a Sub

/js/ajax/login.asp, line 49
xml.setOption(2, xml.getOption(2) - 13056)



	  Dim objXMLHTTP, xml
	
	  ' Create an xmlhttp object:
	  'Set xml = Server.CreateObject("Microsoft.XMLHTTP")
	  Set xml = Server.CreateObject("MSXML2.ServerXMLHTTP.4.0") 
 
	  ' Or, for version 3.0 of XMLHTTP, use:
	  ' Set xml = Server.CreateObject("MSXML2.ServerXMLHTTP")
	
	  ' Opens the connection to the remote server.
	  xml.setOption(2, xml.getOption(2) - 13056)
	  xml.Open "GET", theurl, False
		
	  ' Actually Sends the request and returns the data:
	  xml.Send
	
	  'Display the HTML both as HTML and as text
	'  Response.Write "<h1>The HTML text</h1><xmp>"
	'  Response.Write xml.responseText
	'  Response.Write "</xmp><p><hr><p><h1>The HTML Output</h1>"
	
	  remoteresult= xml.responseText
	  'response.Write("Remote Results=" & remoteresult)
	  
	  Set xml = Nothing

Open in new window

0
 
LVL 17

Expert Comment

by:Shanmuga Sundaram
ID: 36528559
change

xml.setOption(2, xml.getOption(2) - 13056)

as

xml.setOption 2, xml.getOption(2) - 13056

and check whether it helps
0
 
LVL 3

Author Comment

by:harris9999
ID: 36528575
Changed that line and I get this error again:


msxml4.dll

 error '80072f06'

The host name in the certificate is invalid or does not match
0
 
LVL 17

Accepted Solution

by:
Shanmuga Sundaram earned 500 total points
ID: 36528604
check whether this url helps.


'Error: -2147012858 The code below solves the ocurrence of this error
' Description: The host name in the certificate is invalid or does not match
Const SXH_SERVER_CERT_IGNORE_ALL_SERVER_ERRORS = 13056
oxmlhttp.setOption 2, SXH_SERVER_CERT_IGNORE_ALL_SERVER_ERRORS
0
 
LVL 3

Author Comment

by:harris9999
ID: 36528622
I'd just found that one so replaced my line with:

 xml.setOption 2, 13056

So cheers for your help!!

And it gets past that but causes an error elsewhere, maybe another question for that one.
All since enabling SSL.
0

Featured Post

Control application downtime with dependency maps

Visualize the interdependencies between application components better with Applications Manager's automated application discovery and dependency mapping feature. Resolve performance issues faster by quickly isolating problematic components.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you don't have the right permissions set for your WordPress location in IIS, you won't be able to perform automatic updates. Here's how to fix the problem.
Lync server 2013 or Skype for business Backup Service Error ID 4049 – After File Share Migration
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…
HTML5 has deprecated a few of the older ways of showing media as well as offering up a new way to create games and animations. Audio, video, and canvas are just a few of the adjustments made between XHTML and HTML5. As we learned in our last micr…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now