Function at 0x507dc0
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x118
push ebx
push ebp
push esi
push edi
mov dword [esp + 0x18], ecx
push 0x18056
mov byte [esp + 0x14], 0x54
mov byte [esp + 0x15], 0x4d
mov byte [esp + 0x16], 9
mov byte [esp + 0x17], 7
mov byte [esp + 0x18], 0
call fcn.004d8630
mov ebp, eax
mov edi, 0x5a3088
or ecx, 0xffffffff
xor eax, eax
add esp, 4
lea edx, [esp + 0x24]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x24]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
xor ebx, ebx
lea ecx, [esp + ecx + 0x24]
mov dword [esp + 0x1c], ecx
mov edx, dword [esp + 0x1c]
push ebx
push str.zenzen_d.grd
push edx
call fcn.005308a0
add esp, 0xc
lea eax, [esp + 0x24]
push 0
push pe_nt_image_headers32
push 3
push 0
push 1
push 0x80000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x507f4e
lea ecx, [esp + 0x20]
push 0
push ecx
push 0x16
push ebp
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push esi
mov edi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test edi, edi
je 0x507f4e
lea edx, [esp + 0x10]
push edx
push ebp
call fcn.005360f0
add esp, 8
test eax, eax
jne 0x507f4e
push 0x890
call fcn.004d8630
mov esi, eax
add esp, 4
test esi, esi
je 0x507ec9
mov ecx, esi
call fcn.00499ff0
mov dword [esi], vtable.LayoutListText.0
jmp 0x507ecb
xor esi, esi
mov eax, dword [esp + 0x18]
push esi
mov ecx, dword [eax + 0x1bc]
call fcn.0049b020
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 4]
mov al, byte [ebp + 0x15]
mov ecx, dword [0x5b5f18]
test al, al
jne 0x507f11
mov eax, dword [ecx]
call dword [eax + 0x7c]
test eax, eax
jne 0x507efc
push 9
jmp 0x507efe
push 5
mov ecx, esi
call fcn.0046b4a0
mov dword [esi + 0x88c], 0
jmp 0x507f31
mov edx, dword [ecx]
call dword [edx + 0x7c]
test eax, eax
jne 0x507f1e
push 8
jmp 0x507f20
push 2
mov ecx, esi
call fcn.0046b4a0
mov dword [esi + 0x88c], 1
mov eax, dword [esi]
lea ecx, [ebp + 5]
push ecx
mov ecx, esi
call dword [eax + 0x3c]
push 0xf
mov ecx, esi
call fcn.0046b470
mov edx, dword [esi]
push 4
mov ecx, esi
call dword [edx + 0x10]
inc ebx
cmp ebx, 0x64
jl 0x507e34
xor ebx, ebx
mov eax, dword [esp + 0x1c]
push ebx
push str.zenzenu_d.grd
push eax
call fcn.005308a0
add esp, 0xc
lea ecx, [esp + 0x24]
push 0
push pe_nt_image_headers32
push 3
push 0
push 1
push 0x80000000
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x508074
lea edx, [esp + 0x20]
push 0
push edx
push 0x16
push ebp
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push esi
mov edi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test edi, edi
je 0x508074
lea eax, [esp + 0x10]
push eax
push ebp
call fcn.005360f0
add esp, 8
test eax, eax
jne 0x508074
push 0x890
call fcn.004d8630
mov esi, eax
add esp, 4
test esi, esi
je 0x507fef
mov ecx, esi
call fcn.00499ff0
mov dword [esi], vtable.LayoutListText.0
jmp 0x507ff1
xor esi, esi
mov ecx, dword [esp + 0x18]
push esi
mov ecx, dword [ecx + 0x1bc]
call fcn.0049b020
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 4]
mov al, byte [ebp + 0x15]
mov ecx, dword [0x5b5f18]
test al, al
jne 0x508037
mov eax, dword [ecx]
call dword [eax + 0x7c]
test eax, eax
jne 0x508022
push 9
jmp 0x508024
push 5
mov ecx, esi
call fcn.0046b4a0
mov dword [esi + 0x88c], 0
jmp 0x508057
mov edx, dword [ecx]
call dword [edx + 0x7c]
test eax, eax
jne 0x508044
push 8
jmp 0x508046
push 2
mov ecx, esi
call fcn.0046b4a0
mov dword [esi + 0x88c], 1
mov eax, dword [esi]
lea ecx, [ebp + 5]
push ecx
mov ecx, esi
call dword [eax + 0x3c]
push 0xf
mov ecx, esi
call fcn.0046b470
mov edx, dword [esi]
push 4
mov ecx, esi
call dword [edx + 0x10]
inc ebx
cmp ebx, 0x64
jl 0x507f5a
mov eax, dword [esp + 0x18]
push 0x5080b0
mov ecx, dword [eax + 0x1bc]
call fcn.0049b730
push ebp
call fcn.004d86d0
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x118
ret