Function at 0x4b84a0
Capabilities:
Connect socket

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5c3249
mov eax, dword fs:[0]
push eax
sub esp, 0x138
mov eax, dword [0x6926e4]
xor eax, ebp
mov dword [ebp - 0x30], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x144], ecx
mov eax, dword [ebp + 0x1c]
mov byte [eax], 0
mov ecx, dword [ebp - 0x144]
mov dword [ecx + 0x150], 0
mov edx, dword [ebp + 0x18]
mov byte [edx], 0
mov ecx, dword [ebp - 0x144]
add ecx, 0x128
call fcn.004104d0
cmp dword [ebp + 8], 0
jne 0x4b852d
mov eax, dword [ebp - 0x144]
mov dword [eax + 0x150], 1
push 0x6227b0
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x10]
call eax
xor al, al
jmp 0x4b8fae
mov ecx, dword [ebp + 8]
push ecx
lea ecx, [ebp - 0x6c]
call fcn.00411b80
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x6c]
call fcn.0040fee0
push 0x621421
push 0x6227d4
lea ecx, [ebp - 0x6c]
call fcn.00412820
push 0x621422
push 0x6227dc
lea ecx, [ebp - 0x6c]
call fcn.00412820
push 0x2f
lea ecx, [ebp - 0x6c]
call fcn.00414050
lea ecx, [ebp - 0x6c]
call fcn.004d7880
test eax, eax
jne 0x4b85c5
mov edx, dword [ebp - 0x144]
mov dword [edx + 0x150], 1
push 0x6227e8
mov eax, dword [ebp + 0x10]
mov edx, dword [eax]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x10]
call eax
mov byte [ebp - 0x139], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x6c]
call fcn.00412130
mov al, byte [ebp - 0x139]
jmp 0x4b8fae
push 0x622810
lea ecx, [ebp - 0x6c]
call fcn.004147b0
movzx ecx, al
test ecx, ecx
je 0x4b85fc
push 0x62281c
mov ecx, dword [ebp - 0x144]
add ecx, 0x128
call fcn.00413f10
push 0x622828
lea ecx, [ebp - 0x6c]
call fcn.00413f10
movzx edx, byte [0x6897c4]
test edx, edx
je 0x4b8613
mov eax, dword [ebp + 0x10]
push eax
call fcn.004b5e40
add esp, 4
lea ecx, [ebp - 0xbc]
call fcn.00411d60
mov byte [ebp - 4], 1
mov ecx, dword [ebp + 0xc]
push ecx
lea ecx, [ebp - 0xbc]
call fcn.00411080
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0xc0], 0
push 0x20
push 0
lea edx, [ebp - 0x94]
push edx
call fcn.0057e0b0
add esp, 0xc
mov dword [ebp - 0x94], 8
mov dword [ebp - 0x90], 0
mov dword [ebp - 0x8c], 1
lea eax, [ebp - 0x44]
push eax
lea ecx, [ebp - 0x6c]
call fcn.0040fc00
push eax
push 2
call fcn.004b8fd0
add esp, 0xc
movzx ecx, al
test ecx, ecx
je 0x4b86be
push str.This_is_an_IPV4_numeric_address...
mov edx, dword [ebp + 0x10]
mov eax, dword [edx]
mov ecx, dword [ebp + 0x10]
mov edx, dword [eax + 0x14]
call edx
mov dword [ebp - 0x90], 2
mov eax, dword [ebp - 0x94]
or eax, 4
mov dword [ebp - 0x94], eax
jmp 0x4b8707
lea ecx, [ebp - 0x44]
push ecx
lea ecx, [ebp - 0x6c]
call fcn.0040fc00
push eax
push 0x17
call fcn.004b8fd0
add esp, 0xc
movzx edx, al
test edx, edx
je 0x4b8707
push str.This_is_an_IPV6_numeric_address...
mov eax, dword [ebp + 0x10]
mov edx, dword [eax]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x14]
call eax
mov dword [ebp - 0x90], 0x17
mov ecx, dword [ebp - 0x94]
or ecx, 4
mov dword [ebp - 0x94], ecx
cmp dword [0x696bf8], 0
jne 0x4b875e
mov edx, dword [ebp + 0x18]
push edx
mov eax, dword [ebp + 0x14]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp + 8]
push eax
mov ecx, dword [ebp - 0x144]
call fcn.004b7930
mov byte [ebp - 0x13a], al
mov byte [ebp - 4], 0
lea ecx, [ebp - 0xbc]
call fcn.00412130
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x6c]
call fcn.00412130
mov al, byte [ebp - 0x13a]
jmp 0x4b8fae
lea ecx, [ebp - 0x1c]
push ecx
lea edx, [ebp - 0x94]
push edx
lea ecx, [ebp - 0xbc]
call fcn.0040fc00
push eax
lea ecx, [ebp - 0x6c]
call fcn.0040fc00
push eax
call dword [0x696bf8]
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
je 0x4b886c
push str.Failed_to_get_host_address_info.__1_
mov eax, dword [ebp + 0x10]
mov edx, dword [eax]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x10]
call eax
push 0x6228a8
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x14]
call eax
push 0x6228f8
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x14]
call eax
mov ecx, dword [ebp + 0x10]
push ecx
call fcn.004b6920
add esp, 4
lea ecx, [ebp - 0x6c]
call fcn.0040fc00
push eax
push 0x62296c
mov edx, dword [ebp + 0x10]
mov eax, dword [edx]
mov ecx, dword [ebp + 0x10]
mov edx, dword [eax + 0x28]
call edx
lea ecx, [ebp - 0xbc]
call fcn.0040fc00
push eax
push 0x62297c
mov eax, dword [ebp + 0x10]
mov edx, dword [eax]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x28]
call eax
push str.reverting_to_gethostbyname...
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x14]
call eax
mov ecx, dword [ebp + 0x18]
push ecx
mov edx, dword [ebp + 0x14]
push edx
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
mov ecx, dword [ebp - 0x144]
call fcn.004b7930
mov byte [ebp - 0x13b], al
mov byte [ebp - 4], 0
lea ecx, [ebp - 0xbc]
call fcn.00412130
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x6c]
call fcn.00412130
mov al, byte [ebp - 0x13b]
jmp 0x4b8fae
cmp dword [ebp - 0x1c], 0
je 0x4b89b1
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
mov ecx, dword [ebp - 0x144]
call fcn.004b82d0
mov edx, dword [ebp - 0x1c]
push edx
mov ecx, dword [ebp - 0x144]
call fcn.004b8400
mov dword [ebp - 0xc0], eax
cmp dword [ebp - 0xc0], 0
jne 0x4b88bc
mov eax, dword [ebp - 0x1c]
push eax
mov ecx, dword [ebp - 0x144]
call fcn.004b8450
mov dword [ebp - 0xc0], eax
cmp dword [ebp - 0xc0], 0
jne 0x4b88ce
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc0], ecx
mov edx, dword [ebp - 0xc0]
cmp dword [edx + 4], 2
jne 0x4b88ee
push str.Connect_using_IPV4.
mov eax, dword [ebp + 0x10]
mov edx, dword [eax]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x14]
call eax
jmp 0x4b8900
push str.Connect_using_IPV6.
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x14]
call eax
mov dword [ebp - 0xc8], 0
mov ecx, dword [ebp - 0xc0]
cmp dword [ecx + 4], 2
jne 0x4b8936
mov edx, dword [ebp - 0xc0]
mov eax, dword [edx + 0x18]
mov dword [ebp - 0xcc], eax
mov ecx, dword [ebp - 0xcc]
add ecx, 4
mov dword [ebp - 0xc8], ecx
jmp 0x4b8954
mov edx, dword [ebp - 0xc0]
mov eax, dword [edx + 0x18]
mov dword [ebp - 0xd0], eax
mov ecx, dword [ebp - 0xd0]
add ecx, 8
mov dword [ebp - 0xc8], ecx
mov ecx, dword [ebp - 0x144]
add ecx, 0x128
call fcn.004104d0
mov edx, dword [ebp - 0x144]
add edx, 0x128
push edx
mov eax, dword [ebp - 0xc8]
push eax
mov ecx, dword [ebp - 0xc0]
mov edx, dword [ecx + 4]
push edx
call fcn.004b51c0
add esp, 0xc
mov ecx, dword [ebp - 0x144]
add ecx, 0x128
call fcn.0040fc00
push eax
push str.ipAddress1
mov eax, dword [ebp + 0x10]
mov edx, dword [eax]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x28]
call eax
jmp 0x4b8a10
push str.Failed_to_get_host_address_info.__5_
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x10]
call eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp - 0x1c]
push edx
call fcn.004b9020
add esp, 8
mov dword [ebp - 0x1c], 0
mov eax, dword [ebp + 0x1c]
mov byte [eax], 1
mov byte [ebp - 0x13c], 0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0xbc]
call fcn.00412130
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x6c]
call fcn.00412130
mov al, byte [ebp - 0x13c]
jmp 0x4b8fae
push 1
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp - 0xc0]
push edx
mov ecx, dword [ebp - 0x144]
call fcn.004b6290
mov byte [ebp - 0x25], al
movzx eax, byte [ebp - 0x25]
test eax, eax
je 0x4b8a42
mov ecx, dword [ebp - 0x144]
cmp dword [ecx + 0xa4], 0xffffffff
jne 0x4b8aab
mov edx, dword [ebp - 0x144]
mov dword [edx + 0x150], 5
push str.Cannot_connect__invalid_socket__2_
mov eax, dword [ebp + 0x10]
mov edx, dword [eax]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x10]
call eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp - 0x1c]
push edx
call fcn.004b9020
add esp, 8
mov dword [ebp - 0x1c], 0
mov byte [ebp - 0x13d], 0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0xbc]
call fcn.00412130
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x6c]
call fcn.00412130
mov al, byte [ebp - 0x13d]
jmp 0x4b8fae
mov eax, dword [ebp - 0x144]
cmp dword [eax + 0x11c], 0
je 0x4b8ac5
mov ecx, dword [ebp - 0x144]
call fcn.004b5b70
mov ecx, dword [ebp - 0x144]
mov edx, dword [ecx + 0x11c]
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x14], 0
mov byte [ebp - 0xd], 0
mov dword [ebp - 0x70], 0x64
call fcn.00440b60
mov dword [ebp - 0xc4], eax
cmp dword [ebp - 0x14], 0
je 0x4b8b26
mov eax, dword [ebp - 0x2c]
cmp eax, dword [ebp - 0x70]
jb 0x4b8b1b
mov ecx, dword [ebp - 0x2c]
sub ecx, dword [ebp - 0x70]
mov dword [ebp - 0x2c], ecx
cmp dword [ebp - 0x2c], 0x64
jae 0x4b8b19
mov byte [ebp - 0xd], 1
mov dword [ebp - 0x2c], 0x64
jmp 0x4b8b26
mov byte [ebp - 0xd], 1
mov dword [ebp - 0x2c], 0x64
mov dword [ebp - 0x20], 0
mov byte [ebp - 0x71], 0
mov edx, dword [ebp - 0xc0]
mov eax, dword [edx + 0x10]
push eax
mov ecx, dword [ebp - 0xc0]
mov edx, dword [ecx + 0x18]
push edx
mov eax, dword [ebp - 0x144]
mov ecx, dword [eax + 0xa4]
push ecx
call dword [sym.imp.WS2_32.dll_connect]
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
je 0x4b8bcc
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0x2733
je 0x4b8bcc
cmp dword [ebp - 0x20], 0x2726
jne 0x4b8bb6
lea ecx, [ebp - 0x6c]
call fcn.0040fc00
push eax
push 0x622a24
mov edx, dword [ebp + 0x10]
mov eax, dword [edx]
mov ecx, dword [ebp + 0x10]
mov edx, dword [eax + 0x28]
call edx
mov eax, dword [ebp - 0x144]
mov ecx, dword [eax + 0xa4]
push ecx
push 0x622a34
mov edx, dword [ebp + 0x10]
mov eax, dword [edx]
mov ecx, dword [ebp + 0x10]
mov edx, dword [eax + 0x34]
call edx
mov eax, dword [ebp - 0x20]
push eax
push 0x622a44
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x2c]
call eax
cmp dword [ebp - 0x24], 0
je 0x4b8db3
cmp dword [ebp - 0x2c], 0
je 0x4b8db3
cmp dword [ebp - 0x20], 0x2733
jne 0x4b8db3
lea ecx, [ebp - 0xd1]
push ecx
lea edx, [ebp - 0xd3]
push edx
lea eax, [ebp - 0xd2]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
push 1
mov edx, dword [ebp - 0x2c]
push edx
mov ecx, dword [ebp - 0x144]
call fcn.004bac60
movzx eax, al
test eax, eax
je 0x4b8d16
mov ecx, dword [ebp - 0x144]
call fcn.004b5bb0
mov ecx, dword [ebp - 0x144]
mov byte [ecx + 0xa0], 1
mov ecx, dword [ebp - 0x144]
add ecx, 0xb0
call fcn.00512400
lea ecx, [ebp - 0xfc]
call fcn.00411d60
mov byte [ebp - 4], 2
mov edx, dword [ebp + 0x10]
push edx
lea eax, [ebp - 0x100]
push eax
lea ecx, [ebp - 0xfc]
push ecx
mov ecx, dword [ebp - 0x144]
call fcn.004b6fb0
lea ecx, [ebp - 0xfc]
call fcn.0040fc00
push eax
push str.myIP_3
mov edx, dword [ebp + 0x10]
mov eax, dword [edx]
mov ecx, dword [ebp + 0x10]
mov edx, dword [eax + 0x28]
call edx
mov eax, dword [ebp - 0x100]
push eax
push str.myPort_3
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x2c]
call eax
push 0x622a64
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x14]
call eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp - 0x1c]
push edx
call fcn.004b9020
add esp, 8
mov dword [ebp - 0x1c], 0
mov byte [ebp - 0x13e], 1
mov byte [ebp - 4], 1
lea ecx, [ebp - 0xfc]
call fcn.00412130
mov byte [ebp - 4], 0
lea ecx, [ebp - 0xbc]
call fcn.00412130
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x6c]
call fcn.00412130
mov al, byte [ebp - 0x13e]
jmp 0x4b8fae
movzx eax, byte [ebp - 0xd]
test eax, eax
jne 0x4b8dac
call fcn.00440b60
mov dword [ebp - 0x104], eax
mov dword [ebp - 0x108], 0x64
mov ecx, dword [ebp - 0x104]
cmp ecx, dword [ebp - 0xc4]
jbe 0x4b8d57
mov edx, dword [ebp - 0x104]
sub edx, dword [ebp - 0xc4]
mov dword [ebp - 0x108], edx
mov eax, dword [ebp - 0x2c]
cmp eax, dword [ebp - 0x108]
jbe 0x4b8dac
mov ecx, dword [ebp - 0x2c]
sub ecx, dword [ebp - 0x108]
mov dword [ebp - 0x2c], ecx
cmp dword [ebp - 0x2c], 0x3e8
jbe 0x4b8d8d
mov dword [ebp - 0x70], 0x3e8
push 0x3e8
call fcn.00440b50
add esp, 4
jmp 0x4b8d9e
mov dword [ebp - 0x70], 0x64
push 0x64
call fcn.00440b50
add esp, 4
mov edx, dword [ebp - 0x14]
add edx, 1
mov dword [ebp - 0x14], edx
jmp 0x4b8ae6
mov byte [ebp - 0xd3], 1
mov eax, dword [ebp - 0x144]
cmp dword [eax + 0x11c], 0
je 0x4b8dcd
mov ecx, dword [ebp - 0x144]
call fcn.004b5bb0
cmp dword [ebp - 0x24], 0
jne 0x4b8ee1
mov ecx, dword [ebp - 0x144]
mov byte [ecx + 0xa0], 1
mov ecx, dword [ebp - 0x144]
add ecx, 0xb0
call fcn.00512400
mov ecx, dword [ebp - 0x144]
add ecx, 0x10
call fcn.004c1380
mov ecx, dword [ebp - 0x144]
add ecx, 0x58
call fcn.004c1380
lea ecx, [ebp - 0x134]
call fcn.00411d60
mov byte [ebp - 4], 3
mov edx, dword [ebp + 0x10]
push edx
lea eax, [ebp - 0x138]
push eax
lea ecx, [ebp - 0x134]
push ecx
mov ecx, dword [ebp - 0x144]
call fcn.004b6fb0
lea ecx, [ebp - 0x134]
call fcn.0040fc00
push eax
push str.myIP_4
mov edx, dword [ebp + 0x10]
mov eax, dword [edx]
mov ecx, dword [ebp + 0x10]
mov edx, dword [eax + 0x28]
call edx
mov eax, dword [ebp - 0x138]
push eax
push str.myPort_4
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x2c]
call eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp - 0x1c]
push edx
call fcn.004b9020
add esp, 8
mov dword [ebp - 0x1c], 0
push str.connect_successful..
mov eax, dword [ebp + 0x10]
mov edx, dword [eax]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x14]
call eax
mov byte [ebp - 0x13f], 1
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x134]
call fcn.00412130
mov byte [ebp - 4], 0
lea ecx, [ebp - 0xbc]
call fcn.00412130
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x6c]
call fcn.00412130
mov al, byte [ebp - 0x13f]
jmp 0x4b8fae
movzx ecx, byte [ebp - 0x71]
test ecx, ecx
je 0x4b8f1a
mov edx, dword [ebp - 0x144]
mov eax, dword [edx + 0x11c]
push eax
push 0x622aa4
mov ecx, dword [ebp + 0x10]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x2c]
call eax
mov ecx, dword [ebp - 0x144]
mov dword [ecx + 0x150], 6
jmp 0x4b8f2a
mov edx, dword [ebp - 0x144]
mov dword [edx + 0x150], 7
push str.Connect_function_failed.
mov eax, dword [ebp + 0x10]
mov edx, dword [eax]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x10]
call eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp - 0x20]
push edx
call fcn.004b6950
add esp, 8
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
call fcn.004b9020
add esp, 8
mov dword [ebp - 0x1c], 0
mov byte [ebp - 0x140], 0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0xbc]
call fcn.00412130
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x6c]
call fcn.00412130
mov al, byte [ebp - 0x140]
jmp 0x4b8fae
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x30]
xor ecx, ebp
call fcn.0057bd22
mov esp, ebp
pop ebp
ret 0x18