Function at 0x41e670
Capabilities:
Initialize winsock library

Disassembly:
sub esp, 0x1ac
push ebx
push ebp
push esi
push edi
call fcn.0041e2b0
cmp eax, 2
jl 0x41e6c4
cmp eax, 3
jg 0x41e6c4
mov eax, dword [esp + 0x1d0]
mov ecx, dword [esp + 0x1cc]
mov edx, dword [esp + 0x1c8]
push eax
mov eax, dword [esp + 0x1c8]
push ecx
mov ecx, dword [esp + 0x1c8]
push edx
push eax
push ecx
call fcn.0041e370
add esp, 0x14
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1ac
ret
mov eax, dword [esp + 0x1c8]
xor ebp, ebp
cmp eax, ebp
jne 0x41e6df
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
add esp, 0x1ac
ret
mov ebx, dword [esp + 0x1c0]
cmp bx, bp
jne 0x41e6f9
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
add esp, 0x1ac
ret
mov edi, dword [sym.imp.WS2_32.dll_WSASocketA]
push 1
push ebp
push ebp
push ebp
push 1
push 2
call edi
mov esi, eax
cmp esi, 0xffffffff
jne 0x41e774
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x276d
je 0x41e72e
pop edi
pop esi
pop ebp
mov eax, 0xffffd8dd
pop ebx
add esp, 0x1ac
ret
lea edx, [esp + 0x2c]
push edx
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x41e752
pop edi
pop esi
pop ebp
mov eax, 0xffffd8de
pop ebx
add esp, 0x1ac
ret
push 1
push ebp
push ebp
push ebp
push 1
push 2
call edi
mov esi, eax
cmp esi, 0xffffffff
jne 0x41e774
pop edi
pop esi
pop ebp
mov eax, 0xffffd8dd
pop ebx
add esp, 0x1ac
ret
movsx edx, bx
mov ebx, dword [esp + 0x1c4]
mov word [esp + 0x1c], 2
cmp ebx, ebp
je 0x41e795
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]
mov word [esp + 0x1e], ax
lea eax, [esp + 0x1c]
push 0x10
push eax
push esi
call dword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
jne 0x41e7c8
pop edi
pop esi
pop ebp
mov eax, 0xfffffffd
pop ebx
add esp, 0x1ac
ret
push 0x50
call fcn.0042d3e3
mov ebp, eax
mov ecx, 0x14
xor eax, eax
mov edi, ebp
rep stosd dword es:[edi], eax
mov cx, word [esp + 0x1c4]
add esp, 4
test ebx, ebx
mov dword [esp + 0x14], ebp
mov dword [ebp + 2], esi
mov word [ebp], cx
lea edx, [ebp + 6]
mov edi, 0x464fb0
je 0x41e800
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 0x41e98b
mov eax, dword [0x467d24]
lea ebx, [esi + 1]
xor edi, edi
cmp ebx, edi
jne 0x41e88c
cmp eax, edi
je 0x41e87b
push eax
call fcn.0042d40c
add esp, 4
mov dword [0x467d24], edi
mov dword [0x467d2c], edi
mov dword [0x467d28], edi
jmp 0x41e98b
cmp eax, edi
jne 0x41e8cd
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 0x41e98b
mov ecx, dword [0x467d2c]
cmp ebx, ecx
jg 0x41e8f1
cmp ebx, edx
jle 0x41e8e6
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 0x41e98b
mov eax, dword [0x467d30]
cmp eax, edi
jne 0x41e91d
mov eax, edx
cdq
and edx, 7
add eax, edx
sar eax, 3
cmp eax, 4
jge 0x41e911
mov eax, 4
jmp 0x41e91d
cmp eax, 0x400
jle 0x41e91d
mov eax, 0x400
add eax, ecx
cmp ebx, eax
mov dword [esp + 0x10], eax
jl 0x41e92b
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]
mov eax, dword [0x467dbc]
test eax, eax
jne 0x41e9bc
push 0
push 0
push 0
push 0
push 0
push 0x421860
call fcn.0043174b
push 0
push 0
push 0
push 0
push ebp
push 0x420d20
call fcn.0043174b
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x1ac
ret