yashsingh1/xdaforums huggingface dataset:
[HTC One A9] Captain_Throwback:
No, SuperSU wasn't supposed to do anything about formatting SD card as internal. It fixed the SD card not showing up at all issue. I don't know anything about formatting SD card as internal. Perhaps removing the verity key breaks it? I really have no way of knowing. Best thing you can do is report the issue in the beta SuperSU thread. Since I don't use my card as internal storage, I know nothing about that issue. If it works when not rooted, my thought is that it's somehow verity related.

Does it work with the other root method? Does it work without root?
[HTC One A9] joshzdad2013:
Correct me if im wrong,but think 2.6.2 was to fix the sd not even mounting up for some people. I still think it is a rooting issue that screws us up on the external sd to internal idea. and also I've tried 4 different cards tto. ended up with a new 200gb sandisk that wont format to internal for me yet. oh well just have to be patient I guess.
[HTC One A9] Captain_Throwback:
No! Don't be patient - report your issue in the SuperSU Beta thread, along with logs, so that Chainfire can fix it. Also please confirm whether you have this issue with the other root method as well, or without root.
[HTC One A9] joshzdad2013:
Roger that, will do. also.... i have not tried other root method. i will experiment and let you know.
[HTC One A9] bzowk:
Thanks for info. I'll 2nd your post. As for method, I simply used the one listed on first post of this thread by copying boot.img, su.img, wiping, then installing SuperSU.apk. Got s-off via Sunshine (& $25):). What method did you use, Josh?
[HTC One A9] joshzdad2013:
Exact same procedure as you. ?
[HTC One A9] Captain_Throwback:
Can someone try the other root method and see if that works any better?

You'll need to restore a stock boot.img to use it, though (one with verity enabled and the verity key intact), and if you've already rooted with SuperSU, you'll need to delete /data/su.img and uninstall the SuperSU app.
[HTC One A9] rahaar:
Captain, I can confirm that don't have this issue without root , the process of having as internal storage works good....

the problem begin when install root... any versions of supersu.....
[HTC One A9] Captain_Throwback:
And using non-SuperSU root?
[HTC One A9] Haffoc:
I think it works when root is removed and stock boot is flashed. It seems that MM/6.0 formats and encrypts the SD-card for use as internal memory, I'm guessing it fails on the encryption side of things, so you're probably right that's it to do with the verity change.
[HTC One A9] Captain_Throwback:
Right, but the other root method doesn't change any verity settings, which is why I think it will likely work. Has anyone tried it?
[HTC One A9] Haffoc:
If no-one else has by tomorrow - I'll give it a shot and see if it works.
[HTC One A9] rahaar:
I´m a noob in this of root devices, i don't know the other proccess you mention ... sorry....
[HTC One A9] Captain_Throwback:
I've posted it in this thread before, but here you are again.
[HTC One A9] Haffoc:
Tried the other method and formating internal sd-card works. So it seems likely that it requires dm-verity for encrypting the card.
[HTC One A9] bzowk:
Hey Guys - Was away for a bit, but now caught up with encrypted storage thing. I posted on the SuperSU Beta thread, but never got addressed. Based on what you are saying, do you still believe it to be something which could be addressed with SuperSU or different where I just need to use the other root method and forget about it? Thanks
[HTC One A9] Lefteris Fragiadakis (Frago):
Guys what I did on my first new a9

I unlocked the boot loader via HTC site

Flashed twrp recovery

Boot in recovery,make full backup

Format data,not wipe, format

Flashed latest super su 2.62-3 and everything is working great,except write on SD,,,any solution?
[HTC One A9] Captain_Throwback:
SuperSU removes the verify flag and verity key from the boot image ramdisk. If you backup your boot prior to flashing SuperSU and then back it up after flashing it, you can put the flag and key back into your rooted boot.img and re-flash it. Android Image Kitchen handles unpacking/repacking boot images nicely.
[HTC One A9] Fischfuss:
Is there a tutorial how to do this?
[HTC One A9] Captain_Throwback:
Tutorial? Doubtful. But I just gave you the instructions. It's really not terribly difficult, if you actually try it.
[HTC One A9] Fischfuss:
o.k., I use Android Image Kitchen to unpack my stock boot.img. Now I have the unpacked ramdisk. Inthere the verity_key file. But no verify flag? is that also a file called "varity_flag"?
[HTC One A9] Captain_Throwback:
In fstab.qcom, the top line for mounting /userdata includes the flag "verify" - that is the flag that SuperSU removes, and the one that, along with the verity_key file you found, will need to be replaced in the rooted boot.img.

EDIT: Additionally in that file, the last flag on that line says "forceencrypt" which is the flag that forces encryption on the device. SuperSU will change that flag to say "encryptable" instead, so that encryption is just optional. That flag shouldn't affect adoptable storage either way (I don't think).
[HTC One A9] bzowk:
Thanks for the info. After a bit of research, I'm assuming that the steps I need to follow to perform this are below. As I already have SuperSU installed / flashed on my A9, I'm assuming that I need to restore the phone to RUU for AT&T - Cingular / HTC A9 factory image before starting. I'd think that I couldn't just use a boot.img that wasn't from my phone as it has to be on the phone to set the flag. Is that correct? HTC only offers a Developer image for A9, but I have AT&T. Hopefully there won't be a difference if I need to use it instead of the RUU listed above.

Steps I Plan to Take

1. Download & restore RUU or HTC Factory Image to phone (which one?) via it's integrated install utility

2. Enable Dev mode & USB Debugging to establish ADB connectivity via USB

3. Obtain boot.img using one of the two below methods

a. Use ROMDump to backup boot.img from phone

b. Extract boot image from RUU (Was able to get rom.zip from RUU's EXE which itself extracted to about 30 zip files. I tried extracting all of these using a variety of tools on Linux and Windows, got encryption error each time. One of the files which seemed to successfully extract was "boot_signed.img" - can I use it without having to capture one off the phone?

4. Install / flash SuperSU

5. Perform step 3 again and save boot.img (which now has SuperSU installed)

6. Download / extract Android Image Kitchen for Windows or Linux

7. From extracted path, execute "unpackimg boot.img" (targeting the original boot.img that was captured) to split the image and mount it to a folder

8. Get the flag and key needed - I guess they are presented as individual files in the mounted image?

9. Execute "repackimg boot.img" to save changes from mounted image back into img file

10. Repeat steps 7 - 9 except instead of copying the key & flag out, copy it into the mounted image then repack it again

11. Reboot the phone to fastboot then execute "fastboot flash boot boot.img" (boot.img being the newly edited image which was repacked) to flash phone with new boot.img

After a successful write and reboot, SD card Internal formatting should be fixed and I'll still be rooted with SuperSU. Please let me know if I got any of this wrong, you know of a better way to do any of it, or I left out any required detail. Waiting to perform until I hopefully get some sort of reply.

Thanks!
[HTC One A9] Captain_Throwback:
That's a lot of steps.

If you already have a stock boot.img extracted from an RUU for your device, then all you need is the verity_key file from its ramdisk, provided the boot.img is the exact one for your device, and you haven't modifed /system at all. I already stated above regarding the verity_key and verify flag. Then use TWRP to backup your current, rooted boot partition (the file it creates, boot.emmc.win = boot.img). Confirm the build fingerprints in the two images match in default.prop in the ramdisk, and then add the verify flag and verity_key into the rooted ramdisk. Repack, fastboot flash (or flash the image in TWRP), and you should be good to go.

If /system has been touched at all, though, adding dm-verity back into the boot.img will prevent the device from booting. So be sure before going this route (as long as you haven't mounted system rw in TWRP and not installed any root app that automatically touches /system, you should be fine). And if you end up not being able to boot, just remove the verify flag from the fstab and it'll boot again (you can leave the verity_key file in the ramdisk - it doesn't get used if verity is disabled anyway).
[HTC One A9] Lefteris Fragiadakis (Frago):
I can't understand why we have to backup the boot image, I just flashed supersu 2.62-3 and everything working fine, did I miss something?
[HTC One A9] Captain_Throwback:
Yes, you missed that SuperSU breaks adopted storage.
[HTC One A9] Lefteris Fragiadakis (Frago):
What adopted space u mean? Information me my friend,,,
[HTC One A9] Fischfuss:
Some people (like me) can't format the ext-SDcard as internal storage if they rooted with jcase-method!
[HTC One A9] joshzdad2013:
Just used the new AT&T ruu on HTC site, full device nuke & re-root using this method. All is good.
[HTC One A9] Lefteris Fragiadakis (Frago):
Any tip how we will get full write access on external sd card?
[HTC One A9] Captain_Throwback:
Use an app that supports it?

We have full write access to the SD card already . . .
[HTC One A9] Lefteris Fragiadakis (Frago):
No, let's say tubemate-youtube-downloader, it allows only specific folders on external sd card,, before u could fix it by sd write fix app, u can find it in play store, now that app don't work
[HTC One A9] Captain_Throwback:
The app needs to be updated to use the Marshmallow method of accessing external storage. That's not a ROM or root issue.
[HTC One A9] Lefteris Fragiadakis (Frago):
Yes I know it,I just wanted to be sure, thank you,,,
[HTC One A9] Fischfuss:
I'm still looking for stock unlocked Boot.img (htc_hiaeuhl:6.0, CL635503, TMO_DE_1.10.111.7)

NO - I don't have a backup and this one:

http://xdaforums.com/one-a9/development/dump-hiaaerouhlhtceurope1-10-401-7-t3229782

don' matches with my device.

My Device: htc/hiaeuhl_00111/htc_hiaeuhl:6.0/MRA58K/635503.7:user/release-keys

Please can someone give me an unmodified, unlocked Boot-Image

Many Thanks
[HTC One A9] JochenP:
i will download this file from xtc2-net (TMO DE 1.10.111.7 Radio 1.0.U00297.1@51007 30.05 F 453830 )
[HTC One A9] Fischfuss:
that would be great!

I try to S-OFF with sunshine, but for some reason I can't mount my system r/w and so sunshine does not work. the support of sunshine say possible wrong boot.img.
[HTC One A9] JochenP:
support of sunshine makes itself easy: if something goes wrong they comment always to install another ROM ?!! Not so easy with S-ON, CID or MID if they don't matches possible ROM's
[HTC One A9] Mudgle:
How do i get the boot.img from my device?
[HTC One A9] NuShrike:
The latest OTA changed drivers in I'd assume the boot.img. So previous boot.img will have broken drivers (including WiFi, battery, etc) with the latest OTA'd image.

edit:

only flash the latest SuperSU beta 2.64 and not the 2.52 that's listed in the SuperSU beta OP.
[HTC One A9] 65vdub:
Try systemless SuperSU 2.64 worked for me on the latest ota. Just make sure you don't flash the patched boot.img from the op. Just flash twrp after taking the update and put SuperSU 2.64 on your SD card (or download it after taking the update) then flash twrp and install the zip.
[HTC One A9] techlogik:
^This.

I have a US Unlocked phone. The other thread about going from rooted up to 6.0.1 update is wreaking havoc on some.

So, I just downloaded the RUU for unlocked phones from HTC directly. Ran that. Then, did a basic setup of the phone. Let it update to 6.0.1. Re-setup phone, let it update etc.

Then, install TWRP, format Data, copy BetaSU 2.64 onto your SDCard, install via TWRP.

Rooted, latest 6.0.1 now, restore/setup phone etc...required of course.

No problems copying stuff to the SDCard internal/External one now like I was getting, and others as well.

Once you are S-Off and bootloader unlocked, RUU'ing, flashing TWRP and rerooting with the BetaSU zip is the easiest with a restore/setup again of the phone IMO. Mine wouldn't even boot using the other update methods in the thread, much of what applies to this thread here what I posted on that thread the steps and you mention as well.

Good luck.
[HTC One A9] jolorbz:
I have really slow internet and had read over this thread before i took the latest update. I failed do to a backup before i flashed boot img for unlocked found here. My wifi is broken now and i can't download a full RUU. Would you be able to share just the boot img from that RUU with me..?. :fingers-crossed:
[HTC One A9] DjamS2a:
Hey guys.

A problem for me.

I have flashed the boot.img and reboot my phone just after :(

Now I am stuck with the HTC logo and the "This build is for development...."

I have no access to fastboot.

Can you help me ?
[HTC One A9] Bubbamanlarry:
Well, I'm looking forward to Sunshine but I cant even get rooted yet. Any ideas? Here's my problem - There is no "option" for fastboot in the list with bootloader, etc. I need an answer fast. I've never had this issue before. I'm on an AT&T A9. Without fastboot function, I'm stuck. Thanks in advance for your help.
[HTC One A9] Ivanovic:
Boot into download mode and use fastboot commands as usual

Στάλθηκε από το HTC One A9 μου χρησιμοποιώντας Tapatalk
[HTC One A9] km8j:
Hi. I have three questions...

1) Is s-off required to achieve root?

2) Does this method work on 6.0.1? http://dottech.org/189122/how-to-root-htc-one-a9-on-android-6-0-marshmallow-guide/

3) Can you keep encryption with unlock BL/root?
[HTC One A9] gozbo147:
boot img zip

Hi, I'm looking for a boot image zip that matches my fingerprint:

htc/hiaeuhl_00401/htc_hiaeuhl:6.0/MRA58K/656287.5:user/release-keys
[HTC One A9] Captain_Throwback:
What do you need it for?
[HTC One A9] gozbo147:
In order to root my A9. Maybe i can just use that one:

EE - ro.build.fingerprint=htc/hiaeuhl_00401/htc_hiaeuhl:6.0/MRA58K/635503.7:user/release-keys - a9-ee-635503.7.zip
[HTC One A9] Captain_Throwback:
You don't need any custom boot.img to root. Go to the TWRP thread and read up.
[HTC One A9] pasudag:
Hello guys, my English is not quite perfect, I read some of the threads TWRP, I have doubts about many things, so to get to the root end with the last TWRP 2.8.7.0 must unlock the bootloader, putting TWRP 2.8.7.0 and flash supersu 2.62 right? thanks for the help..
[HTC One A9] jaypeg123:
It is all very well covered in multiple threads, unlock bootloader, install twrp, format data, reboot recovery, install supersu, that's it!
[HTC One A9] pasudag:
Thanks, in fact, the format data is used to temporarily disable encryption right?

Inviato dal mio HTC One utilizzando Tapatalk
[HTC One A9] gozbo147:
I thought it was required to "disable full device encryption". I had a look to the TWRP thread and it is mentioned that it cannot (currently) decrypt HTC Sense ROMs.

To achieve root without format data should i just need to install TWRP then flash seSuperuser ?
[HTC One A9] Captain_Throwback:
Yes. And install the app.
[HTC One A9] zorantoma:
How to factory reset in bootloader?

Hello

I'm new to the A9 coming from m9 so flashing is not a problem for me but for the love of god How do i do a factory reset from the bootloader as i have no option for it. can someone help me please
[HTC One A9] Captain_Throwback:
There's only an option to do that in Download Mode if you're S-OFF.

However, depending on why you're trying to factory reset, you should probably consider reading the FAQ in the TWRP thread first (this root method is deprecated).

Additionally, if your device is still encrypted, you can help me out by flashing this TWRP and uploading a log in the TWRP thread.
[HTC One A9] zorantoma:
Sorry,didnt see your post earlier,before i flashed twrp and moved on with root and soff.
[HTC One A9] captainfips:
Stuck in something like a boot-loop

I've got a problem... I wanted to root my One A9 and came across this nice guide. Everything went nice till the step where I had to factory reset the phone via the (not TWRP) recovery. I just forgot that and restarted the phone with the option in the "htc download mode"... So I have already flashed the modified boot image but bot the TWRP-Recovery.... Now I am stuck in something like a "boot-loop" just without the restart every couple of seconds... I am just getting shown the same screen for hours.... I don't know anything else I could do to get back to the download mode or the (again not TWRP) recovery.

Thanks in advance for help!

(Sorry for my (maybe) bad english, I normally speak german...)
[HTC One A9] JochenP:
Restore boot.img that you have hopefully backed up from within twrp.

Then install systenless root via twrp.
[HTC One A9] captainfips:
TWRP wasn't installed yet as I said... So I haven't had the opportunity to make a backup. But my real problem is that the phone doesn't react on anything not even my pc realizes it when I connect it with the USB cable...
[HTC One A9] JochenP:
Thie method is obsolet - it is better to use systemless root.

No problem that you have not yet factory reset you device.

go to download mode by pressing volume down (after restarting device by pressing volume up and power for ca 10 seconds)

in download mode fastboot flash recovery twrp.img
[HTC One A9] CellTech03:
Does anyone know how to Sim unlock the Sprint A9 for international gsm?

Thanks
[HTC One A9] Captain_Throwback:
I thought all new Sprint devices that were world-roaming-capable came SIM unlocked? Have you called Sprint and asked them?
[HTC One A9] bigdaddyrobb:
Is this still the most correct and up to date way to root A9 6.01 with 1:56.617.1?
[HTC One A9] Captain_Throwback:
No. See the TWRP thread FAQ.
[HTC One A9] bilal_sul:
we have determined that your phone may be running a modified version of its system software.

problem htc A9 I need help :\

or someone can show me a way how to gain s-0n again on my htc A9 thanks.
[HTC One A9] Captain_Throwback:
Just run an RUU.
[HTC One A9] bilal_sul:
I tried through SD Card it says ( 7 RU_FAIL cid in android-info mismatched )
[HTC One A9] Vazkez23:
Hello,

firstly thank you very much for the thread I done it. Well sort of :P

Unfortunately my bootloader still showing "s-on" and some of the apps does not work. For example Add away or ES explorer does not give me root access to phone. I did the root check and all seems to find, however I can see in your video that yours shows "s-off".

So could you be so kind and advice what did I do wrong please?

Thank you again and sorry if I am asking the same question again.
[HTC One A9] pspilot:
Jeez, I read all the 40+ pages here and I hope to be a bit smarter now :eek:. Originally I was just searching the right root.img for my A9 (European, unlocked, from Amazon in January), but couldn't find one. Then I learned here about the new SuperSU (2.52+) and now I think I'm finally ready to root my A9. But I had a few final questions, before I dare to go on. Maybe they help also others to clearify the process once more - it seems with Android 6, the encryption and certain HTCs 'varieties', the A9 is more tricky to handle than other Androids I had before. But back to topic:

Bootloader is unlocked with HTC, TWRP (2.8.8.0) is flashed and working and I did a huge system backup - I ticked about every option to backup I could :angel:. I did NOT yet format the data partition, which leads to my first question: what's that doing? I really don't understand that whole encryption scheme and I don't understand, why TWRP is asking me for my pattern, but doesn't recognize it then. Formatting the data partition is helping to overcome that, or why do I have to do that? As far as I understood, S-ON has nothing to do with it, or does it? That's another of these questions: what's S-OFF good for?

Formating the data means I loose everything, right? Is that like a factory reset? And if, could I safe my configurations also with a Titanium Backup within the system? Of course I already installed and configured a few individual things since I have the A9. I would really appreciate, if I could understand that whole thing a bit better.

Anyway, after data is formatted I just install the SuperSU.zip with TWRP from my SD, reboot and I'm rooted, right?

Last-but-not-least, a big THANKS for all the work here, especially to the overly patient jcase (to answer the same questions over and over), to Captain_Throwback and of course to Chainfire :). Without you guys owning an Android device wouldn't be the same :good:!
[HTC One A9] treetolber:
LED is constant green

Ever since this process my LED on the front is constantly green.
[HTC One A9] CarinaPDX:
pspilot: as stated elsewhere Android 6.x encrypts /data by default, TWRP is capable of working with the standard Android encryption BUT HTC uses a different encryption which TWRP can't decrypt. So in order to have tools like TWRP to be able to work on /data it is necessary to wipe it and reformat it unencrypted. So first select no encryption, then wipe data, then reboot, and TWRP will have a /data which it can access to install root. Of course wiping means all content is removed from /data. [Edit: when TWRP is asking you for a PIN to decrypt the /data partition, it intends to use that to decrypt but it can't do it since it doesn't recognize the HTC method.]

S-ON is another can of worms. You will be fine without changing to S-OFF for rooting. It should be possible to install custom ROMs with S-ON as well, but it depends. Basically S-ON allows changing /system, /boot, and /recovery (all that is usually needed for custom ROMs); with stock ROMs it does not allow going backwards to older versions or different versions (such as changing from EU to US). This also protects other partitions, such as /radio and /misc, from changes. Normally you won't need to be S-OFF. Exceptions are to change region versions or just a desire to freely move between ROMs without restrictions. The downside is that without the restrictions it is quite possible to brick a phone - "with great power comes great responsibility".

Greg
[HTC One A9] pspilot:
Oops - where do I select 'no encryption'? In TWRP? Can't find that option. And should I wipe, or format data? Or is formatting data automatically resetting the encryption? Jeez, it seems I'll never understand that system :rolleyes:

Thanks for your interesting explanation, especially the fact, that data encryption and S-ON are not related was totally new for me. So S-ON is no Android 6, but an HTC 'thing'?
[HTC One A9] CarinaPDX:
I'm not remembering where the encryption option is set - search the threads, it is out there.

As with so much else, every manufacturer does things a bit differently - S-ON/OFF is HTC's solution. In fact, HTC does S-ON differently on the A9 than on some previous models. In the US the Federal Communications Commission looks dimly at public access to the programming of the SDR (software defined radio) in /radio. It is quite easy for some incompetent or evil person to make the radio operate on unlicensed frequencies or use unapproved codecs, etc, and thus they require the /radio to be hard to get at directly. An RUU can replace /radio along with the rest of the firmware if it is intended for that version of phone - otherwise S-OFF is necessary. BTW S-ON also checks signatures for ROM images, preventing installation of corrupted firmware. Personally I think it best to keep the protections of S-ON unless there is a specific need, such as for developing ROMs or changing stock ROM versions (regions/carriers, etc).

Greg