Function at 0x40c790
Capabilities:
Encode data using xor
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x578
push ebx
mov ebx, dword [esp + 0x580]
push ebp
push esi
mov esi, dword [esp + 0x58c]
push edi
xor edi, edi
mov ecx, ebx
mov dword [esp + 0x4c], edi
mov dword [esp + 0x50], edi
mov dword [esp + 0x54], edi
mov dword [esp + 0x58], edi
mov dword [esp + 0x5c], edi
mov dword [esp + 0x60], edi
mov dword [esp + 0x64], edi
mov dword [esp + 0x68], edi
mov dword [esp + 0x6c], edi
mov dword [esp + 0x70], edi
mov dword [esp + 0x74], edi
mov dword [esp + 0x78], edi
mov dword [esp + 0x7c], edi
mov dword [esp + 0x80], edi
mov dword [esp + 0x84], edi
mov dword [esp + 0x88], edi
mov edx, esi
mov eax, dword [ecx]
add ecx, 4
mov ebp, dword [esp + eax*4 + 0x4c]
lea eax, [esp + eax*4 + 0x4c]
inc ebp
dec edx
mov dword [eax], ebp
jne 0x40c7f7
cmp dword [esp + 0x4c], esi
jne 0x40c82f
mov ecx, dword [esp + 0x5a0]
mov edx, dword [esp + 0x5a4]
mov dword [ecx], edi
mov dword [edx], edi
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x578
ret
mov esi, dword [esp + 0x5a4]
mov ecx, 1
lea eax, [esp + 0x50]
mov ebp, dword [esi]
mov dword [esp + 0x10], ebp
cmp dword [eax], edi
jne 0x40c852
inc ecx
add eax, 4
cmp ecx, 0xf
jbe 0x40c845
cmp ebp, ecx
mov dword [esp + 0x14], ecx
jae 0x40c860
mov dword [esp + 0x10], ecx
mov ebp, ecx
mov eax, 0xf
lea edx, [esp + 0x88]
cmp dword [edx], edi
jne 0x40c878
dec eax
sub edx, 4
cmp eax, edi
jne 0x40c86c
cmp ebp, eax
mov dword [esp + 0x2c], eax
jbe 0x40c886
mov dword [esp + 0x10], eax
mov ebp, eax
mov dword [esi], ebp
mov esi, 1
shl esi, cl
cmp ecx, eax
jae 0x40c8a5
lea edx, [esp + ecx*4 + 0x4c]
sub esi, dword [edx]
js 0x40c8c0
inc ecx
add edx, 4
shl esi, 1
cmp ecx, eax
jb 0x40c897
lea ecx, [eax*4]
mov dword [esp + 0x38], ecx
lea edx, [esp + ecx + 0x4c]
mov ecx, dword [esp + ecx + 0x4c]
sub esi, ecx
mov dword [esp + 0x48], esi
jns 0x40c8d0
pop edi
pop esi
pop ebp
mov eax, 0xfffffffd
pop ebx
add esp, 0x578
ret
add ecx, esi
mov dword [esp + 0x90], edi
mov dword [edx], ecx
xor ecx, ecx
dec eax
je 0x40c8f3
xor edx, edx
add ecx, dword [esp + edx + 0x50]
add edx, 4
dec eax
mov dword [esp + edx + 0x90], ecx
jne 0x40c8e2
xor edx, edx
mov eax, dword [ebx]
add ebx, 4
cmp eax, edi
je 0x40c916
mov ecx, dword [esp + eax*4 + 0x8c]
lea eax, [esp + eax*4 + 0x8c]
mov dword [esp + ecx*4 + 0x108], edx
inc ecx
mov dword [eax], ecx
mov eax, dword [esp + 0x590]
inc edx
cmp edx, eax
jb 0x40c8f5
mov eax, dword [esp + 0x38]
lea edx, [esp + 0x108]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0x2c]
mov ecx, dword [esp + eax + 0x8c]
mov eax, ebp
mov dword [esp + 0x590], ecx
mov ecx, dword [esp + 0x14]
xor ebx, ebx
mov dword [esp + 0x8c], edi
neg eax
cmp ecx, edx
mov dword [esp + 0x28], ebx
mov dword [esp + 0x18], 0xffffffff
mov dword [esp + 0xcc], edi
mov dword [esp + 0x38], edi
jg 0x40cc14
lea edx, [ecx - 1]
lea ecx, [esp + ecx*4 + 0x4c]
mov dword [esp + 0x40], edx
mov dword [esp + 0x34], ecx
mov edx, dword [esp + 0x34]
mov ecx, dword [edx]
mov edx, ecx
dec ecx
test edx, edx
mov dword [esp + 0x30], ecx
je 0x40cbeb
mov ecx, dword [esp + 0x14]
lea esi, [eax + ebp]
cmp ecx, esi
jle 0x40cabb
mov dword [esp + 0x3c], esi
mov edx, dword [esp + 0x2c]
mov ecx, dword [esp + 0x18]
mov edi, dword [esp + 0x3c]
add eax, ebp
sub edx, eax
inc ecx
add edi, ebp
cmp edx, ebp
mov dword [esp + 0x18], ecx
mov dword [esp + 0x44], eax
mov dword [esp + 0x3c], edi
jbe 0x40c9cf
mov edx, ebp
mov ebx, dword [esp + 0x14]
sub ebx, eax
mov eax, 1
mov ecx, ebx
shl eax, cl
mov ecx, dword [esp + 0x30]
inc ecx
cmp eax, ecx
jbe 0x40ca12
mov edi, dword [esp + 0x30]
mov esi, dword [esp + 0x34]
or ecx, 0xffffffff
sub ecx, edi
add eax, ecx
cmp ebx, edx
jae 0x40ca12
inc ebx
cmp ebx, edx
jae 0x40ca12
mov ecx, dword [esi + 4]
add esi, 4
shl eax, 1
cmp eax, ecx
jbe 0x40ca12
sub eax, ecx
inc ebx
cmp ebx, edx
jb 0x40c9ff
mov esi, dword [esp + 0x5a8]
mov edi, 1
mov ecx, ebx
push 8
mov eax, dword [esi + 0x28]
shl edi, cl
lea edx, [edi + 1]
push edx
push eax
call dword [esi + 0x20]
add esp, 0xc
test eax, eax
je 0x40cc37
mov edx, dword [esp + 0x5a0]
lea ecx, [eax + 8]
add eax, 4
mov dword [esp + 0x38], ecx
mov dword [edx], ecx
mov dword [esp + 0x5a0], eax
mov dword [eax], 0
mov eax, dword [esp + 0x18]
test eax, eax
lea ebp, [esp + eax*4 + 0xcc]
mov dword [ebp], ecx
je 0x40ca9f
mov edx, dword [esp + 0x28]
mov esi, ecx
mov ecx, dword [esp + 0x44]
mov dword [esp + eax*4 + 0x8c], edx
mov eax, dword [esp + 0x10]
mov byte [esp + 0x20], bl
sub ecx, eax
mov byte [esp + 0x21], al
mov eax, dword [ebp - 4]
mov dword [esp + 0x24], esi
shr edx, cl
mov ecx, dword [esp + 0x20]
mov dword [eax + edx*8], ecx
mov dword [eax + edx*8 + 4], esi
mov edx, dword [esp + 0x3c]
mov eax, dword [esp + 0x14]
mov ebp, dword [esp + 0x10]
cmp eax, edx
mov eax, dword [esp + 0x44]
jg 0x40c9aa
mov ebx, dword [esp + 0x28]
mov cl, byte [esp + 0x14]
mov edx, dword [esp + 0x590]
sub cl, al
mov byte [esp + 0x21], cl
mov ecx, dword [esp + 0x1c]
lea edx, [esp + edx*4 + 0x108]
cmp ecx, edx
jb 0x40cae2
mov byte [esp + 0x20], 0xc0
jmp 0x40cb32
mov ecx, dword [ecx]
mov edx, dword [esp + 0x594]
cmp ecx, edx
jae 0x40cb03
cmp ecx, 0x100
sbb dl, dl
and dl, 0xa0
add dl, 0x60
mov byte [esp + 0x20], dl
jmp 0x40cb23
sub ecx, edx
mov edx, dword [esp + 0x59c]
shl ecx, 2
mov dl, byte [ecx + edx]
add dl, 0x50
mov byte [esp + 0x20], dl
mov edx, dword [esp + 0x598]
mov ecx, dword [ecx + edx]
mov dword [esp + 0x24], ecx
mov ecx, dword [esp + 0x1c]
add ecx, 4
mov dword [esp + 0x1c], ecx
mov ecx, dword [esp + 0x14]
mov esi, 1
sub ecx, eax
mov edx, ebx
shl esi, cl
mov ecx, eax
shr edx, cl
cmp edx, edi
jae 0x40cb74
mov ecx, dword [esp + 0x38]
lea ebx, [esi*8]
lea ecx, [ecx + edx*8]
mov ebp, dword [esp + 0x20]
add edx, esi
mov dword [ecx], ebp
mov ebp, dword [esp + 0x24]
mov dword [ecx + 4], ebp
add ecx, ebx
cmp edx, edi
jb 0x40cb57
mov ebp, dword [esp + 0x10]
mov ebx, dword [esp + 0x28]
mov ecx, dword [esp + 0x40]
mov edx, 1
shl edx, cl
test ebx, edx
je 0x40cb8b
xor ebx, edx
shr edx, 1
test ebx, edx
jne 0x40cb83
mov esi, 1
mov ecx, eax
xor ebx, edx
mov edx, dword [esp + 0x18]
shl esi, cl
mov ecx, dword [esp + edx*4 + 0x8c]
lea edx, [esp + edx*4 + 0x8c]
mov dword [esp + 0x28], ebx
dec esi
and esi, ebx
cmp esi, ecx
je 0x40cbd4
mov esi, dword [esp + 0x18]
sub eax, ebp
dec esi
mov ecx, eax
mov dword [esp + 0x18], esi
mov esi, 1
shl esi, cl
mov ecx, dword [edx - 4]
sub edx, 4
dec esi
and esi, ebx
cmp esi, ecx
jne 0x40cbb3
mov ecx, dword [esp + 0x30]
mov edx, ecx
dec ecx
test edx, edx
mov dword [esp + 0x30], ecx
jne 0x40c997
mov esi, dword [esp + 0x48]
mov edx, dword [esp + 0x34]
mov ecx, dword [esp + 0x14]
add edx, 4
inc ecx
mov dword [esp + 0x34], edx
mov edx, dword [esp + 0x40]
inc edx
mov dword [esp + 0x14], ecx
mov dword [esp + 0x40], edx
mov edx, dword [esp + 0x2c]
cmp ecx, edx
jle 0x40c982
test esi, esi
je 0x40c822
cmp dword [esp + 0x2c], 1
je 0x40c822
pop edi
pop esi
pop ebp
mov eax, 0xfffffffb
pop ebx
add esp, 0x578
ret
mov eax, dword [esp + 0x18]
test eax, eax
je 0x40cc50
mov eax, dword [esp + 0xcc]
push esi
push eax
call fcn.0040cee0
add esp, 8
pop edi
pop esi
pop ebp
mov eax, 0xfffffffc
pop ebx
add esp, 0x578
ret