yashsingh1/xdaforums huggingface dataset:
[Xperia Z5 Premium Android Development] YasuHamed:
FIRST download RC1supersu2.76.zip and put it in your xperia's SDCARD from

https://download.chainfire.eu/969/SuperSU/

now

your question are very interesting and honestly reminds me with my thirst of understanding android

lets start from very beginning

1. Android updates by SONY for XPERIA VARIENTS can be updated via SONY PC/COMPANION and/or XPERIA COMPANION, ONLY if bootloader is LOCKED, ORIGINAL and device has never been altered.

2. since your device is BOOT UNLOCKED you can not update using xperia companion

3. flashtool is the BEST tool for flashing xperia devices

4. build numbers are timely updates from SONY Japan for xperia devices for latest android patches and even latest android version from google. (currently xperia Z5 is on .305 (Marshmallow Android v6.01)

5. download .305 ftf file from xperifirm (preview attached) / after finish close xperifirm and WAIT for flashtool to compile that ftf file (maytake 10+mins)

6. flash this ftf file wiping everything (i am hoping you have taken backup of your device) / i flashed with these settings (image attached)/ to flash u need to connect xperia in flashmode.

7. flashing takes upto 30 mins and at the last header file getting closed, it takes aleast 20mins!

after it flashed

download the kernel by [MENTION=5410058]KbaB.BroS[/MENTION] from

https://mega.nz/#F!KwZhjLIK!uNbDzR6lCXMaaW7jKFS1WQ!6hZj1DyK

i believe your device is E6833, so download E6833.IMG (ONLY)

again from flashtool, click the thunder button, click fastbootmode, click "select kernel to flash" , it will ask you to connect your z5 in fastmode, then dialog box will POPUP asking kernel, point it to E6833.img (select .img file from dropdown menu of the dialog box )

done,

boot and on first screen press volume up, it will goto TWRP, select INSTALL, select STORAGE SDCARD and select RC1 superSu2.78 zip and install. //// wipe delvikcace and cache /// REBOOT in to system

done! (atleast for now)

reboot your device
[Xperia Z5 Premium Android Development] mhyr:
I remmebered why I downloaded the tft file from another source ! I dont know whats up whit my flashtools , I have tried 5 times to download the .305 or other roms by xperifirm, with or with out v*p*n ! every time it stops and doesnt go more than 2% i have attached pics :( this way i never could flash any thing with flashtools or even root my phone :(( im very sad and exhausted and dont know what the problem is and why is this keep going on :.( , reinstalling flashtools, firewall allowed,kaspersky protectioon off . nothing worked :((
[Xperia Z5 Premium Android Development] YasuHamed:
thats your internet connection

here i am attaching the TORRENT file for u

open using any good torrent client, like Utorrent or bittorrent etc

[MENTION=4487555]mahyjooon[/MENTION]
[Xperia Z5 Premium Android Development] YasuHamed:
HERE YOU GO

forget the torrent

https://xpericheck.com/device/E6633

i had downloaded 1297-9122 - Customized MEA	32.2.A.0.305-R8C

https://alfafile.net/file/45u9 (the uploaded file here)
[Xperia Z5 Premium Android Development] mhyr:
thanks alot , but honey my device is sony z5 premium E6833 not 6633 :confused: are they the same?!

[MENTION=5613633]YasuHamed[/MENTION]
[Xperia Z5 Premium Android Development] YasuHamed:
oops

here u go

https://xpericheck.com/device/E6833

https://alfafile.net/file/4M7p [MENTION=4487555]mahyjooon[/MENTION]
[Xperia Z5 Premium Android Development] mhyr:
[MENTION=5613633]YasuHamed[/MENTION] thanks for your really helpfull and quick ansewrs.i have tried your given link .i can not get premium acount unfortunatelly and every time i click on free mode button it disapears i dont know why, i have attached screenshot :((
[Xperia Z5 Premium Android Development] YasuHamed:
give me time , i will upload 2.5gb stock on my google drive will share it from my Gdrive with u :)
[Xperia Z5 Premium Android Development] YasuHamed:
[MENTION=4487555]mahyjooon[/MENTION]

i have started uploading ftf file on this following link

https://www.mediafire.com/folder/nq47j0sxzzj52/6.01_-_32.2.A.0.305_-_OCT2016

should get completed in a while ( depending on the server speed)

when u see an ftf file 2,557,992KB , means its fully uploaded

just download from my account

thanks
[Xperia Z5 Premium Android Development] mhyr:
No tft yet ! just 2 files there, one .img and one supersu.zip
[MENTION=5613633]YasuHamed[/MENTION]
[Xperia Z5 Premium Android Development] YasuHamed:
cheking!
[Xperia Z5 Premium Android Development] YasuHamed:
I think approperiate mother board driver is missing

There's a directory named "drivers" under the main flashtool dir. Run flashtool-drivers.exe and install the appropriate drivers. I think "Common Drivers SO-03H)" is the one you need. I ended up installing all of them to get it to flash (which took ages).

or you may download here

http://developer.sonymobile.com/downloads/drivers/xperia-z5-premium-driver/

if its windows8 or 10 then disable signature verification! windows10 behaves badly while flashing android devices
[Xperia Z5 Premium Android Development] icaruswalks:
Thank you for this! I thought I had the right drivers after installing Sony PC Companion, and verifying the device via Minimal ADB and Fastboot commands, but apparently that was not the case. For posterity's sake, the correct name for the driver you mentioned is "Xperia acro HD (SO-03D) driver for ICS." That saved me a lot of time, as you correctly pointed out that installing all the drivers would have taken a very long time.
[Xperia Z5 Premium Android Development] YasuHamed:
you are always welcome bro
[Xperia Z5 Premium Android Development] chev3:
hi

I am new to Sony Smartphones and have some questions.

I just want to delete some pre-installed apps on MM and than remove root access and get back the original locked bootloader.

I know the bootloader must be unlocked to get root.

The Z5 is now on LP and I backed up the TA Partion with iovyroot, now I want to upgrade back to MM and unlock the bootloader to gain root acces or should I unlock the BL on LP?

After this I just want to delete the bloatware on the Z5 and remove Root and get back to locked BL with the TA backup

So restoring the TA Partition relockes the bootloader automatically and the Z5 will be working 100% with all function and DRm keys as before?

Can I restore TA Partition on MM that was created on LP?
[Xperia Z5 Premium Android Development] YasuHamed:
since controlling the BEAST part of extracting DRM KEYS is DONE

you can unlock your bootloader at any level either LP or MM, its upto u!

the point is! to gain root access, you must have unlocked bootloader!

whil your on MM (android 6.01) / latest build 32.2.A.0.305 (xperia z5 E68xx)

download supersu from

https://download.chainfire.eu/1003/SuperSU/SR1-SuperSU-v2.78-SR1-20160915123031.zip

put it in your SD CARD

unlock your bootloader (if you don't know how to unlock , i am giving you link at the bottom of my post)

after unlocking the bootloader, device restarts. / shutdown device.

connect device in FLASHMODE (using flashtool)

goto the stock modified kernel depositories by [MENTION=5410058]KbaB.BroS[/MENTION]

https://mega.nz/#F!KwZhjLIK!uNbDzR6lCXMaaW7jKFS1WQ!WpZAkLZC (download img file of your device ONLY)

flash kernel / restart device/ keep toggling volume up key / it will take u to recover / install from zip and flash that superSU file/

rebooot your z5p

DONE.

IF you want you can lock your bootloader now by using flashtool.

DRM keys restoration is recommended but not necessary since these modified kernels are stimulating drm keys

useful links

stock ftf files

https://xpericheck.com/device/E6833

https://xpericheck.com/device/E6853

https://xpericheck.com/device/E6883

my DETAILED post on this subject

http://xdaforums.com/z5-premium/development/rooting-xperia-z5-z5p-variants-drm-keys-t3437902
[Xperia Z5 Premium Android Development] chev3:
I have the E6653 device and I need to take the kernel from tobias.waldvogel http://xdaforums.com/xperia-z5/development/root-automatic-repack-stock-kernel-dm-t3301605 or can I take it from KbaB.BroS but I guess it is only for Z5P ? Or can I take the AndroPlus Kernel?

regards
[Xperia Z5 Premium Android Development] YasuHamed:
[MENTION=5410058]KbaB.BroS[/MENTION] kernel's are verified, I am using it on my device
[Xperia Z5 Premium Android Development] TimeIsAll:
How do i restore the DRM keys? :)
[Xperia Z5 Premium Android Development] YasuHamed:
as of now , no need, the modified kernels have DRM fix
[Xperia Z5 Premium Android Development] chev3:
I have the E6653 not the Z5P. Which kernel should I take? because tobias.waldvogel isn´t anymore on xda I heard and his kernel is for .253 only

regards
[Xperia Z5 Premium Android Development] YasuHamed:
download ftf file for E6653 from

https://xpericheck.com/device/E6653

extract ftf file using 7zip

here you will find kernel.sin file

send me, i will modity it for you!
[Xperia Z5 Premium Android Development] Fravin:
Links for the Kernel

The links for the modified Kernel are gone...
[Xperia Z5 Premium Android Development] atif_afzal:
I don't under stand.. Either IVROOT backup the TA or TA 9.11v ... I have z5P dual 5.1.1 (170), I use IVROOT it generate one file TA-19112016 and its size is 2048. Now let me know that I have done properly back my TA/DRM or not.

When I use TA 9.11V I an unable to make backup because it ask to root. Please let me know because I want to unlock my bootloader
[Xperia Z5 Premium Android Development] FireDragonmx:
Hello!

Can I restore my DRM keys backup to my E6853 once its rooted on .305 firmware? Sorry if my english is bad!
[Xperia Z5 Premium Android Development] YasuHamed:
seems like you already have!

i used https://github.com/DevShaft/Backup-TA/releases

to extract DRM KEYS
[Xperia Z5 Premium Android Development] BumRush:
Downgraded back to 32.0.A.6.115 R2B but kingroot doesn't seem work work on my E6833. Tried iovy root as well but it also say device nit supported. Want to extract my DRM keys before unlocking the bootloader.
[Xperia Z5 Premium Android Development] -DM-:
The only firmwares supported by iovyroot for your device are:

E6883 (32.0.A.6.160 & 32.0.A.6.170 & 32.0.A.6.209)

Thats in the 1rst post of the iovyroot thread...downgrade to any of those and it should work...never tried kingroot (never will either)
[Xperia Z5 Premium Android Development] miramirovich:
Hi, I'm going to root my Z5p Dual E6833, but I'm little confused which

Firmware to Downgrade?

I want to extract my DRM-KEYS / TA BACKUPS (FIDO KEYS)

My firmware is 32.1.A.1.163

You recommended to downgrade to "32.0.A.6.115 R2B" but this one

is not supported by iovyroot - according in supported models

table, the only one is:

E6833 (32.0.A.6.170)

In XperiFirm I found these:

E6833_Commercial and Journalists_1298-2874_32.0.A.6.170_R4B

E6833_Promoter_1300-1929_32.0.A.6.170_R2B

E6833_Store Front_1300-2624_32.0.A.6.170_R2B

Which one is right one, or I must use 32.0.A.6.115 R2B ?

In XperiFirm I can not find 32.2.A.0.253 for Z5p Dual E6833 for further upgrade.

Your Links not working.

I found some Xperia Z5 Premium Dual_E6833_32.2.A.0.253_Middle East_Generic 6.0.1

Can some one please point me the right way to proceed.

Thank you.
[Xperia Z5 Premium Android Development] -DM-:
Don't have any of those firmwares as I use a E6853...but take a look at this thread on the xperia x performance, read thru the thread, there is going to be a way to backup the TA without downgrading soon, they're working on an automated tool to run script right now...

So no more downgrading, you can send them info that they need about the Z5p to help them if you want...just go and check it out
[Xperia Z5 Premium Android Development] YasuHamed:
i will REFLASH my .305 firmware and will see that this script runs for z5p or not!

atleast to the level of freezing app
[Xperia Z5 Premium Android Development] -DM-:
Pretty interesting what's going on over there in that thread...started with serajr dirtycow temp root to freeze apps and it evolved into reconstruction of the trim area by user p0kemon...which means that in the future we won't have to wait for an exploit to temp root to extract the TA...we can just unlock the bootloader, root and reinstall TA...

That is going to be great news for any upcoming xperia phones...
[Xperia Z5 Premium Android Development] miramirovich:
Very interesting , I will follow this topic and I hope this method will become reality soon!

I lost my patience of waiting - not good at all.

But what is your opinion in my situation- should I downgrade to

supported by iovyroot firmware /and which one/- E6833 (32.0.A.6.170):

E6833_Commercial and Journalists_1298-2874_32.0.A.6.170_R4B

E6833_Promoter_1300-1929_32.0.A.6.170_R2B

E6833_Store Front_1300-2624_32.0.A.6.170_R2B

or I should use unsupported by iovyroot one but recommended by author of this topic "32.0.A.6.115 R2B"?

Then for further upgrade is this one is suitable for Flashing my Z5P E6833

"Z5 Premium Dual_E6833_32.2.A.0.253_Middle East_Generic 6.0.1"?

Thank you.
[Xperia Z5 Premium Android Development] -DM-:
A poster on the previous page said that .115 didn't work for him with iovyroot, you can give a try yourself, the other supported firmwares that you listed here should though...

You're not going to stay on that firmware anyway, it's just too temp root and backup your TA...so I don't see any problem there...

YasuHamed should know more about it though as he has a E6883...wait for his reply and see
[Xperia Z5 Premium Android Development] -DM-:
Dirtycow TA backup tool is out...check here

Check if your firmware is vulnerable to dirtycow (which it should be as it's still MM) then give that new tool a shot ;)
[Xperia Z5 Premium Android Development] miramirovich:
I Tried this tool and it Seemed to work on

Xperia Z5 Premium Dual E6833:

Original untouched /out of the box/ Brand New

Running 32.1.A.1.163 firmware

Android version 6.0

Here the result:

Picking 64-bit version

Running on E6833 on 64-bit platform

Pushing files

975 KB/s (9984 bytes in 0.010s)

594 KB/s (6088 bytes in 0.010s)

1394 KB/s (14280 bytes in 0.010s)

497 KB/s (10184 bytes in 0.020s)

0 KB/s (876 bytes in 1.000s)

Running scripts to dump ta to "TAIMG" on device

Overwriting run-as

Attempting to dirtycow

Done dirtycowing

Overwriting secondary payload (screenrecord)

Attempting to dirtycow

Attempting to dirtycow

Done dirtycowing

Attempting exploit

Attempting to dirtycow

Attempting to dirtycow

Attempting to dirtycow

Attempting to dirtycow

Done dirtycowing

Waiting for result....

Got a total of 2097152 bytes

Exploit successful!

Dumped TA as TA_E6833_CB5A29DVBE_ёЁ1207-201617.img

Pulling image

4129 KB/s (2097152 bytes in 0.496s)

Cleaning up

TA Sucessfully pulled to TA_E6833_CB5A29DVBE_ср1207-201617.img

****NOTE: Please verify filesize is 2MB ****

Press any key to continue . . .

Really nice work!
[Xperia Z5 Premium Android Development] atif_afzal:
[MENTION=5613633]YasuHamed[/MENTION]:

Dear i want to know that new boot.image is stock modified kernel or different for E6833 32.2.A.5.11
[Xperia Z5 Premium Android Development] -DM-:
You should put a confirmation with your info in that thread, so others know it also works for that device...
[Xperia Z5 Premium Android Development] miramirovich:
I'm not allowed to write in developers topic.

Feel free if you can to post my result in developers topic.
[Xperia Z5 Premium Android Development] YasuHamed:
its stock modified kernel, only securities have been switched off. so the device will work with SONY partitions only.
[Xperia Z5 Premium Android Development] YasuHamed:
well i am hearing alot about dirtycow xploit to gain any root access and even TA backup is possible. however this tool is simply temporary to extract DRM KEYS and then later you must unlock bootloader and install twrp and flash superSU
[Xperia Z5 Premium Android Development] YasuHamed:
E6833_Commercial and Journalists_1298-2874_32.0.A.6.170_R4B , is LP kernel hence u can root it via kingroot, kingoroot , in order to gain / backup drm keys (link giving in the main thread)

however later unlocking boot is must to have root access in android6.0.1
[Xperia Z5 Premium Android Development] -DM-:
Correct, it's a temp root just for the point of backing up the TA, just like iovyroot, with the only difference that you don't need to downgrade to a supported Lollipop firmware...it works on any actual MM that haven't been patched yet (won't work N though when it comes out)

Root with a locked bootloader won't ever be possible with verified boot anyway
[Xperia Z5 Premium Android Development] YasuHamed:
very nicely elaborated -DM- (y)

to be VERY HONEST, I need root access ONLY to remove bloatware and freeze apps! DirtyCow offeres enough. My future device ofcourse will be any xperia flagship when 5G comes out with VoLTE support and Android N or O will be out! I won't patch kernel as long as any xploit allow me to switchoff/remove apps!

( another debate is why buying unfinished xperia flagships with reasonable ram and storage on such high prices when competitors such as one+, Xiaomi are offering so much more on reasonable prices)
[Xperia Z5 Premium Android Development] miramirovich:
I'm little confused do I must unlock boot loader to downgrade with FlashTool or not?

If I unlock it first to downgrade I will lose my TA and DRM keys right?

How can I restore later something which is gone-wipe after unlocking Boot loader?

Thank you
[Xperia Z5 Premium Android Development] YasuHamed:
with android devices fastboot mode and flashmode are the two communication channels with your device (over adb)

original unchanged (stock roms) can be pushed in fastboot mode,

modified stock roms (kernel, system, third party roms) can be flashed in flashmode.

you can flash original STOCKROM (ONLY) in fastboot mode

you can flash ANY STOCKROM and/or modified stock roms and kernels in FLASHMODE

FLASHMODE works ONLY when bootloader is LOCKED

for fastboot mode, unlocking bootloader is not necessary.

for xperia devices the best such tool is flashtool ( www.flashtool.net)

the downloaded file of "E6833_Commercial and Journalists_1298-2874_32.0.A.6.170_R4B" will be ftf file, UNCHANGED and hence you can flash it in fastboot mode. and then using kingroot, drm keys can be extracted. once you have root access on LOCKED bootloader (on LP kernel , android5.x.x) . you can backup your drmkeys!

later unlock bootloader, upgrade/flash latest stockfirm where, and flash modified kernel having twrp (as given in the first thread) and from twrp , flash superSU (must be placed in your sd card earlier)
[Xperia Z5 Premium Android Development] miramirovich:
You mean that I can use FlashTool with locked bootloader and can downgrade or upgrade any official Firmware

downloaded with XperiFirm designed for my device, with no worries about loosing TA- DRM keys?

So if I downgrade for example to 32.0.A.6.170 LP and can not backup my TA, then I can Upgrade to any official

Firmware from XperiFirm with FlashTool with locked bootloader?
[Xperia Z5 Premium Android Development] kalasha:
Issue with img or twrp Rec.

The rooting does work with the files and instructions below, but there are two issues:

When the phone is encrypted after root, you cannot deactivate the encryption or basically the decrypt the phone. The second issue occurs when you try to do a factory reset after the phone is encrypted - the phone cannot perform the factory reset because the phone's internal drive/storage is encrypted.

If anyone can provide a proper solution - it would be appreciated. Not too sure if the issue is the img file or something else.

thank you,

KS
[Xperia Z5 Premium Android Development] wild786:
Is there a modified kernel for E6883 for the new 32.2.A.5.11 update?

Nvm, I found it
[Xperia Z5 Premium Android Development] necrogodomega:
While this thread is super full of cool useful info, the link for the modified kernels doesn't work anymore. So I can't find one for my E6883.

I want to keep it rooted but right now it's at 5.1.1 LP and build 32.0.A.6.209 and both KINGROOT and ONECLICKBOOT don't work for it.

What's also annoying is that my phone in it's current state doesn't have any Google Services (Play store, Google Play Services) or whatever.

Anyone have any suggestions? Thanks a lot.
[Xperia Z5 Premium Android Development] wild786:
I suggest reading this guide: http://xdaforums.com/z5-premium/development/stock-root-xperia-z5-premium-sony-stock-t3335974

There's a kernel available for E6883 for the newest update here: http://xdaforums.com/z5-premium/general/32-1-1-185-stock-modified-kernel-t3355369
[Xperia Z5 Premium Android Development] necrogodomega:
Cool thanks.

I was wondering too that if I update to the latest kernel for E6883 would it still use all the Networks the same? Like

can I still use 3G and 4G for China Mobile?
[Xperia Z5 Premium Android Development] wild786:
Well, when you use XperiFirm to download the firmware update make sure you get the one with the same CDA as your current firmware and you shouldn't have any problems..

Check this thread for more info: http://xdaforums.com/crossdevice-dev/sony/pc-xperifirm-xperia-firmware-downloader-t2834142
[Xperia Z5 Premium Android Development] YasuHamed:
out from the ftf file for 32.2.A.5.11 , for E6883

extract and send me the kernel.sin file ( u may use 7zip)

i will fix the kernel for u
[Xperia Z5 Premium Android Development] ajsalas:
Can i use the kernel from E6833 into the E6853?
[Xperia Z5 Premium Android Development] KbaB.BroS:
[MENTION=5613633]YasuHamed[/MENTION] the link you have is outdated, the link from my thread works perfectly fine.
[Xperia Z5 Premium Android Development] YasuHamed:
[MENTION=5410058]KbaB.BroS[/MENTION]

thank you :)

i have updated :)
[Xperia Z5 Premium Android Development] konstantinos3:
What about E6853???

Should I download kernel from https://mega.nz/#F!7gRDBIJY!af8WZfXMno2Pm_OgEMSqNQ ?

and then

- flash SR3-SuperSU-v2.78-SR3-20161103171345 via twrp (link???)

- reboot into system
[Xperia Z5 Premium Android Development] YasuHamed:
the latest firmare is 32.2.A.5.11 so from here download your device's kernel (boot loader must be unlocked

https://mega.nz/#F!7gRDBIJY!af8WZfXMno2Pm_OgEMSqNQ!m4YTBJjC

the SR5 of supersu2.78 is out!

http://xdaforums.com/apps/supersu/2014-09-02-supersu-v2-05-t2868133 (download link is in the first post)

best of luck
[Xperia Z5 Premium Android Development] konstantinos3:
Thanx a lot!

Should I wipe anything? I would prefer not to set my device from the beginning... :angel::angel:
[Xperia Z5 Premium Android Development] YasuHamed:
its not necessary!

but I would recommend it!

some how it improved battery life!
[Xperia Z5 Premium Android Development] lOmarBl:
Thank you!!!

I FRKN LOVE YOU. Thank you bro!

Salam from Lebanon! :)

الله يجزيك الخير!
[Xperia Z5 Premium Android Development] EMJI79:
English only please [emoji4]
[Xperia Z5 Premium Android Development] |Omar|:
Will you update this for 32.3.A.0.372 (Android 7 Nougat)???

Will you update this for 32.3.A.0.372 (Android 7 Nougat)???

Please do man! :fingers-crossed:
[Xperia Z5 Premium Android Development] Langdang02:
+1
[Xperia Z5 Premium Android Development] xrenoix:
Do not ask eta please
[Xperia Z5 Premium Android Development] |Omar|:
I never asked for the ETA. Read my comment again, please. :)

Sheesh.. what's up with some XDA users and telling people what to do, and I'm not talking tutorials..
[Xperia Z5 Premium Android Development] Nirvana Rules:
Not my work, I just put it together for myself and I'm sharing

OK guys I managed to follow the instructions in Z5 section and now I'm running Nougat with drm keys.

1. Flash nougat with flashtools ( I erased everything so back up your photos videos etc)

2.After initial boot complete startup wizard.

3. Put attached file into root of sdcard

4.boot into fastboot and flash boot image that has TWRP I used the one from latest MM

5. Boot into TWRP

6. Flash Zip and you're in.

I read that you can also flash SU but I just wanted my DRM Keys back at least for the time being. I hope this helps some of you. Enjoy!!!!
[Xperia Z5 Premium Android Development] whalesplaho:
Dis ll give bootloop cos yhu have changed tha kernel to a none compatible more... Yhu didnt state what to do after flashing tha zip!