Function at 0x4470e1
Capabilities:
Get socket status
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c0
lea eax, [ebp - 0x78]
push esi
push ebx
push edi
mov edi, dword [ebp + 8]
mov byte [ebp - 1], 0
push eax
call fcn.0043ea88
add esp, 4
nop
cmp byte [ebp + 0x10], 0
je 0x447145
push edi
call fcn.00446d8e
add esp, 4
test al, al
je 0x447159
nop
nop
mov eax, dword [ebp - 0x78]
jmp 0x447128
mov esi, dword [eax]
push eax
call fcn.0041d48f
add esp, 4
mov eax, esi
or eax, eax
jne 0x44711b
mov dword [ebp - 0x70], 0
mov dword [ebp - 0x74], 0
mov eax, dword [ebp - 0x74]
mov dword [ebp - 0x78], eax
jmp 0x447a65
push edi
call fcn.00446fe9
add esp, 4
or al, al
je 0x447159
mov dword [ebp + 0xc], 0
cmp dword [ebp + 0xc], 0
jle 0x4471b1
movzx eax, byte [ebp + 0x14]
push eax
push edi
call fcn.00447a6a
sub esp, 0xfffffff8
mov dword [ebp - 0x3bc], eax
mov dword [ebp - 0x3c0], eax
sar dword [ebp - 0x3bc], 0x1f
mov eax, dword [ebp - 0x3bc]
test eax, eax
jl 0x4471b1
mov edx, dword [ebp - 0x3bc]
mov ecx, dword [ebp + 0xc]
mov esi, ecx
sar esi, 0x1f
cmp edx, esi
jg 0x4471b1
jl 0x4471a8
mov edx, dword [ebp - 0x3c0]
cmp edx, ecx
jae 0x4471b1
mov ebx, dword [ebp - 0x3c0]
mov dword [ebp + 0xc], ebx
cmp byte [ebp + 0x10], 0
jne 0x4471f4
cmp dword [ebp + 0xc], 0
jg 0x4471f4
cmp byte [edi + 0x10], 0
jne 0x4471f4
nop
nop
mov eax, dword [ebp - 0x78]
jmp 0x4471d7
mov edi, dword [eax]
push eax
call fcn.0041d48f
add esp, 4
mov eax, edi
test eax, eax
jne 0x4471ca
mov dword [ebp - 0x70], 0
mov dword [ebp - 0x74], 0
mov eax, dword [ebp - 0x74]
mov dword [ebp - 0x78], eax
jmp 0x447a65
mov eax, dword [edi + 8]
add dword [eax + 0x1c], 1
cmp dword [edi + 0x1c], 0xffffffff
jne 0x4472c8
mov eax, dword [str.GHS_Dummy_WSAAsyncSelect]
mov dword [ebp - 0x24], eax
push 0x28
push 0
lea eax, [ebp - 0xa0]
push eax
call fcn.004a7ae0
sub esp, 0xfffffff4
push 0
mov eax, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call eax
mov dword [ebp - 0x90], eax
mov eax, 0x4470be
mov dword [ebp - 0x9c], eax
mov esi, dword [ebp - 0x24]
mov dword [ebp - 0x7c], esi
lea esi, [ebp - 0xa0]
push esi
mov eax, dword [sym.imp.USER32.dll_RegisterClassA]
call eax
push 0
push 0
mov eax, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call eax
push eax
push 0
push 0
push 0xa
push 0xa
push 0
push 0
push 0
push str.MainWClass
push dword [ebp - 0x24]
push 0
mov eax, dword [sym.imp.USER32.dll_CreateWindowExA]
call eax
mov dword [edi + 0x1c], eax
push 0
push 0x562
xor eax, eax
push str..._src_shared_libcxxutil_ut_idle.cc
push str._sockwin___NULL
cmp dword [edi + 0x1c], 0
setne al
push eax
call fcn.00409813
add esp, 0x14
xor eax, eax
push 0
push 0x563
push str..._src_shared_libcxxutil_ut_idle.cc
push str._created_sockwin___HWND_0xffffffff
cmp dword [edi + 0x20], 0xffffffff
sete al
push eax
call fcn.00409813
mov eax, dword [edi + 0x1c]
mov dword [edi + 0x20], eax
sub esp, 0xffffffec
mov dword [ebp - 0x50], 0
jmp 0x44745c
mov dword [ebp - 0x3c], 0
mov esi, dword [edi + 8]
mov edx, dword [ebp - 0x50]
mov esi, dword [esi + 0x10]
mov esi, dword [esi + edx*4]
cmp esi, 0
jne 0x4472f1
jmp 0x447458
mov eax, dword [esi]
lea eax, [eax + 0x28]
push esi
mov eax, dword [eax + 4]
call eax
sub esp, 0xfffffffc
or al, al
je 0x447333
mov eax, dword [esi]
lea eax, [eax + 0x10]
push esi
mov eax, dword [eax + 4]
call eax
add esp, 4
or al, al
je 0x44731b
or dword [ebp - 0x3c], 2
jmp 0x447333
mov dword [ebp + 0xc], 0
mov eax, dword [edi + 8]
mov edx, dword [ebp - 0x50]
mov eax, dword [eax + 4]
mov byte [eax + edx], 1
mov byte [ebp - 1], 1
mov eax, dword [esi]
lea eax, [eax + 0x30]
push esi
mov eax, dword [eax + 4]
call eax
add esp, 4
test al, al
je 0x447375
mov eax, dword [esi]
lea eax, [eax + 0x10]
push esi
mov eax, dword [eax + 4]
call eax
sub esp, 0xfffffffc
test al, al
je 0x44735d
or dword [ebp - 0x3c], 4
jmp 0x447375
mov dword [ebp + 0xc], 0
mov eax, dword [edi + 8]
mov eax, dword [eax + 8]
mov edx, dword [ebp - 0x50]
mov byte [eax + edx], 1
mov byte [ebp - 1], 1
mov eax, dword [esi]
push esi
lea eax, [eax + 0x20]
mov eax, dword [eax + 4]
call eax
add esp, 4
test al, al
je 0x4473b6
mov eax, dword [esi]
lea eax, [eax + 0x10]
push esi
mov eax, dword [eax + 4]
call eax
sub esp, 0xfffffffc
or al, al
je 0x44739f
or dword [ebp - 0x3c], 9
jmp 0x4473b6
mov dword [ebp + 0xc], 0
mov eax, dword [edi + 8]
mov edx, dword [ebp - 0x50]
mov eax, dword [eax]
mov byte [eax + edx], 1
mov byte [ebp - 1], 1
mov eax, dword [esi]
push esi
lea eax, [eax + 0x38]
mov eax, dword [eax + 4]
call eax
sub esp, 0xfffffffc
or al, al
je 0x4473d3
mov dword [ebp + 0xc], 0
mov byte [ebp - 1], 1
cmp dword [ebp - 0x3c], 0
je 0x4473dd
or dword [ebp - 0x3c], 0x20
cmp dword [ebp - 0x3c], 0
je 0x447458
mov eax, dword [esi]
push esi
lea eax, [eax + 0x10]
mov eax, dword [eax + 4]
call eax
sub esp, 0xfffffffc
test al, al
je 0x447458
mov eax, dword [esi]
lea eax, [eax + 0x48]
push esi
mov eax, dword [eax + 4]
call eax
add esp, 4
or al, al
je 0x447439
mov eax, dword [esi]
lea eax, [eax + 0x18]
push esi
mov eax, dword [eax + 4]
call eax
mov ebx, eax
add esp, 4
xor eax, eax
jne 0x447429
push 0xc
call fcn.0041d478
sub esp, 0xfffffffc
test eax, eax
je 0x44742c
mov dword [eax + 8], ebx
push eax
lea eax, [ebp - 0x78]
push eax
call fcn.0043eaee
add esp, 8
mov eax, dword [esi]
lea eax, [eax + 0x18]
push dword [ebp - 0x3c]
push 0x400
push dword [edi + 0x1c]
push esi
mov eax, dword [eax + 4]
call eax
add esp, 4
push eax
call sub.WS2_32.dll_WSAAsyncSelect
sub dword [ebp - 0x50], 0xffffffff
mov edx, dword [edi + 8]
mov edx, dword [edx + 0x14]
cmp edx, dword [ebp - 0x50]
jg 0x4472d4
mov dword [ebp - 0x54], 0
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x40], 0
mov ebx, dword [edi + 0x14]
cmp dword [ebx + 0xc], 0
jle 0x447529
mov eax, dword [edi + 0x14]
push 4
push dword [eax + 0xc]
mov eax, dword [fcn.004092c1]
call eax
sub esp, 0xfffffff8
mov dword [ebp - 0x54], eax
mov ebx, dword [edi + 0x14]
push 4
push dword [ebx + 0xc]
mov eax, dword [fcn.004092c1]
call eax
sub esp, 0xfffffff8
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x38], 0
jmp 0x44751e
mov ecx, dword [ebp - 0x38]
mov edx, dword [edi + 0x14]
mov edx, dword [edx + 8]
mov edx, dword [edx + ecx*4]
mov dword [ebp - 0x34], edx
cmp dword [ebp - 0x34], 0
jne 0x4474d7
jmp 0x44751a
mov eax, dword [ebp - 0x34]
mov eax, dword [eax]
lea eax, [eax + 0x10]
push dword [ebp - 0x34]
mov eax, dword [eax + 4]
call eax
sub esp, 0xfffffffc
or al, al
je 0x44751a
mov edx, dword [ebp - 0x54]
mov ebx, dword [ebp - 0x38]
mov ecx, dword [ebp - 0x40]
mov dword [edx + ecx*4], ebx
mov eax, dword [ebp - 0x34]
mov eax, dword [eax]
push dword [ebp - 0x34]
lea eax, [eax + 0x18]
mov eax, dword [eax + 4]
call eax
add esp, 4
mov edx, dword [ebp - 0x44]
mov ecx, dword [ebp - 0x40]
mov dword [edx + ecx*4], eax
add dword [ebp - 0x40], 1
sub dword [ebp - 0x38], 0xffffffff
mov edx, dword [edi + 0x14]
mov edx, dword [edx + 0xc]
cmp edx, dword [ebp - 0x38]
jg 0x4474c0
cmp dword [ebp - 0x40], 0
jne 0x447557
push dword [ebp - 0x54]
mov eax, dword [0x4d3eec]
call eax
mov dword [ebp - 0x54], 0
sub esp, 0xfffffffc
push dword [ebp - 0x44]
mov eax, dword [0x4d3eec]
call eax
sub esp, 0xfffffffc
mov dword [ebp - 0x44], 0
push 2
push 0x4ff
push dword [ebp + 0xc]
push dword [ebp - 0x44]
push dword [ebp - 0x40]
mov eax, dword [sym.imp.USER32.dll_MsgWaitForMultipleObjectsEx]
call eax
mov dword [ebp - 0x2c], eax
jmp 0x4475b2
mov edx, dword [ebp - 0x78]
mov edx, dword [edx + 8]
mov dword [ebp - 0x14], edx
mov dword [ebp - 0x6c], 0
push 0
push 0x400
push dword [edi + 0x1c]
push dword [ebp - 0x14]
call sub.WS2_32.dll_WSAAsyncSelect
lea eax, [ebp - 0x6c]
push eax
push 0x8004667e
push dword [ebp - 0x14]
call sub.WS2_32.dll_ioctlsocket
lea eax, [ebp - 0x78]
push eax
call fcn.004426c7
add esp, 4
cmp dword [ebp - 0x70], 0
jne 0x447573
mov dword [ebp + 0xc], 0
mov eax, dword [ebp - 0x2c]
cmp eax, 0xffffffff
jne 0x447614
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [ebp - 8], eax
push 0
lea eax, [ebp - 0x68]
push 0
push eax
push 0x400
push dword [ebp - 8]
push 0
push 0x1100
mov eax, dword [sym.imp.KERNEL32.dll_FormatMessageA]
call eax
push dword [ebp - 0x68]
push str.Wait_failed:__s_n
call fcn.004a6738
lea eax, [eax + 0x40]
push eax
call fcn.004a68ed
sub esp, 0xfffffff4
push dword [ebp - 0x68]
mov eax, dword [sym.imp.KERNEL32.dll_LocalFree]
call eax
jmp 0x447685
cmp dword [ebp - 0x2c], 0x102
je 0x447685
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 0x2c]
cmp edx, eax
jne 0x44763a
cmp dword [edi + 0x24], 0
je 0x447685
push dword [edi + 0x1c]
mov eax, dword [edi + 0x24]
call eax
add esp, 4
jmp 0x447685
cmp dword [ebp - 0x40], 0
jle 0x44766a
mov eax, dword [ebp - 0x2c]
test eax, eax
jb 0x44766a
mov edx, dword [ebp - 0x2c]
mov eax, dword [ebp - 0x40]
dec eax
cmp edx, eax
jae 0x44766a
mov eax, dword [edi + 0x14]
mov edx, dword [ebp - 0x2c]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x54]
mov edx, dword [ecx + edx*4]
mov byte [eax + edx], 1
mov byte [ebp - 1], 1
jmp 0x447685
mov eax, dword [ebp - 0x2c]
cmp eax, 0xc0
je 0x447685
cmp dword [edi + 0x24], 0
je 0x447685
push dword [edi + 0x1c]
mov eax, dword [edi + 0x24]
call eax
sub esp, 0xfffffffc
push dword [edi + 0x1c]
call fcn.00446634
mov eax, dword [edi + 0x28]
sub esp, 0xfffffffc
mov eax, dword [eax + 4]
mov eax, dword [eax]
mov dword [ebp - 0x64], eax
mov dword [ebp - 0x5c], eax
jmp 0x4476ba
mov eax, dword [ebp - 0x5c]
push dword [eax + 0xc]
call fcn.00446676
add esp, 4
lea eax, [ebp - 0x5c]
push eax
call fcn.00442f60
add esp, 4
mov ebx, dword [edi + 0x28]
mov ebx, dword [ebx + 4]
cmp dword [ebp - 0x5c], ebx
mov dword [ebp - 0x60], ebx
jne 0x4476a0
push dword [ebp - 0x54]
mov eax, dword [0x4d3eec]
call eax
add esp, 4
mov dword [ebp - 0x54], 0
push dword [ebp - 0x44]
mov eax, dword [0x4d3eec]
call eax
mov dword [ebp - 0x44], 0
sub esp, 0xfffffffc
mov dword [ebp - 0x2a8], 0
mov dword [ebp - 0x3ac], 0
mov dword [ebp - 0x1a4], 0
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x4c], 0
jmp 0x4478da
mov edx, dword [ebp - 0x4c]
mov ebx, dword [edi + 8]
mov ebx, dword [ebx + 0x10]
mov ebx, dword [ebx + edx*4]
cmp ebx, 0
jne 0x447737
jmp 0x4478d6
mov eax, dword [ebx]
lea eax, [eax + 0x28]
push ebx
mov eax, dword [eax + 4]
call eax
sub esp, 0xfffffffc
test al, al
je 0x4477b8
mov eax, dword [ebx]
push ebx
lea eax, [eax + 0x10]
mov eax, dword [eax + 4]
call eax
sub esp, 0xfffffffc
test al, al
je 0x4477a0
mov eax, dword [ebx]
lea eax, [eax + 0x18]
push ebx
mov eax, dword [eax + 4]
call eax
mov dword [ebp - 0x20], eax
add esp, 4
nop
cmp dword [ebp - 0x2a8], 0x40
jae 0x44778d
mov eax, dword [ebp - 0x20]
mov esi, dword [ebp - 0x2a8]
sub dword [ebp - 0x2a8], 0xffffffff
mov dword [ebp + esi*4 - 0x2a4], eax
nop
mov edx, dword [ebp - 0x20]
lea esi, [edx + 1]
cmp dword [ebp - 0x58], esi
cmovg esi, dword [ebp - 0x58]
mov dword [ebp - 0x58], esi
jmp 0x4477b8
mov dword [ebp + 0xc], 0
mov edx, dword [ebp - 0x4c]
mov eax, dword [edi + 8]
mov eax, dword [eax + 4]
mov byte [eax + edx], 1
mov byte [ebp - 1], 1
mov eax, dword [ebx]
lea eax, [eax + 0x30]
push ebx
mov eax, dword [eax + 4]
call eax
add esp, 4
or al, al
je 0x447839
mov eax, dword [ebx]
lea eax, [eax + 0x10]
push ebx
mov eax, dword [eax + 4]
call eax
sub esp, 0xfffffffc
test al, al
je 0x447821
mov eax, dword [ebx]
push ebx
lea eax, [eax + 0x18]
mov eax, dword [eax + 4]
call eax
mov dword [ebp - 0x1c], eax
add esp, 4
nop
cmp dword [ebp - 0x3ac], 0x40
jae 0x44780e
mov eax, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x3ac]
add dword [ebp - 0x3ac], 1
mov dword [ebp + edx*4 - 0x3a8], eax
nop
mov edx, dword [ebp - 0x1c]
lea esi, [edx + 1]
cmp dword [ebp - 0x58], esi
cmovg esi, dword [ebp - 0x58]
mov dword [ebp - 0x58], esi
jmp 0x447839
mov dword [ebp + 0xc], 0
mov edx, dword [ebp - 0x4c]
mov eax, dword [edi + 8]
mov eax, dword [eax + 8]
mov byte [eax + edx], 1
mov byte [ebp - 1], 1
mov eax, dword [ebx]
push ebx
lea eax, [eax + 0x20]
mov eax, dword [eax + 4]
call eax
add esp, 4
or al, al
je 0x4478b9
mov eax, dword [ebx]
push ebx
lea eax, [eax + 0x10]
mov eax, dword [eax + 4]
call eax
add esp, 4
test al, al
je 0x4478a2
mov eax, dword [ebx]
lea eax, [eax + 0x18]
push ebx
mov eax, dword [eax + 4]
call eax
add esp, 4
mov dword [ebp - 0x18], eax
nop
cmp dword [ebp - 0x1a4], 0x40
jae 0x44788f
mov esi, dword [ebp - 0x1a4]
mov eax, dword [ebp - 0x18]
add dword [ebp - 0x1a4], 1
mov dword [ebp + esi*4 - 0x1a0], eax
nop
mov edx, dword [ebp - 0x18]
lea esi, [edx + 1]
cmp dword [ebp - 0x58], esi
cmovg esi, dword [ebp - 0x58]
mov dword [ebp - 0x58], esi
jmp 0x4478b9
mov dword [ebp + 0xc], 0
mov esi, dword [edi + 8]
mov esi, dword [esi]
mov edx, dword [ebp - 0x4c]
mov byte [esi + edx], 1
mov byte [ebp - 1], 1
mov eax, dword [ebx]
push ebx
lea eax, [eax + 0x38]
mov eax, dword [eax + 4]
call eax
add esp, 4
test al, al
je 0x4478d6
mov dword [ebp + 0xc], 0
mov byte [ebp - 1], 1
sub dword [ebp - 0x4c], 0xffffffff
mov esi, dword [edi + 8]
mov esi, dword [esi + 0x14]
cmp esi, dword [ebp - 0x4c]
jg 0x447721
mov eax, dword [ebp + 0xc]
cdq
mov ecx, 0x3e8
idiv ecx
mov dword [ebp - 0x3b4], eax
mov eax, dword [ebp + 0xc]
cdq
mov ecx, 0x3e8
lea ebx, [ebp - 0x3ac]
idiv ecx
lea eax, [ebp - 0x3b4]
mov esi, edx
imul esi, esi, 0x3e8
mov dword [ebp - 0x3b0], esi
push eax
lea eax, [ebp - 0x1a4]
push ebx
lea ebx, [ebp - 0x2a8]
push ebx
push eax
push dword [ebp - 0x58]
call sub.WS2_32.dll_select
test eax, eax
jle 0x447a14
mov dword [ebp - 0x48], 0
jmp 0x447a05
mov edx, dword [edi + 8]
mov ecx, dword [ebp - 0x48]
mov edx, dword [edx + 0x10]
mov edx, dword [edx + ecx*4]
mov dword [ebp - 0x30], edx
cmp dword [ebp - 0x30], 0
jne 0x447965
jmp 0x447a01
mov eax, dword [ebp - 0x30]
mov eax, dword [eax]
push dword [ebp - 0x30]
lea eax, [eax + 0x10]
mov eax, dword [eax + 4]
call eax
sub esp, 0xfffffffc
test al, al
je 0x447a01
mov eax, dword [ebp - 0x30]
mov eax, dword [eax]
lea eax, [eax + 0x18]
push dword [ebp - 0x30]
mov eax, dword [eax + 4]
call eax
sub esp, 0xfffffffc
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x1a4]
push eax
push dword [ebp - 0x10]
call sub.WS2_32.dll___WSAFDIsSet
or eax, eax
je 0x4479b9
mov esi, dword [edi + 8]
mov edx, dword [ebp - 0x48]
mov esi, dword [esi]
mov byte [esi + edx], 1
mov byte [ebp - 1], 1
lea eax, [ebp - 0x3ac]
push eax
push dword [ebp - 0x10]
call sub.WS2_32.dll___WSAFDIsSet
or eax, eax
je 0x4479dd
mov eax, dword [edi + 8]
mov edx, dword [ebp - 0x48]
mov eax, dword [eax + 8]
mov byte [eax + edx], 1
mov byte [ebp - 1], 1
lea eax, [ebp - 0x2a8]
push eax
push dword [ebp - 0x10]
call sub.WS2_32.dll___WSAFDIsSet
test eax, eax
je 0x447a01
mov eax, dword [edi + 8]
mov eax, dword [eax + 4]
mov ebx, dword [ebp - 0x48]
mov byte [eax + ebx], 1
mov byte [ebp - 1], 1
sub dword [ebp - 0x48], 0xffffffff
mov edx, dword [edi + 8]
mov edx, dword [edx + 0x14]
cmp edx, dword [ebp - 0x48]
jg 0x44794b
cmp byte [ebp + 0x10], 0
je 0x447a29
cmp byte [ebp - 1], 0
je 0x447a29
push edi
call fcn.00446d8e
add esp, 4
push dword [edi + 8]
call fcn.00445d81
sub esp, 0xfffffffc
nop
nop
mov eax, dword [ebp - 0x78]
jmp 0x447a4c
mov edx, dword [eax]
mov dword [ebp - 0xc], edx
push eax
call fcn.0041d48f
sub esp, 0xfffffffc
mov eax, dword [ebp - 0xc]
test eax, eax
jne 0x447a3b
mov dword [ebp - 0x70], 0
mov dword [ebp - 0x74], 0
mov eax, dword [ebp - 0x74]
mov dword [ebp - 0x78], eax
nop
pop edi
pop ebx
pop esi
leave
ret