yashsingh1/xdaforums huggingface dataset:
[Verizon HTC One (M7)] thatsonlyme:
Recently I had my htc one replaced under warranty. I returned it back to stock using this guide.

now my new phone has some issues outlined here:http://xdaforums.com/verizon-htc-one/help/screen-wont-charging-t2900644/post55967111#post55967111

I tried returning my new phone back to stock to see if the issue persist and while setting it up I've noticed that superuser is still there and I still have root. I'm not sure if the phone I returned is still rooted because after flashing ruu i didn't set it up but I'm kinda worried that it is and if they notice they may deny warranty claim.

is that normal? if yes maybe it would be a good idea to update this guide with superuser removal procedure after ruu-ing.
[Verizon HTC One (M7)] michaelbsheldon:
Yes, Definitely before you go S-On, open SuperSU, uncheck boxes and scroll down to Cleanup section. choose Full Unroot. The program will entirely

disappear on reboot, leaving you virgin stock and ready to S-On for return.
[Verizon HTC One (M7)] thatsonlyme:
It wasn't mentioned enywhere so i didn't check. It's too late now, i sent the phone back, i hope they won't notice.
[Verizon HTC One (M7)] O-rangePeels:
Could not allocate.

Fastboot says the file is too big and i dont have enough space but i have 7 gbs open. What should i do?
[Verizon HTC One (M7)] bmt626:
Check the md5 on the zip file if it didn't download correctly it will not flash
[Verizon HTC One (M7)] scotty1223:
sure it works. i kow your fustrated,but your having user errors,not a prollem with the process.

make sure rom.zip is in your platform tools directory. check the file name- windows adds and hides extensions,so if you physically named the file rom.zip,it may actually be named rom.zip.zip :eek:

the basic prollem is either that there is not a file with the exact name your trying to flash,in the directory your working from,or there is not enuff room in the phones memory to temporatily load rom.zip,depending on the exact error your getting.

if youre 100% sure all that is correct,try fastboot erase cache in ruu mode,right before the flash zip command
[Verizon HTC One (M7)] syphix:
Make sure your zip is named correctly. I had the same error. Windows dumbly renamed my file Rom.zip.zip. I had to rename in cmd.

rename Rom.zip.zip Rom.zip

After that, it was good to go.
[Verizon HTC One (M7)] dobo84:
OK thanks fellas...think I'll give it another go might of been I was dead tired to.

Sent from my One

---------- Post added at 12:57 PM ---------- Previous post was at 12:28 PM ----------

Just a update ran it again this morning and it worked. the file extension was hidden..... thank all for the help
[Verizon HTC One (M7)] josh995:
Will this put the stock recovery back on?

Sent from my HTC One.
[Verizon HTC One (M7)] mgunnell:
Return to Stock Issue - Suggestions?

Anyone have this happen that has tried this? Phone will not boot into anything but the black bootloader screen with 4 triangles (one on each corner) The RUU process got almost to end and this happens.

Error is :

(bootloader) [RUU]UZ,rcdata,100

(bootloader) [RUU]WP,rcdata,0

(bootloader) [RUU]WP,rcdata,100

(bootloader) ...... Successful

FAILED (remote: 53 image unzipping fail)

finished. total time: 311.312s

I am going to re-download the file again, but have tried this 3 times with same error at same point. (makes me think may be the file, but MD5 matches) ANY suggestion would be extremely appreciated.

Issue resolved - Re-downloaded file and worked like a charm, THX for the great tutorial!
[Verizon HTC One (M7)] josh995:
Hey guys I asked a few days ago but no answer so I just want to see if this puts the stock recovery back on? I'm using twrp now
[Verizon HTC One (M7)] bmt626:
Yes
[Verizon HTC One (M7)] enfurnic:
download for RUU seems to be broken stopping at different points. Are there any mirrors? Or another way to get the file since my phone has to be warrantied out
[Verizon HTC One (M7)] kinglime:
Is there an easy way to return to S-OFF?
[Verizon HTC One (M7)] syphix:
Rumrunner.

I returned to stock and S-On when I had an issue with my SIM card. Took it into Verizon and they were none the wiser. Replaced the SIM, got 4G back, and immediately ran Rumrunner to get back on BoneStock.

Had no issues whatsoever.
[Verizon HTC One (M7)] cstrife999:
This worked well for me thanks!
[Verizon HTC One (M7)] enfurnic:
this worked great thanks now to send the phone for warranty
[Verizon HTC One (M7)] UrbanJester:
I am in the same boat as well. Would the S-Off via java card be an option to revive this brick? :crying:
[Verizon HTC One (M7)] scotty1223:
yes. as long as you can swtch between hboot and fsatboot.

at least,in theory it is an option. since no one has tried it,there may be flags preventing the diag file from doing its job with the security warning,etc.

i personally would send it to him and try it. its hard telling if/when a signed ruu will emerge. if you have my luck,no matter how long you wait,there will be no ruu until the day after youve sent the phone to sonic ;) :p
[Verizon HTC One (M7)] GRAWM1A1:
Definitely helpful if anything ever goes wrong.
[Verizon HTC One (M7)] josh995:
Works perfectly! Thanks for this!
[Verizon HTC One (M7)] mkeefner:
Worked amazingly! Thank you for this!!
[Verizon HTC One (M7)] UrbanJester:
It is on its way! fingers crossed! :)
[Verizon HTC One (M7)] scotty1223:
Awsome! Let me know how it works out :)
[Verizon HTC One (M7)] Uzephi:
If it says "too many links" it is because the firmware doesn't match the ruu.

Go to santod's stock Rom thread and download the corresponding firmware to match the ruu.

If you are on correct firmware, it might be ram issues on your PC. You need the extracted size available which I believe is somewhere around 2-2.5 gigs or larger. Not HDD space, but ram.
[Verizon HTC One (M7)] tflogic:
Err I feel a bit silly that I'm in this situation and have to resort to help but here I'm lost and confused.

So I'm planning on sending in my device to exchange and I've followed the instructions listed in the OP but somewhere in between flashing the RUU and rebooting, I think I skipped a step.

So after my reboot, I booted into the ROM I had before and it wasn't stock so I figured something went wrong. When I rebooted into bootloader, my device had S-On, was Locked, and had the Tampered flag on it. I can't boot into any ROM and ADB is unrecognized. So I tried to reflash the RUU via the command "fastboot flash zip rom.zip" but now I'm getting this error:

Any idea what to do? My OS version is 5.28.605.2 and I grabbed the signed RUU zip from santod's AFH at this link. Any idea how to proceed from here?
[Verizon HTC One (M7)] dottat:
Pull just the firmware.zip out of this file and flash it in ruu mode twice. Do not extract the firmware.zip file. It's signed and extracting it will break that.

https://www.androidfilehost.com/?fid=23622183712466856
[Verizon HTC One (M7)] tflogic:
Alright, thanks!. Just did that and it was successful!

What's next to get back to stock? When I boot, it just takes me back to the ROM I had beforehand (NuSense). And if I try to boot into recovery, it directs me to the stock recovery with the red triangle. Still has the Tampered flag whilst Locked and S-On. Scared to try anything else on my own without instruction.
[Verizon HTC One (M7)] dottat:
Now see if htc sync sees your phone.
[Verizon HTC One (M7)] tflogic:
HTC Sync does see my phone. When I go to Repair, it states that there is no software available for my phone (I think since I'm on NuSense).
[Verizon HTC One (M7)] dottat:
Try sunshine and see what happens.
[Verizon HTC One (M7)] tflogic:
Says it's incompatible with my phone.
[Verizon HTC One (M7)] dottat:
Pretty sure the firmware you are on fixed the firewater exploit but you should probably try it too since nusense uses a custom kernel. Otherwise, that's the best you are gonna get being locked and s on. My guess is you didn't run the ruu twice and it only did some firmware. If you had ran the full ruu, nusense would have been wiped.
[Verizon HTC One (M7)] tflogic:
****. Didn't work.

Well, thanks for your help. Bought you a coffee.
[Verizon HTC One (M7)] dottat:
Yep. It just dawned on me the firmware zip has stock kernel. Must be time for sleep lol. Either way.. It's locked and s on and boots. Will probably pass the exchange test.
[Verizon HTC One (M7)] dottat:
Guessy whatty... I can fix you!

You game?

http://xdaforums.com/verizon-htc-one/help/exe-ruu-vzw-m7-4-4-3-s-users-t2919442
[Verizon HTC One (M7)] tflogic:
Damn thanks bro! You da real MVP.
[Verizon HTC One (M7)] dadams312:
I can't get the phone back to S-ON, any help would be appreciated.

Unrooted, locked bootloader.
[Verizon HTC One (M7)] dottat:
Try running the above ruu I linked and then see if you can turn it on.
[Verizon HTC One (M7)] dadams312:
The one with the EXE? I'm on a mac.
[Verizon HTC One (M7)] dottat:
That sucks.
[Verizon HTC One (M7)] dadams312:
I have access to a windows machine, just don't have drivers or adb or anything set up on it. If I can't find another solution to it soon I will definitely look into that.

Thanks for the suggestion.
[Verizon HTC One (M7)] dottat:
You try using the Rom.zip inside the zip folder via fastboot in ruu mode.
[Verizon HTC One (M7)] dadams312:
From the link above?

I haven't, what is the Rom.zip?
[Verizon HTC One (M7)] dottat:
The actual ruu
[Verizon HTC One (M7)] dadams312:
OK, so I went back through the process of flashing stock through fastboot RUU and immediately tried to S-ON again and it took this time.

So looks like I'm ready to head back to Verizon. I got the phone shortly after it released, what are the chances that Verizon will just swap it with a different one?
[Verizon HTC One (M7)] dottat:
Sounds good.

Hardware problem? Edge upgrade?
[Verizon HTC One (M7)] dadams312:
Top speaker stopped working. Can't hear anything if I use the phone, have to have speakerphone on. Obviously no stereo speakers when 1 isn't working.

---------- Post added at 11:41 PM ---------- Previous post was at 11:37 PM ----------

And actually, root is back and I can't seem to unroot it now. I do the unroot in supersu, reboot and it's back and rooted still.
[Verizon HTC One (M7)] dottat:
My buddy was twenty days past 1year and they wouldn't help him. Did you check it after ruu?

---------- Post added at 11:42 PM ---------- Previous post was at 11:41 PM ----------

If you flashed the Rom.zip I have above fully (may take a second run of the fastboot command) you will not have root.
[Verizon HTC One (M7)] dadams312:
Yeah, still nothing.
[Verizon HTC One (M7)] dottat:
Read my note above about root.
[Verizon HTC One (M7)] dadams312:
I assume I will need to S-ON and unlock the bootloader again before being able to flash that?
[Verizon HTC One (M7)] dottat:
No. That one will flash s on and locked. If you have issues flashing it via fastboot now that you are s on, use the exe version on a pc.
[Verizon HTC One (M7)] dadams312:
I'm having a problem with ADB now, seems like one thing after another. ADB will show my device, but it shows offline. Tried several fixes including rebooting everything and killing the adb server.
[Verizon HTC One (M7)] dottat:
Unplug. Go into developer options. Revoke authorization. Reconnect. Check adb devices.
[Verizon HTC One (M7)] dadams312:
This is what I got when I attempted to flash the Rom.zip from your link.

---------- Post added at 01:33 AM ---------- Previous post was at 12:36 AM ----------

So, it fails trying to update by flashing it from adb fastboot. It also failed using the EXE in windows (I setup adb and made sure the device was connected).
[Verizon HTC One (M7)] dadams312:
Might have gotten in over my head. I've got S-ON, Bootloader is Locked, SuperSU and root comes back every time I reboot the phone.

I can't flash anything through ADB/Fastboot, can't use the EXE posted above because it all fails when check signatures. I also don't have any sort of recovery on the phone.
[Verizon HTC One (M7)] dottat:
You still working this?

Flash this first in fastboot ruu mode. Then try main ruu exe again. You have to use the exe and a Windows pc for the main ruu ... It's the only way around the signature problem.

https://www.androidfilehost.com/?fid=95784891001602985
[Verizon HTC One (M7)] dadams312:
Well, I worked on it to a point where I took it to Verizon today, explained that the top speaker quit working 2 days ago, tested it....worked great, beautiful clean stereo sound....sigh. Told the guy I swear that it hasn't worked at all for 2 days, I handed him the phone and took his phone and called him from his phone....problem began again there.

Long story short, they are sending me a "new" phone on Monday.
[Verizon HTC One (M7)] dadams312:
Thanks for all the help dottat, I was able to get it stock enough for Verizon to agree to send me a replacement phone.:good:
[Verizon HTC One (M7)] andybones:
new or refurb?
[Verizon HTC One (M7)] dadams312:
Refurb I would assume.
[Verizon HTC One (M7)] D623:
This worked great, thank you :)
[Verizon HTC One (M7)] prichable:
well im trying to get back to stock and i need a decrypted ruu i think? i dont really understand the difference and which one i really need so i guess i need decrypted because it says so in the steps above. i just dont know where to find one but if you can send me one... that would be greatly appreciated:D
[Verizon HTC One (M7)] Uzephi:
If you are s-on you would have to flash a signed encrypted ruu. S-off, it doesn't matter.
[Verizon HTC One (M7)] Mike02z:
OP, thank you very much. My son's 2 year old M7 just had the charging port go out. I had the insurance but was very concerned about returning the phone Unlocked and S-Off even though the issue was certainly hardware. I followed your guide and it was a life saver.

Perhaps I missed it, but one place I got momentarily stuck was with SuperSU. I removed this via the app but then had no way to gain su to run the abd command to lock the bootloader.

What I did was to push the RUU again to the phone, ran the adb commands to lock the bootloader then I removed SuperSU via the app itself. Everything else worked as written.

Thanks again. It's been a while since I messed with the M7 (since getting an M8 on release day) and this guide was great!
[Verizon HTC One (M7)] bgymn2000:
The link to the RUU does not contain the files anymore... Is there another location for them? I saw that dottat has posted custom RUU with root but would that cause problems? Can I use that and then remove root somehow?

Thanks
[Verizon HTC One (M7)] Mike02z:
Just do a Google search on Verizon M7 Decrypted RUU. The first link that came up for me was a Verizon RUU Zip 1.10.605.10.

Not sure how XDA takes to posting links to other sites or I'd just post the link I found.

To answer your other question, yes, you can RUU with SU installed. In fact, you MUST have SuperSU (or some other form of root access) to run the ADB command to lock the bootloader.

It just means you need to lock the botloader and then remove SuperSU using the settings menu and the "Fully unroot option" within the SuperSU application. Then SuperSU disappears and you can turn S-On.
[Verizon HTC One (M7)] michaelbsheldon:
This is the exe that you want for an S-0ff M7 device to get it back to a stock rooted rom. To make it 100% stock, remove SuperUser.

Thanks to dottat: https://www.androidfilehost.com/?fid=95784891001602579
[Verizon HTC One (M7)] dottat:
Actually guys... Thread is here.

http://xdaforums.com/showthread.php?p=56302410

Lock your boot loader on a rooted Rom first. Then flash this. The above ruu does NOT have su and will flash even once s-on too.

After flashing this all should look well. Do a factory reset and if all still looks good turn s back on. That's it.
[Verizon HTC One (M7)] neutronjeff:
I'm going to be doing this soon as VZW is replacing my m7 free under extended warranty for the pink camera issue.
[Verizon HTC One (M7)] rob22202:
Oops. Wrong Thread.
[Verizon HTC One (M7)] eudoxia:
Greetings,

I got a deal on an M8 and need to get my M7 back to stock. Is the method in this thread still the easiest current way to get back to stock?

-Jen
[Verizon HTC One (M7)] Gizmoe:
Yes it is. Really all your doing is resetting the tampered flag to locked, flashing stock ruu and then setting it back to s-on. It's really easy.
[Verizon HTC One (M7)] steveg545:
The process for returning to S-On worked perfectly, so many thanks for that. My only issue now is terrible battery life with the official Lollipop update from Verizon (fully charged to <90% in less than one hour, and it gets worse from there).

Has anyone else experienced any similar issues after unrooting?
[Verizon HTC One (M7)] tat2me2:
Took me a couple of tries but I did it - Thanks for this info
[Verizon HTC One (M7)] levjoy12:
I really need an encrypted RUU

Hi - last night I tried to return my unlocked, s-off phone to stock using this method: http://xdaforums.com/showthread.php?t=2475216

But something went wrong and now I'm stuck in recovery with the "tampered" and "security warning" messages. It's bricked.

It's my understanding that if I flash an encrypted RUU from recovery I can use this phone again. But I can't access the encrypted recovery anywhere. I know it's not ok to post it here... but can anyone help me?
[Verizon HTC One (M7)] scotty1223:
what went wrong,was that you didnt follow directions,and turned s on before you were completely stock. technically,it is not bricked,as it would easily be fixed with a signed ruu,if one existed.

your understanding is not quite correct. you need to flash a

signed

htc file. the issue here is not the ruu is decripted,it is that is not signed with htc's official signiture,wich is needed when you are s on.

you have 2 options when a phone is locked and has a security warning

1)re-unlock the bootloader. if you have your original token,you can possibly still use it(depending on what other factors have changed). otherwise,if you were s offed by the java card,you can get a new unlock_code.bin if you still have the funky mid(PN073****)

2) run a signed ruu. your SOL here.

ok,theres actually possibly one more:

3)keep track of wether the java card works for the other guy in your situation. if it does,send your phone to sonic

more info starting at post 37
[Verizon HTC One (M7)] nbelshaw:
Thanks for your post!

Thanks for this great tutorial. I know I'm going to need this some day!
[Verizon HTC One (M7)] TCommander:
I'm looking to get this to work and when I run the echo -ne '\x00\x00\x00\x00' | dd of=/dev/block/mmcblk0p3 bs=1 seek=33796 command, I get a Cannot open for write: permission denied error. I'm not sure what is lacking permission. I'm running from a windows machine. ran the cmd as administrator and even checked the permissions on the path in Root Explorer. What permission am I missing?

I would like to flash the RUU and stay S-Off for now but can't seem to get the bootloader locked.
[Verizon HTC One (M7)] scotty1223:
Make sure you have a # prompt. If entering the shell gives you a $ and not a #,you'll need to type su

Wen you first type su ,you will need to have your phone awake and be watching for a superuser pop up to grant permissions.

You'll need to be running a rooted Rom.

Edit:

You don't need to lock the bootloader to run the ruu,if that's why you're trying to lock it.
[Verizon HTC One (M7)] TCommander:
Thanks for the info. I realized I probably didn't after I posted that. That said in an attempt to solve this challenge I tried SU (Since I do indeed see $). It just accepts SU and returns to a $ prompt. No questions asked from the phone or the command window. I am running CM 10.2 (Should have mentioned) that earlier. Is there something else I need to do to grant super user access?
[Verizon HTC One (M7)] Menardo:
Anyone hear back from Sonic to see if the java card will work?!
[Verizon HTC One (M7)] scotty1223:
Cm roms come not rooted by default,so you'll have to authorize root access for adb somewhere within the Rom. Again,if you're not going to stock for warranty,you don't need to lock the bootloader. Just run rhe ruu.

---------- Post added at 11:30 AM ---------- Previous post was at 11:27 AM ----------

Urbanjester sent his to him. I imagine well know soon if it worked,or didn't
[Verizon HTC One (M7)] Menardo:
You know if he has talked to sonic?! I've messaged him a couple times and no response back. I understand he's probably busy. Just trying to see how f'd I am... Thanks guys
[Verizon HTC One (M7)] sprovo:
Nice tutorial. Can someone post a picture of the stock bootloader with the update. Just want to double check everything is rightbefore I send the phone back
[Verizon HTC One (M7)] airjordanmmix:
Do you know how i can put the stock recovery on my htc one? i'm trying to put my phone into fastboot oem rebootRUU but the phone don't accept the command. if by any chance you know how i can put back the stock recovery i will appreciate.

Thanks in advance
[Verizon HTC One (M7)] jbh00jh:
Try to flash the recovery img. with Flashify from the play store. I have used Flashify to flash both twrp and clockwork recoveries so it might flash the stock img. Good luck.
[Verizon HTC One (M7)] airjordanmmix:
nice thanks! i just need to find the original stock recovery.img to flash it. do i have that when i did the nandroid backup? sorry for asking too much and thank you for the help :good:
[Verizon HTC One (M7)] jbh00jh:
Not sure, request a link to the stock recovery, someone is sure to have a link or can post a copy.
[Verizon HTC One (M7)] airjordanmmix:
any help will be very appreciate!!

do anybody have the original stock recovery.img? i'm trying to enter my phone here <> fastboot oem rebootRUU but is not working, can anybody post it or any link that i can download it? i really need it because my phone is not allowing me to do nothing or don't want to enter in fastboot oem rebootRUU
[Verizon HTC One (M7)] Menardo:
are you stuck at the fastboot screen or are you able to enter the operating system?!
[Verizon HTC One (M7)] airjordanmmix:
i can enter to the main screen of my phone, download and install App, everything like that is normal. i just can't enter my phone into fastboot oem rebootRUU i need someone that know about this to help me. because i can't get this to work. the phone don't want to receive any kind of command when i go to fastboot i really need help :(
[Verizon HTC One (M7)] UrbanJester:
Got it back unbricked! Thanks to Sonic!
[Verizon HTC One (M7)] airjordanmmix:
:crying: Right now i can pass the boot screen (white with the htc logo in green) i can go to recovery or bootloader but i formatted the system :( so my phone is useless until i found this external mini usb that i can connect something with any rom to install. (well that's what i think since i don't know that much about all this) :(
[Verizon HTC One (M7)] Menardo:
I think you in the same boat im in. Did the same thing and had to send my phone to sonic to get him to fix it.... Waiting on it to be returned from him
[Verizon HTC One (M7)] airjordanmmix:
how much do he charge and how can i get in contact with him?
[Verizon HTC One (M7)] Menardo:
Here's a link to his profile... Send him a pm and explain your situation to him and he will get back with you on what you need to do...

http://xdaforums.com/member.php?u=4845298
[Verizon HTC One (M7)] J.Guido85:
Is it possible to get a video of this tutorial?
[Verizon HTC One (M7)] kdj67f:
Thanks for posting all of this, just got all back to stock to turn my second phone in for warranty replacement for another blown earpiece. Great write up!
[Verizon HTC One (M7)] one4thewings:
Due to misunderstanding the documentation I didn't know that I had to flash the rom.zip twice. I'm in a loop situation too. And after believing my device was fine since the rom.zip gave the expected error and stayed in RUU like the tutorial indicated, I re-enabled S-ON.

I'm trying to do a warranty repair, but this is obviously a show stopper. I was able to get the bootloader unlocked again. But that's not going to help me is it?