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.

Exception thrown: 'OpcLabs.EasyOpc.UA.OperationModel.UAException' in mscorlib.dl

More
03 Jun 2021 11:30 #9724 by hcvoort
Some additional text:

This exception was originally thrown at this call stack:
System.Security.Cryptography.CryptographicException.ThrowCryptographicException(int)
System.Security.Cryptography.X509Certificates.X509Utils.LoadCertFromBlob(byte[], System.IntPtr, uint, bool, System.Security.Cryptography.X509Certificates.SafeCertContextHandle)
System.Security.Cryptography.X509Certificates.X509Certificate.LoadCertificateFromBlob(byte[], object, System.Security.Cryptography.X509Certificates.X509KeyStorageFlags)
System.Security.Cryptography.X509Certificates.X509Certificate2.X509Certificate2(byte[], string, System.Security.Cryptography.X509Certificates.X509KeyStorageFlags)
Opc.Ua.CertificateFactory.Load(System.Security.Cryptography.X509Certificates.X509Certificate2, bool)
Opc.Ua.CertificateIdentifier.Find(bool)
Opc.Ua.Configuration.ApplicationInstance.CheckApplicationInstanceCertificate(bool, ushort)
OpcLabs.EasyOpc.UA.Toolkit.UAClientEngineBase.ValidateOrCreateClientCertificate.AnonymousMethod__2()
OpcLabs.EasyOpc.UA.Toolkit.UAEngineBase.PerformSdkAction(OpcLabs.EasyOpc.UA.Toolkit.UASdkCallType, System.Func<System.IDisposable>, string, System.Action)

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

More
03 Jun 2021 11:28 #9723 by hcvoort
Ok, thanks:

The inner exception is:
CryptographicException: The specified network password is not correct.

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

More
03 Jun 2021 10:10 #9722 by support
Hello,

I am somewhat confused, because you have written that you are doing debugging in Visual Studio. With that, it should be possible to have it break into the debugger when the exception is thrown, and then inspect it.

If Visual Studio is not doing it by itself:

1. In VS, do Debug -> Windows -> Exception settings.
2. In "Exception Settings" window, right-click "Common Language Runtime Exceptions" and select "Add".
3. Type OpcLabs.EasyOpc.UA.OperationModel.UAException and press Enter.
4. Run the program (Debug -> Start Debugging).

Hopefully it will now break into the debugger.

Best regards

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

More
03 Jun 2021 08:02 #9720 by hcvoort
I can nog get the inner exception as the app crashes constantly. Do you have any advice to get it?

What I can see in the windows eventviewer if I run the build .exe is the following:

Faulting application name: hmiver005.exe, version: 5.0.0.0, time stamp: 0x60b88b62
Faulting module name: ntdll.dll, version: 10.0.19041.964, time stamp: 0xb7db0838
Exception code: 0xc0000374
Fault offset: 0x000e6b83
Faulting process id: 0x279c
Faulting application start time: 0x01d7584e476cff00
Faulting application path: D:\\HMI\hmi\bin\Release\hmiver005.exe
Faulting module path: C:\WINDOWS\SYSTEM32\ntdll.dll
Report Id: 76393a56-1d1f-46c4-bd6e-c34a31d39eb0
Faulting package full name:
Faulting package-relative application ID:

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

More
02 Jun 2021 14:58 #9719 by support
Hello.

Can you please provide the text of the inner exception (the CryptographicException) as well?
Thank you

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

More
02 Jun 2021 14:29 - 02 Jun 2021 14:30 #9718 by hcvoort
Dear opc labs admin,

I am working on an application I build several years ago, with QuickOPC 2016.2 al written in C#. The application was running fine during debugging in Visual Studio.
I wanted to cange some code and do debugging this week and ran into this error which crashes the application all the time:

Exception thrown: 'OpcLabs.EasyOpc.UA.OperationModel.UAException' in mscorlib.dll
An OPC-UA operation failure with error code -1 (0xFFFFFFFF) occurred, originating from 'mscorlib'. The inner exception, of type 'System.Security.Cryptography.CryptographicException', contains details about the problem.


When I remove all EasyUAClient objects, the application runs fine. Does this have something to do with windows certificates? Could you please guide me in resolving this issue? Support will be highly appreciated.

Im am using Visual Studio 2015 (VS 2019 gives the same issues)

Carsten
Last edit: 02 Jun 2021 14:30 by hcvoort.

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

Moderators: support
Time to create page: 0.054 seconds