Edit
Thanks to everyone in the commen section, lk.img
seems to be what I was looking for and it is indeed right, because it has strings for varies commands like
oem p2u
oem reboot-recovery
oem off-mode-charge
the lk.img
for my phone can be downloaded here
The only thing left is to reverse engineer
it but most programs I use cannot figure out what file type it is
Motive
I am trying to find the binary for fastboot mode
in my phone
So that I can understand what my phone 's vendor fastboot
does when I send
a command using fastboot protocol
what Have I Tried
1
I read fastboot's source code here
in the Android.bp
cc_binary {
name: "fastbootd",
defaults: ["fastboot_defaults"],
recovery: true,
product_variables: {
debuggable: {
cppflags: ["-DFB_ENABLE_FETCH"],
},
},
srcs: [
"device/commands.cpp",
"device/fastboot_device.cpp",
"device/flashing.cpp",
"device/main.cpp",
"device/usb.cpp",
"device/usb_client.cpp",
"device/tcp_client.cpp",
"device/utility.cpp",
"device/variables.cpp",
"socket.cpp",
],
it seems that the fastboot's program on the android phone will be compiled with name fastbootd
,
So I tried finding it by downloading my phone's official firmware and locating it using linux's find
but it doesn't seem to reside in the firmware
2
I have read similar question
But it didn't tell in more detail on how to get a copy of the binary and doesn't seem to have satisfactory answer
Phone details
Not sure if it matters because I think all android's fastboot
binary should be in the same location
Model Number : vivo1819
vivo ROM : Funtouch OS 10.5
Android version : 11
Hardware Version No. : MP_0.1
Software Version : PD1831F_EX_A_8.1.48
Firmware Download
https://drive.google.com/file/d/13coKM6yMS39MVRauyyZ7FO3B_twlTB1a/view?usp=sharing
Question
So how can I get my phone's fastboot
so that I can get a copy and learn more about it via reverse engineering
aboot
orabl
or something similar. The same can be extracted from firmware zip..img
. You need to reverse-engineer it. But better have a look at LK source code first. It's open-source. But it won't have OEM-specific changes.