topjohnwu
46275b90c2
Generalize unxz
2023-09-21 05:47:21 -07:00
topjohnwu
0a2a590ab7
Use Utf8CStr for logging
2023-09-12 17:35:20 -07:00
topjohnwu
89aee6ffa7
Add more to the Utf8CStr family
...
Better C strings with path operations
2023-09-12 17:35:01 -07:00
topjohnwu
4eaf701cb7
Address clippy warnings
2023-09-06 21:45:12 -07:00
topjohnwu
732a161b67
Minor cleanup
2023-06-22 02:23:27 -07:00
vvb2060
9929b25339
Move su request path to magisk tmp
2023-06-20 03:29:06 -07:00
topjohnwu
d7d0a44693
Remove randomness from Magisk
2023-06-14 17:05:49 -07:00
topjohnwu
5e2ef1b7f4
Better bytes support in C++
2023-06-06 17:11:42 -07:00
topjohnwu
2a654e5d7f
Improve byte_data const correctness
2023-06-03 03:16:03 -07:00
topjohnwu
c30fbdf145
Simplify logging code
2023-05-29 01:27:40 -07:00
topjohnwu
533aeadd38
Update cstr macro
2023-05-25 01:03:04 -07:00
topjohnwu
18d0cedbe2
Parse rule files with Rust
2023-05-24 19:11:56 -07:00
topjohnwu
5a94ef9106
Fix init rust code setup
2023-05-23 21:50:13 -07:00
topjohnwu
8e8f01f8b5
Move project common code into include
2023-05-23 21:30:30 -07:00
topjohnwu
5627053b74
Move su folder into core
2023-05-23 01:36:25 -07:00
topjohnwu
2bcf2e76f1
Generate cxx binding in build.rs
2023-05-19 15:16:54 -07:00
vvb2060
726ffdcd98
Fix meizu rootfs type
2023-05-06 00:06:59 -07:00
vvb2060
f9d22cf8ee
New magisk tmp dir: /debug_ramdisk
...
Co-authored-by: LoveSy <shana@zju.edu.cn>
2023-05-06 00:04:11 -07:00
vvb2060
ee50da566f
Cancel recursive bind
2023-05-06 00:04:11 -07:00
vvb2060
9f7d410959
Use pathname local socket
2023-05-06 00:04:11 -07:00
topjohnwu
b136aba1e2
Implement magiskinit logging in Rust
2023-05-02 16:49:43 -07:00
topjohnwu
0cf0d2b821
Move avd_hack boolean out of init class
2023-04-25 23:34:45 -07:00
vvb2060
68c2817d40
Enable avd hack for debug build
2023-04-25 23:00:59 -07:00
topjohnwu
cc5ff36165
Revert "Cancel recursive bind"
...
This reverts commit a18a440236e6b1563cd9ceb1abee21836d5cebd8.
2023-04-05 10:47:13 -07:00
vvb2060
5c165c9bb0
Fix avd hack
2023-04-05 04:01:32 -07:00
topjohnwu
6c3519923d
Make things more obvious
2023-04-05 04:01:07 -07:00
vvb2060
69529ac59c
Fix restorecon
2023-04-04 02:34:16 -07:00
vvb2060
a18a440236
Cancel recursive bind
2023-04-04 02:12:07 -07:00
LoveSy
aa7846c1c0
No need to mount ROOTMIR if tmp_dir != /sbin
2023-04-04 02:12:07 -07:00
topjohnwu
2087e47300
Get random separately
2023-04-03 18:32:11 -07:00
vvb2060
46ce765860
Use stable random seed
2023-04-03 18:32:11 -07:00
LoveSy
dba5020e4f
Refactor magiskrc
2023-03-22 17:53:15 -07:00
LoveSy
b9d0a3b3d4
Use partition name or devpath's name
2023-03-21 00:40:11 -07:00
topjohnwu
76405bd984
Add more comments
2023-03-21 00:40:11 -07:00
topjohnwu
4e2b88b3d0
Rename rules to preinit
...
It is possible that we will allow more preinit files for modules.
Rename the partition and folders from rules to preinit.
2023-03-21 00:40:11 -07:00
LoveSy
7048aa1014
Rename sepolicy.rules -> rules
2023-03-21 00:40:11 -07:00
vvb2060
362eea741f
Refactor sepolicy.rules resolve native
...
Co-authored-by: LoveSy <shana@zju.edu.cn>
2023-03-21 00:40:11 -07:00
LoveSy
03cee0b8d4
Remove meaningless umount in magiskinit
...
This is no longer required since we redirect to /data/magiskinit
2023-03-19 23:35:18 -07:00
LoveSy
9555380818
Replace parse_mnt with parse_mount_info
2023-03-06 05:09:12 -08:00
vvb2060
2a4aa95a6f
Identify tmpfs used by magisk
2023-02-26 14:23:11 -08:00
vvb2060
2c53356bfd
Remove unexpected files
2023-02-26 03:47:38 -08:00
LoveSy
b249832571
Use statfs to check rootfs
...
This helps support adb remount
2023-02-12 22:49:27 -08:00
LoveSy
9e8c68af12
Refactor sepolicy.rules resolve
...
We resolve available partitions for sepolicy.rules when patching
boot and bind mount the partition by magiskinit.
For older devices, the previous logic won't work because the part name
is never readable.
Co-authored-by: topjohnwu <topjohnwu@gmail.com>
2023-02-12 00:36:38 -08:00
vvb2060
7a9e6d2ad2
Remove unexpected /sbin/overlay.d
2023-02-09 20:08:59 -08:00
LoveSy
4318ab5cd2
Reuse tmpfs for magic mount
...
As we already have a tmpfs (magisktmp), we can reuse them for
magic mount
2023-01-20 03:49:40 +08:00
topjohnwu
57d83635c6
Check stub.xz existence
2022-12-26 16:07:04 -08:00
vvb2060
ad0e6511e1
Stop embedding stub.apk in magiskinit
2022-12-26 16:07:04 -08:00
LoveSy
5763a3d908
Support replacing existing .rc by overlay.d
...
Co-authored-by: topjohnwu <topjohnwu@gmail.com>
2022-12-26 03:28:10 -08:00
LoveSy
bdfedea4e0
Close missing fd
...
Fix #6463
2022-12-24 15:16:27 -08:00
LoveSy
4ed34cd648
Eliminate unnecessarily copy on magiskinit
...
This patch reuses the abused /data tmpfs for magisktmp
2022-12-23 17:03:16 -08:00