Function at 0x1001ea70
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create raw socket
Create tcp socket
Create udp socket
Resolve dns
Send data
Send data on socket

Disassembly:
sub esp, 0x194
push ebp
mov ebp, dword [esp + 0x19c]
test ebp, ebp
je 0x1001ea89
mov eax, dword [ebp + 4]
test eax, eax
jne 0x1001ea94
or eax, 0xffffffff
pop ebp
add esp, 0x194
ret
mov ecx, dword [0x100eaaac]
test ecx, ecx
mov eax, dword [0x100eaab0]
jne 0x1001eaa6
mov eax, dword [ebp + 8]
test eax, eax
mov dword [esp + 4], eax
jne 0x1001eab6
mov dword [esp + 4], 0x15
push ebx
xor eax, eax
test ecx, ecx
lea ebx, [ebp + 0x18]
mov edx, ebx
mov dword [edx], eax
mov dword [edx + 4], eax
mov dword [edx + 8], eax
mov dword [edx + 0xc], eax
je 0x1001ead0
push ecx
jmp 0x1001ead4
mov eax, dword [ebp + 4]
push eax
call dword [sym.imp.WSOCK32.dll_gethostbyname]
test eax, eax
jne 0x1001eafa
push str.gethostbyname_failed
push eax
push 9
call fcn.100651c0
add esp, 0xc
pop ebx
or eax, 0xffffffff
pop ebp
add esp, 0x194
ret
cmp word [eax + 0xa], 4
jbe 0x1001eb1e
push str.gethostbyname_address_mismatch
push 0
push 9
call fcn.100651c0
add esp, 0xc
pop ebx
or eax, 0xffffffff
pop ebp
add esp, 0x194
ret
mov word [ebx], 2
movsx ecx, word [eax + 0xa]
mov edx, dword [eax + 0xc]
push esi
mov esi, dword [edx]
mov eax, ecx
push edi
shr ecx, 2
lea edi, [ebp + 0x1c]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.WSOCK32.dll_htons]
push 0
push 1
push 2
mov word [ebp + 0x1a], ax
call dword [sym.imp.WSOCK32.dll_socket]
push 0x10
push ebx
push eax
mov dword [ebp + 0x2c], eax
call dword [sym.imp.WSOCK32.dll_connect]
test eax, eax
jge 0x1001eb77
push str.Failed_to_create_a_connection
push 0
jmp 0x1001ef4b
mov eax, ebp
call fcn.1001e6c0
cmp eax, 2
je 0x1001eb9e
mov eax, dword [ebp + 0x2c]
push eax
call dword [sym.imp.WSOCK32.dll_closesocket]
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov dword [ebp + 0x2c], eax
pop ebp
add esp, 0x194
ret
mov eax, dword [0x100eaaac]
test eax, eax
je 0x1001ed46
mov eax, dword [0x100eaab4]
test eax, eax
mov ebx, dword [sym.imp.msvcrt.dll__snprintf]
mov edi, dword [sym.imp.WSOCK32.dll_send]
je 0x1001ec9d
push eax
push str.USER__s_r_n
lea ecx, [esp + 0x1c]
push 0x190
push ecx
call ebx
lea eax, [esp + 0x24]
add esp, 0x10
mov byte [esp + 0x1a3], 0
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1001ebe8
sub eax, edx
push 0
push eax
mov eax, dword [ebp + 0x2c]
lea edx, [esp + 0x1c]
push edx
push eax
call edi
mov esi, eax
test esi, esi
jl 0x1001ed01
mov eax, ebp
call fcn.1001e6c0
dec eax
je 0x1001ec9d
dec eax
je 0x1001ec41
dec eax
jne 0x1001ef55
mov eax, dword [0x100eaab8]
test eax, eax
je 0x1001ec4c
push eax
push str.PASS__s_r_n
lea eax, [esp + 0x1c]
push 0x190
push eax
call ebx
add esp, 0x10
jmp 0x1001ec60
mov eax, dword [0x100eaab8]
test eax, eax
je 0x1001ec9d
jmp 0x1001ec2a
push str.PASS_anonymous__r_n
lea ecx, [esp + 0x18]
push 0x190
push ecx
call ebx
add esp, 0xc
lea eax, [esp + 0x14]
mov byte [esp + 0x1a3], 0
lea edx, [eax + 1]
nop
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1001ec70
sub eax, edx
push 0
push eax
mov eax, dword [ebp + 0x2c]
lea edx, [esp + 0x1c]
push edx
push eax
call edi
mov esi, eax
test esi, esi
jl 0x1001ed01
mov eax, ebp
call fcn.1001e6c0
cmp eax, 3
jg 0x1001ef55
mov eax, dword [0x100eaabc]
test eax, eax
jl 0x1001ed7b
cmp eax, 1
jle 0x1001ecbd
cmp eax, 2
je 0x1001eda3
jmp 0x1001ed7b
mov eax, dword [ebp + 4]
push eax
push str.SITE__s_r_n
lea ecx, [esp + 0x1c]
push 0x190
push ecx
call ebx
lea eax, [esp + 0x24]
add esp, 0x10
mov byte [esp + 0x1a3], 0
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1001ece4
sub eax, edx
push 0
push eax
mov eax, dword [ebp + 0x2c]
lea edx, [esp + 0x1c]
push edx
push eax
call edi
mov esi, eax
test esi, esi
jge 0x1001ed30
push str.send_failed
push 0
push 9
call fcn.100651c0
mov ecx, dword [ebp + 0x2c]
add esp, 0xc
push ecx
call dword [sym.imp.WSOCK32.dll_closesocket]
pop edi
mov eax, esi
pop esi
pop ebx
mov dword [ebp + 0x2c], 0xffffffff
pop ebp
add esp, 0x194
ret
mov eax, ebp
call fcn.1001e6c0
cmp eax, 2
jne 0x1001ed96
mov dword [0x100eaabc], 1
mov eax, ebp
call fcn.1001e8a0
test eax, eax
jl 0x1001ef55
mov eax, ebp
call fcn.1001e6c0
sub eax, 2
je 0x1001ef25
dec eax
jne 0x1001ef00
mov eax, ebp
call fcn.1001e940
test eax, eax
jge 0x1001ef32
mov ecx, dword [ebp + 0x2c]
push ecx
call dword [sym.imp.WSOCK32.dll_closesocket]
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov dword [ebp + 0x2c], eax
pop ebp
add esp, 0x194
ret
cmp dword [0x100eaabc], 1
je 0x1001ef55
mov eax, dword [ebp + 0x10]
test eax, eax
jne 0x1001edc4
mov eax, dword [ebp + 4]
push eax
push str.USER_anonymous__s_r_n
lea ecx, [esp + 0x1c]
push 0x190
push ecx
call ebx
add esp, 0x10
jmp 0x1001eddd
mov edx, dword [ebp + 4]
push edx
push eax
push str.USER__s__s_r_n
lea eax, [esp + 0x20]
push 0x190
push eax
call ebx
add esp, 0x14
lea eax, [esp + 0x14]
mov byte [esp + 0x1a3], 0
lea edx, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1001edf0
push 0
sub eax, edx
mov edx, dword [ebp + 0x2c]
push eax
lea ecx, [esp + 0x1c]
push ecx
push edx
call edi
mov esi, eax
test esi, esi
jge 0x1001ee3c
push str.send_failed
push 0
push 9
call fcn.100651c0
mov eax, dword [ebp + 0x2c]
add esp, 0xc
push eax
call dword [sym.imp.WSOCK32.dll_closesocket]
pop edi
mov eax, esi
pop esi
pop ebx
mov dword [ebp + 0x2c], 0xffffffff
pop ebp
add esp, 0x194
ret
mov eax, ebp
call fcn.1001e6c0
cmp eax, 1
je 0x1001ef1b
cmp eax, 2
je 0x1001ef1b
mov eax, dword [ebp + 0x14]
test eax, eax
jne 0x1001ee72
push str.PASS_anonymous__r_n
lea ecx, [esp + 0x18]
push 0x190
push ecx
call ebx
add esp, 0xc
jmp 0x1001ee87
push eax
push str.PASS__s_r_n
lea edx, [esp + 0x1c]
push 0x190
push edx
call ebx
add esp, 0x10
lea eax, [esp + 0x14]
mov byte [esp + 0x1a3], 0
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x1001ee96
mov ecx, dword [ebp + 0x2c]
push 0
sub eax, edx
push eax
lea eax, [esp + 0x1c]
push eax
push ecx
call edi
mov esi, eax
test esi, esi
jge 0x1001eee2
push str.send_failed
push 0
push 9
call fcn.100651c0
mov edx, dword [ebp + 0x2c]
add esp, 0xc
push edx
call dword [sym.imp.WSOCK32.dll_closesocket]
pop edi
mov eax, esi
pop esi
pop ebx
mov dword [ebp + 0x2c], 0xffffffff
pop ebp
add esp, 0x194
ret
mov eax, ebp
call fcn.1001e6c0
cmp eax, 1
je 0x1001ef1b
cmp eax, 2
je 0x1001ef1b
cmp dword [0x100eaabc], 2
jne 0x1001ed7b
mov eax, dword [ebp + 0x2c]
push eax
call dword [sym.imp.WSOCK32.dll_closesocket]
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov dword [ebp + 0x2c], eax
pop ebp
add esp, 0x194
ret
mov dword [0x100eaabc], 2
pop edi
pop esi
pop ebx
xor eax, eax
pop ebp
add esp, 0x194
ret
mov eax, ebp
call fcn.1001e6c0
sub eax, 2
je 0x1001ef25
dec eax
jne 0x1001ef55
push str.FTP_server_asking_for_ACCNT_on_anonymous_n
push 0x7d2
push 9
call fcn.100651c0
add esp, 0xc
mov edx, dword [ebp + 0x2c]
push edx
call dword [sym.imp.WSOCK32.dll_closesocket]
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov dword [ebp + 0x2c], eax
pop ebp
add esp, 0x194
ret