Commit Graph

2784 Commits

Author SHA1 Message Date
topjohnwu
b106d1c501 Fix stupid mistake 2019-02-14 04:24:30 -05:00
topjohnwu
99db0672b4 Minor MagiskHide adjustments
- Fail fast on unsupported systems
- Show proper fail message on unsupported systems
- inotify_fd shall be swapped out before closing to prevent
  the proc_monitor thread to read from incomplete inotify fd
2019-02-14 04:08:05 -05:00
topjohnwu
d584360de2 More optimized APK traversal 2019-02-14 00:52:59 -05:00
topjohnwu
4eed6794c7 More MagiskHide optimizations
- Use a general procfs traversal function with callbacks
- Much better functions for killing processes
2019-02-13 20:16:26 -05:00
topjohnwu
c66cabd80f Several MagiskHide improvements
- Directly get UID instead of traversing /data/data everytime
- Use /data/user_de/0 instead of /data/data on Android 7.0+
- Update hide_uid set incrementally when adding/initializing targets
- Guard hide_uid set with the same lock as hide_list vector
- Do not add GMS package into database; only add to in-memory list
2019-02-13 06:16:26 -05:00
Park Ju Hyung
24da3485bd Hardcode GMS unstable to MagiskHide
With the new detection method, it is impossible to check for components.

Remove additional checks for components and simply hardcode string to
proc_monitor.cpp and query cmdline to see if it's GMS unstable.

This addresses wasted resources on applying custom namespace
on all GMS processes.

Signed-off-by: Park Ju Hyung <qkrwngud825@gmail.com>
2019-02-12 23:39:57 -05:00
Park Ju Hyung
7384d2d330 Completely rework MagiskHide
Previous MagiskHide detects new app launches via listening through logcat
and filtering launch info messages.

This is extremely inefficient and prone to cause multiple issues both
theoratically and practically.

Rework this by using inotify to detect open() syscalls to target APKs.

This also solves issues related to Zygote-forked caching mechanisms such as
OnePlus OxygenOS' embryo.

Signed-off-by: Park Ju Hyung <qkrwngud825@gmail.com>
2019-02-12 23:39:57 -05:00
topjohnwu
e5940168fe Fix string resources 2019-02-12 17:03:20 -05:00
Igor Sorocean
6855baf0f8 Update romanian translation 2019-02-12 17:01:11 -05:00
Fatih Fırıncı
dfd16e8fef Update strings.xml 2019-02-12 17:01:01 -05:00
Remita Amine
98a36819bc Limit Boot Image selection dialog to File Managers 2019-02-12 17:00:48 -05:00
marciozomb13
de8bc9ca9d Update strings.xml
PT-rBR update
2019-02-12 17:00:32 -05:00
topjohnwu
c137f2de4f Remove SDK 16 support completely
Android 4.1 init miss several significant features Magisk reply on,
so the final decision is to forget about it in the future.

Pull minSdkVersion of Magisk Manager back to 17 and remove some
unnecessary adjustments done for SDK 16
2019-02-12 16:58:05 -05:00
topjohnwu
0f55fcafe8 Migrate EXT4 images instead of removing them 2019-02-12 16:13:31 -05:00
topjohnwu
ed027ec3ee Refactor build flags 2019-02-12 05:17:02 -05:00
topjohnwu
b3fd79cbb9 Add more cmdline options and specify as internal API 2019-02-12 04:05:51 -05:00
topjohnwu
ed4df87b57 Remove imgtool 2019-02-12 02:44:46 -05:00
topjohnwu
1321f097b8 Remove usage of magisk.img
Mounting ext4 images causes tons of issues, such as unmountable with broken F2FS drivers.
Resizing is also very complicated and does not work properly on all devices.
Each step in either measuring free space, resizing, and shrinking the image is a
point of failure, and either step's failure could cause the module system completely broken.

The new method is to directly store modules into /data/adb/modules, and for module installation
on boot /data/adb/modules_update. Several compatibility layers has been done: the new path is
bind mounted to the old path (/sbin/.magisk/img), and the helper functions in util_functions.sh
will now transparently make existing modules install to the new location without any changes.

MagiskHide is also updated to unmount module files stored in this new location.
2019-02-12 02:14:57 -05:00
Aidan Holland
cfa28f0c4a Empty Exceptions 2019-02-11 17:14:29 -05:00
topjohnwu
ab47b717b1 Reorganize scripts 2019-02-11 17:14:07 -05:00
Aidan Holland
65ebb0d2f8 Misc Formatting
* PEP8 and linting
* empty exceptions
2019-02-11 03:18:15 -05:00
Rom
49640ce03a Update French translation 2019-02-11 03:06:44 -05:00
vvb2060
e05cdc83f3 fix extract_bb 2019-02-11 02:35:04 -05:00
topjohnwu
992a9ea2f9 Fix EMUI 9 detection 2019-02-11 02:26:15 -05:00
topjohnwu
228351fc13 Prevent bootloop on non system-as-root devices
Close #1058
2019-02-10 13:51:41 -05:00
topjohnwu
8a5b6f2b86 Block all signals in daemon 2019-02-10 04:18:50 -05:00
topjohnwu
71ecbb3af3 Clean/refactor includes 2019-02-10 03:57:51 -05:00
topjohnwu
5746614ccf Keep track of timestamps and skip old logs 2019-02-10 03:16:52 -05:00
topjohnwu
3a422c3f15 Remove magisklogd, use threads and BlockingQueue 2019-02-10 01:05:19 -05:00
topjohnwu
b3242322fd Harden socket verification
- Do not allow connections to magiskd from binaries other than the one started the server
- Do not allow connections to magisklogd without root access
2019-02-09 15:02:46 -05:00
Licaon_Kter
9826640ae6 f-strings need Python 3.6
...this is a blocker for F-Droid since Debian Strech has only Python 3.5.x
2019-02-09 05:35:05 -05:00
topjohnwu
1f5267204b Better cmdline parsing 2019-02-09 05:23:56 -05:00
topjohnwu
ed25e1bbd6 Directly inject services into init.rc 2019-02-09 02:48:05 -05:00
topjohnwu
c8491d008f Move sbin overlay creation to magiskinit 2019-02-09 01:51:46 -05:00
Mevlüt TOPÇU
08e3405394 Update strings.xml 2019-02-07 00:45:51 -05:00
dark-basic
4ebfa07186 Some adjustments - Update Strings
I changed some words for their synonyms. In order to verify how it behaves on screens less than 5 inches.
(Some changes were made, since several devices I have, some words do not appear yet having space)
2019-02-07 00:45:43 -05:00
Erfan Abdi
6698c189fc Support non-ext4 filesystem for vendor and system
Signed-off-by: Erfan Abdi <erfangplus@gmail.com>
2019-02-07 00:45:30 -05:00
topjohnwu
f0639390aa Update dependencies 2019-02-07 00:37:40 -05:00
topjohnwu
bbdfed2d5a Fix strings 2019-02-05 00:52:52 -05:00
Madis
7f4daa2c50 Estonian update 2019-02-05 00:50:53 -05:00
Gozzwip
baf9b67b35 Creating Azerbaijani file 2019-02-05 00:50:40 -05:00
Mevlüt TOPÇU
caf73b0b36 Update Turksih language
Merge please

Thank you
2019-02-05 00:50:28 -05:00
Furkan
acf87c2794 fix one word 2019-02-05 00:50:17 -05:00
topjohnwu
7f5f6b54fb Ask for fingerprint before deleting policy
Close #1038
2019-02-04 23:08:06 -05:00
topjohnwu
a08eb8a446 Hide install button by default
Close #1037
2019-02-04 22:56:45 -05:00
topjohnwu
b31402766e Add 7.0.0 changelog 2019-02-04 03:15:20 -05:00
topjohnwu
9ab3143bf0 Force preference screen to use our preference stored in DE 2019-02-04 03:13:01 -05:00
topjohnwu
81a0cddb9e Add DirectBoot support to receivers and SuRequestActivity
Close #1032, courtesy of @vvb2060
2019-02-04 01:58:04 -05:00
topjohnwu
f620ac769f Update newline in docs 2019-02-03 23:48:20 -05:00
topjohnwu
dc91041edd Update documentation 2019-02-03 23:37:38 -05:00