yashsingh1/xdaforums huggingface dataset:
[HTC One A9] reachedxyz:
Error not file folder out. please help me

root@sphinx-300E4Z:/home/sphinx/Desktop/RUU# ./decrypt-htc

Welcome to the RUU extraction and decryption script!

No ruu.exe found. Proceeding to rom.zip extraction...

Archive: rom_A9.zip
End-of-central-directory signature not found. Either this file is not
a zipfile, or it constitutes one disk of a multi-part archive. In the
latter case the central directory and zipfile comment will be found on
the last disk(s) of this archive.
note: rom_A9.zip may be a plain executable, not an archive
unzip: cannot find zipfile directory in one of rom_A9.zip or
rom_A9.zip.zip, and cannot find rom_A9.zip.ZIP, period.
zip_*.zip

ruuveal
-------

failed to open source zip: No such file or directory
mv: cannot stat ‘zip_0.zip’: No such file or directory

Freeing up some space...

Extracting sparse system images from decrypted zip files...

unzip: cannot find or open out_zip_*.zip, out_zip_*.zip.zip or out_zip_*.zip.ZIP.

No zipfiles found.

Freeing up moar space...

Converting sparse images into a single raw system image (this may take several minutes)...
Cannot open input file system.img*

Freeing up all the space...

Raw system image creation complete! Image is now ready for extraction by ROM Kitchen :)

Renaming and moving files...

unzip: cannot find or open ../out/firmware.zip, ../out/firmware.zip.zip or ../out/firmware.zip.ZIP.
cat: android-info.txt: No such file or directory

mv: cannot stat ‘boot*’: No such file or directory
rm: cannot remove ‘android-info.txt’: No such file or directory
Rom.zip has been renamed for your device.

Boot image extracted from firmware.zip. boot.img & system.img can be used as base for building a new ROM.

Script complete! Files can be found in the 'out' folder. Enjoy your decrypted system!
[HTC One A9] nkk71:
What are you trying to decrypt?

As mentioned previously:

Archive: rom_A9.zip
End-of-central-directory signature not found. Either this file is not
a zipfile, or it constitutes one disk of a multi-part archive. In the
latter case the central directory and zipfile comment will be found on
the last disk(s) of this archive.
note: rom_A9.zip may be a plain executable, not an archive
unzip: cannot find zipfile directory in one of rom_A9.zip or
rom_A9.zip.zip, and cannot find rom_A9.zip.ZIP, period.

^^ doesnt seem to be a proper RUU, maybe a bad download, maybe some other file. that's why i asked for people to "

including RUU name, version and link

"
[HTC One A9] un1ocked:
always get this error

EDIT:

my htc is not compatible
[HTC One A9] nkk71:
Fix your permissions, the files don't have execute permission set

chmod 755
[HTC One A9] blueberry60:
Is there any chance to work on Ubuntu 14.4 LTS? It was unsuccessful,terminal says "no such a file or directory" but the rom.zip related to 0PJAIMG or RUU exists in folder named as "place_rom_zip_here".
[HTC One A9] nkk71:
Ah, the dreaded "It doesn't work" post :crying::crying:

I'm using Ubuntu 14.04.3 LTS (64bit), works fine

you may wanna check here and here about reporting issues

you don't seem to have any particular issue, except the "it".... dunno what that is, so unless you provide proper information, we can't help; and by the time you do, you'd probably already realize it was something you could/have already fixed.
[HTC One A9] blueberry60:
I've upgraded Ubuntu to 15.10 version and issue has been solved,many thanks [MENTION=2605798]nkk71[/MENTION].
[HTC One A9] nkk71:
Glad it worked out for you

but just for anybody reading this

Captain_Throwback is using Ubuntu 15.10

I'm using Ubuntu 14.04.3

and both work fine
[HTC One A9] blueberry60:
I think,there're some updated modules just like libssl,phyton etc in your Ubuntu 14 but I couldn't find what else was required to execute decrypt-htc.
[HTC One A9] blueberry60:
[DECRYPT RUU][64-BIT LINUX ONLY] Universal HTC RUU/ROM Decryption Tool (v2.0.0)

I've done all unruu,decrypt process via ruuveal method successfully before and ruu file sizes related to M7 were not large,but I had to complete all necessary components as libbs,phyton etc in kmdm ruuveal. M9 RUU file sizes are larger than M7,so I couldn't fail to decrypt and create system dump files.

Your immediate attention to this matter is appreciated and many thanks to Captain_Throwback for this very useful thread.
[HTC One A9] frank9184:
Hello,How Can i get a hosd.img from my phone ?

Any solution?><
[HTC One A9] nkk71:
Probably a language barrier or something, but enough please!

1- stop spreading false rumours about python, libssl, whatever... :rolleyes:

(I believe the post above is more than enough to prove that the decrypt worked on a clean / no python / libssl / whatever, worked just fine, if you have proof to the contrary please do so with some real information; the "it doesn't work" is not even information, not even close)

2- please don't quote posts as long as the above, or just use a hidden section

3- we've asked repeatedly for the information needed if you want our support or continued development on this, in case you didn't see it before, here it is again
[HTC One A9] blueberry60:
My intend was not to spread false rumours and rate this topic poorly,I think you misunderstood me.Most important point that I wanted to emphasize is to reveal the difference between kmdm/ruuveal decrypt method and Captain_Throwback decrypt method.

It's absolutely required libssl-dev to be installed from Ubuntu Software Center in kmdm/ruuveal method.

http://xdaforums.com/showthread.php?t=2264316

HTC One M9 cihazımdan Tapatalk kullanılarak gönderildi
[HTC One A9] nkk71:
nvm :crying::crying::crying:

you are soooo right, how could i even have missed something as silly libssl-dev, python, alligator, crocodile, and all the other 600 libs i downloaded between steps 1 and 2 :eek::rolleyes::rolleyes:

PS: if you're really that much into it, you may wanna check github when things changed betweed 2013 and 2016 (about libs and stuffed animals)
[HTC One A9] Captain_Throwback:
Huh?

This decrypt method uses ruuveal, so what you're saying makes no sense :confused:.

There can be no difference; the methods are the same.
[HTC One A9] nkk71:
It

could

work on your version, but since

mine

is different, and that of kmdm is even

another

version, who knows what works where... obviously, the berry has some very in-depth knowledge, what was missed,

but it's not like I have any idea what's going on in this thread anywho
[HTC One A9] blueberry60:
This article is related to kmdm guide:

Download:

https://github.com/kmdm/ruuveal/

Directions (taken from README.md and kmdm tips below):

Compile (terminal commands in bold):

1) sudo apt-get install libmcrypt-dev automake autoconf libtool libssl-dev

(libmcrypt-dev package is required. if not previously installed, bash autogen.sh will throw "`AM_PATH_LIBMCRYPT' not found". other errors will be thrown when running autogen if the automake, autoconf and libtool packages haven't been installed. openssl/aes.h requires libssl-dev package)

(kmdm: To run the autotools step (autogen.sh) you, um, need the autotools installed... E.g. (in the very least): automake, autoconf, libtool.)

2) bash autogen.sh

3) ./configure ; make
[HTC One A9] nkk71:
you just don't want to listen or even try to listen

1- https://github.com/kmdm/ruuveal/commit/03a616e81b7857809dca13ec8dfb3054eb576907

2- the binaries have already been compiled and supplied

now either, produce an error, with a decent output - ie not "it doesnt work", nor "file not found" - or just stop, seriously

unless you may have noticed, things evolve over time, so does the format and content of RUUs, we've accounted for quite a few variants

... largezip vs not

... sparse vs not

... encrypted vs not

would you like me to go on??

btw, i hate youtube videos of how things are done, and you can stop referring to me as if i'm an outsider; i'm one of the people involved in this, so stop referring to me as if i have no clue what i'm talking about!
[HTC One A9] Captain_Throwback:
What does compiling ruuveal have to do with anything? Ruuveal is already included in the zip. You don't have to compile it, so what you're referring to is irrelevant.

Also, perhaps you should listen to [MENTION=2605798]nkk71[/MENTION], since he did more work on this than I did. Also, others have used this (and he already proved it works on a clean Ubuntu system) without error. So as he said, until you produce some log output and something other than outdated, irrelevant information, please cease posting incorrect data.
[HTC One A9] blueberry60:
Your tool works perfectly in Ubuntu 15.10 without any problems and not needed any libs ,I only tried to share my experiments and troubles on old ruuveal method not yours,but this situation caused stress.Sorry for that.

I researched new GitHub and if I'm not mistaken that some codes referring to LIBMCRYPT_LIBS had been removed.

Take care of yourself.
[HTC One A9] JochenP:
wow, this is incredible - script works perfectly and creates all files flawlessly (A9)!

big, big thanks to the programmer

have md5 of twrp saved files and files generated from decrypt tool to be equal?

I believe not - a binary compare shows a lot of zeros at the end of the recovery saved file...

No problem to flash and execute recovery_singed.img :good::good::good:
[HTC One A9] nkk71:
Nice, glad you enjoyed it;

and no the md5's will be different; the recovery_signed.img is just a file, so it will only be as long as it needs to be, the one backed up by twrp, will be a full partition backup (the contents would be the same, except for the padding at the end)

... just as if you flashed TWRP into the partition, the actual fastboot flash will write the TWRP.img file, but if you take a backup, the whole partition will be backed up, even though the contents are "technically" the same.... hope that makes sense :o
[HTC One A9] JochenP:
yes - that make sense and is now clear - thank you for your explanation :good:
[HTC One A9] vegetaleb:
Hello bro!

I see you everywhere :D

Now I want to build a full rom not only deodex based on RUU as my actual gallery app is super buggy and can't edit RAW anymore.

This tool is enough to build a rom or I need to use Superr kitchen too?
[HTC One A9] JochenP:
decrypt tool provides the basis - for ROM- 'cooking' supers kitchen :)
[HTC One A9] -stim:
This is awesome! I'm gonna try this out when I get home tonight.
[HTC One A9] -stim:
Confirmed working with Linux Mint Cinnamon 17. 3 64-bit out of the box.

Decrypted RUU_HIA_AERO_UL_M60_SENSE7GP_ATT_Cingular_US_1.27.502.5.exe with Universal_HTC_Decrypt_Tool-v2.0.0 with no issues. Thanks guys!

If anyone needs a zip or RUU decrypted and doesn't have access to Linux, Shoot me a PM and let me know. If you point me in the direction of the zip or RUU you need I will decrypt it for you using these tools.
[HTC One A9] jbfountain:
Thank you [MENTION=1162986]Captain_Throwback[/MENTION] and [MENTION=2605798]nkk71[/MENTION] for this tool. So much easier than doing it within Windows. Now who should I donate to? Captain_Throwback you refer to giving credit to nkk71 so should he be the one I donate to, or should I spit it between the 2 of you?
[HTC One A9] Captain_Throwback:
After discussing with [MENTION=2605798]nkk71[/MENTION], we think a split in the donations is fair. He suggested 50/50, but I believe he deserves more than me, so a 60 (for him) 40 (for me) split would be fine.

You might also want to consider donating to the other people mentioned in the OP, as without their tools/source code/work this wouldn't be possible either.

Even if you don't donate anything to us (as it's not why we do this anyway), you thanks and kind words are appreciated!
[HTC One A9] jbfountain:
Ok. That's 7 people to donate to. I don't want the donations to be really small so I will start with you and nkk71, and then work on the rest a few at a time. I'm not rich (insert chuckle), and this tool is definitely worth more than I can afford, but I will do my best. Thanks again for making this tool available for all.

Using XDA to unleash the power of Android on my S6 Edge Plus & HTC One M9
[HTC One A9] jbfountain:
[MENTION=1162986]Captain_Throwback[/MENTION] I took care of everyone the best I could except for [MENTION=570187]Twogo[/MENTION]od, [MENTION=456600]Flemmard[/MENTION], and [MENTION=2976903]A.S._id[/MENTION]. I couldn't find twogood, and Flemmard and A.S._id didn't have donation links. I did PM the later two to thank them and ask them if they did have a donation link to please send it to me. If you have any info on how I can donate to those 3 please forward it to me. Thanks again to all those involved in making this tool possible.

Cheers
[HTC One A9] Flemmard:
Thank you :) Even if kmdm did most of the work ^^
[HTC One A9] nkk71:
Many thanks, very much appreciated. You are an officer and a gentleman :good:

Hopefully we'll soon (as time permits) have a small update to the tool :o , including a Windows version :cyclops:
[HTC One A9] A.S._id:
+1 :good: :o
[HTC One A9] longnt2007:
Thanks for the decryption tool, I've used for decrypt firmware from HTC D728W, notice that firmware name begin with 2PQ8IMG (HTC A9 is 2PQ9IMG) so if I leave original filename 2PQ8IMG.zip, the tool stuck forever at "Looking for android-info.txt..."

So I've renamed rom file to 2PQ9IMG.zip, the decryption tool now working fine and try to search hboot/hosd.img to build new keyfile 2PQ8_keyfile_1.bin, but in this firmware hosd.img named as hosd_verified.img, so I must extract hosd_verified.img and enter it in terminal console to build a new keyfile. After that all system files have been extracted successful :good:
[HTC One A9] reachedxyz:
Hi sir

Please hepl me, error code

Welcome to the RUU extraction and decryption script!

No ruu.exe found. Proceeding to rom.zip decryption/extraction...

Extracting ZIP files
LargeZip format detected, using ruuveal
ruuveal
-------

Large zip format detected containing 6 zipfile(s)
Dumped (copied) zip file to: 01_dmp.zip
Dumped (copied) zip file to: 02_dmp.zip
Dumped (copied) zip file to: 03_dmp.zip
Dumped (copied) zip file to: 04_dmp.zip
Dumped (copied) zip file to: 05_dmp.zip
Dumped (copied) zip file to: 06_dmp.zip
Finished: Successfully extracted zip files to '/home/androidrepair/Desktop/Tool_HTC/Burn_HTC/working/extract'

Looking for android-info.txt in encrypted ROM zips...

Model ID found by extracting android-info.txt from rom zip. Model ID identified as: 0P6B
Looking for keyfile: 0P6B_keyfile_6.bin
Found matching keyfile! Using keyfile: 0P6B_keyfile_6.bin

Decrypting ZIP files

Decrypting 01_dmp.zip
Encrypted zip detected, running ruuveal...
ruuveal
-------

Invalid zip file - aborting!
failed to decrypt zip file!
Processing ZIP... 32768/56555916
ERROR: could not decrypt file (err=249)

/home/androidrepair/Desktop/Tool_HTC/Burn_HTC/working/decrypt/decrypted_system
/home/androidrepair/Desktop/Tool_HTC/Burn_HTC/out

Attempting to create system.img
ERROR: No system image files found, aborting!

Renaming and moving files...

mv: cannot stat ‘/home/androidrepair/Desktop/Tool_HTC/Burn_HTC/working/decrypt/decrypted_all/boot_signed.img’: No such file or directory
Rom.zip has been renamed for your device.

Boot image extracted from firmware.zip. boot.img & system.img can be used as base for building a new ROM.

Script complete! Files can be found in the 'out' folder. Enjoy your decrypted system!
[HTC One A9] Captain_Throwback:
Looks like a bad zip download (or just a bad file). Where's the file you used?
[HTC One A9] reachedxyz:
No. File zip not bad. error key devices by Tool. You have check key for m8. Thanks
[HTC One A9] Captain_Throwback:
Well, you didn't answer my question, but I'll guess as to which ROM you were trying to decrypt. In which case, delete the file tools/keyfiles/0P6B_keyfile_6.bin and drop the attached keyfiles in there instead. Then let me know if it decrypts for you.
[HTC One A9] reachedxyz:
You have share problem create file key.bin
[HTC One A9] nkk71:
What's a "share problem create file key.bin"?

For the M8 the 6.xx.xxx.x series RUUs have 2 possible keyfiles, something we haven't encountered before... one is in the original tool files, the other was linked by Captain_Throwback above. perhaps if you re-read the post you'll get it working
[HTC One A9] glennsamuel32:
Thanks [MENTION=1162986]Captain_Throwback[/MENTION] and [MENTION=2605798]nkk71[/MENTION]

I downloaded http://dl3.htc.com/application/RUU_HIMA_UL_M60_SENSE70_ATT_MR_NA_Gen_Unlock_3.35.617.12.exe for the M9 Unlocked...

Everything went ok and I even got the "green" script complete message...

But there were a lot of 'cautions' and the system.img is 4.7gb...

I'm coming from Samsung ROM's and those top out at 2.4gb, and so I just wanted to make sure it's normal...

Here's the final output...
[HTC One A9] nkk71:
sounds correct, that would be the size of the entire system partition.

you may have noticed that after creating the system.img the scripts does a filesystem check (e2fsck) on the system.img to verify it's a correct ext4 filesystem.

and if you event want to go a step further you can mount in linux, something like

mount -o ro system.img my_mount_path

then you can access the files in it

or LinuxReader for Windows should also work
[HTC One A9] kjablonski:
I dont know how to say thank you enough. My phone was bricked after a failed OTA and RUU. I could only boot into bootloader and download mode. I used this tool to create the zip file and loaded it onto my sd card and everything was reverted back to stock. Here were my symptoms so that hopefully someone with the same issue wont have to do the 3 days of research i did.

Failed RUU status 155

Unable to boot to recovery

Relocked

S-On

Security Warning

Software Status: Modified
[HTC One A9] xdagee:
failed to decrypt zip file!

In an attempt to flash the MM update AT&T HTC RUU.exe for my M8, I ended up in an ERROR 155. Which is something like incorrect RUU according to HTC docs. I downloaded it again and tried but same issue

ERROR [155~159]: IMAGE ERROR

One of these error messages will appear when you use the incorrect RUU to update and the image file size is larger than the Flash ROM size. In this case, download the correct RUU version and try again.

I tried to decrypt it with this tool and I think it wasn't successful.

running bash command in Windows 10.

here is the log

Welcome to the RUU extraction and decryption script!

Extracting temporary files...
Extracting rom zip files...
Extracting rom.zip...done.
Extracting android-info.txt...done.
Cleaning up...
Done!

Extracting ZIP files
LargeZip format detected, using ruuveal
ruuveal
-------

Large zip format detected containing 6 zipfile(s)
Dumped (copied) zip file to: 01_dmp.zip
Dumped (copied) zip file to: 02_dmp.zip
Dumped (copied) zip file to: 03_dmp.zip
Dumped (copied) zip file to: 04_dmp.zip
Dumped (copied) zip file to: 05_dmp.zip
Dumped (copied) zip file to: 06_dmp.zip
Finished: Successfully extracted zip files to '/mnt/c/Users/Wofa/Downloads/Universal_HTC_Decrypt_Tool-v2.0.0/working/extract'

Model ID found by extracting android-info.txt from RUU. Model ID identified as: 0P6B

Looking for keyfile: 0P6B_keyfile_6.bin
Found matching keyfile! Using keyfile: 0P6B_keyfile_6.bin

Decrypting ZIP files

Decrypting 01_dmp.zip
Encrypted zip detected, running ruuveal...
ruuveal
-------

Invalid zip file - aborting!
failed to decrypt zip file!
Processing ZIP... 32768/58714563
ERROR: could not decrypt file (err=249)

/mnt/c/Users/Wofa/Downloads/Universal_HTC_Decrypt_Tool-v2.0.0/working/decrypt/decrypted_system
/mnt/c/Users/Wofa/Downloads/Universal_HTC_Decrypt_Tool-v2.0.0/out

Attempting to create system.img
ERROR: No system image files found, aborting!

Renaming and moving files...

mv: cannot stat ‘/mnt/c/Users/Wofa/Downloads/Universal_HTC_Decrypt_Tool-v2.0.0/working/decrypt/decrypted_all/boot_signed.img’: No such file or directory
Rom.zip has been renamed for your device.

Boot image extracted from firmware.zip. boot.img & system.img can be used as base for building a new ROM.

Script complete! Files can be found in the 'out' folder. Enjoy your decrypted system!

root@DESKTOP-P0F6HA1:/mnt/c/Users/Wofa/Downloads/Universal_HTC_Decrypt_Tool-v2.0.0#

Any help would be much appreciated, I just need to flash firmware am S-ON.

RUU Name: RUU_M8_UL_M60_SENSE70_ATT_MR_Cingular_US_6.20.502.5.exe

Source for RUU
[HTC One A9] nkk71:
1) if you're on

pre

6.xx.xxx.x firmware on the M8, then you need to flash signed 6.xx.xxx.x firmware first (you can get them from the OTA, there would be a signed firmware.zip inside the OTA.zip), then you can run the RUU

(Note on the M8 with S-ON, you need to have bootloader relocked)

2) as for the decryption it looks like it's picking up the wrong key (fixed in the upcoming release), there are two keys for the M8 6.xx ruus, so

go to the keyfiles folder and delete 0P6B_keyfile_1.bin and 0P6B_keyfile_6.bin

download the attached zip, and add the files inside the zip to the keyfiles folder, then let it run again, it should go for "trying known keys" instead of picking up a key from the name
[HTC One A9] micha279:
Hi,

please find keyfile for "2PRG" attached. Keyfile is for HTC m9e ROMs, also referred as m9s or M9 Prime Camera Edition.

Thanks for the great tool :)

Cheers,

Michael

PS: I noted that the tool doesn't handle directorys with spaces in directory name - maybe sth. for future release but nothing urgent :)

PPS: Additional note: boot image is named "boot_verified.img" in firmware folder for m9e :)
[HTC One A9] JochenP:
Linux don't like spaces - do not use spaces in path
[HTC One A9] nkk71:
Thanks, keyfile added, the other two issues should no longer be a problem, new version is up here:

[TOOL][LINUX|WINDOWS][64bit][20-MAY-2016]Universal HTC RUU/ROM Decryption Tool 3.0.0

still a couple of things to add... but 3.0.1 can wait a day or two :o
[HTC One A9] xdagee:
Moved to main thread .
[HTC One A9] absolutevelo:
Hello im newbie here,

so i success extract / decrypt files 0PAJIMG.ZIP Ruu with no errors.

here's folder inside "Out":

firmware

system

just asking, how to boot in handheld with 2 folder above?

i try with RUU 0PAJIMG.ZIP with HTC E8 with HBOOT (Press Power + Vol Down)

and get an error

so i decryp that 0PAJIMG.ZIP
[Xperia Z5 Compact Q&A, Help & Troubleshooting] Kallu609:
Hello everyone!

I don't know if this is the right place to post this, but here goes nothing:

I'm trying to update from version 32.0.A.6.152 to 32.0.A.6.200. When it completes downloading the update, it just stops and says: "Could not verify" and no other details.

And yes, I've unlocked the bootloader, if that matters. I'd really love to have the update, is there any workarounds or solutions for this?

Thanks in advance! :)

E: So there was a subsection for questions too... Silly me. Mods please move?
[Xperia Z5 Compact Q&A, Help & Troubleshooting] langeveld024:
I'm not entirely sure so anyone,correct me if I'm wrong, but I think the reason it won't install is because of root and/or unlocked.

You can download via xperifirm and flash via flashtool.

If u don't know how, try to search a bit because there are plenty of guides about it.

BTW, when u open this thread in browser you can click the triangle "!" button below your post to report it for thread moving.

I could do that too but I prefer to tell you so you can request a moving yourself ;)
[Xperia Z5 Compact Q&A, Help & Troubleshooting] Kallu609:
Thanks for the helpful reply! I think that's all I need to hear. Reported post & changed title to solved. :)