all groups > iis security > october 2003 >
You're in the

iis security

group:

script fails first time with "accept client certificates"


script fails first time with "accept client certificates" Martin Peters
10/30/2003 2:52:48 PM
iis security:
I like to secure my ASP with either a username and
password or a client certificate. Therefore I have
set "require SSL" and "accept client certificates".

However, my script fails for the first document that I
send if I use a username and password. The error on the
client is: "There is a security problem.". There is no
entry in the IIS server log file.

There is no problem when I supply a client certificate.
Also, there is no problem if I set "ignore client
certificates".

I have tried with MSXML3 SP2 and MSXML4 SP2 without
any difference in behaviour. Can someone explain why
I get an error for the first message?

<job id="eSCLSend">
<script language="JScript">

submitDocument("document1.xml");
submitDocument("document2.xml");

function submitDocument(inputdoc) {
var httpOb = new ActiveXObject("MSXML2.XMLHTTP");

httpOb.open
("POST", "https://servername/ReceiveXML.asp",
false, "username", "password");
httpOb.setRequestHeader("Content-Type", "text/xml");

var fso, ts, msg;
var ForReading = 1;
fso = new ActiveXObject("Scripting.FileSystemObject");
ts = fso.OpenTextFile(inputdoc, ForReading);
msg = ts.ReadAll();
ts.Close();

try {
httpOb.send(msg);
} catch(e)
WScript.Echo(e.number);
WScript.Echo(e.description);
}

WScript.Echo(httpOb.statusText);
WScript.Echo(httpOb.responseText);
}
</script>
RE: script fails first time with "accept client certificates" v-wdxu NO[at]SPAM online.microsoft.com
10/31/2003 1:37:41 AM
Hi Martin,

So far as I know on this issue, XMLHTTP starts to support SSL with client certificates from XML 3.0 sp1. There is one kb article which introduce
detailed information abotu this issue for you. Please go to:
301429 HOWTO: Install Client Certificate on IIS Server for ServerXMLHTTP
http://support.microsoft.com/?id=301429

Please feel free to let me know if you have any further questions.

Does this answer your question? Thank you for using Microsoft NewsGroup!

Wei-Dong Xu
Microsoft Product Support Services
Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

RE: script fails first time with "accept client certificates" Martin Peters
10/31/2003 1:52:35 AM
Hi,

I have basic authentication enabled. File security is
enabled and works, because with "ignore client
certificates" it works without problems.

Kind regards,

Martin
[quoted text, click to view]
you should check which authentication method you are
using. It is suggested that you
[quoted text, click to view]
that you can take full advantage of windows security
features. Furthermore, since you
[quoted text, click to view]
authentication will also help you a lot. Then, you can
also check whether the user account
[quoted text, click to view]
RE: script fails first time with "accept client certificates" v-wdxu NO[at]SPAM online.microsoft.com
10/31/2003 1:53:17 AM
Hi Martin,

If you want to use username and password for the request, you should check which authentication method you are using. It is suggested that you
use Windows integrated authentication method for you so that you can take full advantage of windows security features. Furthermore, since you
choose SSL to secure the connection, Basic and digest authentication will also help you a lot. Then, you can also check whether the user account
ha permisson to that asp page. You can right click the page and check that from security property.

Please feel free to let me know if you have any further questions.

Does this answer your question? Thank you for using Microsoft NewsGroup!

Wei-Dong Xu
Microsoft Product Support Services
Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

RE: script fails first time with "accept client certificates" Martin Peters
10/31/2003 2:01:18 AM
Hi,

I've read this article, but my problem is a little
different. I've tried with XML 3.0 SP2 and 4.0 SP2
without luck.

Martin
[quoted text, click to view]
SSL with client certificates from XML 3.0 sp1. There is
one kb article which introduce
[quoted text, click to view]
RE: script fails first time with "accept client certificates" v-wdxu NO[at]SPAM online.microsoft.com
11/1/2003 5:49:08 AM
Hi Martin,

Thank you for replying!

I'd suggest you can test whether you can link to your server with client certificate for html files. If there is some errors, some kb articles may help
you some on this issue.
252657 IIS 5.0: HTTP 403.16 Forbidden: Client Certificate Untrusted or Invalid.
http://support.microsoft.com/?id=252657

332077 IIS 6.0: Computer Must Trust All Certification Authorities Trusted by
http://support.microsoft.com/?id=332077

Furthermore, it will be appreciated that you tell me which OS you are using and whether there is proxies between your client and server.

Thank you for using Microsoft NewsGroup!

Wei-Dong Xu
Microsoft Product Support Services
Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

RE: script fails first time with "accept client certificates" Martin Peters
11/3/2003 12:24:33 PM
Hi Wei-Dong,

I'm not using a client certificate, so I'm afraid the
articles do not apply.

I tried with a Windows 2000 and Windows 2003 server, both
the same behaviour. The client is Windows 2000.

It should be easy to reproduce with the script in my
initial post.

Kind regards,

Martin
[quoted text, click to view]
server with client certificate for html files. If there is
some errors, some kb articles may help
[quoted text, click to view]
which OS you are using and whether there is proxies
between your client and server.
[quoted text, click to view]
RE: script fails first time with "accept client certificates" Martin Peters
11/4/2003 1:15:56 PM
Thank you for your answers. The point is that I did not
select *require client certificates", but "accept client
certificates". This option means that a client certificate
is optional. My belief is that the XMLHTTP class does not
handle this option properly. Or perhaps a programming
error in my script. Anyway, I will pursue this through
formal channels to product support and post back the
answer from them.

Kind regards,

Martin

[quoted text, click to view]
the IIS with a certificate, it means that you should
install a valid client certificate in the client
[quoted text, click to view]
client certificate in the client, IIS will not accept any
request from the client. I think this is the
[quoted text, click to view]
RE: script fails first time with "accept client certificates" v-wdxu NO[at]SPAM online.microsoft.com
11/4/2003 4:43:56 PM
Hi Martin,

Thank you for replying!

If you select "requir Client certificate" and configure the IIS with a certificate, it means that you should install a valid client certificate in the client
so that IIS can accept the client request. Without a client certificate in the client, IIS will not accept any request from the client. I think this is the
reason why you get the security error message.

Please feel free to let me know if you have any further questions.

Does this answer your question? Thank you for using Microsoft NewsGroup!

Wei-Dong Xu
Microsoft Product Support Services
Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

RE: script fails first time with "accept client certificates" v-wdxu NO[at]SPAM online.microsoft.com
11/5/2003 8:26:24 AM
Hi Martin,

Thank you for replying!

It will be appreciated that you send one demo project for me so that I can test this for you. And tell me which OS you are using and your networking
configuration. If it is convenience for you, please capture one screen for the detailed error information. Thank you very much in advance!

Thank you for using Microsoft NewsGroup!

Wei-Dong Xu
Microsoft Product Support Services
Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

AddThis Social Bookmark Button