Function at 0x41e370
Capabilities:
Initialize winsock library

Disassembly:
mov eax, dword [esp + 0xc]
sub esp, 0x1ac
push ebx
push ebp
xor ebp, ebp
push esi
cmp eax, ebp
push edi
jne 0x41e392
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
add esp, 0x1ac
ret
mov bx, word [esp + 0x1c0]
cmp bx, bp
jne 0x41e3ad
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
add esp, 0x1ac
ret
mov edi, dword [sym.imp.WS2_32.dll_socket]
push ebp
push 1
push 2
call edi
mov esi, eax
cmp esi, 0xffffffff
jne 0x41e420
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x276d
je 0x41e3de
pop edi
pop esi
pop ebp
mov eax, 0xffffd8ef
pop ebx
add esp, 0x1ac
ret
lea eax, [esp + 0x2c]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x41e402
pop edi
pop esi
pop ebp
mov eax, 0xffffd8ef
pop ebx
add esp, 0x1ac
ret
push ebp
push 1
push 2
call edi
mov esi, eax
cmp esi, 0xffffffff
jne 0x41e420
pop edi
pop esi
pop ebp
mov eax, 0xffffd8ef
pop ebx
add esp, 0x1ac
ret
movsx edx, bx
mov ebx, dword [esp + 0x1c4]
mov word [esp + 0x1c], 2
cmp ebx, ebp
je 0x41e441
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push edx
mov dword [esp + 0x24], ebp
call dword [sym.imp.WS2_32.dll_htons]
lea ecx, [esp + 0x1c]
push 0x10
push ecx
push esi
mov word [esp + 0x2a], ax
call dword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
jne 0x41e474
pop edi
pop esi
pop ebp
mov eax, 0xfffffffd
pop ebx
add esp, 0x1ac
ret
push 0x50
call fcn.0042d3e3
mov dx, word [esp + 0x1c4]
mov ebp, eax
mov ecx, 0x14
xor eax, eax
mov edi, ebp
add esp, 4
rep stosd dword es:[edi], eax
mov word [ebp], dx
mov dword [esp + 0x14], ebp
test ebx, ebx
mov dword [ebp + 2], esi
lea edx, [ebp + 6]
mov edi, 0x464fb0
je 0x41e4ac
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0x467d08
mov eax, ecx
mov esi, edi
mov edi, edx
mov edx, dword [esp + 0x1d0]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, dword [esp + 0x1d4]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x1cc]
mov dword [ebp + 0x48], edx
mov dword [ebp + 0x44], ecx
mov dword [ebp + 0x4c], eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov edx, dword [0x467d28]
mov esi, edx
cmp esi, edx
mov dword [esp + 0x18], esi
jl 0x41e637
mov eax, dword [0x467d24]
lea ebx, [esi + 1]
xor edi, edi
cmp ebx, edi
jne 0x41e538
cmp eax, edi
je 0x41e527
push eax
call fcn.0042d40c
add esp, 4
mov dword [0x467d24], edi
mov dword [0x467d2c], edi
mov dword [0x467d28], edi
jmp 0x41e637
cmp eax, edi
jne 0x41e579
lea edi, [ebx*4]
push edi
call fcn.0042d3e3
mov edx, eax
mov ecx, edi
mov dword [0x467d24], edx
mov edi, edx
mov edx, ecx
xor eax, eax
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
add esp, 4
and ecx, 3
rep stosb byte es:[edi], al
mov dword [0x467d2c], ebx
mov dword [0x467d28], ebx
jmp 0x41e637
mov ecx, dword [0x467d2c]
cmp ebx, ecx
jg 0x41e59d
cmp ebx, edx
jle 0x41e592
mov ecx, ebx
lea edi, [eax + edx*4]
sub ecx, edx
xor eax, eax
rep stosd dword es:[edi], eax
mov dword [0x467d28], ebx
jmp 0x41e637
mov eax, dword [0x467d30]
cmp eax, edi
jne 0x41e5c9
mov eax, edx
cdq
and edx, 7
add eax, edx
sar eax, 3
cmp eax, 4
jge 0x41e5bd
mov eax, 4
jmp 0x41e5c9
cmp eax, 0x400
jle 0x41e5c9
mov eax, 0x400
add eax, ecx
cmp ebx, eax
mov dword [esp + 0x10], eax
jl 0x41e5d7
mov dword [esp + 0x10], ebx
mov eax, dword [esp + 0x10]
lea ecx, [eax*4]
push ecx
call fcn.0042d3e3
mov ecx, dword [0x467d28]
mov esi, dword [0x467d24]
mov ebp, eax
mov edi, ebp
rep movsd dword es:[edi], dword [esi]
mov eax, dword [0x467d28]
mov ecx, ebx
sub ecx, eax
lea edi, [ebp + eax*4]
xor eax, eax
rep stosd dword es:[edi], eax
mov edx, dword [0x467d24]
push edx
call fcn.0042d40c
mov eax, dword [esp + 0x18]
mov esi, dword [esp + 0x20]
mov dword [0x467d24], ebp
mov ebp, dword [esp + 0x1c]
add esp, 8
mov dword [0x467d28], ebx
mov dword [0x467d2c], eax
mov ecx, dword [0x467d24]
push 0x467d08
mov dword [ecx + esi*4], ebp
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push 0
push 0
push 0
push 0
push ebp
push 0x41e9e0
call fcn.0043174b
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x1ac
ret