yashsingh1/xdaforums huggingface dataset:
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] MikiGry:
A simple implementation in flashtool should fix it - ARP check

Current ARP level =< firmware that's going to be flashed - install

Current ARP level > firmware that's going to flashed - abort installation

As simple as that

But knowing how stupid Xiaomi can be ... I'm not sure if I want then to play with flash tool :P
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] corkiejp:
It is already code into the flashall script (from V9.5.14.0.OEICNFA): -

set CURRENT_ANTI_VER=3
for /f "tokens=2 delims=: " %%i in ('fastboot %* getvar anti 2^>^&1 ^| findstr /r /c:"anti:"') do (set version=%%i)
if [%version%] EQU [] set version=0
if %version% GTR %CURRENT_ANTI_VER% (
echo current device antirollback version is greater than this package
exit /B 1
)

So obviously the tool bypass the manual script and does it's own thing.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] sauliiin:
Ok... I breaking my head into Miui world! First I'm ****ed with anti roll back 4 :P. I read a lot, but there are a lot of new stuff that I never heard about on Samsung world :{

Pleaseeeee, just tell me if I'm correct.

Unloocking bootloader is easy after waiting time. Ok here. Than, I want custom recovery just to flash magisk!

Since Im on anti 4, fastboot commands are bloked, right? So, 1: "fastboot flash antirbpass dummy.img"; 2: flash TWRP or Redwolf with "fastboot flash recovery XXXX.img"; 3: Boot Twrp or Redwolf using “fastboot boot XYZ.img”. 4: In recovery, I normally flash magisk and be happy :)

Now... I will have custom recovery, I believe. Will my phone still receive OTA, will I be able to update manualle ota files from updater?

At last... I feel kind of naked without recovery... Does redwolf really stick after a rom update?

Thanks.. Really hope someone could helpe cause I'm really lost.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] kostas gp:
So we come to the realization that we, massively, have to push things to change this state instead of just waiting for Xiaomi to sympathize. The question, at least for me, is what is the best thing we can do for this. Also, this is something that must be done asap,(in fact it should have already happened, a long time ago) before our beloved whyred gets old.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] cobben:
That they went forward with the same ARB implementation to Mi 6x and another device, without any discussion or fixes, shows that they are satisfied with how things went with Whyred and are going to gradually push this out to all their devices.

The flashaholics are probably seen mostly as a nuisance, and at less then 0.1% if their customer base can safely be ignored / thrown under the buss.

Just like Huawei did, except Huawei chose to shut down the free flashing entirely.

Might that be a more reasonable approach?

One can wonder what advantage they see in causing unsuspecting folks to brick their phones?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] kostas gp:
So, taking that into consideration we can assume or predict that things can get worse. Their sales are going even better, they are expanding this stupid ARB implementation to further devices, so why not proceed into even more unfavorable actions for us, the flashaholics. Maybe they even forbid us to unlock our bootloaders at all, at some point. And then xiaomi will stop being that super vfm and quality, regarding the smartphones, for us. And then what? I'll go buy a Samsung? I am really frustrated.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] Marek_M94:
I've got same questions like you, but im not intrested in installing magisk - im looking forward to install xiaomi.eu roms after unlocking bootloader if there'll be any new one.

now im stuck at .19 rom and waiting for unlock permission..

so stupid way to make people more and more frustrated xiaomi..
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] corkiejp:
[MENTION=7466486]vishaltehlan412[/MENTION] You update your bootloader to 9.5.14 firmware (I assume oreo), so you can not go back to nougat by Mi Flash.

Also assume you have the Indian version of WHYRED as that is the only version with nougat.

Check your anti version again

fastboot getvar anti

If still reporting 3, you maybe able to use a recovery rom to return to nougat(if that is anti 3 as well), if you can source it.

Proceed at your own risk!
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] cobben:
Samsung? Hardly, rather iPhone if the whole Android thing becomes even more corrupted.

With Android you are paying for part of the service by being sold to advertisers, which we few "flashaholics" have been able to avoid by devious means which they obviously want to shut down.

In China I suppose the "sold to advertisers" is replaced by "controlled and monitored by the state for your own good", sort of. Wondering how that works out for Apple in China?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] vishaltehlan412:
Yes i have indian version......i checked again so its 3 only .I wanted to return to nougat but now it seems bad idea ...Can u suggest a rom with good battery backup as i play pubg a lot .Any miui 10 version with anti 3 or custom rom u might have used
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] corkiejp:
[MENTION=7466486]vishaltehlan412[/MENTION] You can check the fastboot rom flashall script for this line: -

set CURRENT_ANTI_VER=

If it says 2, it is probably not advised to downgrade to nougat.

Don't play that game are use MIUI, but see here for suggested roms: -

https://www.google.com/search?q=best+custom+xiaomi+rom+for+pubg

https://www.youtube.com/watch?v=am1wT0wROjQ
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] sauliiin:
I have to wait for 5 more days to unlock, but already trying to get as much information as I can... I'm old on Android world, Im here since eclair, but it seems a lot is different on Miui.

As soon as I unlock the phone, I will try to put everything to practice and safely try some stuff and give you feedback.

Unfortunately, here im getting no answers and all blurred... Dont know if people are using more telegram or Xiaomi forum.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] leoabr:
I'll make a detailed explanation because what happened doesn't make sense

I bought my RN5 a month ago and i wait for 15 days to Unlock BL , between this time i changed to the Beta 8.7.5 ( Anti 3), when all this story of Antirollback happened, i decided to go back to 9.5.17(anti 3) and unlock my BL, everything went fine and i came to MIUI.EU 8.6.28, after that i went to the P Treble and stayed for only 1 hour and got back to MIUI.EU, when the MIUI.EU 8.7.26 released, i updated and i've been using everyday without problem, but TUESDAY this happened :

I went to the street, used the Uber app and came back to home like always, as i can remember, the phone had 50% battery. A couple minutes later i was using the web whatsapp on PC and the software disconnected, at the first moment i didn't understood because the wifi was online, but when i took my RN5 he was turned off and didn't turned on anymore. I tried to power on the device and nothing, when i put on PC, i got this message on the device manager

qualcomm hs-usb qdloader 9008

He is on EDL mode and i can't do anything, he was ANTI 3, i tried to flash with miflashbeta, miflashpro, miflash old, but the only way that probably will work is with the xiaomi ID Authorization because every version fails ( Only Sig Nop and Sig Tag, Port errors and needing authorization).

REMEMBER : He was ANTI 3 but he got a EDL mode like ARB downgrade??????

Please Help and i appreciate tour understanding
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] kostas gp:
Ha, I see your point. The truth is that I am not really willing to purchase anything from Apple, although they have really good devices in many fields. So, I hope xiaomi will show mercy to our flashaholic community and give us some freedom and the favor we used to have. I acknowledge that selling us to the advertisers and giving a hand to the state so it looks after our own good is important. But I hope that Xiaomi and the rest of the manufacturers will show generosity on us.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] azwina:
currently i on miui 10 8.7.5 global firmware with ROOT status , and i can received OTA update 8.8.9 firmware, i know that version is anti roll back version , if i update my root status will there ?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] MeNoNoob:
Do anyone know what kind error is this? This annoying one occurred everytime I tried
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] sauliiin:
Have you flashed dummy.img? Its is necessary to release fastboot commands if you are on arb4. It is needed to flash every time before
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] Popeyeraname:
9.5.19 with twrp installed. Can I reflash normal 9.5.19(from miui official site) via twrp or flashtool, without bricking my device? Thank you in advance.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] Tudor75:
Hi everyone. Currently I have 9.5.19.0. If i will install a custom rom and then i want to go back to my previous version of stable rom, what should i do . Thanks.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] P.Rabbit:
I have the bootloader unlocked and the last version TWRP (Official)

Flashey the dummy.img and even so when I run the command '' fastboot getvar anti '' I get the 4. I currently have the global rom, no root.

What do I have to do to get the 3? I want to install AEX Rom
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] corkiejp:
[MENTION=6483493]P.Rabbit[/MENTION] If your already updated your device to Anti 4, then there is noway to get back to 3 at present without bricking your device.

You can still flash whatever custom rom you want, just don't flash any anti 3 MIUI Firmware/Rom.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] P.Rabbit:
Thank you.

So it means I can use any pure androi rom / Aosp ?

What I should not do is try to install a MIUI rom, with 3.

this is it ?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] kellerman40:
There is definitely some battery drain, I dont use the device that much and have barely 3hrs SOT at 50% battery.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] sauliiin:
There is nothing you can do... At least for now. You are ARB 4 for life :P

You just have to take more care when flashing miui rom. Custom are ok.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] kostas gp:
Can anyone make some prediction if there is any possibility of someone been able to hack ARB and give us the ability to downgrade it or even remove it?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] dlghowk:
Hello!

I know that this question was asked many times... But just want to be sure.

Which version of the MIUI 10 Beta had integrated de ARB protection? As I knew 8.7.6 had it first, but in other places says that 8.7.5 had the ARB first.

And, would you recommend me to upgrade to 9.5.19.0? I planing to change the rom of this device. I now know that what triggers the ARB protection is downloading firmware (Thanks to this thread <3)

Sorry for the bad English!
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] kostas gp:
Op and xiaomi's announcement say that 8.7.5 is anti 3. Also, if you want to upgrade to 9.5.19.0, flash the firmwareless version that you can find in XDA, if you are on anti 3. I don't know if 9.5.19.0 is better than previous versions in any aspect, but I guess that it will have the latest security patch.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] Jeff.angkasa:
root can't get ota update. you can get update notifocation but u cannot update with system update. u must download .zip copy to phone and flash with twrp

if i not wrong miui 10 beta 8.7.5 first. if u want to upgrade to 9.5.19.0 , u cannot downgrade to 9.5.17.0. if u downgrade, u phone can brick and u can't fix if u dont have mi id authorized.

---------- Post added at 02:31 AM ---------- Previous post was at 02:16 AM ----------

In the MIUI version 9.5.19.0, Xiaomi implemented the Anti-Rollback Protection (ARP) system that was on Google since the Oreo. ARP is a preventive mechanism for users to downgrade to the previous version, assuming that the latest firmware is the safest.

Why is there ARP?

If you lose your cell, then you can hack your data by downgrading the firmware to an older version that is easier to break. With ARP, this gap is closed

What does the concept work for?

If you have flashed or updated OTA / full ROM to version 9.5.19.0 and above, MIUI 10 8.7.6 and above; then when you try to flash to the previous version, it will brick HH, enter EDL mode, aka total dead (dead).

Wow, horrified. until dead? What is the solution?

There is no definite solution until now. The problem is that even in EDL mode, you can usually flash another firmware. But it turns out that after trying various users on xda, it still can't. The error timeout or HH doesn't detect at all. So there really isn't another solution. Even the dumplings told the user who had been hit by this to the nearest service center. Don't know whether it will be charged or what will be repaired.

How come? ARP isn't just protection?

Yes. Should it be based on the rules of Google, the HH will only fail to boot. But if it is flashed to a new version that follows the ARB index it should be able to boot again. But it can't flash, how can I save. This is why the dumplings make the HH brick and can not be taken away. It's true that implementation is wrong and very dangerous. Many are angry at the official story explaining this "ARP feature".

so you cannot hope remove arb. maybe open petition to xiaomi in order to be able to flash to the new version that follows the ARB version. because this is an implementation error of xiaomi in applying arb
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] kostas gp:
I see. Thank you for the information. I am not related to hacking stuff but I supposed that hacking the ARP would be possible. I mean, major banks and other ultra secured companies have been hacked. But who, with such abilities, will invest time to a smartphone to help our community? I guess the best we have to do for now is keep avoiding to update our bootloaders. For those who are on anti 4, have patience and be careful. For those with bricked devices, good luck.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] AL_IRAQI:
First of all i would like to thank everyone who is helping on my threads, especially [MENTION=4868912]corkiejp[/MENTION], its really great to see you guys answer each other :D

Everything should be fine, just follow the right steps for flashing P, then go back later to Miui like a normal ROM

Yes dummy first.. it wont brick your phone

i said switching between anti 4 ROMs is fine

You're using Nougat bootloader

Your anti is 4, you can check it by going into fastboot then typing

fastboot getver anti

i saw you that kept checking for like 10 times, no need for this just check once and thats it

Well, 9.5.19.0 already has ARB XD

Contact Mods on Miui Forums, and tell them that you need edl flash to fix bootloop

I think most phones launched with O has come kinda of ARB, just dont flash older fw and you should be fine

Nope, they already pushed it to like 5 another Mi devices

8.7.6 is the first beta with ARB, and 9.5.19.0 is the first Stable with ARB

if you dont want to deal with extra anti 4 headache, stick with 9.5.17.0
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] Tudor75:
Anyone?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] timberwolf60:
Currently my phone had been updated 8.8.9 global dev rom as shown, I flashed the official twrp 3.2.3. When my phone booted into twrp, I installed dummy.img into recovery partition, fellow installed twrp 3.2.3,flashed lazyflahser. Once completed I booted into twrp, finally I booted into miui system. After booted to miui, I pressed volume up and power button and my phone successfully booted into twrp recovery, this only way I was abled booted my phone to twrp from miui system. Please advices me my method correct or not? Thank.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] taco9:
I have no doubt ARB will be pushed to more phones and is here to stay. But very much doubt it will persist in its current form where hard bricking is the result of flashing older ROMs. Motorolas implementation imo is the proper way to do it, where ARB will just prevent installation without hard bricking.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] rEsonancE_0404:
And the question now is, how to go back to MIUI and remove the custom recovery. Does flashing full rom with the same build or higher will do the trick? Or flashing via MIflash, does it brick the device or not?

As OP said awhile ago, it is ok to switch roms as long as arb version is 4, so if I want to roll back to 8.8.2 (current rom is 8.8.9) is it ok? Will my device be ok?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] gr8techie:
Both 8.8.2 and 8.8.9 are on anti 4 so you can safely go back to 8.8.2 from 8.8.9. And yes, you can switch between different ROMs as long as the anti version is 4.

---------- Post added at 07:02 PM ---------- Previous post was at 06:51 PM ----------

Thanks for the info. BTW, you meant

fastboot getvar anti

Thanks a lot. :good:
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] sumon937:
I am in china stable ARB rom, My bootloader is unlocled. Can i go to global stable 9.5.19 with TWRP? I mean without fastboot flash?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] AL_IRAQI:
Just wipe data and flash back Miui

Why would you flash dummy to recovery ?!, you could end up bricking your phone by doing so!!

DUMMY is for fastboot commands unlock only, dont go flash is somewhere else

other than that everything is right

its will stay as is :P

Yup, just flash back full ROM if you're already running anti 4

Yeah, but flash global Cust first
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] rEsonancE_0404:
Finally, I cleared up my mind about this s**t implementation of xiaomi to their device

Heads up for this OP explanation, great work

And one more last question, why antirbpass is the command in the fastboot? Where does this image is exactly flashing? Does antirbpass partition is present in the table?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] JaggedPill:
How do I check anti rollback version on a new update/firmware that is to be updated/flashed. On my device/ current firmware version I've checked already.

---------- Post added at 06:28 AM ---------- Previous post was at 06:23 AM ----------

Big thanks again to [MENTION=4648515]AL_IRAQI[/MENTION] for saving my device.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] taco9:
ADB > fastboot getvar anti
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] The4anoni:
So if i am 9.6.2.0 i can downgrade to 9.5.19 ,right ?

Should i flash from Mi Flash or something else ?

Can i use fastboot rom from Xiaomi Site or should i use fw less version ?

I have anti 4
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] polik1:
Can someone confirm? I have brand new phone, I'm on Miui 9 9.5.17.0 and in order to flash custom ROM I need to:

1) unlock bootloader with MiUnlock (after 360 hours)

2) flash dummy.img via fastboot

3) flash TWRP wia fastboot

4) after reboot to TWRP I can flash anything I want (all custom roms and MIUI with anti>=4)

Can I flash latest firmwares from this https://xdaforums.com/redmi-note-5-pro/development/firmware-xiaomi-redmi-note-5-t3766138 thread? Will doing so delete TWRP recovery?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] The4anoni:
If you are on 9.5.17 you don't need to do these just unlock bootloader and flash as usual
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] Kalyan8106:
If you're on 9.6.2.0 download the 9.5.19.0 full ROM and flash it through updater it will flash bootloader is not to be unlocked it works on locked bootloader tooo
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] Ashish Banka:
I am on 8.7.26 can I flash fastboot rom 9.5.19.0 overit ?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] Kalyan8106:
Yess You can download the full ROM recovery zip and update it through the updater
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] drumandbassfreak:
Will this be necessary for Xiaomi.eu ROM's? Once the unlocking waitvhas passed I'm thinking to switch to this rom or maybe lineage OS
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] luminouche:
Hi

Can't flash V9.5.19.0 fastboot version

I'm on V9.5.17.0 rooted with TWRP installed, and i want to flash a fresh new V9.5.19.0 using Fastboot

When i put phone in Fastboot mode, "flash_all.bat" command opens a window, then immediatly close.

I have fastboot getvar = 3
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] kachrukamble:
I'm in similar situation, can anyone shed light on this ?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] rajumack07:
There are many replies to similar queries in so many places yet every one is asking, let me reply as this might help anyone:

1) Yes

2) not required as you are in ARB3. This is required if you have triggered ARB4 (fastboot commands are disabled in ARB4, so to enable them dummy img flash required).

3) Yes and then from the same fastboot console boot twrp from there to overrite twrp on miui recovery. This is a must step if you want twrp as recovery.

4)you can flash any custom roms but do a backup of miui and then clean install and then flash custom roms (follow custom rom installation steps as mentioned in their specific threads) . For miui, you should do fastboot flash of ARB4 roms to avoid any issues (for flashing twrp on ARB4, steps are different) or after step 3 and boring into twrp as i mentioned stay on ARB3 rom by flashing lazy flasher or magisk for root and then reboot to system.

Hope it helps

---------- Post added at 11:03 AM ---------- Previous post was at 11:01 AM ----------

There are many replies to similar queries in so many places yet every one is asking, let me reply as this might help anyone:

1) Yes

2) not required as you are in ARB3. This is required if you have triggered ARB4 (fastboot commands are disabled in ARB4, so to enable them dummy img flash required).

3) Yes and then from the same fastboot console boot twrp from there to overrite twrp on miui recovery. This is a must step if you want twrp as recovery.

4)you can flash any custom roms but do a backup of miui and then clean install and then flash custom roms (follow custom rom installation steps as mentioned in their specific threads) . For miui, you should do fastboot flash of ARB4 roms to avoid any issues (for flashing twrp on ARB4, steps are different) or after step 3 and boooting into twrp as i mentioned stay on ARB3 rom by flashing lazy flasher or magisk for root and then reboot to system.

Hope it helps
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] corkiejp:
First have you a global path setup on windows for ADB/Fastboot tools?

Second Instead of double clicking on the bat script, run it from a CMD/Powershell window : - .\flash_all.bat

Third why aren't you using Mi Flash, instead of trying the manual method?

What error are you getting in the second step post above?
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] luminouche:
Try by yourself

Unzip the tgz of a fastboot rom, and right click over "Flash_all.bat", run as admin.

It'll do the same job than MiFlash.

Never used MiFlash since i had my Redmi Note 3.

Anyway, i rebooted computer, then i flashed this way "old" 9.5.17.0

I installed TWRP (Fastboot flash recovery...) and the AL_IRAQI 9.5.19.0 zip, all is ok now.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] corkiejp:
[MENTION=629881]luminouche[/MENTION] I know how to use bat scripts. You said the window closed on you, for some reason there was an error and the script exited.

If you run the script from a CMD/Powershell window, you would have seen what caused the error.

Also bat scripts (with fastboot/adb commands) don't need admin permissions in windows.
[Xiaomi Redmi Note 5 Pro Guides, News, & Discussion] BiosCZ:
Guys? What do you think about this?

https://s22.postimg.cc/64bxxlp2p/Bez_n_zvu.png