-
-
Notifications
You must be signed in to change notification settings - Fork 83
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
SSL error when porting from node:tls with a self sign certificate (SSLV3_ALERT_HANDSHAKE_FAILURE or CertPathValidatorException) #190
Comments
Ok I found the fix and basically it implies to save the cert and the private key inside a keystore, I forked it. |
you mean the private key of client or server? |
private key of client Now I will try to implement getCertificate and getPeerCertificate, on android it should be easy but no idea about ios. |
Hello @vricosti, |
I don't think so because I have only implemented on android, I should try it on iOS but don't know yet if it will be complicated or not... |
Hi,
I am trying to port a library androidtv-remote that was originally designed to run in a node environment to be able to run inside a react-native app.
For the ssl part it was using node:tls and it works fine with it.
The android device I am connecting to is using a self signed certificate and the app is using a self signed certificate too.
Here is the server ssl characteristics:
The application I am using is available here: https://github.com/vricosti/TestAndroidTVRemoteApp
At the beginning a self signed certificate is generated inside packages/androidtv-remote/src/certificate/CertificateGenerator.js
this.cert object holds 2 fields, key and cert holding private key and certificate in pem
and then this certificate was used to start the tls connection:
I have the following error:
if use
rejectUnauthorized: true
So in both case it fails...
I tried to add the server certificate and pass it but same error:
and I even check that inside the android code it receives the passed certificate...
thanks in advance
The text was updated successfully, but these errors were encountered: