Function at 0x4023f0
Capabilities:
Connect socket
Get local ipv4 addresses
Get socket information
Set socket configuration

Disassembly:
mov eax, dword [0x42c4e8]
sub esp, 0x2cc
cmp eax, 0xffffffff
push ebx
push ebp
push esi
push edi
je 0x40242b
push str.FTP_ERR:_Cannot_reconnect_until_previous_connection_terminated.
push 0x41c060
call fcn.00408948
add esp, 8
call fcn.00401700
mov eax, 9
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2cc
ret
mov ebp, dword [esp + 0x2e4]
push ebp
call sub.WSOCK32.dll_inet_addr
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x402505
mov eax, dword [0x42c2d0]
xor ebx, ebx
cmp eax, ebx
je 0x4024cc
push 0x417080
push str.novaftp.log
call fcn.00408935
mov esi, eax
add esp, 8
cmp esi, ebx
je 0x4024ae
push ebp
push str.Attempting_DNS_lookup_on__s_n
push 0x42c2e0
call fcn.00408948
mov edi, 0x42c2e0
or ecx, 0xffffffff
xor eax, eax
add esp, 0xc
repne scasb al, byte es:[edi]
not ecx
dec ecx
push esi
push ecx
push 1
push 0x42c2e0
call fcn.00408440
mov edx, eax
mov edi, 0x42c2e0
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp edx, ecx
je 0x4024b4
mov dword [0x42c2d0], ebx
push esi
call fcn.0040860d
add esp, 4
test eax, eax
je 0x4024c7
mov dword [0x42c2d0], ebx
call fcn.00401600
lea eax, [esp + 0x10]
mov dword [esp + 0x10], ebx
push eax
push ebp
call fcn.004022f0
add esp, 8
cmp eax, ebx
jne 0x402ae8
mov eax, dword [esp + 0x10]
cmp eax, ebx
jne 0x4024fe
call fcn.00401c10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2cc
ret
mov ecx, dword [eax + 0xc]
mov edx, dword [ecx]
mov ebx, dword [edx]
mov eax, dword [0x42c2d0]
test eax, eax
je 0x402599
push 0x417080
push str.novaftp.log
call fcn.00408935
mov esi, eax
add esp, 8
test esi, esi
je 0x402573
push ebx
push ebp
push str.IP_address_for__s_is:___X_n
push 0x42c2e0
call fcn.00408948
mov edi, 0x42c2e0
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
repne scasb al, byte es:[edi]
not ecx
dec ecx
push esi
push ecx
push 1
push 0x42c2e0
call fcn.00408440
mov edx, eax
mov edi, 0x42c2e0
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp edx, ecx
je 0x40257d
mov dword [0x42c2d0], 0
push esi
call fcn.0040860d
add esp, 4
test eax, eax
je 0x402594
mov dword [0x42c2d0], 0
call fcn.00401600
mov edi, dword [esp + 0x2ec]
test edi, edi
jne 0x4025ce
mov eax, dword [str.anonymous]
mov ecx, dword [0x417ad4]
mov dx, word [0x417ad8]
mov dword [esp + 0xdc], eax
mov dword [esp + 0xe0], ecx
mov word [esp + 0xe4], dx
jmp 0x4025f2
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0xdc]
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [esp + 0x2f0]
test edi, edi
jne 0x402613
mov ecx, 5
mov esi, str.wizard_novalogic.com
lea edi, [esp + 0x1dc]
rep movsd dword es:[edi], dword [esi]
movsb byte es:[edi], byte [esi]
jmp 0x402637
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x1dc]
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
xor edi, edi
push edi
push 1
push 2
call sub.WSOCK32.dll_socket
cmp eax, 0xffffffff
mov dword [0x42c4e8], eax
jne 0x40265d
call fcn.00401c10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2cc
ret
lea ecx, [esp + 0x14]
push 4
push ecx
push 8
push 0xffff
push eax
mov dword [esp + 0x28], 1
call sub.WSOCK32.dll_setsockopt
push 0x15
mov word [esp + 0x24], 2
mov dword [esp + 0x28], ebx
call sub.WSOCK32.dll_htons
mov word [esp + 0x22], ax
mov eax, dword [0x42c2d0]
cmp eax, edi
je 0x402723
push 0x417080
push str.novaftp.log
call fcn.00408935
mov esi, eax
add esp, 8
cmp esi, edi
jne 0x4026bd
mov dword [0x42c2d0], edi
jmp 0x40270b
push str.Connecting_to_ftp_server_n
push 0x42c2e0
call fcn.00408948
mov edi, 0x42c2e0
or ecx, 0xffffffff
xor eax, eax
add esp, 8
repne scasb al, byte es:[edi]
not ecx
dec ecx
push esi
push ecx
push 1
push 0x42c2e0
call fcn.00408440
mov edx, eax
mov edi, 0x42c2e0
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp edx, ecx
je 0x402709
mov dword [0x42c2d0], eax
xor edi, edi
push esi
call fcn.0040860d
add esp, 4
test eax, eax
je 0x40271e
mov dword [0x42c2d0], edi
call fcn.00401600
mov ebp, dword [esp + 0x2e0]
mov edx, dword [0x42c4e8]
push 0x10
push 0xbd1
push ebp
push edx
mov dword [0x42c4e4], edi
mov dword [0x42c4ec], edi
call sub.WSOCK32.dll_WSAAsyncSelect
cmp eax, 0xffffffff
jne 0x40275f
call fcn.00401c10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2cc
ret
mov ecx, dword [0x42c4e8]
lea eax, [esp + 0x20]
push 0x10
push eax
push ecx
call sub.WSOCK32.dll_connect
cmp eax, 0xffffffff
jne 0x402793
call sub.WSOCK32.dll_WSAGetLastError
cmp eax, 0x2733
je 0x402793
call fcn.00401c10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2cc
ret
cmp dword [0x42c4e4], 0x10
je 0x4027eb
mov esi, dword [sym.imp.USER32.dll_PeekMessageA]
mov ebx, dword [sym.imp.USER32.dll_TranslateMessage]
push 1
push edi
push edi
lea edx, [esp + 0x4c]
push edi
push edx
call esi
test eax, eax
je 0x4027e2
mov eax, dword [esp + 0x44]
cmp eax, 0x12
je 0x402af3
cmp eax, 0xbd2
je 0x402af3
lea eax, [esp + 0x40]
push eax
call ebx
lea ecx, [esp + 0x40]
push ecx
call dword [sym.imp.USER32.dll_DispatchMessageA]
cmp dword [0x42c4e4], 0x10
jne 0x4027a8
cmp dword [0x42c4ec], edi
je 0x402803
call fcn.00401c10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2cc
ret
mov edx, dword [0x42c4e8]
push edi
push edi
push ebp
push edx
call sub.WSOCK32.dll_WSAAsyncSelect
cmp eax, 0xffffffff
jne 0x402827
call fcn.00401c10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2cc
ret
mov ecx, dword [0x42c4e8]
lea eax, [esp + 0x18]
push eax
push 0x8004667e
push ecx
mov dword [esp + 0x24], edi
call sub.WSOCK32.dll_ioctlsocket
mov edx, dword [esp + 0x24]
mov ebx, dword [esp + 0x22]
push edx
call fcn.004022c0
mov edi, eax
or ecx, 0xffffffff
xor eax, eax
add esp, 4
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
and ebx, 0xffff
mov eax, ecx
mov esi, edi
mov edi, 0x42c2a0
push ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
push 0x417a98
rep movsb byte es:[edi], byte [esi]
mov edi, 0x417a94
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, 0x42c2a0
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x42c2a0
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, 0x42c2a0
push ecx
call fcn.00408948
mov ebx, dword [sym.imp.USER32.dll_PostMessageA]
add esp, 0xc
push 0x42c2a0
push 4
push 0xbd0
push ebp
call ebx
mov eax, dword [0x42c2d0]
test eax, eax
je 0x402975
push 0x417080
push str.novaftp.log
call fcn.00408935
mov esi, eax
add esp, 8
test esi, esi
je 0x40294f
push 0x42c2a0
push str.Received_ftp_server_control_connection_from__s_n
push 0x42c2e0
call fcn.00408948
mov edi, 0x42c2e0
or ecx, 0xffffffff
xor eax, eax
add esp, 0xc
repne scasb al, byte es:[edi]
not ecx
dec ecx
push esi
push ecx
push 1
push 0x42c2e0
call fcn.00408440
mov edx, eax
mov edi, 0x42c2e0
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp edx, ecx
je 0x402959
mov dword [0x42c2d0], 0
push esi
call fcn.0040860d
add esp, 4
test eax, eax
je 0x402970
mov dword [0x42c2d0], 0
call fcn.00401600
push ebp
call fcn.004021e0
add esp, 4
test eax, eax
jne 0x402ae8
mov eax, dword [str.USER]
mov cx, word [0x417a60]
mov dword [esp + 0x5c], eax
mov word [esp + 0x60], cx
lea edi, [esp + 0xdc]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x5c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea edx, [esp + 0x5c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x417988
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x5c]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
push ebp
call fcn.00402200
add esp, 8
test eax, eax
jne 0x402ae8
mov ecx, dword [str.PASS]
lea edi, [esp + 0x1dc]
mov dword [esp + 0x5c], ecx
or ecx, 0xffffffff
mov dx, word [0x417a58]
repne scasb al, byte es:[edi]
not ecx
mov word [esp + 0x60], dx
sub edi, ecx
lea edx, [esp + 0x5c]
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea edx, [esp + 0x5c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x417988
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x5c]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
push ebp
call fcn.00402200
add esp, 8
test eax, eax
jne 0x402ae8
mov eax, dword [0x42c4e8]
lea ecx, [esp + 0x1c]
lea edx, [esp + 0x30]
push ecx
push edx
push eax
mov dword [esp + 0x28], 0x10
call sub.WSOCK32.dll_getsockname
mov eax, dword [esp + 0x34]
xor edx, edx
mov dl, byte [esp + 0x36]
mov ecx, eax
shr ecx, 0x18
push ecx
xor ecx, ecx
mov cl, ah
push edx
and eax, 0xff
push ecx
push eax
push str.PORT__d__d__d__d_
push 0x41bb00
call fcn.00408948
add esp, 0x18
push 2
push 3
push 0xbd0
push ebp
call ebx
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2cc
ret
push str.FTP_ERR:_Cancelling_connection_due_to_user_abort.
push 0x41c060
call fcn.00408948
add esp, 8
call fcn.00401700
pop edi
pop esi
pop ebp
mov eax, 4
pop ebx
add esp, 0x2cc
ret