Request Aborted error from Android
vikramIde opened this issue · 2 comments
Bug description
When i try to hit a node server running from an android device, In android device I am getting the Request Aborted
issue.
So I read in the readme that when browser shows SSL error we should regenerate the certs I did that as well.
Btw this error doesn't exist in server running without https on localhost.
with android version lower than 9.
The andorid version >9 has made api's to be compulsory with https, and that's why we used this package but we are getting this error .
Any thoughts in direction would be appreciated
Regards
Hi @vikramIde,
I'm not sure if you are running the server on your laptop or your Android device.
Case 1: laptop or remote server
https-localhost
is meant to be used, well, on localhost. It's definitely NOT a production server. It generates a self-signed certificate and makes your machine trust it. If you visit the server on the localhost, your machine will accept the certificate as safe since you have thought the machine recognizes it. From whatever else machine, the certificate is unknown, and since it's self-signed, it will mark the connection as unsafe by default.
If you are running the server on your laptop and accessing the endpoint from your Android device, the Android device won't trust it.
Case 2: running https-localhost
on your Android device
I don't really know if it would work. Theoretically, since Android is Linux, it could run correctly. You will probably need to run it as root the first time to generate and trust the certificate. In this case, you will need to root your device, which I suggest not to, unless it's a test device and you really need to.
Marked as stale for no activity in the past 60 days. In 7 days it will be closed unless new activity.