[Guide] Mate 9 Magisk

wancyber

Senior Member
Jan 14, 2018
51
20
8
Cyberjaya
Update:
***UPDATE LINK FOR MAGISK 17.1 & TWRP 3.2.1
***No need to Format Data/Wipe unless you know what you doing !


THINGS NEED :
"Minimal ADB and Fastboot"
"Unlock Code"
"MAGISK"
"TWRP"
"PC"
"HW.zip & Public Data.zip (if you wipe/format)-usually u don't need this
"Huawei Prop Fix" (if safetynet test fail)
"Ramdisk.img" (if supersu installed)


FIRST STEP :
- Download and Install "Minimal ADB and Fastboot" and install it on your computer.
- Download Magisk, TWRP, and all the files that you need - Link Provided Below
- Enable 'USB debugging' in phone settings
- Make sure that Hisuite is installed (which will ensure that USB drivers are installed)

*If you choose Format Data => yes (wipe) in TWRP :
- Download HW.zip and Public_data.zip for your firmware from http://pro-teammt.ru/firmware-database/
- Search for your firmware, eg: MHA-L29C432B365.
- Click on the "filelist" next to your firmware, copy and paste the full links in new tabs to download "update_full_MHA-L29_hw_eu.zip" and "update_data_full_public.zip".
- hw_eu/sea.zip will be different depending on your region/cust.

*** BACKUP all your data (internal storage) as UNLOCKING bootloader will WIPE all your DATA !!!


A) UNLOCKING BOOTLOADER :
- Visit this page :
http://emui.huawei.com/en/
- Then click on Download. And then click on "Unlock bootloader"
OR https://emui.huawei.com/en/plugin/unlock/detail
(direct you to login/sign up pages)
- Fill the required details on the form.
- Copy paste the code and save it in any text file.

Make sure,
- USB Debugging has been enabled on the phone
- Phone has been verified to connect to the computer and permanently accepted the RSA id and connected in debug mode.
- "Enable OEM Unlock" has been enabled in the developer options.

Now,
- Power off the phone, then hold volume-down and insert usb cable to enter fastboot mode.
- Enter the following commands :
fastboot oem unlock xxxxx (xxxxx your unlock code)
fastboot reboot
Congrats, now your bootloader is unlocked ! :D

B) COPYING :
- Copy the twrp.img file to the "Minimal ADB and Fastboot" directory
- Copy the Magisk, Huawei Prop Fix & all necessary files to SD Card (not internal storage)

C) FLASHING :
- Power off the phone, then hold volume-down and insert usb cable to enter fastboot mode / bootloader mode.
- Enter the following commands :
fastboot flash recovery_ramdisk TWRP_3.2.1-0_OREO_fixlinks.img (flash 1 only 3.0.3 / 3.2.1)
fastboot reboot
** If you have SuperSU installed, flash ramdisk.img :
(fastboot flash ramdisk ramdisk.img)

** Note: if you have SuperSU installed, you must restore stock ramdisk.img.
Download your firmwares update.zip from
http://pro-teammt.ru/firmware-database/
Search for your firmware, example used below : MHA-L29C432B365.
Then extract update.app from update.zip.
Download and Open Huawei Update Extractor, go to settings tab and disable both checksum.
Open update.app in Huawei update extractor and extract ramdisk.img.


- Power off the phone, hold volume-up and power button to enter TWRP.
- Entering TWRP, select "Keep Read Only" (Everytime enter TWRP select this.)
- Wipe => Format Data => Yes/No (Choose NO, if you don't know)
* If Format Data=> Yes,
- Flash Public Data.zip
- Flash Hw.zip.
* If Format Data=> No, continue flashing Magisk.

- Install => Select 'Magisk-v16.0(1600).zip' file
- Reboot => System => Do Not Install.
You're Rooted with Magisk 17.1 !



Minimal ADB and Fastboot :
https://forum.xda-developers.com/showthread.php?t=2317790

Magisk 17.1 :
https://mega.nz/#!jVUnWKZQ!fw4Ch6rnRtK6UUoOcI9FqwLykOmwgw-wgCUPD854vNk

TWRP 3.0.3 with fixlinks by Mankindtw:
https://mega.nz/#!AWpymRbC!ncVMIZL177b2OssrjSuKVq2AyyxzUqj_BKfsMEAajhw

TWRP 3.2.1 with fixlinks by Blackball :
https://mega.nz/#!qVFTTKLb!DfE5y43bJWfEM_Xt2jmK71ZwSNEorRebgEydiEJr1fo

Huawei Prop Fix by mankindtw :
https://drive.google.com/open?id=1Ru...W0LTMR6Ip5xIcM



OFFICIAL ANNOUNCEMENT :
https://forum.xda-developers.com/hon...0-pro-t3749280
(patching ramdisk in Manager is not necessary as we have TWRP, and if you already have Magisk installed, Direct Install will work)


Credits :
This is their works : mankindtw, ante0
( I'm just helping them :D )
Magisk : topjohnwu
TWRP : mankindtw, Blackball
Unlocking Bootloader Guide : Saurabhg9
Minimal ADB and Fastboot : Shimp208
Huawei Firmwares Finder: Team MT

Guideance by : @ante0

Sent from my Huawei Mate 9 using XDA Labs
 
Last edited:
  • Like
Reactions: eeeric

ante0

Senior Member
Dec 28, 2009
3,206
1,576
243
Stockholm
Updated :
***No need to Format Data(Wipe) with MAGISK 15.4 or 16.0.


THINGS NEED :
"Minimal ADB and Fastboot"
"Unlock Code"
"MAGISK"
"TWRP"
"PC"
"HW.zip & Public Data.zip (if you wipe/format)-usually u don't need this
"Huawei Prop Fix" (if safetynet test fail)
"Ramdisk.img" (if supersu installed)


FIRST STEP :
- Download and Install "Minimal ADB and Fastboot" and install it on your computer.
- Download Magisk, TWRP, and all the files that you need - Link Provided Below
- Enable 'USB debugging' in phone settings
- Make sure that Hisuite is installed (which will ensure that USB drivers are installed)

*If you choose Format Data => yes (wipe) in TWRP :
- Download HW.zip and Public_data.zip for your firmware from http://pro-teammt.ru/firmware-database/
- Search for your firmware, eg: MHA-L29C432B365.
- Click on the "filelist" next to your firmware, copy and paste the full links in new tabs to download "update_full_MHA-L29_hw_eu.zip" and "update_data_full_public.zip".
- hw_eu/sea.zip will be different depending on your region/cust.

*** BACKUP all your data (internal storage) as UNLOCKING bootloader will WIPE all your DATA !!!


A) UNLOCKING BOOTLOADER :
- Visit this page :
http://emui.huawei.com/en/
- Then click on Download. And then click on "Unlock bootloader"
OR https://emui.huawei.com/en/plugin/unlock/detail
(direct you to login/sign up pages)
- Fill the required details on the form.
- Copy paste the code and save it in any text file.

Make sure,
- USB Debugging has been enabled on the phone
- Phone has been verified to connect to the computer and permanently accepted the RSA id and connected in debug mode.
- "Enable OEM Unlock" has been enabled in the developer options.

Now,
- Power off the phone, then hold volume-down and insert usb cable to enter fastboot mode.
- Enter the following commands :
fastboot oem unlock xxxxx (xxxxx your unlock code)
fastboot reboot
Congrats, now you're bootloader is unlocked ! :D

B) COPYING :
- Copy the twrp.img file to the "Minimal ADB and Fastboot" directory
- Copy the Magisk, Huawei Prop Fix & all necessary files to SD Card (not internal storage)

C) FLASHING :
- Power off the phone, then hold volume-down and insert usb cable to enter fastboot mode / bootloader mode.
- Enter the following commands :
fastboot flash recovery_ramdisk TWRP_3.2.1-0_OREO_fixlinks.img (flash 1 only 3.0.3 / 3.2.1)
fastboot reboot
** If you have SuperSU installed, flash ramdisk.img :
(fastboot flash ramdisk ramdisk.img)

** Note: if you have SuperSU installed, you must restore stock ramdisk.img.
Download your firmwares update.zip from
http://pro-teammt.ru/firmware-database/
Search for your firmware, example used below : MHA-L29C432B365.
Then extract update.app from update.zip.
Download and Open Huawei Update Extractor, go to settings tab and disable both checksum.
Open update.app in Huawei update extractor and extract ramdisk.img.


- Power off the phone, hold volume-up and power button to enter TWRP.
- Entering TWRP, select "Keep Read Only" (Everytime enter TWRP select this.)
- Wipe => Format Data => Yes/No (Choose NO, if you don't know)
* If Format Data=> Yes,
- Flash Public Data.zip
- Flash Hw.zip.
* If Format Data=> No, continue flashing Magisk.

- Install => Select 'Magisk-v16.0(1600).zip' file
- Reboot => System => Do Not Install.
You're Rooted with Magisk 16.0 !



Minimal ADB and Fastboot :
https://forum.xda-developers.com/showthread.php?t=2317790

Magisk 16.0 :
https://mega.nz/#!ncEwXKQS!hmgQlzPQ9slK3yZRzyhl2no-rJ6DAxHOTyE6xaU-7Gc

TWRP 3.0.3 with fixlinks by Mankindtw:
https://mega.nz/#!AWpymRbC!ncVMIZL177b2OssrjSuKVq2AyyxzUqj_BKfsMEAajhw

TWRP 3.2.1 with fixlinks by Blackball :
https://mega.nz/#!4DYngAxL!OJEgQ4a4cSTypHgRBbMQbok2BRDuVHSDXNktAJ_PnKQ

Huawei Prop Fix by mankindtw :
https://drive.google.com/open?id=1Ru...W0LTMR6Ip5xIcM



OFFICIAL ANNOUNCEMENT :
https://forum.xda-developers.com/hon...0-pro-t3749280
(patching ramdisk in Manager is not necessary as we have TWRP, and if you already have Magisk installed, Direct Install will work)


Credits :
This is their works : mankindtw, ante0
( I'm just helping them :D )
Magisk : topjohnwu
TWRP : mankindtw, Blackball
Unlocking Bootloader Guide : Saurabhg9
Minimal ADB and Fastboot : Shimp208
Huawei Firmwares Finder: Team MT

Guideance by : @ante0

Sent from my Huawei Mate 9 using XDA Labs
Also, an FYI, Pretoriano80 made a TWRP with decryption support: https://forum.xda-developers.com/mate-9/development/recovery-twrp-3-2-1-0-t3783353
 
  • Like
Reactions: wancyber

ulli5

Member
Mar 11, 2018
11
0
0
SafetyNet test fails

It can. No need to install prop fix at all.
Why doesn't it do then in my case? My phone is an MHA-L29C432B363. I just flashed Android 7 via HWOTA and updgraded via OTA. Then I flashed Xposed and Magisk (tried v16.0 and v16.6). Everything seems to be OK, but when I do the SafetyNet Test with Magsik Manager I get "false" in both tests.
 

rufik

Senior Member
Jan 18, 2010
331
84
28
Łódź
Why doesn't it do then in my case? My phone is an MHA-L29C432B363. I just flashed Android 7 via HWOTA and updgraded via OTA. Then I flashed Xposed and Magisk (tried v16.0 and v16.6). Everything seems to be OK, but when I do the SafetyNet Test with Magsik Manager I get "false" in both tests.
Because of exposed. I have same model as you but B366 build and I'm passing safety net.
 
  • Like
Reactions: wancyber and ulli5