Function at 0x439750
Capabilities:
Check mutex on windows
Get socket status
Receive data
Receive data on socket

Disassembly:
sub esp, 0x544
mov eax, dword [esp + 0x550]
push ebx
push ebp
xor ebp, ebp
cmp eax, ebp
lea ebx, [esp + 0x144]
mov dword [esp + 0x10], ebp
mov dword [esp + 0x14], ebp
je 0x439b8f
cmp dword [esp + 0x55c], ebp
je 0x439b8f
lea ecx, [esp + 0x1c]
mov eax, ebx
push ecx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x10], 8
mov dword [esp + 0x24], ebp
mov dword [esp + 0xc], ebp
call fcn.0045a1c9
add esp, 4
push esi
push edi
lea ebx, [ebx]
mov esi, dword [esp + 0x55c]
test esi, esi
jle 0x43987f
lea edx, [esp + 0x30]
push edx
call fcn.0045a1c9
mov eax, dword [esp + 0x34]
sub eax, dword [esp + 0x28]
add esp, 4
cmp eax, esi
jg 0x4399fd
mov edi, dword [esp + 0x558]
xor ecx, ecx
mov dword [esp + 0x40], ecx
lea edx, [esp + 0x40]
push edx
push ecx
push ecx
lea eax, [esp + 0x54]
push eax
push ecx
mov dword [esp + 0x58], ecx
mov dword [esp + 0x54], 2
mov dword [esp + 0x60], edi
mov dword [esp + 0x5c], 1
call sub.WS2_32.dll_select
mov esi, eax
call sub.WS2_32.dll_WSAGetLastError
cmp esi, 0xffffffff
jne 0x439841
cmp eax, 0x2733
je 0x439855
push eax
push str.kascRecv:_select___returns_code__d.
call fcn.00432720
add esp, 8
mov dword [esp + 0x10], 0xfffffff4
jmp 0x439a30
cmp esi, 1
jne 0x439855
lea ecx, [esp + 0x48]
push ecx
push edi
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
jne 0x439888
lea edx, [esp + 0x2c]
push edx
call fcn.0045a1c9
mov eax, dword [esp + 0x30]
mov ecx, dword [esp + 0x34]
add esp, 4
cmp eax, ecx
jne 0x4399b3
push 0x14
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x4399b3
mov edi, dword [esp + 0x558]
jmp 0x43988f
mov esi, dword [esp + 0x55c]
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x20]
push 0
sub ecx, ebp
push ecx
lea eax, [edx + ebp]
push eax
push edi
call sub.WS2_32.dll_recv
cmp eax, 0xffffffff
jne 0x4398eb
call sub.WS2_32.dll_WSAGetLastError
cmp eax, 0x2733
jne 0x439ab6
test esi, esi
jg 0x4398c7
test ebp, ebp
je 0x439a11
cmp dword [esp + 0x1c], 0x493e0
jg 0x439a1b
test esi, esi
jg 0x4398e1
push 0xa
call dword [sym.imp.KERNEL32.dll_Sleep]
add dword [esp + 0x1c], 0xa
jmp 0x4399b3
test eax, eax
jle 0x439ade
add ebp, eax
test esi, esi
jle 0x439906
lea ecx, [esp + 0x24]
push ecx
call fcn.0045a1c9
add esp, 4
mov eax, dword [esp + 0x28]
test eax, eax
mov dword [esp + 0x1c], 0
jne 0x4399b3
cmp ebp, 8
jl 0x4399b3
cmp byte [ebx], 0x4a
jne 0x4399a4
cmp byte [ebx + 1], 0x5e
jne 0x4399a4
cmp byte [ebx + 2], 0x7a
jne 0x4399a4
cmp byte [ebx + 3], 4
jne 0x4399a4
movzx edx, byte [ebx + 6]
movzx ecx, byte [ebx + 7]
xor eax, eax
mov ah, byte [ebx + 4]
mov al, byte [ebx + 5]
shl eax, 8
or eax, edx
shl eax, 8
or eax, ecx
cmp eax, 0x400
mov dword [esp + 0x18], eax
jle 0x439996
add eax, 8
push eax
call fcn.00459619
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x439ad1
mov eax, dword [esp + 0x18]
mov ecx, ebp
mov edx, ecx
shr ecx, 2
lea esi, [esp + 0x14c]
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
mov dword [esp + 0x20], ebx
rep movsb byte es:[edi], byte [esi]
add dword [esp + 0x14], eax
mov dword [esp + 0x28], 1
jmp 0x4399b3
dec ebp
push ebp
lea eax, [ebx + 1]
push eax
push ebx
call fcn.0045a450
add esp, 0xc
cmp ebp, dword [esp + 0x14]
jl 0x4397b0
mov esi, dword [esp + 0x18]
lea ecx, [esi + 8]
cmp ebp, ecx
jl 0x439a30
lea edx, [esp + 0x14c]
cmp ebx, edx
push esi
je 0x439af7
mov edi, dword [esp + 0x24]
add ebx, 8
push ebx
push edi
call fcn.0045a450
mov eax, dword [esp + 0x56c]
mov dword [eax], edi
mov eax, dword [esp + 0x570]
add esp, 0xc
mov dword [eax], esi
jmp 0x439a5e
push str.kascRecv:_timeout.
mov dword [esp + 0x14], 0xfffffff1
call fcn.00432720
jmp 0x439a2d
mov dword [esp + 0x10], 0xfffffff7
jmp 0x439a30
push str.kascRecv:_Too_much_time_has_elasped_without_data_after_receiving_at_least_one_byte.
call fcn.00432720
mov dword [esp + 0x14], 0xfffffff4
add esp, 4
lea ecx, [esp + 0x14c]
cmp ebx, ecx
je 0x439a44
push ebx
call fcn.0045932f
add esp, 4
mov edx, dword [esp + 0x564]
mov eax, dword [esp + 0x560]
mov dword [edx], 0
mov dword [eax], 0
test ebp, ebp
jle 0x439b80
xor ecx, ecx
mov dword [esp + 0x34], ecx
mov dword [esp + 0x38], ecx
push str.KASC_STAT_MUTEX
push ecx
lea edx, [esp + 0x3c]
mov dword [esp + 0x44], ecx
push edx
mov dword [esp + 0x40], 0xc
mov dword [esp + 0x44], ecx
mov dword [esp + 0x48], 1
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov esi, eax
test esi, esi
je 0x439b49
push 0x3a98
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edi, eax
jmp 0x439b4d
push eax
push str.kascRecv:_recv___returns_code__d.
mov dword [esp + 0x18], 0xfffffff4
call fcn.00432720
add esp, 8
jmp 0x439a30
mov dword [esp + 0x10], 0xfffffff5
jmp 0x439a30
jne 0x439aea
push str.kascRecv:_recv___returns_code_0.
jmp 0x439a20
mov dword [esp + 0x10], 0xffffff9d
jmp 0x439a30
call fcn.00459619
mov ecx, dword [esp + 0x564]
add esp, 4
test eax, eax
mov dword [ecx], eax
je 0x439b33
mov ecx, esi
mov edx, ecx
shr ecx, 2
mov edi, eax
mov eax, dword [esp + 0x564]
lea esi, [ebx + 8]
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x18]
mov dword [eax], esi
jmp 0x439a5e
mov eax, dword [esp + 0x564]
mov dword [esp + 0x10], 0xfffffff5
mov dword [eax], esi
jmp 0x439a5e
mov edi, dword [esp + 0x2c]
mov ebx, 0x4ccaf8
mov eax, 0x4ccadc
call fcn.00439090
mov ecx, dword [0x4ccadc]
add ecx, ebp
test esi, esi
mov dword [0x4ccadc], ecx
je 0x439b80
test edi, edi
jne 0x439b79
push esi
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x544
ret
pop ebp
mov eax, 0xfffffffd
pop ebx
add esp, 0x544
ret