Solved

msxml3.dll - Access is denied.

Posted on 2011-09-13
11
3,338 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
Comment Utility
did you check here
0
 
LVL 17

Expert Comment

by:Shanmuga Sundaram
Comment Utility
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
Comment Utility
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
Comment Utility
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
Comment Utility
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
Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

 
LVL 3

Author Comment

by:harris9999
Comment Utility
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
Comment Utility
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
Comment Utility
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
Comment Utility
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
Comment Utility
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
Comment Utility
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

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Introduction Knockoutjs (Knockout) is a JavaScript framework (Model View ViewModel or MVVM framework).   The main ideology behind Knockout is to control from JavaScript how a page looks whilst creating an engaging user experience in the least …
Lync server 2013 Backup Service Error ID 4049 – After File Share Migration
The viewer will learn how to count occurrences of each item in an array.
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…

744 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

16 Experts available now in Live!

Get 1:1 Help Now