ys1231/MoveCertificate

Read Description!

IamLoot opened this issue · 8 comments

Can you please do something that add my certificate into /system/etc/security/cacerts/ directory too. Currently it's only moving certificate to /apex/com.android.conscrypt/cacerts/

I want it to move that my custom certificates to /system/etc/security/cacerts/ this directory too. thank you

If you use Magisk.
Look for the switch related to Systemless hosts in Magisk settings. After clicking, Magisk should create an empty module named hosts
Find this directory /data/adb/modules/hosts/ and create a new directory /system/etc/security/cacerts/ in it.
Then put your .0 certificate file in it and restart the device. This should work. In my Android 11 device, I created the /system/media/ path and successfully wrote the bootanimation file to the system, I think this should also apply to cacerts.

If you use Magisk. Look for the switch related to Systemless hosts in Magisk settings. After clicking, Magisk should create an empty module named hosts Find this directory /data/adb/modules/hosts/ and create a new directory /system/etc/security/cacerts/ in it. Then put your .0 certificate file in it and restart the device. This should work. In my Android 11 device, I created the /system/media/ path and successfully wrote the bootanimation file to the system, I think this should also apply to cacerts.

Sadly I'm on ksu. Btw Thanks, I will try that too when i switch to magisk

This module supports magisk and kernelsu, and its main function is to move certificates. You can modify the moving path to achieve your goal.

This module supports magisk and kernelsu, and its main function is to move certificates. You can modify the moving path to achieve your goal.

I added this code after line number 109 on file post-fs-data.sh

cp -u /data/local/tmp/cert/* $MODDIR/certificates

but it's doesn't work. Can you please help me

111 lines, 90 lines, have been processed.

111 lines, 90 lines, have been processed.

I've added this in move_custom_cert function.

cp -f /data/local/tmp/cert/* /system/etc/security/cacerts/

But still it doesn't work 🥲 (I'm on Android 14)

Android14, do you still need the directory /system/etc/security/cacerts/? If you have this requirement, just delete if else, and it will be implemented.

Android14, do you still need the directory /system/etc/security/cacerts/? If you have this requirement, just delete if else, and it will be implemented.

It worked, thank you!