Professional OPC
Development Tools

logos

Online Forums

Technical support is provided through Support Forums below. Anybody can view them; you need to Register/Login to our site (see links in upper right corner) in order to Post questions. You do not have to be a licensed user of our product.

Please read Rules for forum posts before reporting your issue or asking a question. OPC Labs team is actively monitoring the forums, and replies as soon as possible. Various technical information can also be found in our Knowledge Base. For your convenience, we have also assembled a Frequently Asked Questions page.

Do not use the Contact page for technical issues.

Server nonce, SIEMENS Sinumerik OPC UA server

More
16 May 2023 14:23 #11735 by support
Hello.
After considering all the pros and cons, we have decided to make the original behavior the default in newer versions as well.

Please download and rebuild your project with the most recent version, i.e. 5.70.1202.1 (or later) - it is now on our Web site, and on nuget.org.
Note that we could not fully verify the change, because we do not have a "faulty" server available here.

Best regards
The following user(s) said Thank You: Vosecky

Please Log in or Create an account to join the conversation.

More
15 May 2023 11:12 #11734 by Vosecky
Hello OPC Labs.

To be honest, for the customer is much easier to buy a new SW which communicates with the OPC server rather than upgrade the CNC machine.

SIEMENS Sinumerik OPC UA server is the most frequently connected OPC Server.

We have many customers around the world and they will experience such issue in next weeks.

We are getting this error now from more customers around the world (India, China, Germany, ...)

I would like to ask you if you could work with us on some solution which will allow us to connect to this OPC Server.

Thank you.

Please Log in or Create an account to join the conversation.

More
15 May 2023 10:40 #11733 by support
Hello.

The server is not fully OPC UA compliant, and the newer QuickOPC is stricter in security checks.
The server nonce must be long enough (the required length depends on the security policy), it must not be all zeros, and it must be different each time. The OPC UA server has violated some of it.

The primary choice here should be to request that the vendor fixes the server.

It might be possible to figure out some workaround on the client side, but it would be a) awkward, b) less secure.

Regards

Please Log in or Create an account to join the conversation.

More
15 May 2023 10:24 #11732 by Vosecky
Dear support,

Since last update to 5.70.1152 we are getting this error when we are trying to connect to the SIEMENS SINUMERIK OPC server. (complete error log is in the attachment)

What I can do with this error?

File Attachment:

File Name: OPC_error_M355.txt
File Size:172 KB


D:18.56.13.0526:6339: OPC Client: OPC ERR: <nsu=SinumerikVarProvider;ns=2;s=/Channel/State/acProg || OpcLabs.EasyOpc.UA.Engine.UAEngineException: UA SDK error (System.Reflection.TargetInvocationException) in 'static Session.Create'. Exception has been thrown by the target of an invocation.
+ Connection attempt #703; last connected at 01-01-0001 00:00:00 (local); unconnected for 02:27:28.8910000.
+ The client method called (or event/callback invoked) was 'DataChangeNotification'. ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> Opc.Ua.ServiceResultException: The server nonce has not the correct length or is not random enough.
at Opc.Ua.Client.Session.ValidateServerNonce(IUserIdentity identity, Byte[] serverNonce, String securityPolicyUri, Byte[] previousServerNonce, MessageSecurityMode channelSecurityMode)
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at OpcLabs.EasyOpc.UA.Sdk.Shims.SessionShim.ValidateServerNonce(IUserIdentity identity, Byte[] serverNonce, String securityPolicyUri, Byte[] previousServerNonce, MessageSecurityMode channelSecurityMode)
at OpcLabs.EasyOpc.UA.Sdk.Shims.SessionShim.Open2(String sessionName, UInt32 sessionTimeout, IUserIdentity identity, IList`1 preferredLocales, Boolean checkDomain)
at OpcLabs.EasyOpc.UA.Sdk.Shims.SessionShim.<Create>d__3.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at OpcLabs.EasyOpc.UA.Toolkit.Sdk.ToolkitSession.<Create>d__2.MoveNext()
--- End of inner exception stack trace ---> <nsu=SinumerikVarProvider;ns=2;s=/Channel/State/totalParts || OpcLabs.EasyOpc.UA.Engine.UAEngineException: UA SDK error (System.Reflection.TargetInvocationException) in 'static Session.Create'. Exception has been thrown by the target of an invocation.
Attachments:

Please Log in or Create an account to join the conversation.

Moderators: support
Time to create page: 0.060 seconds