Long story: I can access Node OPCUA server from Python opc-client, Prosys OPCUA Explorer, and UaExpert but not from RS OPCUA driver with BadIdentityTokenInvalid error. I decided to compile Reference Client from OPCFoundation (with same branch as use by KpOpcUa, with hard coded certificate check domain disabled) and voila… I can access Node OPCUA server. So, my above change based on what I have found in OPCFoundation example codes.
Thank you for the pull request, but I can’t merge it because of the following:
1. Pull requests in this repository should be targeted to the develop branch.
2. Removing the lines makes impossible to apply the corresponding configuration options.
3. You should try changing the device configuration in KpOpcUa_XXX.xml to use the correct SecurityMode and SecurityPolicy.
Please try the 3rd item and let me know about the result.
I can connect with every 7 combination supported by Node OPCUA from UaExpert dan Prosys including “None and None” but only “Sign & encrypt and Basic256Sha256” with KpOpcUa. No problem, I can connect to Node OPCUA server now without modified source code.