[HELP] Unable to unlock bootloader

Search This thread

mi-saan

Member
Jun 12, 2022
32
4
Last edited:
  • Like
Reactions: MariferC

Kumar7873

Member
Apr 29, 2022
19
2
This is my first time posting on this forum, please do correct me if I'm doing something wrong or haven't provided some information I should have.

I have a Redmi 4 running MIUI Global 11.0.2 (NAMMIXM) which is about four years old and whose bootloader I've been trying to unlock for the past 2-3 days and running into issues.

I run linux on the system I use on a day to day basis, so my first option was XiaoMiTool V2. I enabled developer options, OEM unlocking, added my account in the Mi Unlock Status option and logged in successfully from within the tool but while running the operation to unlock the bootloader through it, I hit an error telling me that there was a serviceToken that was missing. I did find a thread on here that linked to a github issue for the tool, which recommends changing a line (or a few) in the source code and rebuilding the tool. I'm yet to try this, but I figured finding a windows laptop and using the official tool may be easier.

I got my hands on a laptop running windows 10 Pro and downloaded the mi unlock tool version 6.5.224.28 from the official website which when launched prompted me to get the latest version which was apparently 6.5.314.30. After logging in and fumbling around with the drivers for a bit, I got it to recognize my device in the fastboot mode and it finished verifying my device and launched the unlocking process but stopped when it reached 99% with the error "Can't get info, connect again". That's when I found some threads suggesting I enable Mi Cloud and Find My Device and did that, to no avail.

I logged into my Mi account in a browser and located my phone through it as a thread suggested and waited for more than a day (again, what seemed to have worked for someone in the thread). This time I tried with my PC with a clean install of windows 10 dual booted with linux. I still get the same thing error about not getting info, even using drivers installed using a previous version of Mi Unlock tool (the latest one seemed to be missing the program to install the drivers). I tried unlocking with previous versions of this tool too (3.5.1108.44, 4.5.813.51) but with them, on logging in I would just be taken to what seemed like would be my Mi Account page and left there with no obvious indication as to what I'm expected to do next - just connecting my device in the fastboot mode didn't seem to do anything.

I had a look at the logs of the Mi Unlock tool (latest version) :
Code:
2022-3-27 Version:6.5.314.30 Process<00003708> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Begin List Enviroment Variables.
...
DEBUG  <16:43:16.635,T:13496> : Login success and get user detail
DEBUG  <16:43:16.702,T:13496> : WA_AccountLogin
DEBUG  <16:43:16.702,T:14344> : WA_AccountLogin
DEBUG  <16:43:16.702,T:14344> : get set_check_page msg
DEBUG  <16:43:16.704,T:14344> : longin page switch to check page
DEBUG  <16:43:16.704,T:5844> : check right function start
DEBUG  <16:43:18.091,T:5844> : sign result:{
   "code" : 0,
   "descCN" : "成功",
   "descEN" : "success",
   "description" : "成功"
}

DEBUG  <16:43:31.699,T:14032> : auto refresh device list
DEBUG  <16:43:31.703,T:14032> : use desp:USB Composite Device instead of Android
DEBUG  <16:43:31.705,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
DEBUG  <16:43:31.709,T:14032> : new  usb\vid_2717&pid_ff48\6b803337d440
INFO   <16:43:31.709,T:14032> : fastboot devices
DEBUG  <16:43:31.816,T:14032> : auto refresh device list
DEBUG  <16:43:31.819,T:14032> : use desp:USB Composite Device instead of Android
DEBUG  <16:43:31.821,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
INFO   <16:43:31.824,T:14032> : fastboot devices
DEBUG  <16:43:31.931,T:14032> : auto refresh device list
DEBUG  <16:43:31.933,T:14032> : use desp:USB Composite Device instead of Android
DEBUG  <16:43:31.936,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
INFO   <16:43:31.938,T:14032> : fastboot devices
DEBUG  <16:43:32.102,T:14032> : auto refresh device list
DEBUG  <16:43:32.106,T:14032> : use desp:USB Composite Device instead of Android
DEBUG  <16:43:32.108,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
INFO   <16:43:32.111,T:14032> : fastboot devices
DEBUG  <16:43:37.662,T:14032> : auto refresh device list
INFO   <16:43:37.668,T:14032> : fastboot devices
DEBUG  <16:43:37.803,T:14032> : auto refresh device list
INFO   <16:43:37.807,T:14032> : fastboot devices
DEBUG  <16:43:43.906,T:14032> : auto refresh device list
DEBUG  <16:43:43.909,T:14032> : use desp:Android Bootloader Interface instead of Android
DEBUG  <16:43:43.912,T:14032> : new  usb\vid_18d1&pid_d00d\6b803337d440
INFO   <16:43:43.912,T:14032> : fastboot devices
DEBUG  <16:43:44.024,T:14032> : auto refresh device list
DEBUG  <16:43:44.025,T:13616> : -s 6b803337d440 oem device-info
DEBUG  <16:43:44.027,T:14032> : use desp:Android Bootloader Interface instead of Android
INFO   <16:43:44.029,T:14032> : fastboot devices
DEBUG  <16:43:44.165,T:13616> : (bootloader)     Device tampered: false
(bootloader)     Device unlocked: false
(bootloader)     Device critical unlocked: false
(bootloader)     Charger screen enabled: true
(bootloader)     Display panel: Ò’ƒ¾§EÈò5gggíxŠz ‰§fžÿ…§ÍåÊ3†”ÓMí£
OKAY [  0.006s]
Finished. Total time: 0.006s
DEBUG  <16:43:44.165,T:13616> :  getvar product -s 6b803337d440
DEBUG  <16:43:44.271,T:13616> : product: santoni
Finished. Total time: 0.001s
DEBUG  <16:43:44.272,T:13616> :  getvar tokenversion -s 6b803337d440
DEBUG  <16:43:44.384,T:13616> : tokenversion: 6b80333
Finished. Total time: 0.001s
INFO   <16:43:44.384,T:13616> : tokenversion: 6b80333
Finished. Total time: 0.001s
INFO   <16:43:44.384,T:13616> : tokenversion=6
DEBUG  <16:43:44.384,T:13616> :  oem get_token -s 6b803337d440
DEBUG  <16:43:44.612,T:13616> : FAILED (remote: 'unknown command')
fastboot: error: Command failed
INFO   <16:43:44.613,T:13616> : FAILED (remote: 'unknown command')
fastboot: error: Command failed
DEBUG  <16:43:44.613,T:13616> : to check erase feature for 6b803337d440
DEBUG  <16:43:44.615,T:13616> : Begin login unlockApi
ERROR  <16:43:46.310,T:13616> : 2 req url https://in-unlock.update.intl.miui.com/sts?d=bl_01f3e0e93ab5329dab777a9b453ac160&ticket=0&pwd=0&p_ts=1648379597000&fid=0&p_lm=2&auth=ALRhbCOwLwCVP4G8%2B0HGkyQJdN4UyJTLqcT%2FXwe0aZEIJ5gYJh7CgdEmYOyxwrtV1uFDOJ1YJF126OUqwXUTBK7EWkaiOs%2FF099ycMzhxjyTcwoySarBgXJq1hrfb7CNIgfCpo5%2Fejs7agoSOw69KB9XyjXbZThnEhC0V4g0V8g%3D&m=4&tsl=1&nonce=s5orK%2FNcr%2BgBozRh&_ssign=YFNhkFVWn%2FAUc6bTqDP1yWN9A68%3D&clientSign=xb1TM%2Fhxp16l5gPlyyiEEW7uZsg%3D
ERROR  <16:43:46.310,T:13616> : 2 req cookie
DEBUG  <16:43:46.615,T:13616> : End login unlockApi
DEBUG  <16:43:46.981,T:13616> : An unlocked device is an easy target for malware which may damage your device or cause financial loss.
DEBUG  <16:43:49.177,T:14344> : User click unlock button!
DEBUG  <16:43:54.794,T:13616> : -s 6b803337d440 oem device-info
DEBUG  <16:43:54.929,T:13616> : (bootloader)     Device tampered: false
(bootloader)     Device unlocked: false
(bootloader)     Device critical unlocked: false
(bootloader)     Charger screen enabled: true
(bootloader)     Display panel: Ò’ƒ¾§EÈò5gggíxŠz ‰§fžÿ…§ÍåÊ3†”ÓMí£
OKAY [  0.006s]
Finished. Total time: 0.006s
DEBUG  <16:43:59.808,T:13616> : VerifyDeviceInfo
INFO   <16:43:59.809,T:13616> : product:santoni
DEBUG  <16:43:59.810,T:13616> :  getvar tokenversion -s 6b803337d440
DEBUG  <16:43:59.948,T:13616> : tokenversion: 6b80333
Finished. Total time: 0.001s
INFO   <16:43:59.948,T:13616> : tokenversion: 6b80333
Finished. Total time: 0.001s
INFO   <16:43:59.948,T:13616> : tokenversion=6
DEBUG  <16:43:59.948,T:13616> :  oem get_token -s 6b803337d440
DEBUG  <16:44:00.058,T:13616> : FAILED (remote: 'unknown command')
fastboot: error: Command failed
INFO   <16:44:00.058,T:13616> : FAILED (remote: 'unknown command')
fastboot: error: Command failed
WARNING<16:44:00.058,T:13616> : Cannot get token.
INFO   <16:44:29.472,T:15240> : new app version:6.5.314.30 url:http://miuirom.xiaomi.com/rom/u1106245679/6.5.314.30/miflash_unlock-en-6.5.314.30.zip
DEBUG  <16:46:19.529,T:14032> : auto refresh device list
DEBUG  <16:46:19.537,T:14032> : remove usb\vid_18d1&pid_d00d\6b803337d440
INFO   <16:46:19.537,T:14032> : fastboot devices
DEBUG  <16:46:27.971,T:14344> : Close app after cef_close
DEBUG  <16:46:27.990,T:14344> : miflash_unlock exit
From what I can make out from it, it seems to me that running the oem command get_token is the point of failure but unfortunately, I have no idea what that command does or is supposed to do. I have tried running the fastboot commands that the log indicated that the tool was running from a powershell/command prompt window and they give me the same results (one thing I did notice while trying out some commands was that running "fastboot getvar all" seemed to give me a set of variables, one of which was called "token", but I'm not sure if that's relevant here).
I'm not sure how to go ahead diagnosing from here as I couldn't find much information about the oem commands of Xiaomi devices. I'm not sure if there's some step I'm missing in the process or if the latest version of the tool has something different that just doesn't work with my device.

I would greatly appreciate any help on this, either with things to do that might fix the issue or even just references to pages that might clear things up regarding the error I'm getting. Please do let me know if there's any other information I have to provide.

Thank you!
Have you tried this? https://xdaforums.com/t/unable-to-unlock-bootloader-resolved.4456861/page-2#post-87195799
 
  • Like
Reactions: Ofo79

Ofo79

New member
Aug 3, 2022
4
3
Hi,

yes this method worked for me... thanks for your help too ;)(y)

Check

Redmi4X.jpg
 
  • Like
Reactions: Kumar7873

overtunned

New member
Feb 12, 2020
4
0
Follow this : https://xdaforums.com/t/mi-unlock-tool-checking-for-security-issues-stuck.4414465/post-86728047
If this doesn't work for you.
Checking the logs: settings>log path>mi_unlock_flash.log
look for
Code:
DEBUG  <15:34:58.384,T:14760> : VerifyDeviceInfo
INFO   <15:34:58.384,T:14760> : product:santoni
DEBUG  <15:34:58.384,T:14760> :  getvar tokenversion -s <device_id>
DEBUG  <15:34:58.456,T:14760> : tokenversion: <your_version>
Finished. Total time: 0.001s
INFO   <15:34:58.456,T:14760> : tokenversion: <your_version>
Finished. Total time: 0.001s
INFO   <15:34:58.457,T:14760> : tokenversion=4
DEBUG  <15:34:58.457,T:14760> :  oem get_token -s <device_id>
DEBUG  <15:34:58.530,T:14760> : FAILED (remote: 'unknown command')
fastboot: error: Command failed
INFO   <15:34:58.530,T:14760> : FAILED (remote: 'unknown command')
fastboot: error: Command failed
WARNING<15:34:58.530,T:14760> : Cannot get token.

Code:
DEBUG  <15:34:58.457,T:14760> :  oem get_token -s <device_id>

It seems this command is not recognized by some devices. This version of the tool worked for me.

Mi Flash Unlock Tool v5.5.1224.27​



The log should look like this.

Code:
DEBUG  <16:04:43.817,T:4524> : VerifyDeviceInfo
INFO   <16:04:43.818,T:4524> : product:santoni
DEBUG  <16:04:43.818,T:4524> :  getvar tokenversion -s <device_id>
DEBUG  <16:04:43.896,T:4524> : tokenversion: <your_version>
finished. total time: 0.001s
INFO   <16:04:43.897,T:4524> : tokenversion: <your_version>
finished. total time: 0.001s
DEBUG  <16:04:43.897,T:4524> :  getvar token -s <device_id>
DEBUG  <16:04:43.972,T:4524> : token: <your_token>
finished. total time: 0.001s
INFO   <16:04:43.972,T:4524> : token: <your_token>
finished. total time: 0.001s

With that you should get your bootloader unlocked.

2022-10-02 (2).png
 

Infernus001e

New member
Apr 21, 2023
2
0
This is my first time posting on this forum, please do correct me if I'm doing something wrong or haven't provided some information I should have.

I have a Redmi 4 running MIUI Global 11.0.2 (NAMMIXM) which is about four years old and whose bootloader I've been trying to unlock for the past 2-3 days and running into issues.

I run linux on the system I use on a day to day basis, so my first option was XiaoMiTool V2. I enabled developer options, OEM unlocking, added my account in the Mi Unlock Status option and logged in successfully from within the tool but while running the operation to unlock the bootloader through it, I hit an error telling me that there was a serviceToken that was missing. I did find a thread on here that linked to a github issue for the tool, which recommends changing a line (or a few) in the source code and rebuilding the tool. I'm yet to try this, but I figured finding a windows laptop and using the official tool may be easier.

I got my hands on a laptop running windows 10 Pro and downloaded the mi unlock tool version 6.5.224.28 from the official website which when launched prompted me to get the latest version which was apparently 6.5.314.30. After logging in and fumbling around with the drivers for a bit, I got it to recognize my device in the fastboot mode and it finished verifying my device and launched the unlocking process but stopped when it reached 99% with the error "Can't get info, connect again". That's when I found some threads suggesting I enable Mi Cloud and Find My Device and did that, to no avail.

I logged into my Mi account in a browser and located my phone through it as a thread suggested and waited for more than a day (again, what seemed to have worked for someone in the thread). This time I tried with my PC with a clean install of windows 10 dual booted with linux. I still get the same thing error about not getting info, even using drivers installed using a previous version of Mi Unlock tool (the latest one seemed to be missing the program to install the drivers). I tried unlocking with previous versions of this tool too (3.5.1108.44, 4.5.813.51) but with them, on logging in I would just be taken to what seemed like would be my Mi Account page and left there with no obvious indication as to what I'm expected to do next - just connecting my device in the fastboot mode didn't seem to do anything.

I had a look at the logs of the Mi Unlock tool (latest version) :
Code:
2022-3-27 Version:6.5.314.30 Process<00003708> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Begin List Enviroment Variables.
...
DEBUG  <16:43:16.635,T:13496> : Login success and get user detail
DEBUG  <16:43:16.702,T:13496> : WA_AccountLogin
DEBUG  <16:43:16.702,T:14344> : WA_AccountLogin
DEBUG  <16:43:16.702,T:14344> : get set_check_page msg
DEBUG  <16:43:16.704,T:14344> : longin page switch to check page
DEBUG  <16:43:16.704,T:5844> : check right function start
DEBUG  <16:43:18.091,T:5844> : sign result:{
   "code" : 0,
   "descCN" : "成功",
   "descEN" : "success",
   "description" : "成功"
}

DEBUG  <16:43:31.699,T:14032> : auto refresh device list
DEBUG  <16:43:31.703,T:14032> : use desp:USB Composite Device instead of Android
DEBUG  <16:43:31.705,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
DEBUG  <16:43:31.709,T:14032> : new  usb\vid_2717&pid_ff48\6b803337d440
INFO   <16:43:31.709,T:14032> : fastboot devices
DEBUG  <16:43:31.816,T:14032> : auto refresh device list
DEBUG  <16:43:31.819,T:14032> : use desp:USB Composite Device instead of Android
DEBUG  <16:43:31.821,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
INFO   <16:43:31.824,T:14032> : fastboot devices
DEBUG  <16:43:31.931,T:14032> : auto refresh device list
DEBUG  <16:43:31.933,T:14032> : use desp:USB Composite Device instead of Android
DEBUG  <16:43:31.936,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
INFO   <16:43:31.938,T:14032> : fastboot devices
DEBUG  <16:43:32.102,T:14032> : auto refresh device list
DEBUG  <16:43:32.106,T:14032> : use desp:USB Composite Device instead of Android
DEBUG  <16:43:32.108,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
INFO   <16:43:32.111,T:14032> : fastboot devices
DEBUG  <16:43:37.662,T:14032> : auto refresh device list
INFO   <16:43:37.668,T:14032> : fastboot devices
DEBUG  <16:43:37.803,T:14032> : auto refresh device list
INFO   <16:43:37.807,T:14032> : fastboot devices
DEBUG  <16:43:43.906,T:14032> : auto refresh device list
DEBUG  <16:43:43.909,T:14032> : use desp:Android Bootloader Interface instead of Android
DEBUG  <16:43:43.912,T:14032> : new  usb\vid_18d1&pid_d00d\6b803337d440
INFO   <16:43:43.912,T:14032> : fastboot devices
DEBUG  <16:43:44.024,T:14032> : auto refresh device list
DEBUG  <16:43:44.025,T:13616> : -s 6b803337d440 oem device-info
DEBUG  <16:43:44.027,T:14032> : use desp:Android Bootloader Interface instead of Android
INFO   <16:43:44.029,T:14032> : fastboot devices
DEBUG  <16:43:44.165,T:13616> : (bootloader)     Device tampered: false
(bootloader)     Device unlocked: false
(bootloader)     Device critical unlocked: false
(bootloader)     Charger screen enabled: true
(bootloader)     Display panel: Ò’ƒ¾§EÈò5gggíxŠz ‰§fžÿ…§ÍåÊ3†”ÓMí£
OKAY [  0.006s]
Finished. Total time: 0.006s
DEBUG  <16:43:44.165,T:13616> :  getvar product -s 6b803337d440
DEBUG  <16:43:44.271,T:13616> : product: santoni
Finished. Total time: 0.001s
DEBUG  <16:43:44.272,T:13616> :  getvar tokenversion -s 6b803337d440
DEBUG  <16:43:44.384,T:13616> : tokenversion: 6b80333
Finished. Total time: 0.001s
INFO   <16:43:44.384,T:13616> : tokenversion: 6b80333
Finished. Total time: 0.001s
INFO   <16:43:44.384,T:13616> : tokenversion=6
DEBUG  <16:43:44.384,T:13616> :  oem get_token -s 6b803337d440
DEBUG  <16:43:44.612,T:13616> : FAILED (remote: 'unknown command')
fastboot: error: Command failed
INFO   <16:43:44.613,T:13616> : FAILED (remote: 'unknown command')
fastboot: error: Command failed
DEBUG  <16:43:44.613,T:13616> : to check erase feature for 6b803337d440
DEBUG  <16:43:44.615,T:13616> : Begin login unlockApi
ERROR  <16:43:46.310,T:13616> : 2 req url https://in-unlock.update.intl.miui.com/sts?d=bl_01f3e0e93ab5329dab777a9b453ac160&ticket=0&pwd=0&p_ts=1648379597000&fid=0&p_lm=2&auth=ALRhbCOwLwCVP4G8%2B0HGkyQJdN4UyJTLqcT%2FXwe0aZEIJ5gYJh7CgdEmYOyxwrtV1uFDOJ1YJF126OUqwXUTBK7EWkaiOs%2FF099ycMzhxjyTcwoySarBgXJq1hrfb7CNIgfCpo5%2Fejs7agoSOw69KB9XyjXbZThnEhC0V4g0V8g%3D&m=4&tsl=1&nonce=s5orK%2FNcr%2BgBozRh&_ssign=YFNhkFVWn%2FAUc6bTqDP1yWN9A68%3D&clientSign=xb1TM%2Fhxp16l5gPlyyiEEW7uZsg%3D
ERROR  <16:43:46.310,T:13616> : 2 req cookie
DEBUG  <16:43:46.615,T:13616> : End login unlockApi
DEBUG  <16:43:46.981,T:13616> : An unlocked device is an easy target for malware which may damage your device or cause financial loss.
DEBUG  <16:43:49.177,T:14344> : User click unlock button!
DEBUG  <16:43:54.794,T:13616> : -s 6b803337d440 oem device-info
DEBUG  <16:43:54.929,T:13616> : (bootloader)     Device tampered: false
(bootloader)     Device unlocked: false
(bootloader)     Device critical unlocked: false
(bootloader)     Charger screen enabled: true
(bootloader)     Display panel: Ò’ƒ¾§EÈò5gggíxŠz ‰§fžÿ…§ÍåÊ3†”ÓMí£
OKAY [  0.006s]
Finished. Total time: 0.006s
DEBUG  <16:43:59.808,T:13616> : VerifyDeviceInfo
INFO   <16:43:59.809,T:13616> : product:santoni
DEBUG  <16:43:59.810,T:13616> :  getvar tokenversion -s 6b803337d440
DEBUG  <16:43:59.948,T:13616> : tokenversion: 6b80333
Finished. Total time: 0.001s
INFO   <16:43:59.948,T:13616> : tokenversion: 6b80333
Finished. Total time: 0.001s
INFO   <16:43:59.948,T:13616> : tokenversion=6
DEBUG  <16:43:59.948,T:13616> :  oem get_token -s 6b803337d440
DEBUG  <16:44:00.058,T:13616> : FAILED (remote: 'unknown command')
fastboot: error: Command failed
INFO   <16:44:00.058,T:13616> : FAILED (remote: 'unknown command')
fastboot: error: Command failed
WARNING<16:44:00.058,T:13616> : Cannot get token.
INFO   <16:44:29.472,T:15240> : new app version:6.5.314.30 url:http://miuirom.xiaomi.com/rom/u1106245679/6.5.314.30/miflash_unlock-en-6.5.314.30.zip
DEBUG  <16:46:19.529,T:14032> : auto refresh device list
DEBUG  <16:46:19.537,T:14032> : remove usb\vid_18d1&pid_d00d\6b803337d440
INFO   <16:46:19.537,T:14032> : fastboot devices
DEBUG  <16:46:27.971,T:14344> : Close app after cef_close
DEBUG  <16:46:27.990,T:14344> : miflash_unlock exit
From what I can make out from it, it seems to me that running the oem command get_token is the point of failure but unfortunately, I have no idea what that command does or is supposed to do. I have tried running the fastboot commands that the log indicated that the tool was running from a powershell/command prompt window and they give me the same results (one thing I did notice while trying out some commands was that running "fastboot getvar all" seemed to give me a set of variables, one of which was called "token", but I'm not sure if that's relevant here).
I'm not sure how to go ahead diagnosing from here as I couldn't find much information about the oem commands of Xiaomi devices. I'm not sure if there's some step I'm missing in the process or if the latest version of the tool has something different that just doesn't work with my device.

I would greatly appreciate any help on this, either with things to do that might fix the issue or even just references to pages that might clear things up regarding the error I'm getting. Please do let me know if there's any other information I have to provide.

Thank you!
I also faced the same problem but I got my solution
I clicked unlock and when it started, I unplugged device and it reached 99% and stuck then I just plugged my device and it unlocked instantly
 

Top Liked Posts

  • There are no posts matching your filters.
  • 1
    Thank you for the reply.

    I went through all the steps that you mentioned right from my first attempt at unlocking the boot loader and have made sure that OEM unlocking and USB debugging have stayed on.

    I have added my mi account in the mi unlocking status too, and done so multiple times (using mobile data each time, according to the instructions given on the mi unlock status page), having received confirmation that it was added each time (I even tried logging out and back in to my mi account a few times, before adding it in the mi unlocking status again of course).

    If I had got a wait time, I would be happy to wait but unfortunately I haven’t received one, which leaves me unsure of whether just waiting will solve the issue. Each time it stops and fails at 99% and gives me the error described in my first post.
    1
    This is my first time posting on this forum, please do correct me if I'm doing something wrong or haven't provided some information I should have.

    I have a Redmi 4 running MIUI Global 11.0.2 (NAMMIXM) which is about four years old and whose bootloader I've been trying to unlock for the past 2-3 days and running into issues.

    I run linux on the system I use on a day to day basis, so my first option was XiaoMiTool V2. I enabled developer options, OEM unlocking, added my account in the Mi Unlock Status option and logged in successfully from within the tool but while running the operation to unlock the bootloader through it, I hit an error telling me that there was a serviceToken that was missing. I did find a thread on here that linked to a github issue for the tool, which recommends changing a line (or a few) in the source code and rebuilding the tool. I'm yet to try this, but I figured finding a windows laptop and using the official tool may be easier.

    I got my hands on a laptop running windows 10 Pro and downloaded the mi unlock tool version 6.5.224.28 from the official website which when launched prompted me to get the latest version which was apparently 6.5.314.30. After logging in and fumbling around with the drivers for a bit, I got it to recognize my device in the fastboot mode and it finished verifying my device and launched the unlocking process but stopped when it reached 99% with the error "Can't get info, connect again". That's when I found some threads suggesting I enable Mi Cloud and Find My Device and did that, to no avail.

    I logged into my Mi account in a browser and located my phone through it as a thread suggested and waited for more than a day (again, what seemed to have worked for someone in the thread). This time I tried with my PC with a clean install of windows 10 dual booted with linux. I still get the same thing error about not getting info, even using drivers installed using a previous version of Mi Unlock tool (the latest one seemed to be missing the program to install the drivers). I tried unlocking with previous versions of this tool too (3.5.1108.44, 4.5.813.51) but with them, on logging in I would just be taken to what seemed like would be my Mi Account page and left there with no obvious indication as to what I'm expected to do next - just connecting my device in the fastboot mode didn't seem to do anything.

    I had a look at the logs of the Mi Unlock tool (latest version) :
    Code:
    2022-3-27 Version:6.5.314.30 Process<00003708> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
    Begin List Enviroment Variables.
    ...
    DEBUG  <16:43:16.635,T:13496> : Login success and get user detail
    DEBUG  <16:43:16.702,T:13496> : WA_AccountLogin
    DEBUG  <16:43:16.702,T:14344> : WA_AccountLogin
    DEBUG  <16:43:16.702,T:14344> : get set_check_page msg
    DEBUG  <16:43:16.704,T:14344> : longin page switch to check page
    DEBUG  <16:43:16.704,T:5844> : check right function start
    DEBUG  <16:43:18.091,T:5844> : sign result:{
       "code" : 0,
       "descCN" : "成功",
       "descEN" : "success",
       "description" : "成功"
    }
    
    DEBUG  <16:43:31.699,T:14032> : auto refresh device list
    DEBUG  <16:43:31.703,T:14032> : use desp:USB Composite Device instead of Android
    DEBUG  <16:43:31.705,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
    DEBUG  <16:43:31.709,T:14032> : new  usb\vid_2717&pid_ff48\6b803337d440
    INFO   <16:43:31.709,T:14032> : fastboot devices
    DEBUG  <16:43:31.816,T:14032> : auto refresh device list
    DEBUG  <16:43:31.819,T:14032> : use desp:USB Composite Device instead of Android
    DEBUG  <16:43:31.821,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
    INFO   <16:43:31.824,T:14032> : fastboot devices
    DEBUG  <16:43:31.931,T:14032> : auto refresh device list
    DEBUG  <16:43:31.933,T:14032> : use desp:USB Composite Device instead of Android
    DEBUG  <16:43:31.936,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
    INFO   <16:43:31.938,T:14032> : fastboot devices
    DEBUG  <16:43:32.102,T:14032> : auto refresh device list
    DEBUG  <16:43:32.106,T:14032> : use desp:USB Composite Device instead of Android
    DEBUG  <16:43:32.108,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
    INFO   <16:43:32.111,T:14032> : fastboot devices
    DEBUG  <16:43:37.662,T:14032> : auto refresh device list
    INFO   <16:43:37.668,T:14032> : fastboot devices
    DEBUG  <16:43:37.803,T:14032> : auto refresh device list
    INFO   <16:43:37.807,T:14032> : fastboot devices
    DEBUG  <16:43:43.906,T:14032> : auto refresh device list
    DEBUG  <16:43:43.909,T:14032> : use desp:Android Bootloader Interface instead of Android
    DEBUG  <16:43:43.912,T:14032> : new  usb\vid_18d1&pid_d00d\6b803337d440
    INFO   <16:43:43.912,T:14032> : fastboot devices
    DEBUG  <16:43:44.024,T:14032> : auto refresh device list
    DEBUG  <16:43:44.025,T:13616> : -s 6b803337d440 oem device-info
    DEBUG  <16:43:44.027,T:14032> : use desp:Android Bootloader Interface instead of Android
    INFO   <16:43:44.029,T:14032> : fastboot devices
    DEBUG  <16:43:44.165,T:13616> : (bootloader)     Device tampered: false
    (bootloader)     Device unlocked: false
    (bootloader)     Device critical unlocked: false
    (bootloader)     Charger screen enabled: true
    (bootloader)     Display panel: Ò’ƒ¾§EÈò5gggíxŠz ‰§fžÿ…§ÍåÊ3†”ÓMí£
    OKAY [  0.006s]
    Finished. Total time: 0.006s
    DEBUG  <16:43:44.165,T:13616> :  getvar product -s 6b803337d440
    DEBUG  <16:43:44.271,T:13616> : product: santoni
    Finished. Total time: 0.001s
    DEBUG  <16:43:44.272,T:13616> :  getvar tokenversion -s 6b803337d440
    DEBUG  <16:43:44.384,T:13616> : tokenversion: 6b80333
    Finished. Total time: 0.001s
    INFO   <16:43:44.384,T:13616> : tokenversion: 6b80333
    Finished. Total time: 0.001s
    INFO   <16:43:44.384,T:13616> : tokenversion=6
    DEBUG  <16:43:44.384,T:13616> :  oem get_token -s 6b803337d440
    DEBUG  <16:43:44.612,T:13616> : FAILED (remote: 'unknown command')
    fastboot: error: Command failed
    INFO   <16:43:44.613,T:13616> : FAILED (remote: 'unknown command')
    fastboot: error: Command failed
    DEBUG  <16:43:44.613,T:13616> : to check erase feature for 6b803337d440
    DEBUG  <16:43:44.615,T:13616> : Begin login unlockApi
    ERROR  <16:43:46.310,T:13616> : 2 req url https://in-unlock.update.intl.miui.com/sts?d=bl_01f3e0e93ab5329dab777a9b453ac160&ticket=0&pwd=0&p_ts=1648379597000&fid=0&p_lm=2&auth=ALRhbCOwLwCVP4G8%2B0HGkyQJdN4UyJTLqcT%2FXwe0aZEIJ5gYJh7CgdEmYOyxwrtV1uFDOJ1YJF126OUqwXUTBK7EWkaiOs%2FF099ycMzhxjyTcwoySarBgXJq1hrfb7CNIgfCpo5%2Fejs7agoSOw69KB9XyjXbZThnEhC0V4g0V8g%3D&m=4&tsl=1&nonce=s5orK%2FNcr%2BgBozRh&_ssign=YFNhkFVWn%2FAUc6bTqDP1yWN9A68%3D&clientSign=xb1TM%2Fhxp16l5gPlyyiEEW7uZsg%3D
    ERROR  <16:43:46.310,T:13616> : 2 req cookie
    DEBUG  <16:43:46.615,T:13616> : End login unlockApi
    DEBUG  <16:43:46.981,T:13616> : An unlocked device is an easy target for malware which may damage your device or cause financial loss.
    DEBUG  <16:43:49.177,T:14344> : User click unlock button!
    DEBUG  <16:43:54.794,T:13616> : -s 6b803337d440 oem device-info
    DEBUG  <16:43:54.929,T:13616> : (bootloader)     Device tampered: false
    (bootloader)     Device unlocked: false
    (bootloader)     Device critical unlocked: false
    (bootloader)     Charger screen enabled: true
    (bootloader)     Display panel: Ò’ƒ¾§EÈò5gggíxŠz ‰§fžÿ…§ÍåÊ3†”ÓMí£
    OKAY [  0.006s]
    Finished. Total time: 0.006s
    DEBUG  <16:43:59.808,T:13616> : VerifyDeviceInfo
    INFO   <16:43:59.809,T:13616> : product:santoni
    DEBUG  <16:43:59.810,T:13616> :  getvar tokenversion -s 6b803337d440
    DEBUG  <16:43:59.948,T:13616> : tokenversion: 6b80333
    Finished. Total time: 0.001s
    INFO   <16:43:59.948,T:13616> : tokenversion: 6b80333
    Finished. Total time: 0.001s
    INFO   <16:43:59.948,T:13616> : tokenversion=6
    DEBUG  <16:43:59.948,T:13616> :  oem get_token -s 6b803337d440
    DEBUG  <16:44:00.058,T:13616> : FAILED (remote: 'unknown command')
    fastboot: error: Command failed
    INFO   <16:44:00.058,T:13616> : FAILED (remote: 'unknown command')
    fastboot: error: Command failed
    WARNING<16:44:00.058,T:13616> : Cannot get token.
    INFO   <16:44:29.472,T:15240> : new app version:6.5.314.30 url:http://miuirom.xiaomi.com/rom/u1106245679/6.5.314.30/miflash_unlock-en-6.5.314.30.zip
    DEBUG  <16:46:19.529,T:14032> : auto refresh device list
    DEBUG  <16:46:19.537,T:14032> : remove usb\vid_18d1&pid_d00d\6b803337d440
    INFO   <16:46:19.537,T:14032> : fastboot devices
    DEBUG  <16:46:27.971,T:14344> : Close app after cef_close
    DEBUG  <16:46:27.990,T:14344> : miflash_unlock exit
    From what I can make out from it, it seems to me that running the oem command get_token is the point of failure but unfortunately, I have no idea what that command does or is supposed to do. I have tried running the fastboot commands that the log indicated that the tool was running from a powershell/command prompt window and they give me the same results (one thing I did notice while trying out some commands was that running "fastboot getvar all" seemed to give me a set of variables, one of which was called "token", but I'm not sure if that's relevant here).
    I'm not sure how to go ahead diagnosing from here as I couldn't find much information about the oem commands of Xiaomi devices. I'm not sure if there's some step I'm missing in the process or if the latest version of the tool has something different that just doesn't work with my device.

    I would greatly appreciate any help on this, either with things to do that might fix the issue or even just references to pages that might clear things up regarding the error I'm getting. Please do let me know if there's any other information I have to provide.

    Thank you!
    Hey. I'm also affected by this issue. I have waited about a week before trying to unlock the bootloader again, but with no success. Have you tried to unlock your bootloader recently?
    1
    Is there any other unofficial app to unlock bootloader of redmi devices except xiaomi unlock tool v2
    1
    Did you try this : https://xdaforums.com/t/mi-unlock-tool-checking-for-security-issues-stuck.4414465/post-86714179
    I had the same "can't get info, connect again" problem and it worked for me.
    tried the tool mentioned there.
    can't login using qr code as it never moves forward after this step:

    @ro-jc did you find any solution yet?

    1
    This is my first time posting on this forum, please do correct me if I'm doing something wrong or haven't provided some information I should have.

    I have a Redmi 4 running MIUI Global 11.0.2 (NAMMIXM) which is about four years old and whose bootloader I've been trying to unlock for the past 2-3 days and running into issues.

    I run linux on the system I use on a day to day basis, so my first option was XiaoMiTool V2. I enabled developer options, OEM unlocking, added my account in the Mi Unlock Status option and logged in successfully from within the tool but while running the operation to unlock the bootloader through it, I hit an error telling me that there was a serviceToken that was missing. I did find a thread on here that linked to a github issue for the tool, which recommends changing a line (or a few) in the source code and rebuilding the tool. I'm yet to try this, but I figured finding a windows laptop and using the official tool may be easier.

    I got my hands on a laptop running windows 10 Pro and downloaded the mi unlock tool version 6.5.224.28 from the official website which when launched prompted me to get the latest version which was apparently 6.5.314.30. After logging in and fumbling around with the drivers for a bit, I got it to recognize my device in the fastboot mode and it finished verifying my device and launched the unlocking process but stopped when it reached 99% with the error "Can't get info, connect again". That's when I found some threads suggesting I enable Mi Cloud and Find My Device and did that, to no avail.

    I logged into my Mi account in a browser and located my phone through it as a thread suggested and waited for more than a day (again, what seemed to have worked for someone in the thread). This time I tried with my PC with a clean install of windows 10 dual booted with linux. I still get the same thing error about not getting info, even using drivers installed using a previous version of Mi Unlock tool (the latest one seemed to be missing the program to install the drivers). I tried unlocking with previous versions of this tool too (3.5.1108.44, 4.5.813.51) but with them, on logging in I would just be taken to what seemed like would be my Mi Account page and left there with no obvious indication as to what I'm expected to do next - just connecting my device in the fastboot mode didn't seem to do anything.

    I had a look at the logs of the Mi Unlock tool (latest version) :
    Code:
    2022-3-27 Version:6.5.314.30 Process<00003708> >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
    Begin List Enviroment Variables.
    ...
    DEBUG  <16:43:16.635,T:13496> : Login success and get user detail
    DEBUG  <16:43:16.702,T:13496> : WA_AccountLogin
    DEBUG  <16:43:16.702,T:14344> : WA_AccountLogin
    DEBUG  <16:43:16.702,T:14344> : get set_check_page msg
    DEBUG  <16:43:16.704,T:14344> : longin page switch to check page
    DEBUG  <16:43:16.704,T:5844> : check right function start
    DEBUG  <16:43:18.091,T:5844> : sign result:{
       "code" : 0,
       "descCN" : "成功",
       "descEN" : "success",
       "description" : "成功"
    }
    
    DEBUG  <16:43:31.699,T:14032> : auto refresh device list
    DEBUG  <16:43:31.703,T:14032> : use desp:USB Composite Device instead of Android
    DEBUG  <16:43:31.705,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
    DEBUG  <16:43:31.709,T:14032> : new  usb\vid_2717&pid_ff48\6b803337d440
    INFO   <16:43:31.709,T:14032> : fastboot devices
    DEBUG  <16:43:31.816,T:14032> : auto refresh device list
    DEBUG  <16:43:31.819,T:14032> : use desp:USB Composite Device instead of Android
    DEBUG  <16:43:31.821,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
    INFO   <16:43:31.824,T:14032> : fastboot devices
    DEBUG  <16:43:31.931,T:14032> : auto refresh device list
    DEBUG  <16:43:31.933,T:14032> : use desp:USB Composite Device instead of Android
    DEBUG  <16:43:31.936,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
    INFO   <16:43:31.938,T:14032> : fastboot devices
    DEBUG  <16:43:32.102,T:14032> : auto refresh device list
    DEBUG  <16:43:32.106,T:14032> : use desp:USB Composite Device instead of Android
    DEBUG  <16:43:32.108,T:14032> : use desp:Android Composite ADB Interface instead of ADB Interface
    INFO   <16:43:32.111,T:14032> : fastboot devices
    DEBUG  <16:43:37.662,T:14032> : auto refresh device list
    INFO   <16:43:37.668,T:14032> : fastboot devices
    DEBUG  <16:43:37.803,T:14032> : auto refresh device list
    INFO   <16:43:37.807,T:14032> : fastboot devices
    DEBUG  <16:43:43.906,T:14032> : auto refresh device list
    DEBUG  <16:43:43.909,T:14032> : use desp:Android Bootloader Interface instead of Android
    DEBUG  <16:43:43.912,T:14032> : new  usb\vid_18d1&pid_d00d\6b803337d440
    INFO   <16:43:43.912,T:14032> : fastboot devices
    DEBUG  <16:43:44.024,T:14032> : auto refresh device list
    DEBUG  <16:43:44.025,T:13616> : -s 6b803337d440 oem device-info
    DEBUG  <16:43:44.027,T:14032> : use desp:Android Bootloader Interface instead of Android
    INFO   <16:43:44.029,T:14032> : fastboot devices
    DEBUG  <16:43:44.165,T:13616> : (bootloader)     Device tampered: false
    (bootloader)     Device unlocked: false
    (bootloader)     Device critical unlocked: false
    (bootloader)     Charger screen enabled: true
    (bootloader)     Display panel: Ò’ƒ¾§EÈò5gggíxŠz ‰§fžÿ…§ÍåÊ3†”ÓMí£
    OKAY [  0.006s]
    Finished. Total time: 0.006s
    DEBUG  <16:43:44.165,T:13616> :  getvar product -s 6b803337d440
    DEBUG  <16:43:44.271,T:13616> : product: santoni
    Finished. Total time: 0.001s
    DEBUG  <16:43:44.272,T:13616> :  getvar tokenversion -s 6b803337d440
    DEBUG  <16:43:44.384,T:13616> : tokenversion: 6b80333
    Finished. Total time: 0.001s
    INFO   <16:43:44.384,T:13616> : tokenversion: 6b80333
    Finished. Total time: 0.001s
    INFO   <16:43:44.384,T:13616> : tokenversion=6
    DEBUG  <16:43:44.384,T:13616> :  oem get_token -s 6b803337d440
    DEBUG  <16:43:44.612,T:13616> : FAILED (remote: 'unknown command')
    fastboot: error: Command failed
    INFO   <16:43:44.613,T:13616> : FAILED (remote: 'unknown command')
    fastboot: error: Command failed
    DEBUG  <16:43:44.613,T:13616> : to check erase feature for 6b803337d440
    DEBUG  <16:43:44.615,T:13616> : Begin login unlockApi
    ERROR  <16:43:46.310,T:13616> : 2 req url https://in-unlock.update.intl.miui.com/sts?d=bl_01f3e0e93ab5329dab777a9b453ac160&ticket=0&pwd=0&p_ts=1648379597000&fid=0&p_lm=2&auth=ALRhbCOwLwCVP4G8%2B0HGkyQJdN4UyJTLqcT%2FXwe0aZEIJ5gYJh7CgdEmYOyxwrtV1uFDOJ1YJF126OUqwXUTBK7EWkaiOs%2FF099ycMzhxjyTcwoySarBgXJq1hrfb7CNIgfCpo5%2Fejs7agoSOw69KB9XyjXbZThnEhC0V4g0V8g%3D&m=4&tsl=1&nonce=s5orK%2FNcr%2BgBozRh&_ssign=YFNhkFVWn%2FAUc6bTqDP1yWN9A68%3D&clientSign=xb1TM%2Fhxp16l5gPlyyiEEW7uZsg%3D
    ERROR  <16:43:46.310,T:13616> : 2 req cookie
    DEBUG  <16:43:46.615,T:13616> : End login unlockApi
    DEBUG  <16:43:46.981,T:13616> : An unlocked device is an easy target for malware which may damage your device or cause financial loss.
    DEBUG  <16:43:49.177,T:14344> : User click unlock button!
    DEBUG  <16:43:54.794,T:13616> : -s 6b803337d440 oem device-info
    DEBUG  <16:43:54.929,T:13616> : (bootloader)     Device tampered: false
    (bootloader)     Device unlocked: false
    (bootloader)     Device critical unlocked: false
    (bootloader)     Charger screen enabled: true
    (bootloader)     Display panel: Ò’ƒ¾§EÈò5gggíxŠz ‰§fžÿ…§ÍåÊ3†”ÓMí£
    OKAY [  0.006s]
    Finished. Total time: 0.006s
    DEBUG  <16:43:59.808,T:13616> : VerifyDeviceInfo
    INFO   <16:43:59.809,T:13616> : product:santoni
    DEBUG  <16:43:59.810,T:13616> :  getvar tokenversion -s 6b803337d440
    DEBUG  <16:43:59.948,T:13616> : tokenversion: 6b80333
    Finished. Total time: 0.001s
    INFO   <16:43:59.948,T:13616> : tokenversion: 6b80333
    Finished. Total time: 0.001s
    INFO   <16:43:59.948,T:13616> : tokenversion=6
    DEBUG  <16:43:59.948,T:13616> :  oem get_token -s 6b803337d440
    DEBUG  <16:44:00.058,T:13616> : FAILED (remote: 'unknown command')
    fastboot: error: Command failed
    INFO   <16:44:00.058,T:13616> : FAILED (remote: 'unknown command')
    fastboot: error: Command failed
    WARNING<16:44:00.058,T:13616> : Cannot get token.
    INFO   <16:44:29.472,T:15240> : new app version:6.5.314.30 url:http://miuirom.xiaomi.com/rom/u1106245679/6.5.314.30/miflash_unlock-en-6.5.314.30.zip
    DEBUG  <16:46:19.529,T:14032> : auto refresh device list
    DEBUG  <16:46:19.537,T:14032> : remove usb\vid_18d1&pid_d00d\6b803337d440
    INFO   <16:46:19.537,T:14032> : fastboot devices
    DEBUG  <16:46:27.971,T:14344> : Close app after cef_close
    DEBUG  <16:46:27.990,T:14344> : miflash_unlock exit
    From what I can make out from it, it seems to me that running the oem command get_token is the point of failure but unfortunately, I have no idea what that command does or is supposed to do. I have tried running the fastboot commands that the log indicated that the tool was running from a powershell/command prompt window and they give me the same results (one thing I did notice while trying out some commands was that running "fastboot getvar all" seemed to give me a set of variables, one of which was called "token", but I'm not sure if that's relevant here).
    I'm not sure how to go ahead diagnosing from here as I couldn't find much information about the oem commands of Xiaomi devices. I'm not sure if there's some step I'm missing in the process or if the latest version of the tool has something different that just doesn't work with my device.

    I would greatly appreciate any help on this, either with things to do that might fix the issue or even just references to pages that might clear things up regarding the error I'm getting. Please do let me know if there's any other information I have to provide.

    Thank you!
    Have you tried this? https://xdaforums.com/t/unable-to-unlock-bootloader-resolved.4456861/page-2#post-87195799