Privilege Escalation from Zygote to Init
The privilege escalation from zygote to init is possible because system/sepolicy/private/zygote.te contains the following rule: allow zygote self:capability sys_admin;. This rule allows processes in the zygote domain to use the CAP_SYS_ADMIN capability, if they have such a capability. The exploit for this issue is in zygote_exec_target.c, starting at 'if (unshare(CLONE_NEWNS))'. The attack is basically: 1. set up a new mount namespace with a root that is fully attacker-controlled 2. execute crash_dump64, causing an automatic transition to the crash_dump domain 3. the kernel tries to load the linker for crash_dump64 from the attacker-controlled filesystem, resulting in code execution in the context of the zygote.