I have a winform app that is consuming WebService via SSL connection.
We installed the digital certificate for that and the winform app is
loading that cert at run time.
Code in VB.net looks like this:
Dim consumeWebService As New MyWSProxyClass
Dim cert As
System.Security.Cryptography.X509Certificates.X509 Certificate
Try
With consumeWebService
..ClientCertificates.Add(cert.CreateFromCertFile(" c:\eldcert.cer"))
.Credentials =
System.Net.CredentialCache.DefaultCredentials
.Discover()
End With
Problem is that it only runs under the user that installed the
certificate. If any other user logs into the same machine and tries to
run this app it fails. It has problems with accessing the certificates.
Can anyone help me out to solve this problem?
Is it possible to grant access to the certificate for other users and
not only to administrative users?
I tried to use MS certificate configuration tool but it didn't work for
me.
I used this command to try to give access for other accounts to the
certificate:
WinHttpCertCfg.exe -g -c CURRENT_USER\MY -s <cert-a
<DOMAIN>\<USER_NAME>
It says that permissions are granted but the app does not work still.
Thank you,
igor