[Sony Xperia M5] mbc07:
Reminder: iovySU works only on select Lollipop-based firmwares from Xperia M5, if you updated your phone to Android 6.0, the only way to get root is by unlocking its bootloader and flashing a custom kernel, like this one. If your phone has a permanently locked bootloader, there's NO WAY to root while running Marshmallow, but you can still downgrade to Lollipop and use iovySU if you desperately need root access on your bootloader locked M5.

Today I present you iovySU, a tool based on iovyroot binary which can sucessfully root Xperia M5 family! No need to unlock your bootloader or lose your unique DRM keys!

Requirements

• You must be using one of the supported firmwares (they're listed on "Supported Firmwares" down below and are also available as FTF, so you can downgrade with Androxyde's FlashTool if needed).

• USB Debugging must be enabled on the phone (available in Settings => Developer Settings -- if you can't see it, go to Settings => About Phone and tap 7 times on Android Build).

• ADB drivers should be installed on the computer, otherwise this tool won't see it (you can install Xperia Companion to get the drivers or use the stand-alone ADB driver).

• Your computer should be running Windows or Linux (you can probably use the Linux script on Mac, but that's completely untested and not guaranteed to work at all).

Instructions

• Download the attached ZIP and unzip its contents somewhere;

• Connect your phone, open iovysu.bat and wait (if you're on Linux, launch iovysu.sh from Terminal instead);

• After the process finished, the tool will notify you, press any key to reboot your phone;

• If iovySU worked, on your phone you should see a SuperSU notification, tap on it and let it update the binary (if you don't see the SuperSU notification, open SuperSU from app drawer instead);

• After updating the binary, reboot your phone once more and enjoy your fully rooted phone!

Supported Firmwares

For single SIM variants (E5603, E5606 and E5653):

• 30.0.A.1.23

• 30.1.A.1.33

For dual SIM variants (E5633, E5643 and E5663):

• 30.0.B.1.23

• 30.1.B.1.33

Frequently Asked Questions

Q: Help! I've enabled USB Debugging on my phone but iovySU keeps stuck at "Waiting for device" message!

A: This means ADB isn't "seeing" your phone, either because you didn't install ADB drivers (you can use this stand-alone driver) or because you didn't authorize the connection on your phone. If iovySU still can't see your phone, make sure you don't have another Android device with USB Debugging enabled plugged on your computer at the same time or emulators like BlueStacks or Genymotion running.

Q: Help! I'm using one of the supported firmwares, I ran iovySU, it rebooted my phone but I still don't have root access/SuperSU didn't show up in the app drawer!

A: Run iovySU again. Sometimes the exploit may freeze and your phone may reboot before SuperSU gets installed. In case you tried a few times and still can't get root, post the output of the tool here so I can help you.

Q: Help! I'm using a newer firmware but I couldn't find an FTF of a supported firmware version which matches my variant! What can I do?

A: I've uploaded the FTFs of the supported firmwares (check the forum), you can crossflash them safely to your phone (just don't do single SIM => dual SIM or vice versa -- the phone will bootloop). After rooting with iovySU, get an FTF which matches your variant/region with XperiFirm/FlashTool and use dd Flasher Minimal to flash it while maintaining root access.

Q: Why should I use this instead of KingRoot?

A: Mainly because it's open source, so you can see what's actually being modified on your phone. Currently, KingRoot has the convenience of rooting Xperia M5 with one click but on the other hand you get a dubious root managing app that have issues with some root-enabled apps and also includes other bloat stuff built-in. Although with some effort it can be replaced with SuperSU, the process is not that simple and can still leave junk on your system. That's also the main reason I talked with [MENTION=3975929]zxz0O0[/MENTION] as soon as I noticed iovyroot could work on Xperia M5.

Q: I used iovySU and I'm rooted now, but I'm stuck on an older firmware version/another variant and OTAs fail to install. How can I update without losing root access?

A: By using my other tool, dd Flasher Minimal. If you crossflashed your phone in order to use iovySU, just get an FTF that matches your variant/region with FlashTool/XperiFirm and use it with dd Flasher Minimal.

Q: Is there any difference between iovySU and iovyroot?

A: Yes and no. Basically, the only difference between iovySU and iovyroot is that iovyroot gains temporary root to make a TA backup of the supported devices, while iovySU benefits from the same temporary root but to actually install SuperSU permanently on the system. The reason iovyroot script only backups TA partition is that many of the supported devices have additional security measures enabled, like dm-verity, so, these devices would refuse to boot if a single byte was modified on the system partition (and well, you actually need to write into system partition to get permanent root). For our luck, none of the Xperia M5 firmwares available at the moment have dm-verity, so we can get full root access without any issues!

Q: Can I use iovySU to root <insert device here>?

A: Well, if it's a device supported by iovyroot, without dm-verity (or similiar) on its kernel and running an ARM64 version of Android Lollipop or newer, then yes, it should work. It theoretically can work also with 32-bit devices, but then you'll need to modify the SuperSU package used by iovySU with the appropriate binaries (that's because unlikely the official SuperSU package, iovySU uses a stripped down version including only the bare minimum needed to get SuperSU installed on an ARM64 ROM).

Credits

I'm the author of the script but it also includes pieces of code made by [MENTION=631273]Chainfire[/MENTION] (SuperSU) and heavily relies on iovyroot binary. I would also like to thank the people who helped testing the exploit earlier and [MENTION=3975929]zxz0O0[/MENTION] for developing the iovyroot binary and his promptly help in adding Xperia M5 support to it.