BCR icon indicating copy to clipboard operation
BCR copied to clipboard

BCR KSU

Open damondiamond opened this issue 1 year ago • 27 comments

after installing bcr via ksu the application does not appear

damondiamond avatar Jan 03 '25 20:01 damondiamond

Make sure BCR is given root access in KernelSU (even though it doesn't actually need it). If you have any root hiding modules, please try temporarily disabling them.

chenxiaolong avatar Jan 03 '25 21:01 chenxiaolong

I'm on Xiaomi 12 Pro with Android 14 stock global MIUI HyperOS ROM, GKI_KernelSU_SUSFS Kernel, KernelSU Next manager, SuSFS for KernelSU v1.5.4, Zygisk Next, Play Integrity Fix v18.5 and Tricky Store v1.2.0. It happened to me too; in addiction to the module, I installed the apk and, for a short period, it worked. I tried BCR module without other modules enabled but now, also with only apk installed (without BCR module), it crashes as soon as I click on it, so I cannot long click on the version number to enable the debug mode and understand what happens.

fabio-87 avatar Feb 04 '25 10:02 fabio-87

Please grab a logcat with adb logcat -d > logcat.txt right after it crashes and upload that here.

chenxiaolong avatar Feb 04 '25 15:02 chenxiaolong

Here it is.

logcat.txt

fabio-87 avatar Feb 04 '25 15:02 fabio-87

Thanks for the logs. The issue is this:

02-04 16:32:49.896 31436 31436 W om.chiller3.bcr: Accessing hidden field Landroid/media/AudioFormat;->SAMPLE_RATE_HZ_MIN:I (max-target-o, reflection, denied)

BCR is blocked from accessing some private Android APIs. BCR's module normally grants access to these APIs by installing a /system/etc/sysconfig/config-com.chiller3.bcr.xml file.

I'm guessing there's something in KernelSU itself or another module that's causing this file to be hidden from Android system components. Unfortunately, I have no idea what settings you could try changing to fix this.

chenxiaolong avatar Feb 04 '25 23:02 chenxiaolong

Thanks for the logs. The issue is this:

02-04 16:32:49.896 31436 31436 W om.chiller3.bcr: Accessing hidden field Landroid/media/AudioFormat;->SAMPLE_RATE_HZ_MIN:I (max-target-o, reflection, denied)

BCR is blocked from accessing some private Android APIs. BCR's module normally grants access to these APIs by installing a /system/etc/sysconfig/config-com.chiller3.bcr.xml file.

I'm guessing there's something in KernelSU itself or another module that's causing this file to be hidden from Android system components. Unfortunately, I have no idea what settings you could try changing to fix this.

Can be useful if I grab the logcat with module installed (BCR crash anyway) and then the logcat with the module+manual apk installed?

fabio-87 avatar Feb 05 '25 06:02 fabio-87

Sure, I can take a look to see if the error is any different.

chenxiaolong avatar Feb 05 '25 06:02 chenxiaolong

I tried flashing module and, after giving it all permissions and root privileges, now it works but, as you can see from the attached images (BCR icon and the name of app in the App permission page), there are some strange behaviors, also after rebooting again.

PS: In the meanwhile I upgraded to SuSFS for KernelSU v1.5.5, but I'm not sure if it's really correlated. PS2: After rebooting, the App permissions page appears to be back to normal, but the icon is not.

Here is the new logcat file, after I opened BCR, although it no longer crashes (for now): logcat.txt

BCR Icon BCR Android App Permissions

fabio-87 avatar Feb 05 '25 13:02 fabio-87

Thanks for the new logs! Yeah, Android definitely picking up the config file properly now:

02-05 09:53:40.608  2353  3511 I SystemConfig: Reading permissions from /system/etc/sysconfig/config-com.chiller3.bcr.xml

That would explain why it no longer crashes.

As for the icon, you'll probably need to extract BCR's APK and install it to work around the problem. This happens because something is still blocking parts of Android from accessing the module's APK in /system/priv-app/com.chiller3.bcr/app-release.apk. I'm not familiar with susfs, so I'm not sure if it's causing files to be hidden or something else.

chenxiaolong avatar Feb 05 '25 22:02 chenxiaolong

I was having a similar issue after migrating from Magisk to KSU Next + SusFS.

I would open BCR and it would immediately crash with this error:

FATAL EXCEPTION: main
Process: com.chiller3.bcr, PID: 30982
java.lang.NullPointerException: Attempt to invoke virtual method 'android.content.res.Configuration android.content.res.Resources.getConfiguration()' on a null object reference
	at android.app.ConfigurationController.updateLocaleListFromAppContext(ConfigurationController.java:293)
	at android.app.ActivityThread.handleBindApplication(ActivityThread.java:7703)
	at android.app.ActivityThread.-$$Nest$mhandleBindApplication(Unknown Source:0)
	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2486)
	at android.os.Handler.dispatchMessage(Handler.java:106)
	at android.os.Looper.loopOnce(Looper.java:230)
	at android.os.Looper.loop(Looper.java:319)
	at android.app.ActivityThread.main(ActivityThread.java:9063)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:588)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1103)

I don't know if my issue and this are related, but I was able to fix BCR by clearing it's app data and permissions and then making sure BCR was getting root permissions in KSU and not unmounting.

I tried flashing module and, after giving it all permissions and root privileges, now it works but, as you can see from the attached images (BCR icon and the name of app in the App permission page), there are some strange behaviors, also after rebooting again.

PS: In the meanwhile I upgraded to SuSFS for KernelSU v1.5.5, but I'm not sure if it's really correlated. PS2: After rebooting, the App permissions page appears to be back to normal, but the icon is not.

Here is the new logcat file, after I opened BCR, although it no longer crashes (for now): logcat.txt

BCR Icon BCR Android App Permissions

I was having the same issue where the package name would show as the app name and icon would be default.

jbro129 avatar Feb 10 '25 16:02 jbro129

I don't know if my issue and this are related, but I was able to fix BCR by clearing it's app data and permissions and then making sure BCR was getting root permissions in KSU and not unmounting.

Yep, that crash is a similar issue, except Android was having trouble loading the list of supported languages from BCR's APK instead of the icon. The "not unmounting" part is likely what fixed it.

chenxiaolong avatar Feb 10 '25 23:02 chenxiaolong

On an unrelated but maybe actually related note, I updated my kernel from KSU next 12335 to 12437 and now BCR crashes whenever I open it.

FATAL EXCEPTION: main
Process: com.chiller3.bcr, PID: 15629
java.lang.ExceptionInInitializerError
	at com.chiller3.bcr.format.WaveFormat.<clinit>(Unknown Source:15)
	at com.chiller3.bcr.format.Format$$ExternalSyntheticLambda0.invoke(Unknown Source:140)
	at com.chiller3.bcr.format.Format$$ExternalSyntheticLambda0.invoke(Unknown Source:185)
	at kotlin.SynchronizedLazyImpl.getValue(Unknown Source:20)
	at com.chiller3.bcr.format.Format.<clinit>(Unknown Source:13)
	at com.chiller3.bcr.settings.SettingsFragment.refreshOutputFormat(Unknown Source:0)
	at com.chiller3.bcr.settings.SettingsFragment.onCreatePreferences(Unknown Source:128)
	at androidx.preference.PreferenceFragmentCompat.onCreate(Unknown Source:67)
	at androidx.fragment.app.FragmentStateManager.create(Unknown Source:70)
	at androidx.fragment.app.FragmentStateManager.moveToExpectedState(Unknown Source:182)
	at androidx.fragment.app.FragmentManagerImpl.executeOpsTogether(Unknown Source:1166)
	at androidx.fragment.app.FragmentManagerImpl.removeRedundantOperationsAndExecute(Unknown Source:81)
	at androidx.fragment.app.FragmentManagerImpl.execPendingActions(Unknown Source:172)
	at androidx.fragment.app.FragmentManagerImpl.dispatchStateChange(Unknown Source:66)
	at androidx.appcompat.app.AppCompatActivity.onStart$androidx$fragment$app$FragmentActivity(Unknown Source:33)
	at androidx.appcompat.app.AppCompatActivity.onStart(Unknown Source:0)
	at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1582)
	at android.app.Activity.performStart(Activity.java:9034)
	at android.app.ActivityThread.handleStartActivity(ActivityThread.java:4206)
	at android.app.servertransaction.TransactionExecutor.performLifecycleSequence(TransactionExecutor.java:225)
	at android.app.servertransaction.TransactionExecutor.cycleToPath(TransactionExecutor.java:205)
	at android.app.servertransaction.TransactionExecutor.executeLifecycleState(TransactionExecutor.java:177)
	at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:98)
	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2693)
	at android.os.Handler.dispatchMessage(Handler.java:106)
	at android.os.Looper.loopOnce(Looper.java:230)
	at android.os.Looper.loop(Looper.java:319)
	at android.app.ActivityThread.main(ActivityThread.java:9063)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:588)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1103)
Caused by: java.lang.NoSuchFieldException: No field SAMPLE_RATE_HZ_MIN in class Landroid/media/AudioFormat; (declaration of 'android.media.AudioFormat' appears in /system/framework/framework.jar!classes2.dex)
	at java.lang.Class.getDeclaredField(Native Method)
	at com.chiller3.bcr.extension.AudioFormatExtensionsKt.<clinit>(Unknown Source:4)
	... 31 more

When the crash first happened, I saw an alert saying there was an issue and I should clear the app data before using it again. However clearly app data did not fix the issue...

jbro129 avatar Mar 02 '25 22:03 jbro129

Something is probably unmounting BCR's files again. That crash occurs if /system/etc/sysconfig/config-com.chiller3.bcr.xml isn't visible to Android's system components.

chenxiaolong avatar Mar 03 '25 00:03 chenxiaolong

I had similar problem were BCR is not detected I solved by disabling the option "Umount Modules" under KSU manager settings, but didn't test if calls are recorded correctly

after some research I think similar issue was present with systemless hosts modules, and they solved by adding something like this to the services.sh of the module, to kind off force mount the module files

mount --bind "${0%/*}/hosts" /system/etc/hosts

i believe by doing so for every file of BCR module that needs to be injected into the system it could solve the above issues without disabling the Umount Modules for all modules which can affect root hiding maybe but I need yet to test

Edit: tried adding those lines to services.sh mount --bind "${0%/*}/system/priv-app/com.chiller3.bcr/app-release.apk" /system/priv-app/com.chiller3.bcr/app-release.apk

mount --bind "${0%/*}/system/etc/permissions/privapp-permissions-com.chiller3.bcr.xml" /system/etc/permissions/privapp-permissions-com.chiller3.bcr.xml

mount --bind "${0%/*}/system/etc/sysconfig/config-com.chiller3.bcr.xml" /system/etc/sysconfig/config-com.chiller3.bcr.xml

mount --bind "${0%/*}/system/addon.d/51-com.chiller3.bcr.sh" /system/addon.d/51-com.chiller3.bcr.sh

didn't work so...bad luck

Kellwaxx11 avatar Mar 05 '25 21:03 Kellwaxx11

For me, it randomly started working again. Then after a reboot after updating to KSU next 12430, the app disappeared even though it was present in /system/priv-app and all the permission files were present as well.

After I uninstalled zygisk-storage-isolation, BCR show up again in my apps list.

jbro129 avatar Mar 07 '25 00:03 jbro129

BCR crashed again yesterday, after several reboot (I rebooted for other reasons, not for BCR itself). This is the crash.log file (saved just now, after BCR crash):

crash.log.txt

PS: now I'm on Stock HyperOS 2 with Android 15 and KernelSU Next 12430, but BCR worked well anyway, until yesterday.

fabio-87 avatar Mar 10 '25 10:03 fabio-87

Today BCR started working again. This is the log:

BCR-logcat.log.txt

fabio-87 avatar Mar 12 '25 17:03 fabio-87

Today BCR started working again. This is the log:

BCR-logcat.log.txt

what is your current KSU version is it KSU next v12449 ? i think they fixed something related to magic mount

Kellwaxx11 avatar Mar 12 '25 17:03 Kellwaxx11

Today BCR started working again. This is the log:

BCR-logcat.log.txt

what is your current KSU version is it KSU next v12449 ? i think they fixed something related to magic mount

Yes, it's v12449 with r47 GKI kernel flashed today. Yes, you're right, in the latest changelogs there is the revert of the commits about the ksud_magic.

fabio-87 avatar Mar 12 '25 18:03 fabio-87

I was having a similar issue after migrating from Magisk to KSU Next + SusFS.

I would open BCR and it would immediately crash with this error:

FATAL EXCEPTION: main
Process: com.chiller3.bcr, PID: 30982
java.lang.NullPointerException: Attempt to invoke virtual method 'android.content.res.Configuration android.content.res.Resources.getConfiguration()' on a null object reference
	at android.app.ConfigurationController.updateLocaleListFromAppContext(ConfigurationController.java:293)
	at android.app.ActivityThread.handleBindApplication(ActivityThread.java:7703)
	at android.app.ActivityThread.-$$Nest$mhandleBindApplication(Unknown Source:0)
	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2486)
	at android.os.Handler.dispatchMessage(Handler.java:106)
	at android.os.Looper.loopOnce(Looper.java:230)
	at android.os.Looper.loop(Looper.java:319)
	at android.app.ActivityThread.main(ActivityThread.java:9063)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:588)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1103)

I don't know if my issue and this are related, but I was able to fix BCR by clearing it's app data and permissions and then making sure BCR was getting root permissions in KSU and not unmounting.

I tried flashing module and, after giving it all permissions and root privileges, now it works but, as you can see from the attached images (BCR icon and the name of app in the App permission page), there are some strange behaviors, also after rebooting again. PS: In the meanwhile I upgraded to SuSFS for KernelSU v1.5.5, but I'm not sure if it's really correlated. PS2: After rebooting, the App permissions page appears to be back to normal, but the icon is not. Here is the new logcat file, after I opened BCR, although it no longer crashes (for now): logcat.txt BCR Icon BCR Android App Permissions

I was having the same issue where the package name would show as the app name and icon would be default.

I just checked, bcr crashes after enabling this in susfs and rebooting, it stops crashing after disabling and rebooting.

Image

Crash log verbose_2025-03-29T12_43_47.26927.log

yoo07 avatar Mar 29 '25 18:03 yoo07

after installing bcr via ksu the application does not appear

Install the apk from the zip

Image

yoo07 avatar Mar 29 '25 18:03 yoo07

I just checked, bcr crashes after enabling this in susfs and rebooting, it stops crashing after disabling and rebooting.

Image

I can confirm by disabling that option in susfs "TRY UMOUNT FOR ZYGOTE SYSTEM PROCESS" BCR works simply by installing the module and the apk, nothing more.

Kellwaxx11 avatar Mar 29 '25 20:03 Kellwaxx11

Hello I have the same issue after flashing it and giving root access it opens but when I call someone it shows me that the bcr keeps stopping and from bcr I receive a message that it told me call initializing. What can I do to solve this issue? I'm using Redmi note 12 pro plus 5g with crdroid11 android 15 and I rooted it using kernelsu next.

Georgeprogamer12 avatar May 06 '25 11:05 Georgeprogamer12

Hello I have the same issue after flashing it and giving root access it opens but when I call someone it shows me that the bcr keeps stopping and from bcr I receive a message that it told me call initializing. What can I do to solve this issue? I'm using Redmi note 12 pro plus 5g with crdroid11 android 15 and I rooted it using kernelsu next.

In addiction to flash the zip, did you install the apk file that is present inside it?

fabio-87 avatar May 06 '25 12:05 fabio-87

Hello I have the same issue after flashing it and giving root access it opens but when I call someone it shows me that the bcr keeps stopping and from bcr I receive a message that it told me call initializing. What can I do to solve this issue? I'm using Redmi note 12 pro plus 5g with crdroid11 android 15 and I rooted it using kernelsu next.

In addiction to flash the zip, did you install the apk file that is present inside it?

Yes I did it.

Georgeprogamer12 avatar May 06 '25 12:05 Georgeprogamer12

I ran into the same problem. The solution was to remove the OverlayFS RW module.

farline99 avatar May 10 '25 21:05 farline99

I just checked, bcr crashes after enabling this in susfs and rebooting, it stops crashing after disabling and rebooting. Image

I can confirm by disabling that option in susfs "TRY UMOUNT FOR ZYGOTE SYSTEM PROCESS" BCR works simply by installing the module and the apk, nothing more.

+1 it works with that option disabled.

Tried with SukiSu Ultra + susfs4ksu (v1.5.8-R20) and susfs ver 1.5.8

ayusc avatar Jul 11 '25 13:07 ayusc