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

Disassembly:
sub esp, 0x6c
mov eax, dword [0x10a78b80]
xor eax, esp
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x74]
xor ecx, ecx
mov edx, dword [esp + 0x7c]
push ebx
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x7c]
push ebp
mov ebp, dword [esp + 0x78]
push esi
lea esi, [eax + 0x3abf0]
mov dword [esp + 0x30], eax
mov eax, dword [esi + 0x3bb8]
push edi
lea edi, [edx + 0xe0]
mov dword [esp + 0x14], edx
mov dword [esp + 0x20], ebp
cmp byte [eax + 0x4d], cl
mov eax, dword [edi + 0xfd0]
sete cl
mov dword [esp + 0x18], esi
mov dword [esp + 0x38], closesocket
mov dword [esp + 0x40], 0xffffffff
mov ebx, dword [eax]
mov byte [edx + 0x1b5ec], 1
lea ecx, [ecx*2 + 1]
mov edx, dword [esi + 0x1c]
mov dword [esp + 0x30], ecx
mov dword [esp + 0x44], closesocket
mov dword [esp + 0x48], 0xffffffff
mov dword [esp + 0x4c], closesocket
mov dword [esp + 0x50], 0xffffffff
mov dword [esp + 0x54], closesocket
mov byte [esp + 0x58], 0
mov dword [esp + 0x3c], 0
cmp edx, 0xffffffff
je 0x1016e9c4
mov eax, dword [esi + 0x20]
mov dword [esp + 0x24], eax
cmp eax, 0xffffffff
je 0x1016e9c4
mov cl, al
mov ch, dl
inc cl
inc ch
cmp cl, 0xff
je 0x1016e9c4
movsx edx, dl
movsx eax, al
mov dword [esp + 0x28], edx
mov al, byte [eax + edx*8 + 0x10813279]
mov byte [esp + 0x13], al
cmp al, 0xff
je 0x1016e9c4
mov eax, dword [esp + 0x34]
cmp byte [eax + 0x3ee25], 0
je 0x1016e4af
cmp dword [eax + 0x5ced4], 0
je 0x1016e4bc
cmp dword [eax + 0x6d644], 0
jne 0x1016e9c4
lea eax, [ebx + 0x14]
mov word [ebx + 5], 0x11
push eax
mov byte [eax], ch
mov byte [ebx + 0x15], cl
call fcn.10165ce0
mov ecx, dword [esp + 0x18]
add esp, 4
mov byte [esp + 0x1c], al
movzx eax, al
cmp byte [eax + ecx + 0x30f8], 0xff
jne 0x1016e560
mov eax, dword [esp + 0x28]
cmp byte [eax + ecx + 0x30f9], 0xff
je 0x1016e9c4
mov eax, dword [esp + 0x24]
movsx eax, al
cmp byte [eax + ecx + 0x30f9], 0xff
je 0x1016e9c4
mov esi, dword [esp + 0x1c]
lea eax, [ecx + 0x3138]
push eax
lea eax, [ecx + 0x3118]
push eax
push 0
lea eax, [edi + 0x1898]
push eax
lea eax, [edi + 0x1158]
push eax
lea eax, [ecx + 0x30f8]
push eax
push esi
push ebx
push edi
push dword [esp + 0x3c]
call fcn.100b9750
mov eax, dword [esp + 0x3c]
push esi
add eax, 0x2c70
push eax
push edi
call fcn.10162a90
mov esi, dword [esp + 0x4c]
add esp, 0x34
mov ecx, dword [esp + 0x14]
push 0
push ecx
push esi
lea eax, [ebx + 0xc]
push 0x11
push eax
call fcn.10165d40
add esp, 0x14
test eax, eax
je 0x1016e9c4
mov cl, byte [ebx + 0xa0]
mov eax, dword [esp + 0x14]
and cl, 0xfe
mov byte [ebx + 0xa0], cl
mov byte [ebx + 0x53], 0
mov byte [ebx + 0x44], 0xff
mov al, byte [eax + 0x1b5ec]
add al, al
mov word [ebx + 0x87], 0x100
xor al, cl
mov byte [ebx + 0x4f], 0
and al, 2
mov byte [ebx + 0x1c], 0
xor al, cl
mov byte [ebx + 0xa0], al
mov al, byte [ebx + 0x9f]
and al, 0xcf
or al, 0x40
mov byte [ebx + 0x9f], al
mov byte [ebx + 0x86], 0
push dword [esi + 0x1c8]
push ebx
call fcn.101700c0
movzx eax, byte [ebx + 0x15]
push eax
movzx eax, byte [ebx + 0x14]
push eax
push edi
push esi
call fcn.101707d0
mov esi, dword [esp + 0x48]
lea edx, [edi + 0x44]
add esp, 0x18
xor ebp, ebp
nop word [eax + eax]
movsx eax, byte [ebx + 0x14]
lea edx, [edx + 0x538]
lea ecx, [eax*2]
add ecx, ebp
add ecx, eax
lea eax, [ecx + ecx*4]
mov ecx, dword [esp + 0x94]
movups xmm0, xmmword [ecx + eax*4]
movups xmmword [edx - 0x54c], xmm0
mov eax, dword [ecx + eax*4 + 0x10]
mov dword [edx - 0x53c], eax
movsx eax, byte [ebx + 0x15]
lea ecx, [eax*2]
add ecx, ebp
inc ebp
add ecx, eax
lea eax, [ecx + ecx*4]
mov ecx, dword [esp + 0x94]
movups xmm0, xmmword [ecx + eax*4]
movups xmmword [edx - 0x538], xmm0
mov eax, dword [ecx + eax*4 + 0x10]
mov dword [edx - 0x528], eax
cmp ebp, esi
jl 0x1016e600
mov ebp, dword [esp + 0x20]
lea edx, [edi + 0x2c]
xor ecx, ecx
mov eax, dword [edx - 0x10]
lea edx, [edx + 0x538]
mov dword [esp + ecx*4 + 0x60], eax
mov eax, dword [edx - 0x538]
mov dword [esp + ecx*4 + 0x6c], eax
inc ecx
cmp ecx, esi
jl 0x1016e670
mov eax, dword [edi + 0xfdc]
mov edx, dword [edi + 0xfd8]
test eax, eax
je 0x1016e6ab
movzx ecx, byte [eax + 0x9f]
shr ecx, 6
and ecx, 1
jmp 0x1016e6ad
xor ecx, ecx
test edx, edx
je 0x1016e6c0
movzx eax, byte [edx + 0x9f]
shr eax, 6
and eax, 1
jmp 0x1016e6c2
xor eax, eax
mov esi, dword [ebp + 8]
or edx, 0xffffffff
cmp dword [ebp + 0xc], 0x7fffffff
mov dword [esp + 0x1c], edx
mov dword [esp + 0x28], closesocket
jg 0x1016e7d5
jl 0x1016e6eb
cmp esi, edx
jae 0x1016e7d5
cmp dword [ebp], 0x7fffffff
jge 0x1016e7d5
mov edx, dword [esp + 0x14]
add eax, ecx
mov ecx, dword [ebp]
add ecx, dword [edx + eax*8 + 0x6e88]
mov eax, dword [ebp + 0xc]
shld eax, esi, 7
mov dword [esp + 0x18], eax
mov eax, ecx
imul dword [edx + 0x31cc]
shl esi, 7
mov dword [esp + 0x1c], eax
mov eax, edx
mov edx, dword [esp + 0x1c]
add edx, 0x100
mov dword [ebp], ecx
mov dword [esp + 0x20], esi
adc eax, 0
shrd edx, eax, 9
sar eax, 9
add edx, esi
mov dword [esp + 0x1c], edx
adc eax, dword [esp + 0x18]
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x14]
mov edx, dword [eax + 0x31cc]
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x1c]
cmp ecx, 0x7fffffff
jge 0x1016e8a0
cmp dword [ebp + 0x14], 0x7fffffff
jg 0x1016e8a0
jl 0x1016e784
cmp dword [ebp + 0x10], 0xffffffff
jae 0x1016e8a0
test ecx, ecx
js 0x1016e7ac
mov eax, ecx
imul dword [esp + 0x24]
mov esi, eax
mov ecx, edx
add esi, 0x100
adc ecx, 0
shrd esi, ecx, 9
sar ecx, 9
add esi, dword [esp + 0x20]
adc ecx, dword [esp + 0x18]
jmp 0x1016e7cb
neg ecx
mov eax, ecx
mov ecx, dword [esp + 0x18]
imul dword [esp + 0x24]
add eax, 0x100
adc edx, 0
shrd eax, edx, 9
sar edx, 9
sub esi, eax
sbb ecx, edx
mov edx, dword [esp + 0x1c]
mov dword [ebp + 0x10], esi
mov dword [ebp + 0x14], ecx
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x28]
lea ecx, [esp + 0x60]
push esi
push edx
push ecx
push dword [esp + 0x9c]
push eax
mov eax, dword [esp + 0x48]
push eax
lea eax, [esp + 0x50]
push eax
call fcn.101715b0
add esp, 0x1c
cmp dword [esp + 0x4c], esi
jg 0x1016e9c4
jl 0x1016e818
mov eax, dword [esp + 0x1c]
cmp dword [esp + 0x48], eax
ja 0x1016e9c4
movzx eax, byte [ebx + 0x9f]
and eax, 7
cmp dword [edi + eax*4 + 0x1a9c], 0
je 0x1016e83a
mov eax, dword [esp + 0x40]
or eax, dword [esp + 0x44]
jne 0x1016e9c4
mov eax, dword [esp + 0x2c]
mov ecx, 0x29
mov esi, ebx
or byte [eax + 0xb7], 0x40
lea edi, [eax + 0x18]
rep movsd dword es:[edi], dword [esi]
mov esi, eax
movzx eax, byte [esi + 0xa1]
mov cl, al
movzx ecx, cl
imul ecx, ecx, 0x1010101
mov dword [esi + 0xa2], ecx
mov dword [esi + 0xa6], ecx
mov dword [esi + 0xaa], ecx
mov dword [esi + 0xae], ecx
cmp byte [esi + 0xa0], 0
je 0x1016e8e1
mov al, byte [ebx + 0x9f]
test al, al
js 0x1016e896
cmp byte [ebx + 0x14], 0
jle 0x1016e8e1
mov dword [esp + 0x18], 1
jmp 0x1016e8e9
mov dword [ebp], closesocket
mov dword [ebp + 8], 0xffffffff
mov dword [ebp + 0xc], closesocket
mov dword [ebp + 0x10], 0xffffffff
mov dword [ebp + 0x14], closesocket
mov dword [ebp + 0x18], 0xffffffff
mov dword [ebp + 0x1c], closesocket
mov byte [ebp + 0x20], 0
mov dword [ebp + 4], 0
jmp 0x1016e7d9
mov dword [esp + 0x18], 0
mov edi, dword [esp + 0x14]
movzx edx, byte [esi + 0xa1]
mov bh, byte [esp + 0x13]
mov al, byte [edi + 0x1235]
mov bl, byte [edi + 0x1234]
movzx ecx, al
mov dword [esp + 0x30], ecx
shl al, 2
cmp dword [esp + 0x18], 0
movzx ecx, bl
mov dword [esp + 0x20], ecx
movzx ecx, al
movzx eax, byte [edx*4 + 0x10808490]
cmove ecx, eax
movzx eax, byte [edx*4 + 0x10808440]
shl bl, 2
cmp dword [esp + 0x18], 0
mov byte [esp + 0x2c], cl
movzx ecx, bl
cmove ecx, eax
mov eax, dword [esp + 0x20]
test eax, eax
je 0x1016e95a
push eax
push ecx
push dword [edi + 0x117c]
call fcn.10513d40
add esp, 0xc
mov eax, dword [esp + 0x30]
test eax, eax
je 0x1016e975
push eax
push dword [esp + 0x30]
push dword [edi + 0x1180]
call fcn.10513d40
add esp, 0xc
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x40]
mov byte [esi + 0xcc], bh
mov dword [ebp], eax
mov eax, dword [esp + 0x44]
mov dword [ebp + 0x18], ecx
mov dword [ebp + 0x1c], eax
mov dword [ebp + 8], ecx
mov ecx, dword [esp + 0x4c]
mov dword [ebp + 0xc], eax
mov eax, dword [esp + 0x48]
mov dword [ebp + 0x10], eax
mov dword [ebp + 0x14], ecx
mov dword [esi], eax
mov dword [esi + 4], ecx
mov dword [esi + 0xc8], 1
mov dword [esi + 0xc4], 1
mov byte [edi + 0x23b80], 1
mov ecx, dword [esp + 0x78]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.105116c0
add esp, 0x6c
ret