joyce8/EMBER2024-capa huggingface dataset:
Function at 0x44b440
Capabilities:
Access peb ldr_data
Get number of processors

Disassembly:
push 0xffffffffffffffff
push 0x47fd13
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
push ebp
push esi
mov esi, ecx
push edi
mov dword [esp + 0xc], esi
call fcn.00472db4
lea edi, [esi + 0x64]
mov dword [esp + 0x18], 0
mov dword [edi + 4], 0
mov dword [edi], 0x12aec70
mov eax, dword [esp + 0x2c]
mov ebp, dword [esp + 0x24]
mov ecx, dword [esp + 0x30]
mov dword [esi + 0x3c], eax
mov eax, ebp
mov dword [esi], 0x12ad780
mov dword [esi + 0x40], ecx
mov dword [esi + 0x44], 0
mov ecx, dword [eax]
lea edx, [esi + 0x48]
mov byte [esp + 0x18], 1
mov dword [edx], ecx
mov ecx, dword [eax + 4]
mov dword [edx + 4], ecx
mov ecx, dword [eax + 8]
mov dword [edx + 8], ecx
mov eax, dword [eax + 0xc]
mov ecx, dword [esp + 0x40]
mov dword [edx + 0xc], eax
mov eax, dword [esp + 0x44]
push eax
mov dword [esi + 0x5c], ecx
mov dword [esi + 0x60], eax
call dword [0x48208c]
push eax
mov ecx, edi
call fcn.00478453
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x20]
push edx
push eax
push ebp
push 0x50800044
mov ecx, esi
call fcn.004799b2
test eax, eax
je 0x44b55c
mov ecx, dword [esp + 0x3c]
call fcn.00478480
mov ecx, dword [esi + 0x1c]
mov ebp, dword [0x48257c]
push 0
push eax
push 0x30
push ecx
mov dword [esi + 0x58], eax
call ebp
mov edi, dword [esp + 0x34]
test edi, edi
je 0x44b520
push edi
mov ecx, esi
call fcn.00475adf
mov ecx, esi
call fcn.0044b6c0
cmp dword [esp + 0x38], 1
jne 0x44b555
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
mov edx, dword [esi + 0x1c]
push 0xffffffffffffffff
not ecx
dec ecx
push ecx
push 0xb1
push edx
call ebp
mov eax, dword [esi + 0x1c]
push 0
push 0
push 0xb7
push eax
call ebp
mov ecx, esi
call fcn.00475c1a
mov ecx, dword [esp + 0x10]
mov eax, esi
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
add esp, 0x10
ret 0x28

Function at 0x44df80
Capabilities:
Check for software breakpoints

Disassembly:
push esi
mov esi, dword [esp + 8]
cmp dword [esi + 0x10], 0xca
jne 0x44dfb3
push esi
call fcn.00451070
mov eax, dword [esi + 0x40]
add esp, 4
test eax, eax
je 0x44dfac
mov dword [esi + 0x10], 0xcf
mov eax, 1
pop esi
ret
mov dword [esi + 0x10], 0xcb
mov eax, dword [esi + 0x10]
cmp eax, 0xcb
jne 0x44e039
mov eax, dword [esi + 0x1b0]
mov ecx, dword [eax + 0x10]
test ecx, ecx
je 0x44e022
mov eax, dword [esi + 8]
test eax, eax
je 0x44dfd7
push esi
call dword [eax]
add esp, 4
mov ecx, dword [esi + 0x1b0]
push esi
call dword [ecx]
add esp, 4
test eax, eax
je 0x44e01e
cmp eax, 2
je 0x44e022
mov ecx, dword [esi + 8]
test ecx, ecx
je 0x44dfca
cmp eax, 3
je 0x44dffd
cmp eax, 1
jne 0x44dfca
mov eax, dword [ecx + 4]
inc eax
mov dword [ecx + 4], eax
mov eax, dword [esi + 8]
mov ecx, dword [eax + 8]
mov edx, dword [eax + 4]
cmp edx, ecx
jl 0x44dfca
mov edx, dword [esi + 0x13c]
add edx, ecx
mov dword [eax + 8], edx
jmp 0x44dfca
xor eax, eax
pop esi
ret
mov eax, dword [esi + 0x90]
push esi
mov dword [esi + 0x98], eax
call fcn.0044e060
add esp, 4
pop esi
ret
cmp eax, 0xcc
je 0x44e048
mov ecx, dword [esi]
push esi
call dword [ecx]
add esp, 4
push esi
call fcn.0044e060
add esp, 4
pop esi
ret
Function at 0x45cf50
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x480460
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 8
push esi
mov esi, ecx
lea ecx, [esp + 4]
call fcn.0045cb00
lea eax, [esp + 4]
lea ecx, [esi + 4]
push eax
mov dword [esp + 0x18], 0
call fcn.0045cb80
lea ecx, [esp + 4]
push ecx
lea ecx, [esi + 0x14]
call fcn.0045cb80
lea ecx, [esi + 0xc]
call fcn.00471791
lea ecx, [esi + 0x10]
call fcn.00471791
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x1c]
call fcn.0045f3b0
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x30]
call fcn.0045f3b0
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x44]
call fcn.0045f3b0
lea ecx, [esp + 8]
mov dword [esp + 0x14], 1
call fcn.00471806
lea ecx, [esp + 4]
mov dword [esp + 0x14], 0xffffffff
call fcn.00471806
mov ecx, dword [esp + 0xc]
pop esi
mov dword fs:[0], ecx
add esp, 0x14
ret
Function at 0x401470
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push ebx
sub esp, 0x1c
mov ebx, dword [sym.imp.m__iob]
lea eax, [ebp + 0xc]
add ebx, 0x40
push str.error:
push ebx
mov dword [ebp - 8], eax
call fcn.004013a0
add esp, 0xc
mov ecx, dword [ebp + 8]
mov eax, dword [ebp - 8]
push eax
push ecx
push ebx
call fcn.00495c30
pop eax
pop edx
push 0x49d075
push ebx
call fcn.004013a0
mov dword [esp], 0xffffffff
call sub.m_exit
nop
lea esi, [esi]
Function at 0x401a10
Capabilities:
Create pipe
Create process on windows
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x18c
lea eax, [ebp - 0x28]
mov dword [ebp - 0x28], 0xc
mov dword [ebp - 0x24], 0
push 0
push eax
lea eax, [ebp - 0x18]
mov dword [ebp - 0x20], 1
push eax
lea eax, [ebp - 0x14]
push eax
call sub.KERNEL32.dll_CreatePipe
test eax, eax
je 0x401b76
push eax
mov eax, dword [ebp - 0x14]
push 0
push 1
push eax
call sub.KERNEL32.dll_SetHandleInformation
lea edi, [ebp - 0x7c]
lea ebx, [ebp - 0x180]
push 0x44
push 0
push edi
call sub.m_memset
mov dword [ebp - 0x7c], 0x44
mov dword [esp], 0xfffffff6
call sub.KERNEL32.dll_GetStdHandle
lea esi, [ebp - 0x38]
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x40], eax
push 0xfffffffffffffff4
call sub.KERNEL32.dll_GetStdHandle
mov dword [ebp - 0x50], 0x100
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x34], 0
push eax
mov dword [ebp - 0x30], 0
push eax
mov dword [ebp - 0x2c], 0
push 0x104
push ebx
push 0
call sub.KERNEL32.dll_GetModuleFileNameA
add esp, 0xc
push esi
push edi
push 0
push 0
push 8
push 1
push 0
push 0
push str.adb_fork_server_server
push ebx
call sub.KERNEL32.dll_CreateProcessA
mov ecx, dword [ebp - 0x18]
mov ebx, eax
push esi
push ecx
call sub.KERNEL32.dll_CloseHandle
add esp, 0xc
test ebx, ebx
je 0x401b84
sub esp, 0xc
mov eax, dword [ebp - 0x38]
push eax
call sub.KERNEL32.dll_CloseHandle
mov eax, dword [ebp - 0x34]
push eax
call sub.KERNEL32.dll_CloseHandle
lea eax, [ebp - 0x1c]
mov edi, dword [ebp - 0x14]
push 0
push eax
lea eax, [ebp - 0xf]
push 3
push eax
push edi
call sub.KERNEL32.dll_ReadFile
mov esi, dword [ebp - 0x14]
mov ebx, eax
push esi
call sub.KERNEL32.dll_CloseHandle
add esp, 0xc
test ebx, ebx
je 0x401bb0
cmp dword [ebp - 0x1c], 3
jne 0x401b43
cmp byte [ebp - 0xf], 0x4f
je 0x401b66
push edx
push edx
push str.ADB_server_didnt_ACK_n
mov eax, dword [sym.imp.m__iob]
add eax, 0x40
push eax
call fcn.004013a0
or eax, 0xffffffff
add esp, 0x10
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
cmp byte [ebp - 0xe], 0x4b
jne 0x401b43
xor eax, eax
cmp byte [ebp - 0xd], 0xa
jne 0x401b43
jmp 0x401b5e
call sub.KERNEL32.dll_GetLastError
push edx
push eax
push str.CreatePipe___failure__error__ld_n
jmp 0x401b4a
call sub.KERNEL32.dll_GetLastError
push edx
push eax
mov eax, dword [sym.imp.m__iob]
push str.CreateProcess_failure__error__ld_n
add eax, 0x40
push eax
call fcn.004013a0
pop eax
mov eax, dword [ebp - 0x14]
push eax
call sub.KERNEL32.dll_CloseHandle
or eax, 0xffffffff
add esp, 0xc
jmp 0x401b5e
call sub.KERNEL32.dll_GetLastError
push ecx
push eax
push str.could_not_read_ok_from_ADB_Server__error___ld_n
jmp 0x401b4a
Function at 0x401bc0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x134
lea eax, [ebp - 0x110]
push eax
push 0xfc
call sub.KERNEL32.dll_GetTempPathA
lea ecx, [ebp - 0x110]
mov eax, dword [ecx]
add ecx, 4
lea edx, [eax - 0x1010101]
xor eax, 0xffffffff
and edx, eax
and edx, 0x80808080
je 0x401be3
test edx, 0x8080
je 0x401cc0
add dl, dl
mov eax, ecx
sbb eax, 3
mov dword [eax], 0x2e626461
mov dword [eax + 4], 0x676f6c
push 0x49d2cb
push 0x49d2ce
call sub.m_fopen
add esp, 0x10
mov dword [ebp - 0x120], eax
test eax, eax
je 0x401cde
mov ebx, dword [sym.imp.m__iob]
mov ecx, 8
cld
mov edi, ebx
mov esi, eax
rep movsd dword es:[edi], dword [esi]
lea edi, [ebp - 0x110]
push esi
push esi
push 0x49d2d2
push edi
call sub.m_fopen
add esp, 0x10
mov dword [ebp - 0x138], eax
test eax, eax
je 0x401cd0
mov ecx, dword [ebp - 0x138]
push 0
push 4
push 0
push ecx
call sub.m_setvbuf
cld
mov eax, 8
mov esi, dword [ebp - 0x138]
lea edi, [ebx + 0x20]
mov ecx, eax
rep movsd dword es:[edi], dword [esi]
add ebx, 0x40
mov esi, dword [ebp - 0x138]
mov edi, ebx
mov ecx, eax
rep movsd dword es:[edi], dword [esi]
call sub.msvcrt.dll__getpid
add esp, 0xc
push eax
push str.____adb_starting__pid__d______n
push ebx
call fcn.004013a0
add esp, 0x10
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
shr edx, 0x10
add ecx, 2
jmp 0x401c07
mov eax, dword [ebp - 0x120]
mov dword [ebp - 0x138], eax
jmp 0x401c6d
mov ebx, dword [sym.imp.m__iob]
jmp 0x401c4d

Function at 0x402710
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x28
push str.ADB_TRACE
call sub.m_getenv
add esp, 0x10
mov dword [ebp - 0x14], eax
test eax, eax
je 0x4027cc
mov al, byte [eax]
test al, al
je 0x4027cc
push eax
push eax
push str.__:_
mov eax, dword [ebp - 0x14]
push eax
call sub.m_strpbrk
add esp, 0x10
mov dword [ebp - 0x10], eax
test eax, eax
je 0x4027e3
mov edi, dword [ebp - 0x10]
mov esi, dword [ebp - 0x14]
sub edi, esi
mov ebx, dword [0x49d900]
mov dword [ebp - 0x20], edi
test ebx, ebx
je 0x4027c4
mov esi, dword [0x49d900]
xor ebx, ebx
jmp 0x402784
inc ebx
mov esi, dword [ebx*8 + 0x49d900]
test esi, esi
je 0x4027c4
sub esp, 0xc
push esi
call sub.m_strlen
add esp, 0x10
cmp dword [ebp - 0x20], eax
jne 0x402778
mov eax, dword [ebp - 0x20]
mov edi, dword [ebp - 0x14]
cld
cmp eax, eax
mov ecx, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x402778
mov ecx, dword [ebx*8 + 0x49d904]
test ecx, ecx
je 0x4027ff
mov eax, 1
shl eax, cl
mov ecx, dword [0x4dcfc8]
or ecx, eax
mov dword [0x4dcfc8], ecx
mov eax, dword [ebp - 0x10]
cmp byte [eax], 0
jne 0x4027d4
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
inc eax
mov edx, dword [ebp - 0x10]
mov dword [ebp - 0x14], eax
mov al, byte [edx + 1]
jmp 0x402733
sub esp, 0xc
mov eax, dword [ebp - 0x14]
push eax
call sub.m_strlen
mov edi, dword [ebp - 0x14]
add esp, 0x10
add eax, edi
mov dword [ebp - 0x10], eax
jmp 0x402759
mov dword [0x4dcfc8], 0xffffffff
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x402820
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push ebx
sub esp, 0x14
lea eax, [ebp + 0xc]
mov dword [ebp - 8], eax
call sub.m__errno
sub esp, 0xc
mov eax, dword [eax]
push eax
call sub.m_strerror
add esp, 0xc
mov ebx, dword [sym.imp.m__iob]
add ebx, 0x40
push eax
push str.error:__s:
push ebx
call fcn.004013a0
add esp, 0xc
mov ecx, dword [ebp + 8]
mov eax, dword [ebp - 8]
push eax
push ecx
push ebx
call fcn.00495c30
pop eax
pop edx
push 0x49d075
push ebx
call fcn.004013a0
mov dword [esp], 0xffffffff
call sub.m_exit
nop
Function at 0x403b10
Capabilities:
Terminate process
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
push ebx
sub esp, 0x3c
push 0x401450
call section..text
pop eax
pop edx
push 1
push 0x401460
call sub.KERNEL32.dll_SetConsoleCtrlHandler
pop esi
pop eax
call fcn.00404c90
mov dword [0x4c8008], 1
call fcn.004129b0
call fcn.00411c20
sub esp, 0xc
push 0x15b3
call fcn.00406f10
call fcn.0040cc30
add esp, 0xc
mov ebx, dword [ebp + 0xc]
push ebx
lea ebx, [ebp - 0x2a]
push 0x1e
push ebx
call fcn.004014c0
xor ecx, ecx
mov edx, str.smartsocket
mov eax, ebx
call fcn.00401d50
add esp, 0x10
test eax, eax
jne 0x403c40
mov ecx, dword [ebp + 8]
test ecx, ecx
jne 0x403c16
test byte [0x4dcfc8], 1
je 0x403c03
call sub.m__errno
sub esp, 0xc
mov esi, dword [eax]
push 0x4dcfd8
call sub.KERNEL32.dll_EnterCriticalSection
mov ebx, dword [sym.imp.m__iob]
add esp, 0xc
add ebx, 0x40
push str.adb_main
push str.system_core_adb_adb.c
push 0x49d056
push ebx
call fcn.004013a0
call sub.m__errno
mov dword [eax], esi
pop eax
pop edx
push str.Event_loop_starting_n
push ebx
call fcn.004013a0
mov dword [esp], ebx
call sub.m_fflush
mov dword [esp], 0x4dcfd8
call sub.KERNEL32.dll_LeaveCriticalSection
add esp, 0xc
call sub.m__errno
mov dword [eax], esi
call fcn.00412fd0
call fcn.00411900
lea esp, [ebp - 8]
xor eax, eax
pop ebx
pop esi
pop ebp
ret
sub esp, 0xc
push 0xfffffffffffffff5
call sub.KERNEL32.dll_GetStdHandle
lea edx, [ebp - 0xc]
push 0
push edx
push 3
push 0x49d7bf
push eax
call sub.KERNEL32.dll_WriteFile
add esp, 0xc
call fcn.00401bc0
jmp 0x403b93
sub esp, 0xc
push 1
call sub.m_exit
nop
nop
nop
nop
nop
nop

Function at 0x406ce0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x58
push str.ADBHOST
call sub.m_getenv
add esp, 0x10
test eax, eax
je 0x406dd0
mov edx, dword [ebp + 0xc]
push ecx
push 1
push edx
push eax
call fcn.00415ce0
add esp, 0x10
mov edi, eax
test eax, eax
js 0x406dd0
test byte [0x4dcfc8], 8
jne 0x406d61
sub esp, 0xc
lea ebx, [ebp - 0x4c]
push edi
call fcn.00414c30
pop eax
mov eax, dword [ebp + 8]
push eax
push 0x49e5c2
push str._s_d
push 0x40
push ebx
call fcn.00495c90
add esp, 0x20
mov eax, dword [ebp + 0xc]
push 1
push eax
push ebx
push edi
call fcn.00405820
xor eax, eax
add esp, 0x10
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
call sub.m__errno
sub esp, 0xc
mov esi, dword [eax]
push 0x4dcfd8
call sub.KERNEL32.dll_EnterCriticalSection
mov ebx, dword [sym.imp.m__iob]
add esp, 0xc
add ebx, 0x40
push str.local_connect_arbitrary_ports
push str.system_core_adb_transport_local.c
push 0x49e592
push ebx
call fcn.00406ca0
call sub.m__errno
add esp, 0xc
mov dword [eax], esi
push edi
push str.client:_connected_on_remote_on_fd__d_n
push ebx
call fcn.00406ca0
mov dword [esp], ebx
call sub.m_fflush
mov dword [esp], 0x4dcfd8
call sub.KERNEL32.dll_LeaveCriticalSection
add esp, 0xc
call sub.m__errno
mov dword [eax], esi
jmp 0x406d21
push eax
push eax
mov eax, dword [ebp + 0xc]
push 1
push eax
call fcn.004160a0
mov edi, eax
add esp, 0x10
or eax, 0xffffffff
test edi, edi
jns 0x406d18
jmp 0x406d59
Function at 0x406f10
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0xc
mov esi, 0x407280
mov ebx, dword [0x4c8008]
test ebx, ebx
jne 0x406f2d
mov esi, 0x407010
test byte [0x4dcfc8], 8
jne 0x406f80
push edi
mov ebx, dword [ebp + 8]
push ebx
push 0
push esi
call sub.m__beginthread
add esp, 0x10
inc eax
je 0x406f51
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov ecx, dword [0x4c8008]
mov eax, 0x49e5d1
test ecx, ecx
jne 0x406f65
mov eax, 0x49e5d8
push edx
push edx
push eax
push str.cannot_create_local_socket__s_thread
call fcn.00402820
add esp, 0x10
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
call sub.m__errno
sub esp, 0xc
mov edi, dword [eax]
push 0x4dcfd8
call sub.KERNEL32.dll_EnterCriticalSection
mov ebx, dword [sym.imp.m__iob]
add esp, 0xc
add ebx, 0x40
push str.local_init
push str.system_core_adb_transport_local.c
push 0x49e592
push ebx
call fcn.00406ca0
call sub.m__errno
add esp, 0x10
mov dword [eax], edi
mov eax, 0x49e5d1
mov ecx, dword [0x4c8008]
test ecx, ecx
jne 0x406fd3
mov eax, 0x49e5d8
push edx
push eax
push str.transport:_local__s_init_n
push ebx
call fcn.00406ca0
mov dword [esp], ebx
call sub.m_fflush
mov dword [esp], 0x4dcfd8
call sub.KERNEL32.dll_LeaveCriticalSection
add esp, 0xc
call sub.m__errno
mov dword [eax], edi
jmp 0x406f36
Function at 0x407f20
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
push eax
mov eax, 0x1008
call fcn.00495580
mov eax, dword [ebp - 0x10]
mov esi, eax
test eax, eax
js 0x4080ba
mov eax, dword [sym.imp.m__iob]
add eax, 0x40
mov dword [ebp - 0x1014], eax
lea esi, [esi]
test byte [0x4dcfc8], 1
jne 0x407fc1
lea esi, [esi]
lea edx, [ebp - 0x100c]
push eax
push 0x1000
push edx
push esi
call fcn.00413e00
add esp, 0x10
mov edi, eax
test byte [0x4dcfc8], 1
jne 0x408037
cmp edi, 0
je 0x4080ba
jl 0x4080c2
mov ebx, dword [sym.imp.m__iob]
lea eax, [ebp - 0x100c]
add ebx, 0x20
push ebx
push edi
push 1
push eax
call sub.m_fwrite
mov dword [esp], ebx
call sub.m_fflush
add esp, 0x10
test byte [0x4dcfc8], 1
je 0x407f60
call sub.m__errno
sub esp, 0xc
mov ebx, dword [eax]
push 0x4dcfd8
call sub.KERNEL32.dll_EnterCriticalSection
add esp, 0xc
push str.read_and_dump
push str.system_core_adb_commandline.c
push 0x4a06d0
mov eax, dword [ebp - 0x1014]
push eax
call fcn.00407d40
call sub.m__errno
add esp, 0xc
mov dword [eax], ebx
push esi
push str.read_and_dump__:_pre_adb_read_fd_d__n
mov eax, dword [ebp - 0x1014]
push eax
call fcn.00407d40
pop eax
mov eax, dword [ebp - 0x1014]
push eax
call sub.m_fflush
mov dword [esp], 0x4dcfd8
call sub.KERNEL32.dll_LeaveCriticalSection
add esp, 0xc
call sub.m__errno
mov dword [eax], ebx
jmp 0x407f60
call sub.m__errno
sub esp, 0xc
mov eax, dword [eax]
mov dword [ebp - 0x1010], eax
push 0x4dcfd8
call sub.KERNEL32.dll_EnterCriticalSection
mov ebx, dword [sym.imp.m__iob]
add esp, 0xc
add ebx, 0x40
push str.read_and_dump
push str.system_core_adb_commandline.c
push 0x4a06d0
push ebx
call fcn.00407d40
call sub.m__errno
mov edx, dword [ebp - 0x1010]
mov dword [eax], edx
push edi
push esi
push str.read_and_dump__:_post_adb_read_fd_d_:_len_d_n
push ebx
call fcn.00407d40
add esp, 0x14
push ebx
call sub.m_fflush
mov dword [esp], 0x4dcfd8
call sub.KERNEL32.dll_LeaveCriticalSection
add esp, 0xc
call sub.m__errno
mov edx, dword [ebp - 0x1010]
cmp edi, 0
mov dword [eax], edx
jne 0x407f8e
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
call sub.m__errno
cmp dword [eax], 4
je 0x407f50
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret

Function at 0x408100
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0xc
mov edi, eax
mov eax, dword [0x4c8080]
test eax, eax
je 0x40815d
sub esp, 0xc
push eax
call sub.m_strlen
mov dword [esp], edi
mov ebx, eax
call sub.m_strlen
lea esi, [ebx + eax + 2]
mov dword [esp], esi
call sub.m_malloc
add esp, 0x10
mov ebx, eax
test eax, eax
je 0x40817e
sub esp, 0xc
mov ecx, dword [0x4c8080]
push edi
push ecx
push 0x4a07a5
push esi
push eax
call fcn.00495c90
lea esp, [ebp - 0xc]
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
push esi
push esi
push str.adb:_Product_directory_not_specified__use__p_or_define_ANDROID_PRODUCT_OUT_n
mov eax, dword [sym.imp.m__iob]
add eax, 0x40
push eax
call fcn.00407d40
mov dword [esp], 1
call sub.m_exit
push ebx
push ebx
push str.adb:_Out_of_memory__product_file____n
jmp 0x408164
Function at 0x408860
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ebx
sub esp, 0x10
push str.shell:
call fcn.0040b590
add esp, 0x10
mov ebx, eax
test eax, eax
js 0x4088b0
sub esp, 0xc
push 8
call sub.m_malloc
add esp, 0xc
mov dword [eax], ebx
mov dword [eax + 4], 0
push eax
push 0
push 0x4088e0
call sub.m__beginthread
mov eax, ebx
call fcn.00407f20
xor eax, eax
add esp, 0x10
mov ebx, dword [ebp - 4]
leave
ret
call fcn.0040af10
push edx
push eax
mov eax, dword [sym.imp.m__iob]
push 0x4a0867
add eax, 0x40
push eax
call fcn.00407d40
mov eax, 1
add esp, 0x10
mov ebx, dword [ebp - 4]
leave
ret
Function at 0x40bbd0
Capabilities:
Create directory
Get common file path
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x248
mov dword [ebp - 0x240], eax
mov dword [ebp - 0x244], edx
push 0x4a16dc
call sub.m_getenv
add esp, 0x10
mov edi, eax
test eax, eax
je 0x40bd01
test byte [0x4dcfc9], 4
jne 0x40bc93
sub esp, 0xc
push 0x4a1725
push edi
lea edi, [ebp - 0x133]
push 0x4a172e
push 0x103
push edi
call fcn.00495c90
add esp, 0x20
cmp eax, 0x102
jle 0x40bc40
or eax, 0xffffffff
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
lea eax, [ebp - 0x30]
push esi
push esi
push eax
push edi
call sub.msvcrt.dll__stat
add esp, 0x10
test eax, eax
je 0x40bc67
sub esp, 0xc
push edi
call sub.m__mkdir
add esp, 0x10
test eax, eax
js 0x40bd22
sub esp, 0xc
push str.adbkey
push edi
push 0x4a172e
mov ebx, dword [ebp - 0x244]
push ebx
mov ecx, dword [ebp - 0x240]
push ecx
call fcn.00495c90
add esp, 0x20
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
call sub.m__errno
sub esp, 0xc
mov esi, dword [eax]
push 0x4dcfd8
call sub.KERNEL32.dll_EnterCriticalSection
mov ebx, dword [sym.imp.m__iob]
add esp, 0xc
add ebx, 0x40
push str.get_user_keyfilepath
push str.system_core_adb_adb_auth_host.c
push 0x4a1710
push ebx
call fcn.0040bbb0
call sub.m__errno
add esp, 0xc
mov dword [eax], esi
push edi
push str.home__s_n
push ebx
call fcn.0040bbb0
mov dword [esp], ebx
call sub.m_fflush
mov dword [esp], 0x4dcfd8
call sub.KERNEL32.dll_LeaveCriticalSection
add esp, 0xc
call sub.m__errno
mov dword [eax], esi
jmp 0x40bc0c
sub esp, 0xc
lea ebx, [ebp - 0x236]
mov edi, ebx
push ebx
push 0
push 0
push 0x28
push 0
call fcn.0049ab44
add esp, 0xc
jmp 0x40bbff
test byte [0x4dcfc9], 4
je 0x40bc35
call sub.m__errno
sub esp, 0xc
mov esi, dword [eax]
push 0x4dcfd8
call sub.KERNEL32.dll_EnterCriticalSection
mov ebx, dword [sym.imp.m__iob]
add esp, 0xc
add ebx, 0x40
push str.get_user_keyfilepath
push str.system_core_adb_adb_auth_host.c
push 0x4a1710
push ebx
call fcn.0040bbb0
call sub.m__errno
add esp, 0xc
mov dword [eax], esi
push edi
push str.Cannot_mkdir__s
push ebx
call fcn.0040bbb0
mov dword [esp], ebx
call sub.m_fflush
mov dword [esp], 0x4dcfd8
call sub.KERNEL32.dll_LeaveCriticalSection
add esp, 0xc
call sub.m__errno
mov dword [eax], esi
or eax, 0xffffffff
jmp 0x40bc38
Function at 0x40fb00
Capabilities:
Create thread

Disassembly:
push ebp
mov ecx, 4
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0xc
mov edi, str.tcp:
mov ebx, dword [ebp + 8]
cld
mov esi, ebx
repe cmpsb byte [esi], byte es:[edi]
jne 0x40fb75
sub esp, 0xc
add ebx, 4
push ebx
call sub.m_atoi
pop ecx
pop edi
push 0x3a
mov esi, eax
push ebx
call sub.m_strchr
add esp, 0x10
mov ebx, eax
test eax, eax
je 0x40fbb7
sub esp, 0xc
push 0x4dd058
call sub.KERNEL32.dll_EnterCriticalSection
push eax
push eax
lea eax, [ebx + 1]
push 1
push esi
push eax
call fcn.00415ce0
add esp, 0x14
mov esi, eax
push 0x4dd058
call sub.KERNEL32.dll_LeaveCriticalSection
add esp, 0xc
lea esp, [ebp - 0xc]
mov eax, esi
pop ebx
pop esi
pop edi
pop ebp
ret
cld
mov esi, str.dns:
mov ecx, 4
mov edi, ebx
repe cmpsb byte [esi], byte es:[edi]
seta dl
setb al
or esi, 0xffffffff
cmp dl, al
jne 0x40fb6b
sub esp, 0xc
lea eax, [ebx + 4]
push eax
call sub.msvcrt.dll__strdup
add esp, 0x10
test eax, eax
je 0x40fb6b
lea esp, [ebp - 0xc]
mov edx, eax
mov eax, 0x40fa80
pop ebx
pop esi
pop edi
pop ebp
jmp fcn.0040f800
push edx
push edx
push 1
push esi
call fcn.004160a0
add esp, 0x10
mov esi, eax
test eax, eax
js 0x40fb6b
sub esp, 0xc
push eax
call fcn.00414c30
add esp, 0x10
jmp 0x40fb6b