I generated a LetsEncrypt certificate and configured my nodejs server(v16.17.1) with this options:
var options = {
key: fs.readFileSync('/etc/letsencrypt/live/drogoapp.xyz/privkey.pem','utf8'),
cert: fs.readFileSync('/etc/letsencrypt/live/drogoapp.xyz/fullchain.pem','utf8'),
ca:fs.readFileSync('/etc/letsencrypt/live/drogoapp.xyz/chain.pem','utf8')
};
I can succesfully reach my server https through browsers. But when i try it from my android app using volley i get this error:
javax.net.ssl.SSLHandshakeException: java.security.cert.CertPathValidatorException: Trust anchor for certification path not found.
I tested this website to find where is the error and here is the result:
https://www.ssllabs.com/ssltest/analyze.html?d=www.drogoapp.xyz
There is a name mismatch but i am not sure it is the issue. It should be because i typed with www because ssllabs didnt supported without it.
Why my certificate is not trusted? This should be the reason why i cannot connect through android app
By the way i disabled letsencrypt certificate for now so if you use a tool to do a test it wouldnt work