Function at 0x564a20
Capabilities:
Encode data using xor
Parse pe header

Disassembly:
sub esp, 0x9c
mov eax, dword [0x5eeff0]
push ebx
push ebp
push esi
xor esi, esi
push edi
cmp eax, esi
mov dword [esp + 0x10], esi
jne 0x564a8b
push 0x380
mov dword [0x5eeff0], 1
call fcn.005358b0
mov edi, eax
mov ecx, 0xe0
xor eax, eax
mov dword [0x61c25c], edi
rep stosd dword es:[edi], eax
push 0x460
call fcn.005358b0
mov edi, eax
mov ecx, 0x118
xor eax, eax
mov dword [0x61c394], edi
rep stosd dword es:[edi], eax
push 0x8000
call fcn.005358b0
add esp, 0xc
mov dword [0x5eeff8], eax
call fcn.005643b0
mov ebp, eax
cmp ebp, 0xffffffff
je 0x564d63
mov ebx, dword [esp + 0xb4]
test ebx, 0x80000000
je 0x564abf
and ebx, 0x7fffffff
mov dword [esp + 0x10], 1
mov dword [esp + 0xb4], ebx
mov eax, dword [esp + 0xb0]
push ebx
push eax
call fcn.00535320
mov edi, eax
add esp, 8
cmp edi, 0xffffffff
jne 0x564ae4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x9c
ret
lea ecx, [esp + 0x2c]
push 0x40
push ecx
push edi
xor esi, esi
call fcn.00535370
add esp, 0xc
cmp eax, 0x40
jne 0x564b45
cmp byte [esp + 0x2c], 0x4d
jne 0x564b45
cmp byte [esp + 0x2d], 0x5a
jne 0x564b45
mov edx, dword [esp + 0x68]
push esi
push edx
push edi
call fcn.005354c0
lea eax, [esp + 0x38]
push 2
push eax
push edi
call fcn.00535370
add esp, 0x18
cmp eax, 2
jne 0x564b45
cmp byte [esp + 0x2c], 0x50
jne 0x564b45
cmp byte [esp + 0x2d], 0x45
jne 0x564b45
test ebx, ebx
mov esi, 1
jne 0x564ce6
push esi
push edi
call fcn.00564230
mov esi, eax
add esp, 8
cmp esi, 0xffffffff
je 0x564ce6
mov ecx, dword [0x61c390]
push 0
add ecx, esi
push ecx
push edi
call fcn.005354c0
mov edx, dword [0x61c390]
add esp, 0xc
add edx, esi
cmp eax, edx
jne 0x564ce6
lea eax, [esp + 0x14]
push 0x16
push eax
push edi
call fcn.00535370
add esp, 0xc
cmp eax, 0x16
jne 0x564ce6
mov eax, dword [esp + 0x14]
xor ebx, ebx
cmp eax, 0x605444f
mov eax, dword [esp + 0x18]
jne 0x564bec
test ax, ax
je 0x564bec
mov edx, dword [0x61c25c]
lea ecx, [ebp*8]
sub ecx, ebp
lea eax, [edx + ecx*8 + 8]
mov ecx, dword [edx + ecx*8 + 8]
or ecx, 1
mov dword [eax], ecx
mov ecx, 4
mov al, cl
mov dl, 3
imul dl
mov bl, byte [esp + ecx + 0x14]
sub al, 0x5b
xor bl, al
mov byte [esp + ecx + 0x14], bl
inc ecx
cmp ecx, 0x16
jb 0x564bce
mov ebx, dword [esp + 0x18]
jmp 0x564c11
mov cx, word [esp + 0x1e]
cmp cx, word [esp + 0x1c]
jne 0x564ce6
cmp word [esp + 0x1a], 0
jne 0x564ce6
test ax, ax
jne 0x564ce6
mov eax, dword [esp + 0x10]
test eax, eax
je 0x564c32
mov eax, dword [0x61c25c]
lea edx, [ebp*8]
sub edx, ebp
test byte [eax + edx*8 + 8], 1
je 0x564ce6
lea esi, [ebp*8]
sub esi, ebp
shl esi, 3
call fcn.00566a50
mov ecx, dword [0x61c25c]
push ebx
mov dword [esi + ecx], eax
mov edx, dword [0x61c25c]
mov dword [esi + edx + 4], edi
mov eax, dword [0x61c25c]
mov byte [esi + eax + 0x20], 0
mov ecx, dword [esp + 0x28]
mov edx, dword [0x61c390]
mov eax, dword [0x61c25c]
add edx, ecx
mov dword [esi + eax + 0xc], edx
mov ecx, dword [0x61c25c]
mov edx, dword [esp + 0x24]
mov dword [esi + ecx + 0x10], edx
mov eax, dword [0x61c25c]
mov ecx, dword [esi + eax + 0xc]
mov dword [esi + eax + 0x18], ecx
mov edx, dword [0x61c25c]
mov eax, dword [esp + 0x20]
mov dword [esi + edx + 0x1c], eax
mov ecx, dword [0x61c25c]
mov eax, dword [esp + 0x24]
mov edx, dword [esi + ecx]
mov ecx, dword [esp + 0x28]
push edx
mov edx, dword [0x61c390]
add edx, ecx
push eax
push edx
push edi
call fcn.00564420
add esp, 0x14
test eax, eax
jne 0x564cfc
mov eax, dword [0x61c25c]
mov ecx, dword [esi + eax]
push ecx
call fcn.00566ae0
mov edx, dword [0x61c25c]
add esp, 4
mov dword [esi + edx], 0
push edi
call fcn.005353d0
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x9c
ret
mov ecx, dword [esp + 0xb4]
cmp ecx, 1
je 0x564d2b
cmp ecx, 2
je 0x564d2b
mov ecx, dword [0x61c25c]
cmp eax, 0xffffffff
mov dword [esi + ecx + 0x14], 0
je 0x564d47
push eax
call fcn.00535980
add esp, 4
jmp 0x564d47
mov edx, dword [0x61c25c]
cmp eax, 0xffffffff
mov dword [esi + edx + 0x14], eax
jne 0x564d47
mov eax, dword [0x61c25c]
mov dword [esi + eax + 0x14], 0xffffffff
mov ecx, dword [0x61c25c]
push 0
mov edx, dword [esi + ecx]
push edx
call fcn.00566670
add esp, 8
or ebp, 0x4f440000
mov esi, ebp
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x9c
ret