yashsingh1/xdaforums huggingface dataset:
[HTC 10 Guides, News, & Discussion] jcase:
A percent of those that went S-OFF/LOCKED with SunShine 3.3.8 will have kernel flashing issues. We addressed this in 3.3.9 (released May 28th 2016 5PM PST).

Either go back s-on/unlocked and redo sunshine (may throw an error, if it does lmk and i can fix on server) or go s-off unlocked.

This was one of those errors that only occurs on other people's phones, so it was a PITA to track down.
[HTC 10 Guides, News, & Discussion] nteeb:
I've just finished unlocking my device via htcdev.com. I also s-offed it using the latest sunshine apk (3.3.9). So now I'm s-off with unlocked bootloader running the stock, rooted system. I didn't flashed any custom rom-but I want it later.

Do you recommend to set s-on and re run sunshine with the option s-off/locked?

Is there any reason to prefer that option ,not the other one (s-off/unlocked)?

Finally, is it enough to run the "fastboot oem writesecureflag 3" command using without flashing a comlpletely stock rom (European wwe ruu.zip)?

Sorry for my bad English...
[HTC 10 Guides, News, & Discussion] jakdillard:
Ok something interesting going on here. I had the S-off/locked bug and tried to fix it using the suggestions in the op. Now I can unlock the the bootloader with going into developer options selecting "oem unlock", then using the htcdev method it throws "enable unlock" so now I'm stuck.

target reported max download size of 800000000 bytes

sending 'unlocktoken' (0 KB)...

OKAY [ 1.004s]

writing 'unlocktoken'...

(bootloader) flash unlocktoken

(bootloader) [KillSwitch] : /dev/block/bootdevice/by-name/frp

(bootloader) [KillSwitch] Last Byte is 0X01, enable unlock

FAILED (remote: UnlockToken Verify Fail!!)

finished. total time: 1.086s
[HTC 10 Guides, News, & Discussion] beaups:
Get a new token from htcdev
[HTC 10 Guides, News, & Discussion] cbrown245:
I'm having an issue, I'm s-off unlocked, if I wipe data in recovery and flash a rom either it bootloops back to pattern screen and then reboots, or I loose data . But if I format it will start up just fine, but if I go to recovery for anything it will come back with no data if it comes back, either way I have to go back and format once again . I s-offed yesterday with the latest. Does this have anything to do with the required pattern at start? Or should I reset and start over again?

***update***

OK I went ahead and went back to s-on and unlocked, now all is good, can flash anything with a simple wipe, no format needed. Tried to re s-off and got error with some number to pass along to support. Not really sure if going s-off will help, but will still contact support.
[HTC 10 Guides, News, & Discussion] jakdillard:
OK thanks for whatever reason that did not work the first time I tried it, however I tried again now it works,
[HTC 10 Guides, News, & Discussion] bmwbasti:
Hmm, I set my device back to S-On again and wanted to put it to S-Off/locked to be able to put it back to S-On/locked afterwards for returning purpose. But after flashing SuperSU and installing SunShine I get a strange message. Please contact support and give them this number: 178.26.234.187

Damn, I have to send it back by tomorrow :(
[HTC 10 Guides, News, & Discussion] :
Go to their live Support Chat here http://webchat.freenode.net/?channels=sunshine-support

Give them this number and they will help you.
[HTC 10 Guides, News, & Discussion] markwebb:
I am sending my device back and this is what I did without a hitch using adb fastboot:

(a) Flashed US unlocked RUU

(b) changed my supercid back to stock value

(c) got s-on by running "fastboot oem writesecureflag 3" in download mode

(d) locked bootloader

Packed and ready to go.

Have you tried those steps? Didn't take long at all.
[HTC 10 Guides, News, & Discussion] beaups:
That method will set the bootloader to "RELOCKED", not "LOCKED"

--beaups
[HTC 10 Guides, News, & Discussion] markwebb:
Says locked in download mode: is there another flag or warning?
[HTC 10 Guides, News, & Discussion] beaups:
How did you perform step d?
[HTC 10 Guides, News, & Discussion] markwebb:
I'm trying to remember but it already shipped out. :( if worse comes to worst then they'll send it back to me but I doubt it. I have learned from the past that they basically look to make sure everything is included in the box and that it boots up correctly. Refunds are quick.
[HTC 10 Guides, News, & Discussion] jcase:
PM me and ill fix it, new version fixes teh kernel flashing issue as well
[HTC 10 Guides, News, & Discussion] cbrown245:
Thanks bro , beaups got me on support and all is good now . S-off again with no issues . Awesome work guys !!!
[HTC 10 Guides, News, & Discussion] wineds:
I had the 3.38 bug which I fixed yesterday by going SOFF UNLOCKED (thanks Jcase an Beaups). Are there any residual issues fixing the issue this way? Is using the SON UNLOCKED method instead and redoing sunshine a better "cleanup" solution?
[HTC 10 Guides, News, & Discussion] markwebb:
Well, if that were the case and I "thought" it was set to "locked", HTC, either way, just refunded my return on my Credit Card. :) As long as device is pristine with all of the accompanying accessories and boots correctly, I believe one is good to go. :)
[HTC 10 Guides, News, & Discussion] EtherealRemnant:
A number of us with S-OFF locked are having issues with Wi-Fi. It keeps constantly resetting the connection which kills the battery, it doesn't even doze. I did mine immediately after getting my device so I don't know if it's being blamed on S-OFF locked unfairly or if there is some sort of incompatibility going on. Any word on this? dmesg Just shows the Wi-Fi constantly getting reset. The drain is so bad that an hour with the screen off while using Wi-Fi will drop the battery 3-4% while even a weak LTE signal will drop 1% or less in an hour. The only reason I did S-OFF locked was because of the warning that I may not be able to get S-ON locked later but if it's breaking Wi-Fi, I may just flash the US unlocked RUU (since my phone is T-Mobile and doesn't have a RUU) and go back to S-ON and start over. I have a 6GB plan with T-Mobile but I'd rather use my 150Mbps Wi-Fi as opposed to the 15-35Mbps I get from T-Mobile... S-OFF has had complications before so I figured it was worth asking. You geniuses here could probably figure out what's causing it anyway even if it's not S-OFF related. So far it affects all the kernels I've tried. I have a friend who got one who is locked and S-ON and he has no excessive power drain from Wi-Fi while wakelocks on my device are a straight blue line when the screen is off on Wi-Fi and just dots from background apps when I'm on LTE.
[HTC 10 Guides, News, & Discussion] Captain_Throwback:
That has nothing to do with S-OFF. Early bases had some WiFi issues, which were fixed in the 1.53 update. Flashing the US Unlocked RUU should sort it out - you'll just need to set SuperCID first and you should be good to go.
[HTC 10 Guides, News, & Discussion] EtherealRemnant:
​

Unfortunately that's the ROM I'm on and the Wi-Fi constantly is resetting itself on stock and custom kernels. It was brought up it may be S-OFF related but it sounds like its firmware so I'll wait for a new US firmware update and hope that fixes it, thanks.
[HTC 10 Guides, News, & Discussion] Captain_Throwback:
Could be a router issue, then. If not that, then hardware.
[HTC 10 Guides, News, & Discussion] oneshotaz:
You mentioned in the OP that we can Either go back s-on/unlocked and redo sunshine. How can this be done? I have been trying to do it and I don't know how to. I would appreciate your support
[HTC 10 Guides, News, & Discussion] WhiteHartMart:
Looking for some help if possible please.

I've purchased a device which is supposedly pretty much unused. It's a sim free device from Carphone Warehouse UK.

On checking it's showing and S-OFF and Relocked. It seems to have some issues which I'd like investigated/repaired.

1. Is there any chance it could have come from the factory like this?

2. The seller insists he hasn't touched the bootloader - can I check anywhere to see the date the S-OFF status changed?

3. Can I safely return to stock status so warranty is honoured?

4. Is there any other checks I can do?

Thanks in advance.
[HTC 10 Guides, News, & Discussion] beaups:
1.) Rarely devices will come s-off from the factory, never seen them come relocked - most certainly the phone has been tampered with.

2.) Probably not true (like 99%). 2 things: 1.) if it was done from the factory or with javacard (which don't seem to exist for the 10 yet) you can run fastboot oem dump_secrecord - more than likely you won't see anything useful because the seller probably used SunShine to get s-off - and SunShine doesn't set those dates. 2.) open a support ticket on our site: therootninja.zendesk.com and we can advise if SunShine has been purchased and used on that device

3.) Hard to say

4.) See # 2

--beaups
[HTC 10 Guides, News, & Discussion] WhiteHartMart:
Thanks for your reply. Have posted a support ticket as suggested.
[HTC 10 Guides, News, & Discussion] bmwbasti:
Just a quick question. Could it be that with status "locked & S-Off" some apps that require root won't work correctly? I've read several times that eg SuperSU won't grant root access (or even won't be "there" after flashing) and people mentioned that "locked" could be the problem.
[HTC 10 Guides, News, & Discussion] beaups:
We have not see any behavior like this.
[HTC 10 Guides, News, & Discussion] bmwbasti:
I sadly didn't bookmark the thread were it was mentioned but I'll post it if I can find it again.
[HTC 10 Guides, News, & Discussion] Captain_Throwback:
That was before they fixed it ;). If only some root apps are failing, those are app issues and have nothing to do with SunShine.
[HTC 10 Guides, News, & Discussion] bmwbasti:
Ah, I had in mind that it was written by you Captain_Throwback ;)

Thx for clarification :)
[HTC 10 Guides, News, & Discussion] KotTHECat:
That means choosing S-OFF/Locked is completely "safe" at this point? And there won't be any problems being "Locked" (installing mods or even custom ROMs for example)?
[HTC 10 Guides, News, & Discussion] beaups:
We haven't seen any issues except for a bug in an earlier sunshine version.

--beaups
[HTC 10 Guides, News, & Discussion] hesam62k:
S-OFF to S-ON

Hi, thanks for the app. It works flawlessly. I am new to the world of android and have a problem now. I wanted to flash the usa unlocked version rom onto my HTC 10 device (german o2) so i set the s-flag to off and changed the CID and MID. Now that i want to set the S-flag back to ON, i receive the following error(on download mode and using the command "fastboot oem writesecureflag 3" ):

(bootloader) HTC KEY CARD VERSION: 7

(bootloader) Verify hosd Fail(-9)

FAILED (remote: Partition verify fail -9)

finished. total time: 1.225s

---------------------------------------------------------

my device: HTC 10

before S-off or stock state: HTC 10 German O2

-----------

now: Bootloader unlocked & S-OFF

Software status: official 1.80.617.1

Now it works flawlessly with no network problem, no stuttering and no random reboots . Would somebody please help me? I would appreciate any input regarding this matter. Thanks in advance
[HTC 10 Guides, News, & Discussion] jcase:
Flash stock firmware, your bootchain is not properly signed for your device, so it is blocking going s-on. If it didnt block it, you would brick
[HTC 10 Guides, News, & Discussion] hesam62k:
S-OFF to S-ON

Thank you so much for your fast feedback. So do you mean that i should flash my stock image and then go s-on? and must I revert my CID & MID to stock for flashing the stock image?

---------- Post added at 10:06 PM ---------- Previous post was at 09:58 PM ----------

Thank you so much for your fast feedback. So do you mean that i should flash my stock image and then go s-on? and must I revert my CID & MID to stock for flashing the stock image?
[HTC 10 Guides, News, & Discussion] jcase:
I would revert to how you got it
[HTC 10 Guides, News, & Discussion] hesam62k:
Thanks alot for your input. one last question. If i use my device in this condition further, is it going to cause any problem? I ask because my device is functioning without problems I just wanted to set the S-Flag back to ON. Or should I revert everything to Stock (how I received my HTC 10) and try to go S-Off/locked and flash the usa unlocked version again? I require the usa unlock version rom because O2 is not delivering security patches on time. and thank you for your feedbacks sofar.
[HTC 10 Guides, News, & Discussion] jcase:
Should be fine if you stay s off, wht donyou want s on
[HTC 10 Guides, News, & Discussion] hesam62k:
I am glad that you asked. I am not sure actually why but i can remember that i read somewhere that leaving security (protection) of NAND Partions off will open the device to security risks. so i tried to set the s-flag back to on after i was finished with CID, MID and Rom modification.
[HTC 10 Guides, News, & Discussion] jcase:
Most concerning aspect would the ability for someone to flash an boot unsigned code to the device, keep your device in your procession and encrypted it with a strong password negates a lot of that worry.
[HTC 10 Guides, News, & Discussion] hesam62k:
Thanks alot for your time and feedbacks. I will then continue to use my device further with s-off but cautiously. I want the security patches then i have to pay the price :) . Take care and wish you best.:good:

Regards,

Hesam
[HTC 10 Guides, News, & Discussion] ronnbon:
I had my htc 10 unlocked and rooted for a few weeks. Now I am bored of the stock android (early stock android/sense hybrid) and wanted to flash roms again. So I used sunshine today so get s-off and locked- since you all recommended it...

But now I have the red warning text (this is a developer build only....) after rebooting ( which is a little bit annoying) and (more annoying) a note during setup that this device will sent user data etc. etc. to htc and that I cannot disable this.

I have to be honest- I still don't completely understood the difference between s-off and locked s-off unlocked- at least not when it means I can flash roms and root anyway... So I am not really sure what I gained with staying or exactly go back to the locked status.

If I'd rather wanted to go to unlocked again can I simply redo the unlock token routine or could I use sunshine again?

Thanxs.
[HTC 10 Guides, News, & Discussion] darkenedpath:
Having the locked status is an easier "safer" way, to go back s-on if you need to return the phone for warranty purposes (if I'm wrong please correct me). With s-off you gain the ability to flash more things than Roms. (firmware, radios, splash screen, etc) if the red text is that annoying, just unlock the bootloader again. I can confirm it worked for me. You have to remove the unlock token in your faceboot bin before you redo it.
[HTC 10 Guides, News, & Discussion] Genesis Nova:
Attempted to run sunshine to get s-off locked (i'm s-off unlocked at the moment) and sunshine basically tells me I'm already s-off and that "sunshine has nothing to do"
[HTC 10 Guides, News, & Discussion] ronnbon:
It's less the red warning than the "this is a developer device still owned by htc. We will know everything you do with it and you cannot prevent it! " text I get during first setup that concerns me. (ok... that was not that exact wording but the meaning was the same.?) But thanks for your answer anyway!
[HTC 10 Guides, News, & Discussion] beaups:
You will always get that on s-off device, regardless if locked or unlocked. Run a custom ROM without the logging stuff or disable htc logging stuff on your stock rom, if you are concerned.
[HTC 10 Guides, News, & Discussion] ronnbon:
Okay, the last device I changed to s-off was my HTC m7, so this was a while ago.... ? But what I remember were the extreme problems I run into as I had to get it back to untempered for a warranty repair. Thank god for the xda community and a great member from Israel who helped me with that!

Back to topic: so with viper rom installed there should be no more logging?
[HTC 10 Guides, News, & Discussion] beaups:
I think viper removed that, yes, but I would ask them if you want to be certain.
[HTC 10 Guides, News, & Discussion] ronnbon:
Thank you, I will do that.
[HTC 10 Guides, News, & Discussion] KOLIOSIS:
My apologies if this is rehash from previous posts,but,I'm not certain as to how (order of operations) to revert my T-Mobile HTC 10 from Unlocked/TWRP/Root/S-Off to Locked/S-On (to BNIB condition).

Just to make it simpler (in my mind),I'd rather start from a fresh RUU (no TWRP or root)

May seem more steps than from where I am now,so,if it's easier coming from a rooted ROM,I can go that route as well.

Thanks In Advance.
[HTC 10 Guides, News, & Discussion] mdon874:
Del.
[HTC 10 Guides, News, & Discussion] zukers:
so to summarize, I'm on htcdev unlocked S-ON and need to revert to stock:

1. buying sunshine and choose "s-off locked"

2.restore my system image & boot in TWRP

3.flash stock recovery, backup was made on firmware 1.90.401.5 so I need recovery with this build

4. S-ON by typing fastboot oem writesecureflag 3

am I right with this?

Does this procedure return my phone to stock with Software status Official Locked S-ON and possibility to get future OTAs?

many thanks
[HTC 10 Guides, News, & Discussion] Krystalmyth:
I would consider running an RUU instead myself than flash all that..
[HTC 10 Guides, News, & Discussion] andybones:
+1 on running RUU. This is recommended before running the S-ON cmd.
[HTC 10 Guides, News, & Discussion] Krystalmyth:
Aye, this is a delicate operation. Hence the use of massive overkill on target. Those bastards aren't getting away this time. Not after what they did to us that night. Just drop an RUU right on it from low orbit and get out. It's the only way to be sure.
[HTC 10 Guides, News, & Discussion] dastinger:
I'm sorry for the newbie questions but what can/can't do with bootloader unlocked/s-on, bootloader unlocked/s-off and bootloader locked/s-off? What are the differences?

Is it still impossible to relock after unlocking?

Sorry, first time HTC owner coming from Nexus so I'm a bit confused.
[HTC 10 Guides, News, & Discussion] EtherealRemnant:
Bootloader unlock/S-ON allows you to flash TWRP and flash custom ROMs. Only HTC signed firmware and ROM updates will flash. In S-ON, relocking the bootloader will say relocked instead of locked which could affect warranty or trade in status.

Either option with S-OFF allows full control over the phone, you can flash signed and unsigned ROMs and firmware, you can convert your device to another (for example carrier branded to unlocked), and following the process to relock the phone will set your phone to out of the box status with S-ON and locked flags.

Basically S-OFF is for power users and those that need to be able to restore their device back to the point where it shows no signs of being tampered with. If you just want to flash custom ROMs, you just need the bootloader unlock from HTCdev.

S-OFF gives you full control over the phone. It's pretty much the only way that someone that doesn't know what they're doing can actually brick an HTC device.
[HTC 10 Guides, News, & Discussion] dastinger:
Thank you so much!

Let's hope that my phone comes with a version supported by temp root or else there's no point on relocking if I already gave my info to HTC using HTCdev.
[HTC 10 Guides, News, & Discussion] 0kk0:
I'm s-off and unlocked... stock rooted rom 1.95.401.4.

Is it adviced to go s-off and locked. Or will this still be possibile in the futere? Dont now if i should do this now, now i still can?

And is it needed to flash ruu before going back s-on while is still on stock rooted rom? also got untoched system image i can restore.

Thnx a lot and have a nice day!
[HTC 10 Guides, News, & Discussion] komugi:
If you do change the lock status, your data will be wiped. So far there really isn't any reason to do so aside from restoring for warranty purposes.

Sent from my HTC 10
[HTC 10 Guides, News, & Discussion] 0kk0:
Thnx! i will leave it this way. Really love the HTC 10 :laugh:
[HTC 10 Guides, News, & Discussion] xanadu1979:
Android Pay no longer works with an unlocked bootloader. That's why I went from s-off unlocked to s-off locked.

But if you don't need Android Pay, I don't see any good reasons to switch.
[HTC 10 Guides, News, & Discussion] koRn666:
Now my HTC 10 have a unlocked bootloader, a custom ROM, and root, if i run sunshine now and choose S-OFF/Locked this will wipe my data??

Enviado desde mi HTC 10 mediante Tapatalk
[HTC 10 Guides, News, & Discussion] DummyPLUG:
I use sunshine with s-off/locked, then I try to flash supersu with temp boot TWRP, but report bootloader locked(expected behaver even s-off?), so is that I must flash twrp then flash supersu, after that flash back the offical recovery?

I want to able get OTA after root.
[HTC 10 Guides, News, & Discussion] beaups:
Expected behavior, and correct.

--beaups
[HTC 10 Guides, News, & Discussion] DummyPLUG:
thanks, now I need to look for offical recovery for CID_622
[HTC 10 Guides, News, & Discussion] houston_:
I don't habe the phone yet, but I am curious.

I had a Sony Z1 compact to root it, the other day.

The owner of it was very strict about not unlocking the bootloader since the olive will loose the drm keys.

I thought it would only be used for something like widevine... Netflix etc...

But he told me, it would also disable some features of the Sony camera. Hdr for example.

I am planning to purchase the HTC 10 in near future, so I wanted to think about the rooting stuff already.

The experience with the z1c made me wonder, if unlocking the bootloader on the 10 does the same? And if it is prevented by locked soff?

And what will be lost in case of unlocking the 10?
[HTC 10 Guides, News, & Discussion] beaups:
Nothing is lost.
[HTC 10 Guides, News, & Discussion] houston_:
And by flashing a modded sense Rom?
[HTC 10 Guides, News, & Discussion] beaups:
You just lose whatever may have been removed from that Rom. There's no "automatic" loss of anything like there is for Sony devices.
[HTC 10 Guides, News, & Discussion] houston_:
Widevine will be lost if I root my device, won't it?

But thanks already for the info. ??
[HTC 10 Guides, News, & Discussion] beaups:
No.
[HTC 10 Guides, News, & Discussion] wiQbold:
Hi.

last time if I ruu d my HTC10 I wanted to set my boot loader from soff unlocked to soff locked with sunshine, but it says that I am already soff? Is there no need anymore for doing this?
[HTC 10 Guides, News, & Discussion] Kisakuku:
1) RUU,

2) S-On (at your own risk, as it's possible to brick if RUU was not entirely successful),

3) S-Off / Locked with SunShine.
[HTC 10 Guides, News, & Discussion] wiQbold:
I did not read the writesecureflag
[HTC 10 Guides, News, & Discussion] EnGiDrOiD:
no no need
[HTC 10 Guides, News, & Discussion] i$tickitinyour$u$hi:
would not recommend you to use the "writesecureflag 3" if you want to stay s-off.

did it once and jcase gets aggro at the support to get sunshine to work again :angel:
[HTC 10 Guides, News, & Discussion] wiQbold:
did it like that. sunshine done it s job afterwards. S-off locked now. even with wwe ruu..
[HTC 10 Guides, News, & Discussion] ronnbon:
I have a s-off but locked htc 10 with much to old firmware base by now... (I had no time for fun like this the last months. ;) ) Now I wanted to update my current rom (viper10) and to make it correct also the matching firmware.

To be honest- I am not new to flashing and co. but this whole new decrypted phone stuff and systemless apps , and no wipe or wipe etc. confuses me still a lot and feel like a newbie again.

So my question: Do I still just flash the firmware via adb (fastboot flash zip <nameof.zip>") like I know it from the past? And whats with no wipe because of the encryption? I from time to time I like to wipe my phone as kind of super-cleaning for a fresh system . And after that installing the rom update with twrp?

I know- it´s not the exacty right place here for my question- I trying to find the right place for about 2h now and I just getting more and more confused- obviously I missed a lot at the htc10 forum the last 6 months...

Any advice would be appreciated.