-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature Request] Alternative implementation of denylist by maintain two copies of zygote #6
Comments
What could be the possible benefits compared to current implementation? |
|
Both points are invalid.
I suggest you to study generated logs to see what are actually happening to correct your ideas on what happens. |
zygote64 RESIDENT memory is about 137M, PSS is about 7M. If two copies of zygote is too much resource, what about grapheneos guys.
I never said ptrace happens on each individual app. I know that only zygote itself got traced, and the trace will stop after fork, but ptrace still causes wired hangs when zygote forks too frequently. |
My first point was made compared to the current implementaion, which only keeps mount namespace file descriptors in the daemon. And by the way, there aren't so-called a lot of unmap/unmount/etc as you conjectured. For the second point, it seems irrelevant to DenyList implementations. If you can justify it as a valid issue, please open a new issue of it, I will be gald to improve it. |
[[APatch/KSU only] For applications without root privilege and not on the DenyList, only modules mount points are present in their mount namespaces. As an example, this is the ideal configuration for applying font customization modules to their target applications. Note: this is not implemented for Magisk, which needs root mounting points to receive root permission requests] |
@qwerzxcva Yes, what is said in the README applies to all KernelSU variants. |
Is your feature request related to a problem?/你的请求是否与某个问题相关?
Currently all(open-sourced) zygisk implementations hooks into a single zygote process, and need a lot of unmap/unmount/etc cleanup in case the target is in denylist.
Describe the solution you'd like/描述你想要的解决方案
In order to start a new process, system_server will connect to zygote via socket Zygote.PRIMARY_SOCKET_NAME and send all the parameters.
We can hook the system_server, intercept this connection and redirect to a daemon process. If the target app is inside denylist, we redirect the request to an untainted zygote which still listens on Zygote.PRIMARY_SOCKET_NAME, otherwise we redirect the request to zygisk process which listens on alternative socket.
In summary, we need these things:
Additional context/其他信息
This link has a good picture portraying the app start process,
Step 1 and 2 could be merged in system_server if we can get denylist inside system_server.
The text was updated successfully, but these errors were encountered: