Function at 0x10162160
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0xd0
mov esi, esp
mov dword [esi + 0xb8], ebp
movzx eax, byte [ebp + 0x18]
mov dword [esi + 0xbc], esp
mov dword [esi + 0xc8], 0xffffffff
mov dword [esi + 0xc4], 0x10162e60
mov ecx, dword fs:[0]
mov edx, eax
mov dword [esi + 0xb0], eax
lea eax, [esi + 0xc0]
mov dword [esi + 0xc0], ecx
mov dword fs:[0], eax
xor eax, eax
test dl, 1
mov ecx, 0x89
mov byte [esi + 0x13], dl
cmove ecx, eax
mov eax, dword [ebp + 0xc]
mov dword [esi + 0xac], ecx
mov cl, 1
mov edx, dword [eax]
lea eax, [edx + 0xc]
lea ebx, [edx + 0x10]
mov dword [esi + 0xb4], eax
xor eax, eax
lock cmpxchg byte [edx + 0x10], cl
mov dword [esi + 0xc], edx
jne 0x10162708
mov eax, dword [0x10283a20]
mov eax, dword [eax]
test eax, 0x7fffffff
jne 0x10162726
xor eax, eax
movzx ecx, byte [edx + 0x11]
test cl, cl
jne 0x1016273c
mov dword [esi + 0x18], ebx
mov byte [esi + 0x1c], al
mov dword [esi + 4], eax
mov eax, dword [edx + 0x1c]
test eax, eax
je 0x1016224e
mov ecx, dword [edx + 0x18]
mov eax, dword [ecx + eax*4 - 4]
mov eax, dword [eax]
cmp eax, 0x21
jb 0x10162279
lea eax, [edx + 0x14]
mov edx, dword [edx + 0xc]
mov dword [esi + 8], ebx
mov dword [esi + 0xc8], 1
lea ecx, [esi + 0x30]
push eax
call fcn.10162020
add esp, 4
jmp 0x1016226d
lea eax, [edx + 0x14]
mov edx, dword [edx + 0xc]
mov dword [esi + 8], ebx
mov dword [esi + 0xc8], 1
lea ecx, [esi + 0x30]
push eax
call fcn.10162020
add esp, 4
cmp byte [esi + 0x30], 4
mov edx, dword [esi + 0xc]
jne 0x101622cd
mov ebx, dword [esi + 8]
mov eax, dword [edx + 0x1c]
test eax, eax
je 0x10162819
mov ecx, dword [edx + 0x18]
mov edx, dword [ecx + eax*4 - 4]
lock inc dword [edx]
jle 0x101628dc
cmp byte [esi + 4], 0
jne 0x101622ac
mov eax, dword [0x10283a20]
mov eax, dword [eax]
test eax, 0x7fffffff
jne 0x101627ae
xor eax, eax
xchg byte [ebx], al
cmp al, 2
jne 0x1016230b
mov dword [esi + 0xc8], 0xffffffff
push ebx
mov edi, edx
call fcn.101ca9e0
mov edx, edi
add esp, 4
jmp 0x1016230b
mov edi, dword [esi + 0x30]
mov edx, dword [esi + 0x34]
mov ebx, edi
shrd ebx, edx, 8
cmp byte [esi + 4], 0
jne 0x101622f1
mov eax, dword [0x10283a20]
mov eax, dword [eax]
test eax, 0x7fffffff
jne 0x101627d5
mov ecx, dword [esi + 8]
xor eax, eax
xchg byte [ecx], al
cmp al, 2
je 0x10162785
mov ecx, edi
cmp cl, 4
jne 0x101626d7
lea ebx, [esi + 0x30]
lea edi, [esi + 0x20]
mov dword [esi + 4], edx
mov dword [esi + 0x18], edx
mov dword [esi + 0x20], 0
mov dword [esi + 0x30], 0
push 0
push 0
push ebx
push 4
push edi
push 0
push 0
push 0x48000022
push dword [ebp + 0x10]
call dword [sym.imp.ws2_32.dll_WSAIoctl]
cmp eax, 0xffffffff
je 0x10162561
mov eax, dword [esi + 0x20]
xorps xmm0, xmm0
mov ecx, dword [esi + 4]
movsd qword [esi + 0x9a], xmm0
movsd qword [esi + 0xa2], xmm0
movsd qword [esi + 0x68], xmm0
movsd qword [esi + 0x60], xmm0
movsd qword [esi + 0x58], xmm0
movsd qword [esi + 0x50], xmm0
movsd qword [esi + 0x80], xmm0
mov word [esi + 0x88], 0
mov dword [esi + 0x30], 1
mov dword [esi + 0x34], 1
mov word [esi + 0x38], 0
movsd qword [esi + 0x48], xmm0
movsd xmm0, qword [esi + 0x94]
movsd xmm1, qword [esi + 0x9c]
movsd qword [esi + 0x3a], xmm0
movsd qword [esi + 0x42], xmm1
mov dword [esi + 0x74], 0
mov dword [esi + 0x70], 0
mov dword [esi + 0x78], ecx
mov dword [esi + 0x7c], eax
movzx eax, byte [0x10283b09]
push 8
push 0x60
call fcn.10013860
add esp, 8
test eax, eax
je 0x101627fe
mov ebx, eax
push 0x60
lea edi, [esi + 0x30]
push edi
push eax
call sub.VCRUNTIME140.dll_memcpy
add esp, 0xc
mov edx, ebx
mov dword [esi + 0x14], ebx
mov cl, 1
xor eax, eax
add ebx, 8
mov dword [esi + 8], edx
lock cmpxchg byte [edx + 8], cl
mov dword [esi + 4], ebx
je 0x1016242b
mov dword [esi + 0xc8], 3
push ebx
call fcn.101ca940
mov ebx, dword [esi + 4]
lea edi, [esi + 0x30]
add esp, 4
mov eax, dword [0x10283a20]
mov eax, dword [eax]
test eax, 0x7fffffff
je 0x101625af
mov dword [esi + 0xc8], 3
call fcn.101ca8b0
mov ebx, dword [esi + 4]
lea edi, [esi + 0x30]
mov edx, edi
xor al, 1
mov edi, dword [esi + 8]
movzx ecx, byte [edi + 9]
test cl, cl
jne 0x101625c2
mov ecx, dword [esi + 0xb0]
mov edx, dword [esi + 0xac]
add ecx, ecx
and ecx, 4
test al, al
lea ecx, [edx + ecx + 0x110]
mov dword [edi + 0x50], ecx
mov ecx, dword [ebp + 0x14]
mov dword [edi + 0x44], 0
mov dword [edi + 0x40], ecx
jne 0x101624bf
mov eax, dword [0x10283a20]
mov eax, dword [eax]
test eax, 0x7fffffff
je 0x101624bf
mov dword [esi + 0xc8], 3
call fcn.101ca8b0
mov ecx, dword [ebp + 0x14]
mov ebx, dword [esi + 4]
test al, al
jne 0x101624bf
mov eax, dword [esi + 8]
mov byte [eax + 9], 1
xor eax, eax
xchg byte [ebx], al
cmp al, 2
jne 0x101624dd
mov dword [esi + 0xc8], 3
push ebx
call fcn.101ca9e0
mov ecx, dword [ebp + 0x14]
add esp, 4
mov eax, dword [esi + 0xc]
mov edx, dword [esi + 0x14]
lock inc dword [eax]
jle 0x101628dc
lock inc dword [edx]
jle 0x101628dc
mov edi, dword [esi + 0xc]
movzx eax, byte [esi + 0x13]
mov dword [esi + 0xc8], 5
mov dword [esi + 0x30], edi
mov dword [esi + 0x38], ecx
lea ecx, [edi + 8]
mov byte [esi + 0x3c], al
mov dword [esi + 0x34], edx
mov dword [esi + 4], ecx
call fcn.10162ba0
mov eax, dword [esi + 0xc]
mov ebx, dword [ebp + 8]
movzx eax, byte [eax + 0x34]
test al, al
je 0x10162549
mov edx, dword [esi + 4]
lea ecx, [esi + 0x94]
call fcn.10161760
cmp byte [esi + 0x94], 4
mov ebx, dword [ebp + 8]
jne 0x101625f1
movsd xmm0, qword [esi + 0x30]
movsd xmm1, qword [esi + 0x38]
movsd qword [ebx + 8], xmm1
movsd qword [ebx], xmm0
jmp 0x101626f2
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
mov dword [esi + 8], eax
mov dword [esi + 0x20], 0
mov dword [esi + 0x30], 0
push 0
push 0
push ebx
push 4
mov ebx, edi
push edi
push 0
push 0
push 0x4800001c
mov edi, dword [ebp + 0x10]
push edi
call dword [sym.imp.ws2_32.dll_WSAIoctl]
cmp eax, 0xffffffff
mov ecx, edi
je 0x10162620
mov eax, dword [esi + 0x20]
mov edi, ebx
cmp eax, ecx
jne 0x1016234b
jmp 0x1016262c
mov edx, edi
xor eax, eax
mov edi, dword [esi + 8]
movzx ecx, byte [edi + 9]
test cl, cl
je 0x10162465
mov dword [esi + 0x30], ebx
mov byte [esi + 0x34], al
mov dword [esi + 0xc8], 4
push 0x1020c17c
push 0x1020bf90
push edx
push 0x2b
push 0x1020bf64
call fcn.101cbbf0
add esp, 0x14
jmp 0x101628dc
mov ecx, dword [esi + 0x98]
mov eax, dword [esi + 0x94]
mov dword [esi + 0xc8], 0xffffffff
mov dword [ebx + 8], ecx
lea ecx, [esi + 0x30]
mov dword [ebx + 4], eax
mov dword [ebx], 0
call fcn.101607f0
jmp 0x101626f2
mov edi, ecx
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
mov ecx, edi
mov edi, ebx
mov dword [esi + 0x20], 0
mov dword [esi + 0x30], 0
push 0
push 0
lea eax, [esi + 0x30]
push eax
push 4
push edi
push 0
push 0
push 0x4800001d
push ecx
mov ebx, ecx
call dword [sym.imp.ws2_32.dll_WSAIoctl]
cmp eax, 0xffffffff
je 0x1016266b
mov eax, dword [esi + 0x20]
mov ecx, ebx
cmp eax, ebx
jne 0x1016234b
jmp 0x10162673
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
mov ecx, ebx
mov dword [esi + 0x20], 0
mov dword [esi + 0x30], 0
push 0
push 0
lea eax, [esi + 0x30]
push eax
push 4
push edi
push 0
push 0
push 0x4800001b
push ecx
mov edi, ecx
call dword [sym.imp.ws2_32.dll_WSAIoctl]
cmp eax, 0xffffffff
je 0x1016276e
mov eax, dword [esi + 0x20]
cmp eax, edi
jne 0x1016234b
mov eax, dword [esi + 4]
lock dec dword [eax]
jne 0x101626d0
lea eax, [esi + 0x18]
mov dword [esi + 0xc8], 0xffffffff
push eax
call fcn.10006cf0
add esp, 4
mov edx, dword [esi + 8]
xor ebx, ebx
xor ecx, ecx
mov eax, dword [ebp + 8]
mov byte [eax + 4], cl
mov word [eax + 5], bx
shr ebx, 0x10
mov byte [eax + 7], bl
mov dword [eax + 8], edx
mov ebx, eax
mov dword [eax], 0
mov eax, dword [esi + 0xc0]
mov dword fs:[0], eax
mov eax, ebx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
push ebx
call fcn.101ca940
mov edx, dword [esi + 0xc]
add esp, 4
mov eax, dword [0x10283a20]
mov eax, dword [eax]
test eax, 0x7fffffff
je 0x10162201
call fcn.101ca8b0
mov edx, dword [esi + 0xc]
xor al, 1
movzx ecx, byte [edx + 0x11]
test cl, cl
je 0x1016220f
mov dword [esi + 0x30], ebx
mov byte [esi + 0x34], al
mov dword [esi + 0xc8], 0
lea eax, [esi + 0x30]
push 0x1020c100
push 0x1020bfa0
push eax
push 0x2b
push 0x1020bf64
call fcn.101cbbf0
add esp, 0x14
jmp 0x101628dc
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
mov eax, dword [esi + 4]
lock dec dword [eax]
je 0x101626ba
jmp 0x101626d0
mov dword [esi + 0xc8], 0xffffffff
push ecx
mov dword [esi + 4], edx
call fcn.101ca9e0
mov edx, dword [esi + 4]
add esp, 4
mov ecx, edi
cmp cl, 4
je 0x1016230b
jmp 0x101626d7
mov dword [esi + 0xc8], 0xffffffff
mov edi, edx
call fcn.101ca8b0
mov ecx, dword [esi + 0xc]
mov edx, edi
test al, al
jne 0x101622ac
mov byte [ecx + 0x11], 1
jmp 0x101622ac
mov dword [esi + 0xc8], 0xffffffff
mov dword [esi + 4], edx
call fcn.101ca8b0
mov edx, dword [esi + 4]
mov ecx, dword [esi + 0xc]
test al, al
jne 0x101622f1
mov byte [ecx + 0x11], 1
jmp 0x101622f1
mov dword [esi + 0xc8], 2
push 0x60
push 8
call fcn.101cb670
add esp, 8
jmp 0x101628dc
lea eax, [esi + 0xb4]
mov dword [esi + 0x94], 0x1020c15c
mov dword [esi + 0x98], 2
mov dword [esi + 0x30], 2
mov dword [esi + 0x38], 2
mov dword [esi + 0x40], 0x20
mov dword [esi + 0x44], 0
mov dword [esi + 0x48], 4
mov byte [esi + 0x4c], 3
mov dword [esi + 0x50], 2
mov dword [esi + 0x58], 2
mov dword [esi + 0x60], 0x20
mov dword [esi + 0x64], 1
mov dword [esi + 0x68], 4
mov byte [esi + 0x6c], 3
mov dword [esi + 0xc8], 1
mov dword [esi + 0x20], eax
lea eax, [esi + 0x18]
mov dword [esi + 0x24], 0x101605c0
mov dword [esi + 0x28], eax
lea eax, [esi + 0x30]
mov dword [esi + 0x2c], 0x10164e10
mov dword [esi + 0xa4], eax
lea eax, [esi + 0x20]
mov dword [esi + 0xa8], 2
mov dword [esi + 0x9c], eax
mov dword [esi + 0xa0], 2
lea eax, [esi + 0x94]
push 0x1020c16c
push eax
call fcn.101cb880
add esp, 8
ud2