topjohnwu
c2c3bf0ba4
Don't depend on vtable ABI layout
2021-08-12 06:41:59 -07:00
topjohnwu
0d977b54f7
Revise logging code
2021-08-12 03:26:54 -07:00
topjohnwu
20860da4b4
Cleaner daemon handlers
2021-08-11 22:57:08 -07:00
topjohnwu
3ea10b7cf9
Reorganize injection code
2021-08-11 22:56:18 -07:00
topjohnwu
1ec33863bc
Android 5.0 is actually supported
2021-08-11 17:14:22 -07:00
topjohnwu
a260e99090
Support code injection on Android 12
2021-08-11 00:00:21 -07:00
topjohnwu
25efdd3d6f
Use code generator for jni_hooks
2021-08-02 03:20:19 -07:00
topjohnwu
00a1e18959
Store all native JNI methods in data structures
2021-08-01 14:35:16 -07:00
topjohnwu
5e1fba3603
Build a single APK for all ABIs
2021-05-13 00:21:04 -07:00
vvb2060
66cc9bc545
Pure 64bit support
2021-05-12 16:38:34 -07:00
topjohnwu
5b37de8fe5
Build our own zlib
2021-05-10 18:46:03 -07:00
topjohnwu
7df23ceb74
Prevent undefined behavior in magiskboot
2021-05-10 18:38:30 -07:00
topjohnwu
6099f3b015
Always resolve to canonical path
2021-05-10 01:14:53 -07:00
topjohnwu
775d095b3c
Update busybox
...
Fix #4225
2021-05-08 16:45:31 -07:00
Wang Han
3798d50457
Kill processes with SIGKILL rather than SIGTERM
2021-05-04 22:14:46 -07:00
vvb2060
708fe514f8
Always use mirror path
2021-04-23 16:56:23 -07:00
vvb2060
f4ac7c8e7c
Ignore validating class name of isolated process name
...
Fix #4176
Co-authored-by: topjohnwu <topjohnwu@gmail.com>
2021-04-15 23:08:51 -07:00
Wang Han
44f005077d
Don't copy sepolicy.rule to /persist on boot
...
* This seems to be a logic that has been abandoned for a
long time. Now we automatically choose which partition
to store sepolicy.rule. Furthermore, touching /persist is
what we should avoid doing whenever possible.
2021-04-15 05:01:03 -07:00
LoveSy
013b6e68ec
Fix perfect forwarding
2021-04-15 04:58:30 -07:00
LoveSy
95c964673d
Initialized _root
properly
...
Fix #4204
`_root` is uninitialized for non-root nodes. And it will cause `module_node::mount` fail because it uses `root()`. Once the bug is triggered, signal 11 is received but Magisk catch all signals and therefore stuck forever.
2021-04-15 04:58:30 -07:00
Wang Han
e136fb3a4f
Remove outdated sepolicies
...
* Support deodexed ROM: This should not be done and dexpreopt is mandatory since P
Xposed: Xposed handles them just fine, at least in the latest version 89.3
suMiscL6: For whatever audio mods, a leftover of phh time
Liveboot and suBackL6: Was for CF.lumen and LiveBoot, not needed now
* Also cleanup binder sepolicies since we allow all binder transactions.
2021-04-09 21:34:51 -07:00
topjohnwu
01b985eded
Remove more pre SDK 21 stuffs
2021-04-09 21:29:42 -07:00
Shaka Huang
3da318b48e
Fix random return value of faccessat() in x86
...
faccessat() should return 0 when success, but it returns random number with errno == 0 in x86 platform.
It’s a side effect of commit bf80b08b5f
when magisk binaries ‘corretly’ linked with library of API16 .. lol
Co-authored-by: John Wu <topjohnwu@gmail.com>
2021-04-04 03:04:09 -07:00
Shaka Huang
dfe1f2c108
Call freecon() when fgetfilecon() succeeds
2021-04-04 01:58:59 -07:00
topjohnwu
7da36079c1
Always delete existing ro props at setprop
...
Close #4113
2021-03-29 04:16:18 -07:00
topjohnwu
2bef967af1
Make systemproperties more match AOSP
2021-03-29 03:46:07 -07:00
topjohnwu
7e4194418a
Update libcxx
2021-03-28 04:55:56 -07:00
topjohnwu
66e30a7723
Build libc++ ourselves
2021-03-25 01:00:10 -07:00
vvb2060
8ddab84745
Don't auto hide microG
...
close #3559
2021-03-24 04:43:45 -07:00
vvb2060
6865652125
Fix process name in MagiskHide
...
close #3997
2021-03-24 04:43:45 -07:00
Shaka Huang
e3801d6965
Fix overflow
...
`totalsize` might be a big (invalid) number so instead of checking the end address we check the size of the image.
Fix #4049
2021-03-24 03:02:46 -07:00
topjohnwu
336f1687c1
Be more careful with signals
...
Fix #4040
2021-03-18 03:28:02 -07:00
vvb2060
7a007b342a
Correct comment
...
For file-based encryption, /data/adb is always required to encrypt
https://android.googlesource.com/platform/system/extras/+/refs/tags/android-7.0.0_r36/ext4_utils/ext4_crypt_init_extensions.cpp
68258e8444
%5E%21/
2021-03-13 21:10:02 -08:00
vvb2060
0783f3d5b6
Fix mount rules dir
...
close #4006
2021-03-13 21:10:02 -08:00
topjohnwu
82f8948fd4
Separate setting log functions and starting log daemon
2021-03-13 17:50:48 -08:00
Shaka Huang
b9cdc755d1
Returned fds[0] in socketpair() might be STDOUT
...
* There will be garbage output when executing `su` (#4016 )
* Failed to check root status and showing N/A in status (#4005 )
Signed-off-by: Shaka Huang <shakalaca@gmail.com>
2021-03-13 17:50:48 -08:00
topjohnwu
a6f81c66e5
Bypass stdio
2021-03-13 16:17:28 -08:00
topjohnwu
1ff45ac5f5
Proper pattern matching
...
Fix #3998
2021-03-09 04:08:34 -08:00
topjohnwu
43c1105d62
Use dedicated thread for writing logfile
2021-03-09 02:40:12 -08:00
vvb2060
b693d13b93
Proper implementation of cgroup migration
...
https://www.kernel.org/doc/Documentation/admin-guide/cgroup-v1/cgroups.rst
https://www.kernel.org/doc/Documentation/admin-guide/cgroup-v2.rst
2021-03-07 01:55:19 -08:00
topjohnwu
39982d57ef
Fix logging implementation
...
- Block signals in logging routine (fix #3976 )
- Prevent possible deadlock after fork (stdio locks internally)
by creating a new FILE pointer per logging call (thread/stack local)
2021-03-06 13:55:30 -08:00
topjohnwu
851404205b
Update NDK to r21e
2021-03-02 23:18:44 -08:00
topjohnwu
117ae71025
Use custom class instead of std::map
2021-03-02 23:16:10 -08:00
topjohnwu
027ec70262
Patch AVB structures
...
Disable vbmeta verification in flags
2021-03-02 20:37:37 -08:00
topjohnwu
55fdee4d65
Use memmem for searching byte patterns
2021-02-28 14:37:12 -08:00
topjohnwu
0d42f937dd
Refactor magiskboot
2021-02-28 14:37:12 -08:00
vvb2060
ac8372dd26
Add cgroup2 path
...
https://android-review.googlesource.com/c/platform/system/core/+/1585101
2021-02-26 21:36:58 -08:00
Shaka Huang
ba1ce16b8b
Fix error in pure 64-bit environment
...
In Android S preview, there’s no 32-bit libraries in x86_64 system image for emulator.
Signed-off-by: Shaka Huang <shakalaca@gmail.com>
2021-02-22 03:28:54 -08:00
topjohnwu
ccb55205e6
Fix pre 21 support
2021-02-20 03:38:39 -08:00
vvb2060
b76c80e2ce
Fix apex path
2021-02-14 13:37:38 -08:00