joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40e4cb
Capabilities:
Clear file content

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x100c
call fcn.0040c490
mov eax, dword [0x418d60]
xor eax, dword [ebp + 4]
push ebx
push esi
push 1
xor esi, esi
push esi
push dword [ebp + 8]
mov dword [ebp - 4], eax
call fcn.0040e606
or ebx, 0xffffffff
add esp, 0xc
cmp eax, ebx
mov dword [ebp - 8], eax
je 0x40e5f5
push 2
push esi
push dword [ebp + 8]
call fcn.0040e606
add esp, 0xc
cmp eax, ebx
je 0x40e5f5
push edi
mov edi, dword [ebp + 0xc]
sub edi, eax
test edi, edi
jle 0x40e598
mov ebx, 0x1000
push ebx
lea eax, [ebp - 0x100c]
push esi
push eax
call fcn.0040ba90
push 0x8000
push dword [ebp + 8]
call fcn.0040fc68
add esp, 0x14
mov dword [ebp - 0xc], eax
cmp edi, ebx
mov eax, ebx
jge 0x40e551
mov eax, edi
push eax
lea eax, [ebp - 0x100c]
push eax
push dword [ebp + 8]
call fcn.0040a1f8
add esp, 0xc
cmp eax, 0xffffffff
je 0x40e571
sub edi, eax
test edi, edi
jg 0x40e549
jmp 0x40e589
call fcn.0040a451
cmp dword [eax], 5
jne 0x40e586
call fcn.0040a448
mov dword [eax], 0xd
or esi, 0xffffffff
push dword [ebp - 0xc]
push dword [ebp + 8]
call fcn.0040fc68
pop ecx
pop ecx
jmp 0x40e5e0
jge 0x40e5e0
push 0
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.0040e606
push dword [ebp + 8]
call fcn.00409d5d
add esp, 0x10
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov esi, eax
neg esi
sbb esi, esi
neg esi
dec esi
cmp esi, ebx
jne 0x40e5e0
call fcn.0040a448
mov dword [eax], 0xd
call fcn.0040a451
mov edi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [edi], eax
push 0
push dword [ebp - 8]
push dword [ebp + 8]
call fcn.0040e606
add esp, 0xc
mov eax, esi
pop edi
jmp 0x40e5f7
mov eax, ebx
mov ecx, dword [ebp - 4]
xor ecx, dword [ebp + 4]
pop esi
pop ebx
call fcn.0040d859
leave
ret
Function at 0x40f4c8
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [0x419fd4], ebx
push esi
push edi
jne 0x40f548
push str.user32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x40f583
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x415ee8
push edi
call esi
test eax, eax
mov dword [0x419fd4], eax
je 0x40f583
push str.GetActiveWindow
push edi
call esi
push str.GetLastActivePopup
push edi
mov dword [0x419fd8], eax
call esi
cmp dword [0x419c7c], 2
mov dword [0x419fdc], eax
jne 0x40f548
push str.GetUserObjectInformationA
push edi
call esi
test eax, eax
mov dword [0x419fe4], eax
je 0x40f548
push str.GetProcessWindowStation
push edi
call esi
mov dword [0x419fe0], eax
mov eax, dword [0x419fe0]
test eax, eax
je 0x40f58d
call eax
test eax, eax
je 0x40f574
lea ecx, [ebp - 4]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [0x419fe4]
test eax, eax
je 0x40f574
test byte [ebp - 8], 1
jne 0x40f58d
cmp dword [0x419c88], 4
jb 0x40f587
or byte [ebp + 0x12], 0x20
jmp 0x40f5ac
xor eax, eax
jmp 0x40f5bc
or byte [ebp + 0x12], 4
jmp 0x40f5ac
mov eax, dword [0x419fd8]
test eax, eax
je 0x40f5ac
call eax
mov ebx, eax
test ebx, ebx
je 0x40f5ac
mov eax, dword [0x419fdc]
test eax, eax
je 0x40f5ac
push ebx
call eax
mov ebx, eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push ebx
call dword [0x419fd4]
pop edi
pop esi
pop ebx
leave
ret

Function at 0x40f847
Capabilities:
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
push ebx
push esi
push edi
push 4
pop eax
call fcn.0040c490
mov ebx, esp
push 0x1c
lea eax, [ebp - 0x24]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x40f8dc
mov edi, dword [ebp - 0x20]
lea eax, [ebp - 0x48]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov eax, dword [ebp - 0x44]
lea esi, [eax - 1]
not esi
and esi, ebx
sub esi, eax
mov dword [ebp - 4], eax
mov eax, dword [0x419c7c]
mov ecx, eax
dec ecx
neg ecx
sbb ecx, ecx
and ecx, 0xffff1000
add ecx, 0x11000
add ecx, edi
cmp esi, ecx
jb 0x40f8dc
cmp eax, 1
je 0x40f8f4
mov ebx, edi
mov edi, 0x1000
push 0x1c
lea eax, [ebp - 0x24]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x40f8dc
add ebx, dword [ebp - 0x18]
test dword [ebp - 0x14], edi
je 0x40f8b1
test byte [ebp - 0xf], 1
mov ebx, dword [ebp - 0x24]
je 0x40f8d8
xor eax, eax
inc eax
jmp 0x40f910
cmp esi, ebx
jae 0x40f8e0
xor eax, eax
jmp 0x40f910
push 4
push edi
push dword [ebp - 4]
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov eax, dword [0x419c7c]
jmp 0x40f8f6
mov ebx, esi
dec eax
neg eax
sbb eax, eax
and eax, 0x103
lea ecx, [ebp - 8]
push ecx
inc eax
push eax
push dword [ebp - 4]
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
lea esp, [ebp - 0x54]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x41011e
Capabilities:
Set environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
xor ebx, ebx
cmp dword [ebp + 8], ebx
push esi
push edi
mov dword [ebp - 8], ebx
je 0x410189
push 0x3d
push dword [ebp + 8]
call fcn.004109f8
mov esi, eax
cmp esi, ebx
pop ecx
pop ecx
mov dword [ebp - 0xc], esi
je 0x410189
cmp dword [ebp + 8], esi
je 0x410189
xor eax, eax
cmp byte [esi + 1], al
sete al
mov dword [ebp - 4], eax
mov eax, dword [0x419c9c]
cmp eax, dword [0x419ca0]
jne 0x41016f
mov edi, eax
call fcn.004100bd
mov dword [0x419c9c], eax
cmp eax, ebx
jne 0x4101c8
cmp dword [ebp + 0xc], ebx
je 0x410191
cmp dword [0x419ca4], ebx
je 0x410191
call fcn.0040e87d
test eax, eax
je 0x4101c8
or eax, 0xffffffff
pop edi
pop esi
pop ebx
leave
ret
cmp dword [ebp - 4], ebx
jne 0x4102cc
push 4
call fcn.004083a6
cmp eax, ebx
pop ecx
mov dword [0x419c9c], eax
je 0x410189
mov dword [eax], ebx
cmp dword [0x419ca4], ebx
jne 0x4101c8
push 4
call fcn.004083a6
cmp eax, ebx
pop ecx
mov dword [0x419ca4], eax
je 0x410189
mov dword [eax], ebx
mov ebx, dword [0x419c9c]
mov edi, esi
mov esi, dword [ebp + 8]
sub edi, esi
push esi
call fcn.00410070
mov edi, eax
test edi, edi
pop ecx
jl 0x410221
cmp dword [ebx], 0
je 0x410221
lea esi, [ebx + edi*4]
push dword [esi]
call fcn.00407ade
xor eax, eax
cmp dword [ebp - 4], eax
pop ecx
jne 0x410209
mov eax, dword [ebp + 8]
mov dword [esi], eax
jmp 0x410257
mov ecx, dword [esi + 4]
mov dword [esi], ecx
inc edi
add esi, 4
cmp dword [esi], eax
jne 0x410200
mov eax, edi
shl eax, 2
push eax
push ebx
call fcn.00408d20
test eax, eax
pop ecx
pop ecx
je 0x410257
jmp 0x410252
cmp dword [ebp - 4], 0
jne 0x4102c5
test edi, edi
jge 0x410231
neg edi
lea eax, [edi*4 + 8]
push eax
push ebx
call fcn.00408d20
test eax, eax
pop ecx
pop ecx
je 0x410189
lea ecx, [eax + edi*4]
and dword [ecx + 4], 0
mov dword [ecx], esi
mov dword [0x419c9c], eax
cmp dword [ebp + 0xc], 0
je 0x4102ae
push dword [ebp + 8]
call fcn.0040caf0
inc eax
inc eax
push eax
call fcn.004083a6
mov esi, eax
test esi, esi
pop ecx
pop ecx
je 0x4102ae
push dword [ebp + 8]
push esi
call fcn.0040d730
mov eax, esi
sub eax, dword [ebp + 8]
pop ecx
add eax, dword [ebp - 0xc]
pop ecx
and byte [eax], 0
mov ecx, dword [ebp - 4]
inc eax
neg ecx
sbb ecx, ecx
not ecx
and ecx, eax
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
test eax, eax
jne 0x4102a7
or dword [ebp - 8], 0xffffffff
push esi
call fcn.00407ade
pop ecx
cmp dword [ebp - 4], 0
je 0x4102bd
push dword [ebp + 8]
call fcn.00407ade
pop ecx
mov eax, dword [ebp - 8]
jmp 0x41018c
push esi
call fcn.00407ade
pop ecx
xor eax, eax
jmp 0x41018c
Function at 0x411f50
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov eax, dword [esp + 8]
push esi
mov esi, dword [esp + 8]
push edi
lea edi, [esi + eax]
cmp esi, edi
mov eax, dword [esp + 0x14]
movzx ecx, byte [eax + 0x100]
movzx edx, byte [eax + 0x101]
mov dword [esp + 0x10], edi
je 0x411fcb
push ebx
push ebp
jmp 0x411f80
mov ecx, dword [esp + 0x14]
nop
lea edi, [ecx + 1]
and edi, 0xff
mov bl, byte [edi + eax]
movzx ebp, bl
xor ecx, ecx
add edx, ebp
and edx, 0xff
mov cl, byte [edx + eax]
mov byte [edi + eax], cl
mov byte [edx + eax], bl
mov bl, byte [esi]
mov dword [esp + 0x14], edi
add ecx, ebp
and ecx, 0xff
mov cl, byte [ecx + eax]
xor cl, bl
mov byte [esi], cl
movzx ecx, cl
add edx, ecx
mov ecx, dword [esp + 0x18]
inc esi
cmp esi, ecx
jne 0x411f7b
mov cl, byte [esp + 0x14]
pop ebp
pop ebx
pop edi
mov byte [eax + 0x100], cl
mov byte [eax + 0x101], dl
pop esi
ret
Function at 0x4035e0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
push ebx
sub esp, 0x50
mov dword [esp], 0x4016e0
lea ebx, [ebp - 0x26]
call fcn.004b02c0
mov dword [esp + 4], 1
mov dword [esp], 0x401510
call dword [sym.imp.KERNEL32.dll_SetConsoleCtrlHandler]
sub esp, 8
call fcn.00406290
mov dword [0x4ef024], 1
call fcn.00416d10
call fcn.00415ba0
mov dword [esp], 0x15b3
call fcn.00408450
call fcn.0040fec0
mov eax, dword [ebp + 0xc]
mov dword [esp + 8], str.tcp:_d
mov dword [esp + 4], 0x1e
mov dword [esp], ebx
mov dword [esp + 0xc], eax
call fcn.00401550
xor ecx, ecx
mov edx, str.smartsocket
mov dword [esp], 0
mov eax, ebx
call fcn.00402ef0
test eax, eax
jne 0x403767
mov eax, dword [ebp + 8]
test eax, eax
jne 0x403722
test byte [0x504120], 1
je 0x40370f
mov ebx, dword [sym.imp.msvcrt.dll__errno]
call ebx
mov esi, dword [eax]
mov dword [esp], 0x504108
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
sub esp, 4
mov dword [esp + 0xc], str.adb_main
mov dword [esp + 8], str.system_core_adb_adb.c
mov dword [esp + 4], 0x4c008e
mov dword [esp], eax
call fcn.00401520
call ebx
mov dword [eax], esi
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 4], str.Event_loop_starting_n
add eax, 0x40
mov dword [esp], eax
call fcn.00401520
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp], eax
call sub.msvcrt.dll_fflush
mov dword [esp], 0x504108
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
call ebx
mov dword [eax], esi
call fcn.0041b3e0
call fcn.00415be0
lea esp, [ebp - 8]
xor eax, eax
pop ebx
pop esi
pop ebp
ret
mov dword [esp], 0xfffffff5
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
lea edx, [ebp - 0x2c]
sub esp, 4
mov dword [esp + 0xc], edx
mov dword [esp + 0x10], 0
mov dword [esp + 8], 3
mov dword [esp + 4], 0x4c04be
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
sub esp, 0x14
call fcn.004030e0
jmp 0x403680
mov dword [esp], 1
call sub.msvcrt.dll_exit
lea esi, [esi]
lea edi, [edi]
Function at 0x408220
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x6c
mov esi, dword [ebp + 0xc]
mov dword [esp], str.ADBHOST
call sub.msvcrt.dll_getenv
test eax, eax
je 0x4082b3
mov dword [esp + 8], 1
mov dword [esp + 4], esi
mov dword [esp], eax
call fcn.0041a1c0
test eax, eax
mov ebx, eax
js 0x4082b3
test byte [0x504120], 8
jne 0x4082d7
mov dword [esp], ebx
lea edi, [ebp - 0x58]
call fcn.0041aaf0
mov eax, dword [ebp + 8]
mov dword [esp + 0xc], 0x4c16d2
mov dword [esp + 8], str._s_d
mov dword [esp + 4], 0x40
mov dword [esp + 0x10], eax
mov dword [esp], edi
call fcn.004081f0
mov dword [esp + 0xc], 1
mov dword [esp + 8], esi
mov dword [esp + 4], edi
mov dword [esp], ebx
call fcn.00406e30
xor eax, eax
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 4], 1
mov dword [esp], esi
call fcn.00419b10
mov ebx, eax
mov eax, 0xffffffff
test ebx, ebx
js 0x4082ab
test byte [0x504120], 8
je 0x40825f
mov edi, dword [sym.imp.msvcrt.dll__errno]
call edi
mov eax, dword [eax]
mov dword [esp], 0x504108
mov dword [ebp - 0x5c], eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ecx, dword [sym.imp.msvcrt.dll__iob]
lea eax, [ecx + 0x40]
sub esp, 4
mov dword [esp + 0xc], str.local_connect_arbitrary_ports
mov dword [esp + 8], str.system_core_adb_transport_local.c
mov dword [esp + 4], 0x4c1542
mov dword [esp], eax
call fcn.00407b10
call edi
mov edx, dword [ebp - 0x5c]
mov dword [eax], edx
mov ecx, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], ebx
mov dword [esp + 4], 0x4c16ac
lea eax, [ecx + 0x40]
mov dword [esp], eax
call fcn.00407b10
mov ecx, dword [sym.imp.msvcrt.dll__iob]
lea eax, [ecx + 0x40]
mov dword [esp], eax
call sub.msvcrt.dll_fflush
mov dword [esp], 0x504108
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
call edi
mov edx, dword [ebp - 0x5c]
mov dword [eax], edx
jmp 0x40825f
Function at 0x409130
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
push eax
mov eax, 0x1028
call fcn.004b12b0
sub esp, eax
mov eax, dword [esp + eax]
test eax, eax
mov ebx, eax
js 0x409325
lea esi, [ebp - 0x1018]
test byte [0x504120], 1
jne 0x4091c9
mov dword [esp + 8], 0x1000
mov dword [esp + 4], esi
mov dword [esp], ebx
call fcn.00419890
test byte [0x504120], 1
mov edi, eax
jne 0x409260
test edi, edi
je 0x409325
js 0x409316
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], edi
mov dword [esp + 4], 1
mov dword [esp], esi
add eax, 0x20
mov dword [esp + 0xc], eax
call sub.msvcrt.dll_fwrite
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x20
mov dword [esp], eax
call sub.msvcrt.dll_fflush
test byte [0x504120], 1
je 0x40915f
call dword [sym.imp.msvcrt.dll__errno]
mov edi, dword [eax]
mov dword [esp], 0x504108
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
sub esp, 4
mov dword [esp + 0xc], str.read_and_dump
mov dword [esp + 8], str.system_core_adb_commandline.c
mov dword [esp + 4], 0x4c199e
mov dword [esp], eax
call fcn.00408e50
call dword [sym.imp.msvcrt.dll__errno]
mov dword [eax], edi
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], ebx
mov dword [esp + 4], str.read_and_dump__:_pre_adb_read_fd_d__n
add eax, 0x40
mov dword [esp], eax
call fcn.00408e50
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp], eax
call sub.msvcrt.dll_fflush
mov dword [esp], 0x504108
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
call dword [sym.imp.msvcrt.dll__errno]
mov dword [eax], edi
jmp 0x40915f
mov ecx, dword [sym.imp.msvcrt.dll__errno]
mov dword [ebp - 0x1020], ecx
call ecx
mov eax, dword [eax]
mov dword [esp], 0x504108
mov dword [ebp - 0x101c], eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ecx, dword [sym.imp.msvcrt.dll__iob]
lea eax, [ecx + 0x40]
sub esp, 4
mov dword [esp + 0xc], str.read_and_dump
mov dword [esp + 8], str.system_core_adb_commandline.c
mov dword [esp + 4], 0x4c199e
mov dword [esp], eax
call fcn.00408e50
mov ecx, dword [ebp - 0x1020]
call ecx
mov edx, dword [ebp - 0x101c]
mov dword [eax], edx
mov ecx, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 0xc], edi
mov dword [esp + 8], ebx
mov dword [esp + 4], str.read_and_dump__:_post_adb_read_fd_d_:_len_d_n
lea eax, [ecx + 0x40]
mov dword [esp], eax
call fcn.00408e50
mov ecx, dword [sym.imp.msvcrt.dll__iob]
lea eax, [ecx + 0x40]
mov dword [esp], eax
call sub.msvcrt.dll_fflush
mov dword [esp], 0x504108
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [ebp - 0x1020]
sub esp, 4
call ecx
mov edx, dword [ebp - 0x101c]
mov dword [eax], edx
jmp 0x409182
call dword [sym.imp.msvcrt.dll__errno]
cmp dword [eax], 4
je 0x409156
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x409b50
Capabilities:
Create thread

Disassembly:
push ebx
sub esp, 0x18
mov dword [esp], str.shell:
call fcn.0040de20
test eax, eax
mov ebx, eax
js 0x409ba2
mov dword [esp], 8
call sub.msvcrt.dll_malloc
mov dword [eax], ebx
mov dword [eax + 4], 0
mov dword [esp + 8], eax
mov dword [esp + 4], 0
mov dword [esp], 0x408e80
call dword [sym.imp.msvcrt.dll__beginthread]
mov eax, ebx
call fcn.00409130
add esp, 0x18
xor eax, eax
pop ebx
ret
call fcn.0040d500
mov dword [esp + 4], 0x4c426c
mov dword [esp + 8], eax
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp], eax
call fcn.00408e50
add esp, 0x18
mov eax, 1
pop ebx
ret
Function at 0x40e600
Capabilities:
Create directory
Get common file path
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, edx
push esi
mov esi, eax
push ebx
sub esp, 0x26c
mov dword [esp], 0x4c52e4
call sub.msvcrt.dll_getenv
test eax, eax
mov ebx, eax
je 0x40e782
test byte [0x504121], 4
jne 0x40e6d0
mov dword [esp + 0xc], ebx
lea ebx, [ebp - 0x220]
mov dword [esp + 0x10], 0x4c532d
mov dword [esp + 8], 0x4c5336
mov dword [esp + 4], 0x104
mov dword [esp], ebx
call fcn.0040e5d0
cmp eax, 0x103
jg 0x40e6bd
lea eax, [ebp - 0x250]
mov dword [esp + 4], eax
mov dword [esp], ebx
call dword [sym.imp.msvcrt.dll__stati64]
test eax, eax
jne 0x40e6a3
mov dword [esp + 0xc], ebx
mov dword [esp + 4], edi
mov dword [esp], esi
mov dword [esp + 0x10], str.adbkey
mov dword [esp + 8], 0x4c5336
call fcn.0040e5d0
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp], ebx
call dword [sym.imp.msvcrt.dll__mkdir]
test eax, eax
jns 0x40e67b
test byte [0x504121], 4
jne 0x40e7c0
lea esp, [ebp - 0xc]
mov eax, 0xffffffff
pop ebx
pop esi
pop edi
pop ebp
ret
mov ecx, dword [sym.imp.msvcrt.dll__errno]
mov dword [ebp - 0x260], ecx
call ecx
mov eax, dword [eax]
mov dword [esp], 0x504108
mov dword [ebp - 0x25c], eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ecx, dword [sym.imp.msvcrt.dll__iob]
lea eax, [ecx + 0x40]
sub esp, 4
mov dword [esp + 0xc], str.get_user_keyfilepath
mov dword [esp + 8], str.system_core_adb_adb_auth_host.c
mov dword [esp + 4], 0x4c5318
mov dword [esp], eax
call fcn.0040e5a0
mov ecx, dword [ebp - 0x260]
call ecx
mov edx, dword [ebp - 0x25c]
mov dword [eax], edx
mov ecx, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], ebx
mov dword [esp + 4], str.home__s_n
lea eax, [ecx + 0x40]
mov dword [esp], eax
call fcn.0040e5a0
mov ecx, dword [sym.imp.msvcrt.dll__iob]
lea eax, [ecx + 0x40]
mov dword [esp], eax
call sub.msvcrt.dll_fflush
mov dword [esp], 0x504108
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [ebp - 0x260]
sub esp, 4
call ecx
mov edx, dword [ebp - 0x25c]
mov dword [eax], edx
jmp 0x40e633
lea ebx, [ebp - 0x11c]
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0x28
mov dword [esp], 0
call dword [sym.imp.SHELL32.DLL_SHGetFolderPathA]
sub esp, 0x14
jmp 0x40e626
mov esi, dword [sym.imp.msvcrt.dll__errno]
call esi
mov edi, dword [eax]
mov dword [esp], 0x504108
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
sub esp, 4
mov dword [esp + 0xc], str.get_user_keyfilepath
mov dword [esp + 8], str.system_core_adb_adb_auth_host.c
mov dword [esp + 4], 0x4c5318
mov dword [esp], eax
call fcn.0040e5a0
call esi
mov dword [eax], edi
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], ebx
mov dword [esp + 4], str.Cannot_mkdir__s
add eax, 0x40
mov dword [esp], eax
call fcn.0040e5a0
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp], eax
call sub.msvcrt.dll_fflush
mov dword [esp], 0x504108
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
call esi
mov dword [eax], edi
jmp 0x40e6bd
Function at 0x413140
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, eax
push esi
mov esi, edx
push ebx
sub esp, 0x2c
lea eax, [ebp - 0x20]
mov dword [esp], eax
call fcn.0041ab50
test eax, eax
jne 0x413298
mov dword [esp], 0xc
call sub.msvcrt.dll_malloc
test eax, eax
mov ebx, eax
je 0x413287
mov eax, dword [ebp - 0x1c]
mov dword [ebx], edi
mov dword [ebx + 8], esi
mov dword [ebx + 4], eax
mov dword [esp + 8], ebx
mov dword [esp + 4], 0
mov dword [esp], 0x412ec0
call dword [sym.imp.msvcrt.dll__beginthread]
cmp eax, 0xffffffff
je 0x413250
test byte [0x504121], 2
jne 0x4131b7
mov eax, dword [ebp - 0x20]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov ebx, dword [sym.imp.msvcrt.dll__errno]
call ebx
mov esi, dword [eax]
mov dword [esp], 0x504108
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
sub esp, 4
mov dword [esp + 0xc], str.create_service_thread
mov dword [esp + 8], str.system_core_adb_services.c
mov dword [esp + 4], 0x4c5fc9
mov dword [esp], eax
call fcn.00412f20
call ebx
mov dword [eax], esi
mov eax, dword [ebp - 0x1c]
mov dword [esp + 4], str.service_thread_started___d:_d_n
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x20]
mov dword [esp + 8], eax
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp], eax
call fcn.00412f20
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp], eax
call sub.msvcrt.dll_fflush
mov dword [esp], 0x504108
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
call ebx
mov dword [eax], esi
jmp 0x4131ac
mov dword [esp], ebx
call sub.msvcrt.dll_free
mov eax, dword [ebp - 0x20]
mov dword [esp], eax
call fcn.00419a30
mov eax, dword [ebp - 0x1c]
mov dword [esp], eax
call fcn.00419a30
mov dword [esp], str.cannot_create_service_thread_n
call fcn.00413120
lea esp, [ebp - 0xc]
mov eax, 0xffffffff
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp], str.cannot_allocate_stinfo
call fcn.004018e0
jmp 0x413176
mov dword [esp], str.cannot_create_service_socket_pair_n
call fcn.00413120
mov eax, 0xffffffff
jmp 0x4131af
Function at 0x415ba0
Capabilities:
Create thread

Disassembly:
sub esp, 0x1c
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], 0x416b00
call dword [sym.imp.msvcrt.dll__beginthread]
cmp eax, 0xffffffff
je 0x415bd0
add esp, 0x1c
ret
mov dword [esp], str.cannot_create_input_thread
call fcn.00401940
add esp, 0x1c
ret

Function at 0x416c70
Capabilities:
Get common file path
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push esi
push ebx
sub esp, 0x130
mov ebx, dword [ebp + 0xc]
mov dword [esp], str.ANDROID_SDK_HOME
call sub.msvcrt.dll_getenv
test eax, eax
je 0x416cc8
mov dword [esp + 0x14], str.adb_usb.ini
mov dword [esp + 0x10], str..android
mov dword [esp + 0xc], eax
mov eax, dword [ebp + 8]
mov dword [esp + 4], ebx
mov dword [esp + 8], str._s_s_s
mov dword [esp], eax
call fcn.00416bc0
cmp eax, ebx
setge al
lea esp, [ebp - 8]
movzx eax, al
pop ebx
pop esi
pop ebp
ret
lea esi, [ebp - 0x10c]
mov dword [esp + 0x10], esi
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0x28
mov dword [esp], 0
call dword [sym.imp.SHELL32.DLL_SHGetFolderPathA]
sub esp, 0x14
mov dword [esp + 0x14], str.adb_usb.ini
mov dword [esp + 0x10], str..android
mov dword [esp + 0xc], esi
jmp 0x416ca2
Function at 0x41aaf0
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x38
mov eax, dword [ebp + 8]
call fcn.00417110
mov dword [ebp - 0xc], 1
test eax, eax
je 0x41ab11
cmp dword [eax], 0x4c7428
je 0x41ab13
leave
ret
lea edx, [ebp - 0xc]
mov dword [esp + 0x10], 4
mov dword [esp + 0xc], edx
mov dword [esp + 8], 1
mov dword [esp + 4], 6
mov eax, dword [eax + 0xc]
mov dword [esp], eax
call dword [sym.imp.WS2_32.dll_setsockopt]
sub esp, 0x14
leave
ret