views:

3000

answers:

4

I have a unique situation where I need to implement client certificate authentication over HTTPS between IE browser and IIS 6. The browser and IIS are separated by a firewall that only allows the browser to connect to IIS on the SSL port.

We have an internal certificate server on the same network as IIS. I've generated an SSL server cert for IIS and that is installed. I configured IIS to only allow SSL, require client certificates.

The limitation here is the browser machine is on a disconnected network, so I can't go to the CA's http://caserver/CertSrv URL and request a client cert like you normally would.

I figured if there were a way that I could generate a CSR against the Root CA's public key, I can copy it to the CA server to generate the client cert. But, there appears to be no provision in IE or the Certificates MMC to do this. The Certificates MMC seems to require a direct connection to the CA.

Has anyone solved this before?

FYI, All servers referenced run Windows Server 2003.

Update: Thanks to Jonas Oberschweiber and Mark Sutton for pointing out the CertReq.exe command line tool. Using this, I've generated a CSR, and consequently a client certificate that installs successfully. However, IE is apparently not sending this client cert when accessing the IIS server in question; it still generates a 403.7 "Forbidden: SSL client certificate is required." I suspect that the reason is that the Subject field of the client cert does not match the user id of the account running IE, thus perhaps not sending a mismatching client cert. The Subject matches that of the user I used to submit the CSR and generate the client cert on the other end of the firewall.

Does the Subject field matter? Is there something else I need to do to enable IE to send this cert?

A: 

You sound like you have already tried a couple of things so my guess is that you are already aware of these, but I'm going to post them anyway, just in case: Certificate Command Line Tools. I am not sure, however, if they do what you want.

Jonas Oberschweiber
A: 

Go the http://caserver/CertSrv site that you mentioned using a 3rd computer that can see the CA server. Select the 3rd option, download a CA cert, cert chai, or CRL. On the next page select 'Download CA Certificate Chain', which will download the p7b file. Using a flash drive (or email, etc) transfer this to the other computer which will allow you to import it into the trusted root servers in IE.

http://technet.microsoft.com/en-us/library/cc787796.aspx

Aaron
I'm afraid this isn't what I was asking for. Copying over the Root CA cert chain is trivial. I need to generate a client certificate for the disconnected computer.
spoulson
A: 

Use the certreq command on your client as follows

certreq -new -f filein c:\certrequest.req

Here is and example of the filein

[Version] Signature="$Windows NT$"

[NewRequest]
Subject="CN=dc1.extranet.frbrikam.com"
EncipherOnly = False
Exportable = False
KeyLength = 1024
KeySpec = 1
KeyUsage = 0xA0
MachineKeySet = True
ProviderName = "Microsoft RSA SChannel Cryptographic Provider"
ProviderType = 12
RequestType = CMC

[RequestAttributes] CertificateTemplate=TLSServer

Replace the CertificateTemplate with the name of your certificate template

Once you have your request file you need to take it to the certificate authority on a usb stick and use the web enrolment interface as usual to process the request file.

Take the output certificate back to the client open it and click install.

Mark Sutton
This worked to generate a CSR and then a client cert. I can also install the cert on the disconnected server. But, IE doesn't recognize it under Tools/Options/Cert/Personal, presumably because the cert is issued to the user id that generated the client cert, not the user id that generated the CSR.
spoulson
So, in IE I get a 403.7 "Client certificate required" when accessing the IIS server.
spoulson
A: 

Suggestiong for the update, just in case - what is the trusted cert list of in the server?

Subject DN being the same as Windows username has never been a problem for me - although I don't use IIS much. However, somewhere in IIS there is sure to be a trusted certificate list. This error sounds to me like the server's trusted certs list does not include the CA or Root CA that issued the client certificate.

This is particularly true if you never get a certificate selection popup window in IE when you hit the IIS server - even though you have a certificate configured in your IE cert store. That means that the client hit the server, the server gave a list of trusted certs and the client didn't have a cert that fit the list. So the SSL session went to the Forbidden error state.

If the certificate selection window popped up, and you selected and sent the cert, there may be other configuration problems on the server side..

bethlakshmi