Function at 0x403060
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x2080
call fcn.00459eb0
mov eax, dword [0x47f160]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x2078], eax
mov dword [ebp - 0x207c], ecx
push edi
mov dword [ebp - 0x2080], edx
mov ecx, str.kill
mov eax, esi
lea esp, [esp]
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x4030c0
test dl, dl
je 0x4030bc
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x4030c0
add eax, 2
add ecx, 2
test dl, dl
jne 0x4030a0
xor eax, eax
jmp 0x4030c5
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x403116
mov esi, dword [sym.imp.MSVCR100.dll___iob_func]
push str.adb_server_killed_by_remote_request_n
call esi
add eax, 0x40
push eax
call dword [sym.imp.MSVCR100.dll_fprintf]
call esi
add eax, 0x20
push eax
call dword [sym.imp.MSVCR100.dll_fflush]
mov eax, dword [ebp + 0x10]
push eax
call fcn.0040ec90
add esp, 0x10
test eax, eax
je 0x40310e
mov ecx, dword [eax]
mov edx, dword [ecx + 0x10]
push 4
push str.OKAY
push eax
call edx
add esp, 0xc
push 0
call dword [sym.imp.MSVCR100.dll_exit]
mov edi, dword [sym.imp.MSVCR100.dll_strncmp]
push 9
push str.transport
push esi
call edi
add esp, 0xc
test eax, eax
jne 0x403215
push 0xd
push str.transport_usb
push esi
mov dword [ebp - 0x2078], str.unknown_failure
lea ebx, [eax + 2]
call edi
add esp, 0xc
test eax, eax
jne 0x403153
xor ebx, ebx
jmp 0x403194
push 0xf
push str.transport_local
push esi
call edi
add esp, 0xc
test eax, eax
jne 0x403169
lea ebx, [eax + 1]
jmp 0x403194
push 0xd
push str.transport_any
push esi
call edi
add esp, 0xc
test eax, eax
je 0x403194
push 0xa
push str.transport:
push esi
call edi
add esp, 0xc
test eax, eax
jne 0x403194
add esi, 0xa
mov dword [ebp - 0x207c], esi
lea eax, [ebp - 0x2078]
push eax
push ebx
mov ebx, dword [ebp - 0x207c]
push 0xffffffffffffffff
call fcn.00414920
add esp, 0xc
test eax, eax
je 0x4031f1
mov edx, dword [ebp + 0x10]
mov ecx, dword [ebp - 0x2080]
push edx
mov dword [ecx + 0x50], eax
call fcn.0040ec90
add esp, 4
test eax, eax
je 0x4031ff
mov ecx, dword [eax]
mov edx, dword [ecx + 0x10]
push 4
push str.OKAY
push eax
call edx
add esp, 0xc
pop edi
pop esi
mov eax, 1
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00459991
mov esp, ebp
pop ebp
ret
mov edi, dword [ebp - 0x2078]
mov ebx, dword [ebp + 0x10]
call fcn.0040c090
pop edi
pop esi
mov eax, 1
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00459991
mov esp, ebp
pop ebp
ret
push 7
push str.devices
push esi
call edi
add esp, 0xc
test eax, eax
jne 0x403420
mov ecx, 0x46dd48
lea eax, [esi + 7]
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x403252
test dl, dl
je 0x40324e
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x403252
add eax, 2
add ecx, 2
test dl, dl
jne 0x403232
xor eax, eax
jmp 0x403257
sbb eax, eax
sbb eax, 0xffffffff
xor ecx, ecx
test eax, eax
sete cl
mov eax, ecx
mov dword [ebp - 0x2080], eax
test eax, eax
jne 0x403273
cmp byte [esi + 7], cl
jne 0x403420
push 0x1000
lea edx, [ebp - 0x1074]
push 0
push edx
call sub.MSVCR100.dll_memset
push 0x1000
lea eax, [ebp - 0x2074]
push 0
push eax
call sub.MSVCR100.dll_memset
mov ebx, dword [sym.imp.MSVCR100.dll_fprintf]
mov esi, dword [sym.imp.MSVCR100.dll___iob_func]
mov edi, dword [sym.imp.MSVCR100.dll__errno]
add esp, 0x18
test byte [0x4805a8], 1
je 0x403321
call edi
mov ecx, dword [eax]
push 0x480590
mov dword [ebp - 0x2078], ecx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push str.handle_host_request
push str.adb.cpp
push str._s::_s__:
call esi
add eax, 0x40
push eax
call ebx
add esp, 0x10
call edi
mov edx, dword [ebp - 0x2078]
push str.Getting_device_list__n
mov dword [eax], edx
call esi
add eax, 0x40
push eax
call ebx
call esi
add eax, 0x40
push eax
call dword [sym.imp.MSVCR100.dll_fflush]
add esp, 0xc
push 0x480590
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call edi
mov ecx, dword [ebp - 0x2078]
mov dword [eax], ecx
mov edx, dword [ebp - 0x2080]
push edx
lea eax, [ebp - 0x2074]
push eax
mov eax, 0x1000
call fcn.00414b50
lea eax, [ebp - 0x2074]
add esp, 8
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x403345
lea ecx, [ebp - 0x2074]
push ecx
sub eax, edx
push eax
push str.OKAY_04x_s
lea edx, [ebp - 0x1074]
push 0x1000
push edx
call dword [sym.imp.MSVCR100.dll__snprintf]
add esp, 0x14
test byte [0x4805a8], 1
je 0x4033e3
call edi
mov eax, dword [eax]
push 0x480590
mov dword [ebp - 0x2078], eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push str.handle_host_request
push str.adb.cpp
push str._s::_s__:
call esi
add eax, 0x40
push eax
call ebx
add esp, 0x10
call edi
mov ecx, dword [ebp - 0x2078]
push str.Wrote_device_list__n
mov dword [eax], ecx
call esi
add eax, 0x40
push eax
call ebx
call esi
add eax, 0x40
push eax
call dword [sym.imp.MSVCR100.dll_fflush]
add esp, 0xc
push 0x480590
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call edi
mov edx, dword [ebp - 0x2078]
mov dword [eax], edx
lea eax, [ebp - 0x1074]
lea edx, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4033f0
mov ecx, dword [ebp + 0x10]
sub eax, edx
push eax
lea eax, [ebp - 0x1074]
push eax
push ecx
call fcn.00415560
add esp, 0xc
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00459991
mov esp, ebp
pop ebp
ret
push 8
push str.connect:
push esi
call edi
add esp, 0xc
test eax, eax
jne 0x4034b0
push 4
add esi, 8
push str.emu:
push esi
call edi
add esp, 0xc
lea edx, [ebp - 0x2074]
test eax, eax
jne 0x40345a
push edx
add esi, 4
push esi
call fcn.00402f40
add esp, 8
jmp 0x403461
mov ecx, esi
call fcn.00402ce0
lea eax, [ebp - 0x2074]
lea edx, [eax + 1]
lea ebx, [ebx]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x403470
lea ecx, [ebp - 0x2074]
push ecx
sub eax, edx
push eax
push str.OKAY_04x_s
lea edx, [ebp - 0x1074]
push 0x1000
push edx
call dword [sym.imp.MSVCR100.dll__snprintf]
lea eax, [ebp - 0x1074]
add esp, 0x14
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4034a4
jmp 0x4033f7
push 0xb
push str.disconnect:
push esi
call edi
add esp, 0xc
test eax, eax
jne 0x40358f
push 0x1000
push eax
lea edx, [ebp - 0x2074]
push edx
call sub.MSVCR100.dll_memset
mov ebx, dword [sym.imp.MSVCR100.dll__snprintf]
lea edi, [esi + 0xb]
add esp, 0xc
cmp byte [edi], 0
jne 0x4034ef
call fcn.00415030
jmp 0x40353c
push 0x3a
push edi
call dword [sym.imp.MSVCR100.dll_strchr]
add esp, 8
test eax, eax
jne 0x403513
push edi
push str._s:5555
lea eax, [ebp - 0x74]
push 0x63
push eax
call ebx
add esp, 0x10
lea edi, [ebp - 0x74]
call fcn.00414f30
test eax, eax
je 0x403525
mov esi, eax
call fcn.00414fb0
jmp 0x40353c
push edi
push str.No_such_device__s
lea ecx, [ebp - 0x2074]
push 0x1000
push ecx
call ebx
add esp, 0x10
lea eax, [ebp - 0x2074]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x403545
sub eax, edx
lea edx, [ebp - 0x2074]
push edx
push eax
push str.OKAY_04x_s
lea eax, [ebp - 0x1074]
push 0x1000
push eax
call ebx
lea eax, [ebp - 0x1074]
add esp, 0x14
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x403575
sub eax, edx
mov edx, dword [ebp + 0x10]
push eax
lea ecx, [ebp - 0x1074]
push ecx
push edx
jmp 0x403405
mov ecx, str.version
mov eax, esi
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x4035b6
test dl, dl
je 0x4035b2
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x4035b6
add eax, 2
add ecx, 2
test dl, dl
jne 0x403596
xor eax, eax
jmp 0x4035bb
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x40361c
mov esi, dword [sym.imp.MSVCR100.dll__snprintf]
push str.kg01
push 0x46dde4
lea eax, [ebp - 0x10]
push 0xc
push eax
call esi
lea eax, [ebp - 0x10]
add esp, 0x10
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4035e0
lea ecx, [ebp - 0x10]
push ecx
sub eax, edx
push eax
push str.OKAY_04x_s
lea edx, [ebp - 0x1074]
push 0x1000
push edx
call esi
lea eax, [ebp - 0x1074]
add esp, 0x14
lea edx, [eax + 1]
lea ecx, [ecx]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x403610
jmp 0x4033f7
push 0xc
push str.get_serialno
push esi
call edi
add esp, 0xc
test eax, eax
jne 0x4036aa
mov edx, dword [ebp - 0x2078]
mov ebx, dword [ebp - 0x207c]
push eax
push edx
push 0xffffffffffffffff
mov esi, str.unknown
call fcn.00414920
add esp, 0xc
test eax, eax
je 0x40365b
mov eax, dword [eax + 0x58]
test eax, eax
je 0x40365b
mov esi, eax
mov eax, esi
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x403660
push esi
sub eax, edx
push eax
push str.OKAY_04x_s
lea eax, [ebp - 0x1074]
push 0x1000
push eax
call dword [sym.imp.MSVCR100.dll__snprintf]
lea eax, [ebp - 0x1074]
add esp, 0x14
lea edx, [eax + 1]
mov edi, edi
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x403690
sub eax, edx
mov edx, dword [ebp + 0x10]
push eax
lea ecx, [ebp - 0x1074]
push ecx
push edx
jmp 0x403405
push 0xb
push str.get_devpath
push esi
call edi
add esp, 0xc
test eax, eax
jne 0x40373a
mov ebx, dword [ebp - 0x207c]
push eax
mov eax, dword [ebp - 0x2078]
push eax
push 0xffffffffffffffff
mov esi, str.unknown
call fcn.00414920
add esp, 0xc
test eax, eax
je 0x4036e9
mov eax, dword [eax + 0x68]
test eax, eax
je 0x4036e9
mov esi, eax
mov eax, esi
lea edx, [eax + 1]
mov edi, edi
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4036f0
push esi
sub eax, edx
push eax
push str.OKAY_04x_s
lea ecx, [ebp - 0x1074]
push 0x1000
push ecx
call dword [sym.imp.MSVCR100.dll__snprintf]
lea eax, [ebp - 0x1074]
add esp, 0x14
lea edx, [eax + 1]
mov edi, edi
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x403720
sub eax, edx
push eax
mov eax, dword [ebp + 0x10]
lea edx, [ebp - 0x1074]
push edx
push eax
jmp 0x403405
push 9
push str.emulator:
push esi
call edi
add esp, 0xc
test eax, eax
jne 0x403762
add esi, 9
push esi
call dword [sym.imp.MSVCR100.dll_atoi]
push eax
dec eax
push eax
call fcn.00415b70
jmp 0x40340a
push 8
push str.forward:
push esi
call edi
add esp, 0xc
test eax, eax
je 0x403840
push 0xc
push str.killforward:
push esi
call edi
add esp, 0xc
test eax, eax
je 0x403840
push 9
push str.get_state
push esi
call edi
add esp, 0xc
test eax, eax
jne 0x40382c
mov ecx, dword [ebp - 0x2078]
mov ebx, dword [ebp - 0x207c]
push eax
push ecx
push 0xffffffffffffffff
call fcn.00414920
add esp, 0xc
test eax, eax
jne 0x4037c4
mov edx, str.unknown
jmp 0x4037ec
mov eax, dword [eax + 0x44]
sub eax, 0
je 0x4037e7
dec eax
je 0x4037e0
dec eax
je 0x4037d9
mov edx, str.unknown
jmp 0x4037ec
mov edx, str.device
jmp 0x4037ec
mov edx, str.bootloader
jmp 0x4037ec
mov edx, str.offline
mov eax, edx
lea esi, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4037f1
push edx
sub eax, esi
push eax
push str.OKAY_04x_s
lea edx, [ebp - 0x1074]
push 0x1000
push edx
call dword [sym.imp.MSVCR100.dll__snprintf]
lea eax, [ebp - 0x1074]
add esp, 0x14
lea edx, [eax + 1]
nop
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x403820
jmp 0x4033f7
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00459991
mov esp, ebp
pop ebp
ret
push 4
push str.kill
push esi
call edi
xor edx, edx
test eax, eax
sete dl
push 0x3b
mov dword [ebp - 0x2080], eax
lea edi, [edx*4 + 8]
add edi, esi
push edi
call dword [sym.imp.MSVCR100.dll_strchr]
mov esi, eax
add esp, 0x14
test esi, esi
je 0x403914
mov byte [esi], 0
inc esi
cmp byte [edi], 0
je 0x403914
mov al, byte [esi]
test al, al
je 0x403914
cmp al, 0x2a
je 0x403914
mov ecx, dword [ebp - 0x2078]
mov ebx, dword [ebp - 0x207c]
lea eax, [ebp - 0x2078]
push eax
push ecx
push 0xffffffffffffffff
call fcn.00414920
add esp, 0xc
test eax, eax
jne 0x4038bf
mov edi, dword [ebp - 0x2078]
jmp 0x403919
cmp dword [ebp - 0x2080], 0
push eax
je 0x4038d5
push esi
push edi
call fcn.004025d0
add esp, 0xc
jmp 0x4038df
mov ebx, edi
call fcn.00402530
add esp, 4
test eax, eax
jne 0x4038f3
mov edx, dword [ebp + 0x10]
push 8
push str.OKAYOKAY
push edx
jmp 0x403405
cmp dword [ebp - 0x2080], 0
je 0x40390d
mov edi, str.cannot_rebind_smartsocket
cmp eax, 0xffffffff
je 0x403919
mov edi, str.cannot_bind_socket
jmp 0x403919
mov edi, str.cannot_remove_listener
jmp 0x403919
mov edi, str.malformed_forward_spec
mov ebx, dword [ebp + 0x10]
call fcn.0040c090
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
xor eax, eax
pop ebx
call fcn.00459991
mov esp, ebp
pop ebp
ret