i want to install the CA certificate which required to use HttpCanary, but my phone says that i can't install in app also i don't know where the CA file that i install. So it needs root to solve that problem. Is there an any way to install without root? Thank You for your answers, sorry for may bad english.
1 Answers
Android 11 (or at least my LineageOS 18.1) is a pain, since all certificates must be installed directly from the Settings App, but HttpCanary doesn't give you the raw certificate file.
I found a Chinese post and followed it with the help of Google Translator.
this is the CA file, you can name it HttpCanary.pem
and install the it directly from [Settings > Security > Encryption & Credentials > Install a certificate > CA certificate] but the certificate will only be User Trusted, to make it System Trusted you WILL need root access.
[ROOT REQUIRED FOR THE FOLLOWING STEPS]
To install the certificate and make it System Trusted + make HttpCanary detect it, all you need to do is run these commands using ADB from a computer (The connected phone must have USB Debugging turned on):
adb shell
su
mount -o rw,remount /
cp -f /data/data/com.guoshi.httpcanary/cache/HttpCanary.pem /system/etc/security/cacerts/87bc3517.0
chmod 644 /system/etc/security/cacerts/87bc3517.0
touch /data/data/com.guoshi.httpcanary/cache/HttpCanary.jks
chmod 600 /data/data/com.guoshi.httpcanary/cache/HttpCanary.jks

- 146
- 7
-
How to do that without root? Could you answer the question rather than throwing in root method which can be easily googled? – VityaSchel Nov 02 '21 at 14:56
-
1@VityaSchel As I said, you can install the certificate from the Settings, but it will only be User Trusted, which means it won't be useful for you, and to make it System Trusted you WILL need root, there is no going around it! – Safwan Ljd Nov 04 '21 at 01:15