Function at 0x40d550
Capabilities:
Access peb ldr_data
Check for time delay via gettickcount
Connect socket
Get kernel32 base address

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x58d7de
mov eax, dword fs:[0]
push eax
sub esp, 0x38
mov eax, dword [0x5f4760]
xor eax, esp
mov dword [esp + 0x30], eax
push ebx
push esi
push edi
mov eax, dword [0x5f4760]
xor eax, esp
push eax
lea eax, [esp + 0x48]
mov dword fs:[0], eax
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ebx, ecx
mov edi, dword [ebx]
xor eax, eax
mov dword [edi + 0x1c], eax
mov dword [esp + 0x18], edi
add edi, 0x1c
mov dword [edi + 4], eax
mov dword [edi + 8], eax
mov dword [edi + 0xc], eax
mov eax, 2
mov dword [esp + 0x20], ebx
mov word [edi], ax
call esi
cmp dword [0x603db4], 9
mov dword [esp + 0x14], eax
jne 0x40d616
call esi
cmp eax, dword [esp + 0x14]
jbe 0x40d616
call esi
sub eax, dword [esp + 0x14]
cmp eax, 0x1388
jbe 0x40d616
movzx ecx, word [edi + 2]
push ecx
call dword [sym.imp.WS2_32.dll_htons]
movzx edx, ax
mov eax, dword [edi + 4]
push edx
push eax
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
call esi
sub eax, dword [esp + 0x1c]
mov ecx, dword [ebx]
mov edx, dword [ecx + 4]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push str._u__u__AsyncConnect::Work_1:__d_ms__ip:_s_port:_u
mov esi, 0x602250
call fcn.00409e30
add esp, 0x18
mov eax, dword [0x604340]
movzx ecx, word [0x604330]
mov edx, dword [0x60432c]
push eax
push ecx
push edx
push str.Work_proxy__s:_u__type__d
mov esi, 0x602250
call fcn.00409e30
mov eax, dword [0x604340]
add esp, 0x10
cmp eax, 1
je 0x40d650
cmp eax, 2
jne 0x40d7e8
mov eax, dword [0x60432c]
cmp dword [eax - 0xc], 0
je 0x40d7e8
mov ecx, dword [esp + 0x18]
cmp dword [ecx + 0x8158], 0
jne 0x40d6d0
push ecx
mov edx, esp
mov dword [esp + 0x1c], esp
push 0x60432c
push edx
call fcn.00406380
mov dword [esp + 0x54], 0
mov dword [esp + 0x54], 0xffffffff
call fcn.00417da0
add esp, 4
test eax, eax
je 0x40d6a9
movzx eax, word [0x604330]
cmp eax, dword [0x603db0]
je 0x40d6d0
mov ecx, dword [0x60432c]
push ecx
call dword [sym.imp.WS2_32.dll_inet_addr]
mov dword [edi + 4], eax
movzx edx, word [0x604330]
push edx
call dword [sym.imp.WS2_32.dll_htons]
mov word [edi + 2], ax
jmp 0x40d773
mov eax, dword [ebx]
add eax, 0x2c
push eax
lea ecx, [esp + 0x28]
call fcn.00403ca0
mov dword [esp + 0x50], 1
lea ecx, [esp + 0x24]
call fcn.0040d160
mov ecx, dword [ebx]
movzx edx, word [ecx + 0x12c]
push edx
mov esi, eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [edi + 2], ax
mov dword [edi + 4], 0xffffffff
test esi, esi
je 0x40d716
mov dword [edi + 4], esi
jmp 0x40d742
mov ecx, dword [ebx]
add ecx, 0x2c
call fcn.0040d430
mov dword [edi + 4], eax
cmp eax, 0xffffffff
jne 0x40d734
lea eax, [esp + 0x24]
push eax
call fcn.0040d2c0
jmp 0x40d742
push eax
lea ebx, [esp + 0x28]
call fcn.0040d250
mov ebx, dword [esp + 0x20]
mov dword [esp + 0x50], 0xffffffff
cmp dword [esp + 0x3c], 0x10
jb 0x40d75e
mov ecx, dword [esp + 0x28]
push ecx
call fcn.004a3142
add esp, 4
mov dword [esp + 0x3c], 0xf
mov dword [esp + 0x38], 0
mov byte [esp + 0x28], 0
cmp dword [0x603db4], 9
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
jne 0x40d919
call esi
cmp eax, dword [esp + 0x14]
jbe 0x40d919
call esi
sub eax, dword [esp + 0x14]
cmp eax, 0x1388
jbe 0x40d919
movzx edx, word [edi + 2]
push edx
call dword [sym.imp.WS2_32.dll_htons]
mov ecx, dword [edi + 4]
movzx eax, ax
push eax
push ecx
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
call esi
sub eax, dword [esp + 0x1c]
mov edx, dword [ebx]
push eax
mov eax, dword [edx + 4]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push str._u__u__AsyncConnect::Work_2:__d_ms__ip:_s_port:_u
mov esi, 0x602250
call fcn.00409e30
add esp, 0x18
jmp 0x40d913
mov esi, dword [ebx]
add esi, 0x2c
mov eax, esi
mov dword [esp + 0x3c], 0xf
mov dword [esp + 0x38], 0
mov byte [esp + 0x28], 0
lea ecx, [eax + 1]
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x40d807
sub eax, ecx
push eax
push esi
lea ecx, [esp + 0x2c]
call fcn.004027e0
mov dword [esp + 0x50], 2
lea ecx, [esp + 0x24]
call fcn.0040d160
mov ecx, dword [ebx]
movzx edx, word [ecx + 0x12c]
push edx
mov esi, eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [edi + 2], ax
mov dword [edi + 4], 0xffffffff
test esi, esi
je 0x40d852
mov dword [edi + 4], esi
jmp 0x40d87e
mov ecx, dword [ebx]
add ecx, 0x2c
call fcn.0040d430
mov dword [edi + 4], eax
cmp eax, 0xffffffff
jne 0x40d870
lea eax, [esp + 0x24]
push eax
call fcn.0040d2c0
jmp 0x40d87e
push eax
lea ebx, [esp + 0x28]
call fcn.0040d250
mov ebx, dword [esp + 0x20]
cmp dword [0x603db4], 9
jne 0x40d8e2
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
call esi
cmp eax, dword [esp + 0x14]
jbe 0x40d8e2
call esi
sub eax, dword [esp + 0x14]
cmp eax, 0x1388
jbe 0x40d8e2
movzx ecx, word [edi + 2]
push ecx
call dword [sym.imp.WS2_32.dll_htons]
movzx edx, ax
mov eax, dword [edi + 4]
push edx
push eax
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
call esi
sub eax, dword [esp + 0x1c]
mov ecx, dword [ebx]
mov edx, dword [ecx + 4]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push str._u__u__AsyncConnect::Work_3:__d_ms__ip:_s_port:_u
mov esi, 0x602250
call fcn.00409e30
add esp, 0x18
mov dword [esp + 0x50], 0xffffffff
cmp dword [esp + 0x3c], 0x10
jb 0x40d8fe
mov eax, dword [esp + 0x28]
push eax
call fcn.004a3142
add esp, 4
mov dword [esp + 0x3c], 0xf
mov dword [esp + 0x38], 0
mov byte [esp + 0x28], 0
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, dword [edi + 4]
push ecx
call dword [sym.imp.WS2_32.dll_inet_ntoa]
lea edx, [esp + 0x1c]
push edx
mov ecx, eax
call fcn.00402fe0
mov dword [esp + 0x50], 3
push ecx
mov eax, esp
mov dword [esp + 0x1c], esp
lea ecx, [esp + 0x20]
push ecx
push eax
call fcn.00406380
mov byte [esp + 0x54], 4
mov byte [esp + 0x54], 3
call fcn.00417da0
add esp, 4
test eax, eax
je 0x40d974
mov edx, dword [ebx]
movzx eax, word [edx + 0x12c]
cmp eax, dword [0x603db0]
je 0x40dadf
cmp dword [edi + 4], 0xffffffff
je 0x40dadf
cmp dword [0x603db4], 9
jne 0x40d9e2
call esi
cmp eax, dword [esp + 0x14]
jbe 0x40d9e2
call esi
sub eax, dword [esp + 0x14]
cmp eax, 0x1388
jbe 0x40d9e2
movzx ecx, word [edi + 2]
push ecx
call dword [sym.imp.WS2_32.dll_htons]
movzx edx, ax
mov eax, dword [edi + 4]
push edx
push eax
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
call esi
sub eax, dword [esp + 0x1c]
mov ecx, dword [ebx]
mov edx, dword [ecx + 4]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push str._u__u__AsyncConnect::Work_4:__d_ms__ip:_s_port:_u
mov esi, 0x602250
call fcn.00409e30
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
add esp, 0x18
mov eax, dword [ebx]
mov ecx, dword [eax + 0x18]
push 0x10
push edi
push ecx
call dword [sym.imp.WS2_32.dll_connect]
cmp dword [0x603db4], 9
mov dword [esp + 0x18], eax
jne 0x40da59
call esi
cmp eax, dword [esp + 0x14]
jbe 0x40da59
call esi
sub eax, dword [esp + 0x14]
cmp eax, 0x1388
jbe 0x40da59
movzx edx, word [edi + 2]
push edx
call dword [sym.imp.WS2_32.dll_htons]
mov ecx, dword [edi + 4]
movzx eax, ax
push eax
push ecx
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
call esi
sub eax, dword [esp + 0x1c]
mov edx, dword [ebx]
push eax
mov eax, dword [edx + 4]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push str._u__u__AsyncConnect::Work_5:__d_ms__ip:_s_port:_u
mov esi, 0x602250
call fcn.00409e30
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
add esp, 0x18
cmp dword [esp + 0x18], 0xffffffff
je 0x40dad9
push 1
mov eax, ebx
call fcn.0040d3b0
cmp dword [0x603db4], 9
jne 0x40dac7
call esi
cmp eax, dword [esp + 0x14]
jbe 0x40dac7
call esi
sub eax, dword [esp + 0x14]
cmp eax, 0x1388
jbe 0x40dac7
movzx ecx, word [edi + 2]
push ecx
call dword [sym.imp.WS2_32.dll_htons]
movzx edx, ax
mov eax, dword [edi + 4]
push edx
push eax
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
call esi
sub eax, dword [esp + 0x1c]
mov ecx, dword [ebx]
mov edx, dword [ecx + 4]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push str._u__u__AsyncConnect::Work_6:__d_ms__ip:_s_port:_u
mov esi, 0x602250
call fcn.00409e30
add esp, 0x18
mov dword [esp + 0x50], 0xffffffff
lea eax, [esp + 0x1c]
push eax
jmp 0x40dbb7
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp dword [0x603db4], 9
jne 0x40db43
call esi
cmp eax, dword [esp + 0x14]
jbe 0x40db43
call esi
sub eax, dword [esp + 0x14]
cmp eax, 0x1388
jbe 0x40db43
movzx ecx, word [edi + 2]
push ecx
call dword [sym.imp.WS2_32.dll_htons]
movzx edx, ax
mov eax, dword [edi + 4]
push edx
push eax
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
call esi
sub eax, dword [esp + 0x1c]
mov ecx, dword [ebx]
mov edx, dword [ecx + 4]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push str._u__u__AsyncConnect::Work_7:__d_ms__ip:_s_port:_u
mov esi, 0x602250
call fcn.00409e30
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
add esp, 0x18
push 0
mov eax, ebx
call fcn.0040d3b0
cmp dword [0x603db4], 9
jne 0x40dbaa
call esi
cmp eax, dword [esp + 0x14]
jbe 0x40dbaa
call esi
sub eax, dword [esp + 0x14]
cmp eax, 0x1388
jbe 0x40dbaa
movzx eax, word [edi + 2]
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov edx, dword [edi + 4]
movzx ecx, ax
push ecx
push edx
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
call esi
sub eax, dword [esp + 0x1c]
push eax
mov eax, dword [ebx]
mov ecx, dword [eax + 4]
push ecx
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push str._u__u__AsyncConnect::Work_8:__d_ms__ip:_s_port:_u
mov esi, 0x602250
call fcn.00409e30
add esp, 0x18
mov dword [esp + 0x50], 0xffffffff
lea edx, [esp + 0x1c]
push edx
call fcn.00403090
mov ecx, dword [esp + 0x48]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.004a314d
mov esp, ebp
pop ebp
ret