-
Notifications
You must be signed in to change notification settings - Fork 662
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AttributeError: 'bytearray' object has no attribute 'public_key' #1533
Comments
I forgot to add that but this is how I structured my PKI, my server_cert is my CA.
|
this library is DEPRICATED so dont use it with regards to security! your issue however is you are mixing transport security with authorization... your client use the cert and key for auth aswell which the server do not support in the old version! |
Thank you Andreas, this brings some clarity to my problem, I intend to use it momentarily just to get the feel for it, thinking about migrating the actual solution to the asyncio-opcua or node-opcua |
I'm still struggling with this approach. |
From the callstack the server certificate is not set correctly. This should be done when the server starts.
|
Hey, this helped, I had a little more debugging to do but it seems to be working fine now, I'll do some testing tomorrow and if it works out I'll consider it solved and close this discussion! Thank you so much. |
Hi there,
I'm struggling to get my client/server running with secure policies, cryptography, and authentication, I understand this project is deprecated, but I use it for a project at work. Before refactoring and migrating to the new tools, I want to establish secure SSL communication to satisfy client needs.
Here is a simple server I instantiated to develop the PKI and learn how to set this up before adapting it to production.
Here is a simple client I instantiated to communicate with the server and get my certification and private key authenticated.
And here is the error, when I try to connect the client with the server using not just SignAndEncrypt, but Sign as well, only Anonymous access is currently working.
My initial understanding was that my certification was missing a public key, I went in and studied a little more on openssl and upon debugging, I could easily see my Subject Public Key Info pointing out that a rsaEncryption had generated a 2048bit public key, and the modulus after it, if the debugging command helps confirm it, here is the command I wrote:
openssl x509 -in cert/server_cert.pem -pubkey -noout -text
@AndreasHeine I searched the repo's issues and discussions as well as others and saw you as an active moderator at least whenever this used to be more active, I understand this error might be a misuse of some features, but I ask for some help nonetheless as this topic is hard to research upon, and I couldn't find any more info on it.
When using the client UAExpert, same thing happens in any type of Basic256Sha256 secure policy, I don't know what to do anymore. If you decide to help and need any more info on it, I'll gladly provide.
Thanks in advance!
The text was updated successfully, but these errors were encountered: