Connect with OPC UA Server where User Authentication Method is only "Certificate" #1737
jchirantan
started this conversation in
General
Replies: 1 comment 2 replies
-
|
This is the approach. We've discussed this in the past and you have to configure the user certificate in Prosys in some special directory; have you done that? |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi @kevinherron,
I want to connect to Prosys OPC UA Simulation Server with user authentication method is "Certificate".
How can I create client so that, I can connect to this server?
I have tried using X509CertificateIdentifier instead of AnonymousIdentifier, but got exception "Bad_IdentityTokenRejected (0x80210000) "The user identity token is valid but the server has rejected it.""
Following is the code I am using:
OpcUaClientConfig config = OpcUaClientConfig.builder()
.setApplicationUri("urn:eclipse:milo:client:applicationUriNotConfigured")
.setEndpoint(this.endpoint)
.setCertificate(securityIdentClientCert.getCertificate())
.setCertificateChain(new X509Certificate[] {securityIdentClientCert.getCertificate()})
.setKeyPair(new KeyPair(securityIdentClientCert.getCertificate().getPublicKey(), securityIdentClientCert.getPrivateKey()))
.setIdentityProvider(new X509IdentityProvider(securityIdentClientCert.getCertificate(), securityIdentClientCert.getPrivateKey()))
.build();
clientLocal = OpcUaClient.create(config);
clientLocal.connectAsync().get();
I am using Eclipse milo SDK version 1.1.0.
Beta Was this translation helpful? Give feedback.
All reactions