APatch
APatch copied to clipboard
Would it be a good idea to consider putting this app on F-Droid
Magisk and KernelSU are both up on f-droid for download, so why not APatch? And here is F-Droid's inclusion policy, I think APatch is in line with their policy.
KernelSU is not on F-Droid, at least not in the official repo. The Magisk build metadata for F-Droid is maintained by me. If APatch agrees to be included, I can help.
KernelSU is not on F-Droid, at least not in the official repo. The Magisk build metadata for F-Droid is maintained by me. If APatch agrees to be included, I can help.
I was mistaken, KernelSU is currently in the lzzyOnDroid F-Droid Repo. Thanks for your work, hopefully we'll see APatch in F-Droid too.
I agree, if it doesn't inconvenience you too much.
@linsui
I'll have a try. Looks like we need to build magisk first for these libs in https://github.com/bmax121/APatch/tree/main/app/libs/arm64-v8a. But it seems libmagiskpolicy.so is from a different version of magisk?
I'll have a try. Looks like we need to build magisk first for these libs in https://github.com/bmax121/APatch/tree/main/app/libs/arm64-v8a. But it seems libmagiskpolicy.so is from a different version of magisk?
Yes, it was a modified version, so that magiskpolicy can compatible with APatch
Where is the source code of the modified version?
Where is the source code of the modified version?
Wait for @bmax121 upload patiently.
Btw, should the modified magiskpolicy being built together with APatch? If true, we may need hack gradle to do that.
Btw, should the modified magiskpolicy being built together with APatch? If true, we may need hack gradle to do that.
It needs to be built from source. We can build it first then put it in the required location.
Btw, should the modified magiskpolicy being built together with APatch? If true, we may need hack gradle to do that.
It needs to be built from source. We can build it first then put it in the required location.
Sorry for the delay and thanks for supporting APatch. We’re currently working on developing these days so didn’t reply on time. We will notify you once we finished that. ;)
The source is at https://github.com/bmax121/Magisk, Mainly changed this file: https://github.com/bmax121/Magisk/blob/master/native/src/sepolicy/rules.cpp
Which commit do you use? I didn't see any change on master branch.
It's ok now https://github.com/bmax121/Magisk/commit/cc94f7bfda10c9e70e00d6bdaf12362842d6a526
IIUC, APatch doesn't use ONDK to build the rust code. Then does it make sense to build the magisk libs with ONDK? I have to rebuild ONDK from source so if it's not needed maybe I can skip that step.
What is the downloaded compiler in https://github.com/bmax121/KernelPatch/blob/main/.github/workflows/build.yml used for? Is there any simple way to build those kernel patch binaries?
@bmax121 Requested at IzzyOnDroid. According to their scanner report
No offending libs found.
Dangerous flags:
----------------
* usesCleartextTraffic
Permissions:
------------
* android.permission.INTERNET
* android.permission.WRITE_EXTERNAL_STORAGE
* android.permission.READ_EXTERNAL_STORAGE
* android.permission.QUERY_ALL_PACKAGES
* me.bmax.apatch.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION
Need some clarification regarding usesCleartextTraffic
and QUERY_ALL_PACKAGES
@bmax121 Requested at IzzyOnDroid. According to their scanner report
No offending libs found. Dangerous flags: ---------------- * usesCleartextTraffic Permissions: ------------ * android.permission.INTERNET * android.permission.WRITE_EXTERNAL_STORAGE * android.permission.READ_EXTERNAL_STORAGE * android.permission.QUERY_ALL_PACKAGES * me.bmax.apatch.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION
Need some clarification regarding
usesCleartextTraffic
andQUERY_ALL_PACKAGES
Hey shuvashish76 Thank you for your contribution.
usesCleartextTraffic
is for APatch Module WebUI feature and QUERY_ALL_PACKAGES
is being used for selecting SuperUsers Applications. Are those enough? Feel free to notify me if you need more clarification ;)
What is the downloaded compiler in https://github.com/bmax121/KernelPatch/blob/main/.github/workflows/build.yml used for? Is there any simple way to build those kernel patch binaries?
Used for compiling kpimg, no more simple way but use this compiler because other one may lead to kpimg broken.
@pomelohan Thanks. Please add Fastlane metadata as mentioned here. (Necessary for both F-Droid / IzzyOnDroid)
Used for compiling kpimg, no more simple way but use this compiler because other one may lead to kpimg broken.
Where is this special gcc from? How can I build it?
usesCleartextTraffic
is for APatch Module WebUI feature
usesCleartextTraffic
is only used locally on-device (and not to reach out to the internet)? Is that ensured e.g. via a "network security police"?
Used for compiling kpimg, no more simple way but use this compiler because other one may lead to kpimg broken.
Where is this special gcc from? How can I build it?
Sorry for the delay, busy those days...
Update: No need special gcc, only aarch64-elf gcc is required. But it's better to use the same gcc version as KernelPatch using.
usesCleartextTraffic
is for APatch Module WebUI feature
usesCleartextTraffic
is only used locally on-device (and not to reach out to the internet)? Is that ensured e.g. via a "network security police"?
Sorry for the delay, busy those days...
Yes, usesCleartextTraffic
is only used locally on-device. (Located on: /data/adb/modules/<module>/webroot
, it is providing an interface for a
module to control itself). It wouldn't reach out to the internet unless module author do that.
Update: No need special gcc, only aarch64-elf gcc is required. But it's better to use the same gcc version as KernelPatch using.
Am I understand it correctly that I just need an aarch64-elf gcc for all the build related to kernel patch?
Update: No need special gcc, only aarch64-elf gcc is required. But it's better to use the same gcc version as KernelPatch using.
Am I understand it correctly that I just need an aarch64-elf gcc for all the build related to kernel patch?
Yes, but it is recommended to use the same gcc version as KernelPatch CI using because KernelPatch Project is special, unlike other programs. Newer or old version may lead to issues because of optimizations.
Thanks! That only leaves the storage permissions then which could use a short explanation, too 😉
@bmax121 @pomelohan
Yes, but it is recommended to use the same gcc version as KernelPatch CI using because KernelPatch Project is special, unlike other programs. Newer or old version may lead to issues because of optimizations.
Can I use this package? Or I should build the aarch64-elf-gcc somehow? I'm not sure what the difference is.
Yes, but it is recommended to use the same gcc version as KernelPatch CI using because KernelPatch Project is special, unlike other programs. Newer or old version may lead to issues because of optimizations.
Can I use this package? Or I should build the aarch64-elf-gcc somehow? I'm not sure what the difference is.
I thought this version maybe too old to make KernelPatch working. KernelPatch CI is using this one: https://armkeil.blob.core.windows.net/developer/Files/downloads/gnu/12.2.rel1/binrel/arm-gnu-toolchain-12.2.rel1-x86_64-aarch64-none-elf.tar.xz
I thought both of them are GCC 12.2?
Thanks! That only leaves the storage permissions then which could use a short explanation, too 😉
@bmax121 @pomelohan
storage permissions are used to store patched boot image and module upgrading🌹