Function at 0x418745
Capabilities:
Initialize winsock library
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x50c
push ebx
push esi
mov esi, dword [ebp + 8]
and esi, 1
push edi
mov dword [esp + 0x14], esi
jne 0x41876a
xor ebx, ebx
mov dword [0x4235c0], ebx
jmp 0x41876c
xor ebx, ebx
call fcn.00418400
mov edi, eax
mov dword [0x4235d8], edi
cmp edi, ebx
je 0x418900
cmp esi, ebx
jne 0x41879e
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov dword [0x4235d4], eax
cmp eax, ebx
je 0x418900
jmp 0x41884b
push 0x404a34
call fcn.0041833a
push 0x404a44
mov dword [esp + 0x1c], eax
call fcn.0041833a
mov dword [esp + 0x1c], eax
mov eax, dword [0x4235d4]
mov ecx, dword [eax + 0x3c]
mov dword [esp + 0x10], eax
lea ecx, [ecx + eax + 0x80]
cmp dword [esp + 0x1c], ebx
je 0x41884b
cmp dword [esp + 0x18], ebx
je 0x41884b
mov edi, dword [ecx]
cmp edi, ebx
jbe 0x41884b
cmp dword [ecx + 4], 0x14
jbe 0x41884b
add edi, eax
cmp dword [edi], ebx
je 0x41884b
mov eax, dword [edi + 0xc]
add eax, dword [esp + 0x10]
push eax
call dword [esp + 0x20]
mov dword [esp + 0x20], eax
cmp eax, ebx
je 0x418900
mov esi, dword [edi]
mov ebx, dword [edi + 0x10]
add esi, dword [esp + 0x10]
add ebx, dword [esp + 0x10]
jmp 0x41883c
jns 0x41881b
and eax, 0xffff
jmp 0x418823
mov ecx, dword [esp + 0x10]
lea eax, [eax + ecx + 2]
push eax
push dword [esp + 0x24]
call dword [esp + 0x20]
test eax, eax
je 0x418900
mov dword [ebx], eax
add esi, 4
add ebx, 4
mov eax, dword [esi]
test eax, eax
jne 0x418812
add edi, 0x14
xor ebx, ebx
cmp dword [edi], ebx
jne 0x4187eb
lea esi, [esp + 0x24]
mov eax, 0xe5
call fcn.0040e24a
mov eax, esi
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov dword [0x4235dc], eax
cmp eax, ebx
je 0x418900
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x404a54
push eax
call esi
push 0x404a64
push dword [0x4235dc]
mov dword [0x4235e0], eax
call esi
push 0x404a78
push dword [0x4235dc]
mov dword [0x4235e4], eax
call esi
push 0x404a94
push dword [0x4235dc]
mov dword [0x4235e8], eax
call esi
push 0x404aa8
push dword [0x4235dc]
mov dword [0x4235ec], eax
call esi
push 0x404ab4
push dword [0x4235dc]
mov dword [0x4235f0], eax
call esi
mov dword [0x4235f4], eax
cmp dword [0x4235e0], ebx
jne 0x4188ec
cmp dword [0x4235e4], ebx
je 0x418900
cmp dword [0x4235e8], ebx
je 0x418900
cmp dword [0x4235f0], ebx
je 0x418900
cmp eax, ebx
jne 0x418907
xor al, al
jmp 0x418a90
push ebx
push 0x80000
push ebx
call dword [sym.imp.KERNEL32.dll_HeapCreate]
mov dword [0x423480], eax
cmp eax, ebx
jne 0x418931
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov dword [0x423480], eax
mov byte [0x422423], 0
jmp 0x418938
mov byte [0x422423], 1
push 0x42246c
mov dword [0x4226b4], ebx
mov byte [0x422422], 0
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea eax, [esp + 0x38]
push eax
push 0x202
mov dword [0x422484], ebx
call dword [sym.imp.WS2_32.dll_WSAStartup]
mov eax, dword [ebp + 8]
call fcn.0041843a
test al, al
je 0x418900
cmp dword [esp + 0x14], ebx
jne 0x41899b
push ebx
push ebx
push 1
push 0x4235f8
call dword [sym.imp.KERNEL32.dll_CreateEventW]
or dword [0x423a88], 0xffffffff
mov dword [0x423a84], eax
cmp eax, ebx
je 0x418900
push 0x4235d0
push 0xffffffffffffffff
call fcn.004120a7
mov dword [0x4235c4], eax
cmp eax, ebx
je 0x418900
push dword [eax]
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
mov dword [0x4235c8], eax
push eax
mov eax, dword [0x4235c4]
push dword [eax]
call fcn.00411e3f
push dword [ebp + 8]
mov dword [0x4235cc], eax
call fcn.004184b9
test al, al
je 0x418900
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
mov dword [0x423830], eax
mov dword [0x423834], ebx
cmp dword [esp + 0x14], ebx
jne 0x418a01
call fcn.0041851b
jmp 0x418a03
mov al, 1
test al, al
je 0x418900
cmp dword [esp + 0x14], ebx
jne 0x418a40
lea eax, [esp + 0x1c8]
call fcn.00418e24
push ebx
lea eax, [esp + 0x373]
push eax
push dword [0x4235cc]
mov ecx, 0x423a2e
push 0x423838
mov eax, 0x84939312
call fcn.004150ed
push dword [ebp + 8]
call fcn.0041856d
test al, al
je 0x418900
xor eax, eax
test byte [ebp + 8], 2
mov dword [0x423490], ebx
mov word [0x423a90], ax
mov word [0x4223c0], ax
mov word [0x422568], ax
mov word [0x4224e0], ax
mov word [0x422650], ax
mov word [0x4225e8], ax
je 0x418a89
call fcn.00418624
jmp 0x418a8b
mov al, 1
test al, al
setne al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4