Page 1 of 1

About client certificate on "D:" drive

Posted: 07 Jan 2020, 02:21
by k.maeda
Hi SupportTeam,

I'm developing OPC UA Client with C# and "UaSDKNet".
I have question about client certificate.

I trying connect client to server in local machine.
This local machine has installed Windows on "D:" drive.

In this, Failed to connect,
and output the following exception.
-----------------------
StatusCode : BadCertificateInvalid
ErrorMessage: "The client application does not have a certificate assigned. Secured connections are not possible."
-----------------------

SDK log not output error log, and terminated processing for connect.
-----------------------
03:37.12|0001|02|5|<= Discovery.EndGetEndpoints
03:37.12|0001|02|5|=> Session.BeginConnect(EndpointUrl=opc.tcp://XXXXXXX:4841)
03:37.13|0001|01|5|<= ApplicationInstance.Start
-----------------------

I checked to exist client certificate.
If start on administrator, this not occured.

But, this not occured some machine,
and I couldn't identified conditions that occurred.

Are you aware of any of the above error caused by "D:" drive?
Or Can SDK log output details of client certificate error?

Re: About client certificate on "D:" drive

Posted: 13 Jan 2020, 12:20
by Support Team
Hi,

We did not test our example applications on machines with windows installed at other drives than C. If there are are problems finding the certificate store related to the path to the windows installation, then you should configure the the absolute path for the certificate stores in your application configuration (ApplicationCertificate in app.config or in code).

Re: About client certificate on "D:" drive

Posted: 03 Feb 2020, 05:18
by k.maeda
Thanks SupportTeam,

I could not resolve even if changed client certificate path to full path.

The following are points of concern for the processing of the SDK.
- Certificate cannot be loaded with "SecurityUtils.LoadCertificate()"(*1) even if the certificate already exists(*2,*3).
- "ApplicationInstance.AutoCreateCertificate" in "new Session()" specified the return value of "CertificateFactory.CreateCertificate()", but "Session.Connect()" result was "The client application does not have a certificate assigned. Secured connections are not possible.".

*1) The specified certificate path is a full path.
*2) The certificate was created with "CertificateFactory.CreateCertificate()".
*3) The subject specified for "SecurityUtils.LoadCertificate()" and "CertificateFactory.CreateCertificate()" are the same.

Do you have any information about these?