FORUMS
Remove All Ads from XDA

[TOOL] PRFCreator - easily create pre-rooted firmwares

1,446 posts
Thanks Meter: 4,459
 
By zxz0O0, Senior Member on 27th August 2014, 04:11 PM
Post Reply Email Thread
Introducing my new tool called PRFCreator. With this tool, anyone can easily create a pre-rooted firmware.

What is a pre-rooted firmware
A pre-rooted firmware is a firmware, which already includes root. This is for example important if you want to update the firmware to a version, where there is no public root exploit. To flash a pre-rooted firmware, you need a recovery menu. An unlocked bootloader is not required.

How does the tool work
The tool should be self-explanatory. SuperSU zip can be downloaded from here. [NUT]'s dualrecovery (*.flashable.zip) can be downloaded from here. Recovery is optional and if your device is not supported by dualrecovery, you can use any recovery (just has to be a flashable zip).
Depending on the firmware size and your computer speed, generating a pre-rooted firmware can take up to 7 minutes. The pre-rooted firmware will be created in the directory of the executable and called flashable-prerooted.zip.



The order for the extra files is
  1. Extra flashable
    • In the order you added it initially in the GUI
  2. APKs

TWRP is recommended for flashing!

Note: If you do not include the kernel in the pre-rooted firmware, it's recommended to flash it afterwards with flashtool (check "system" under Exclude).
Note2: I am not responsible for any damage done to your device or if you end in a bootloop.

Credits
Androxyde - some helpful information about sin files from his flashtool
[NUT] - used his flashable scripts as base
E:V:A - sgdisk utility compiled for arm
dotnetzip developers (note I'm using a slightly modifed version with a bugfix)

Requirements
Microsoft .NET 4.0

Source code
https://github.com/dosomder/PRFCreator

Changelog
  • v1.3
    • Fix a signing bug when PRFCreator was in a folder which included a space (thanks Calystos)
    • Allow multi select for Extra Zip / APK
    • Update sinflash to v0.42 (fix sha256 bug (thanks RoberM) and large zip file handling (thanks Fragmentation))
  • v1.2
    • Fix a signing bug (thanks RyTekk)
    • Fix bug when flashing multiple apps
    • Update lz4 lib and 7zip binaries (thanks tetsuo55) and dotnetzip library
    • Update sinflash binary to v0.4 (supports now also non-msm devices, thanks eoinkennedy for report)
    .
  • v1.1
    • Allow users to add APKs
    • Improved sinflash to allow compression
    • Fix smaller bugs and improve speed
    .
  • v1.0
    • New method using sinflash (sin files are flashed on the phone directly instead of extracting on the computer)
    • New busybox
    .
  • v0.9
    • Compatible with mono
    • New settings file to change temp folder and choose another destination for the pre rooted firmware
    • Work towards new sin format introduced with Z3+
    .
  • v0.8
    • Add the ability to include additional flashable zip files
    • Display information when clicking on version number
    .
  • v0.7
    • Add zip signing option
    • Small fixes in code
    .
  • v0.6 - Nuked (wrong binary uploaded)
    • Prefer to use gpt uuid instead of partition names
    • Add different modem sin names
    • Clean code
    .
  • v0.5
    • Fixed bug with missing dualrecovery
    • Added check if SuperSU and recovery are flashable
    • Added ability to flash modem
    • Support for sin v2
    .
  • v0.4
    • Make dualrecovery zip optional
    • Fix exception if file does not exist in sin
    .
  • v0.3
    • Initial release
Attached Files
File Type: zip PRFCreator v0.9.zip - [Click for QR Code] (4.29 MB, 27464 views)
File Type: zip PRFCreator v1.0.zip - [Click for QR Code] (4.30 MB, 19496 views)
File Type: zip PRFCreator v1.1.zip - [Click for QR Code] (4.48 MB, 45504 views)
File Type: zip PRFCreator v1.2.zip - [Click for QR Code] (4.54 MB, 8848 views)
File Type: zip PRFCreator v1.3.zip - [Click for QR Code] (4.54 MB, 49928 views)
The Following 407 Users Say Thank You to zxz0O0 For This Useful Post: [ View ] Gift zxz0O0 Ad-Free
 
 
27th August 2014, 04:12 PM |#2  
zxz0O0's Avatar
OP Senior Member
Thanks Meter: 4,459
 
Donate to Me
More
I have a question!
  • What should I check under 'Include' ?
    Quote:

    • Kernel: Personally I recommend to check kernel. For some firmwares it's important otherwise the phone won't boot.
    • FOTAKernel: This kernel is used for OTA Updates. I recommend to include it.
    • Modem: This is the baseband / modem. Some updates can give you slightly better battery life and signal.
    • LTALabel: This is a partition with regulatory informations. It should not really change the performance of your device. I recommend to include it.

    .
  • Do I need to include a recovery?
    Quote:

    No, recovery is optional. If you do not wish to include recovery you should add this flashable zip under Extra Files to be able to mount system as rw: https://github.com/dosomder/SonyRICD.../RICDefeat.zip
    Note: If your bootloader is unlocked, this is not needed as RIC will be disabled anyway.

    .
  • Can I edit system.ext4 inside flashable zip?
    Quote:

    Yes, you can edit it on a linux machine. You don't have to change anything else in the flashable zip. See here for more info: http://forum.xda-developers.com/show...&postcount=246

    .
  • What is zip signing?
    Quote:

    For a proper flashable zip, zip signing is used. It generates a hashtable of all the files in the flashable zip to verify its integrity. Note that zip signing might double the process time of generating a flashable zip.

    .
  • Does it wipe my user data?
    Quote:

    No.

    .
  • What is extra zip?
    Quote:

    With this feature, you can include additional flashable zip files. An example is to include Xposed directly (you can find the flashable zip in the Xposed apk).

The Following 90 Users Say Thank You to zxz0O0 For This Useful Post: [ View ] Gift zxz0O0 Ad-Free
27th August 2014, 04:26 PM |#3  
gravtec's Avatar
Senior Member
Thanks Meter: 334
 
More
Good news... Will try later...
The Following User Says Thank You to gravtec For This Useful Post: [ View ] Gift gravtec Ad-Free
27th August 2014, 06:22 PM |#4  
funky0308's Avatar
Recognized Themer
Flag Osijek
Thanks Meter: 5,723
 
Donate to Me
More
This is awesome tool...
Still couldn't find free time to test it but if it's working and I'm sure it is...

This is more then welcome...

Tnx mate...

Sent from my D6503 using Tapatalk
27th August 2014, 06:49 PM |#5  
Will try this on the next FW release, thanks!
27th August 2014, 07:36 PM |#6  
Senior Member
Thanks Meter: 262
 
More
Thanks for the tool. Looks great. I'll try it.
27th August 2014, 08:57 PM |#7  
nalab1's Avatar
Senior Member
Flag Dunstable
Thanks Meter: 39
 
More
Hi,

Thank you.. Looks really good! What do the Kernel, FOTAKernel and LTALabel checkboxes do? Also, will this work with the latest .133 ftf?

Regards,

Alan
27th August 2014, 09:46 PM |#8  
zxz0O0's Avatar
OP Senior Member
Thanks Meter: 4,459
 
Donate to Me
More
Quote:
Originally Posted by nalab1

Hi,

Thank you.. Looks really good! What do the Kernel, FOTAKernel and LTALabel checkboxes do? Also, will this work with the latest .133 ftf?
Regards,

Alan

It will include those in the flashable zip. FOTAKernel and LTALabel are not really important but I thought why not include this feature. Kernel is more important and I recommend to always use the kernel from the firmware you're using.

It should work with all the current ftfs (the tool is built for sin version 3).
The Following 3 Users Say Thank You to zxz0O0 For This Useful Post: [ View ] Gift zxz0O0 Ad-Free
27th August 2014, 10:41 PM |#9  
nalab1's Avatar
Senior Member
Flag Dunstable
Thanks Meter: 39
 
More
Angry
Quote:
Originally Posted by zxz0O0

It will include those in the flashable zip. FOTAKernel and LTALabel are not really important but I thought why not include this feature. Kernel is more important and I recommend to always use the kernel from the firmware you're using.

It should work with all the current ftfs (the tool is built for sin version 3).

Thanks for the reply... What is sin version 3? Also, what are your recommended settings? Tick all boxes or just the Kernel box? What devices/ROMs has it been tested on? Sorry for all of the questions!
27th August 2014, 10:51 PM |#10  
ptmaniac's Avatar
Senior Member
Flag Aveiro
Thanks Meter: 195
 
More
i just used the xperifirm tool to get the latest z2 .323 update, then used flashtool to create .tft, then your prfcreator tool to make the flashable zip. everything worked perfectly fine (many thanks to the dev's for all this nice and easy to use tools btw), this .zip rom should now be flashable from twrp (i got a locked and unlockable BL) no matter what i have installed on the phone right?

Thanks for your help, i'm new to sony devices and my z2 is only 20 days old, i'm trying hard not to brick it :P
28th August 2014, 02:58 AM |#11  
androidfreak70's Avatar
Senior Member
Flag here!
Thanks Meter: 648
 
Donate to Me
More
Wow! Is this magic?

Xperia™ Z (C6602) with Tapatalk!
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes