Function at 0x4cfc54
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x98
mov eax, dword [ebp + 8]
cmp dword [eax + 0x4f40], 0
je 0x4cfdd5
mov ecx, dword [ebp + 0x14]
shr ecx, 9
mov dword [ebp - 0x28], ecx
push 0x1f
push 0
lea edx, [ebp - 0x24]
push edx
call fcn.0054bf90
add esp, 0xc
push 0xd
push 0
lea eax, [ebp - 0x38]
push eax
call fcn.0054bf90
add esp, 0xc
mov byte [ebp - 0x24], 0x55
mov byte [ebp - 0x23], 0x53
mov byte [ebp - 0x22], 0x42
mov byte [ebp - 0x21], 0x43
mov ecx, dword [ebp + 0x14]
and ecx, 0xff
mov byte [ebp - 0x1c], cl
mov edx, dword [ebp + 0x14]
shr edx, 8
and edx, 0xff
mov byte [ebp - 0x1b], dl
mov eax, dword [ebp + 0x14]
shr eax, 0x10
and eax, 0xff
mov byte [ebp - 0x1a], al
mov ecx, dword [ebp + 0x14]
shr ecx, 0x18
and ecx, 0xff
mov byte [ebp - 0x19], cl
mov dl, byte [ebp + 0x1c]
mov byte [ebp - 0x17], dl
mov byte [ebp - 0x16], 0xa
mov al, byte [ebp + 0x18]
mov byte [ebp - 0x15], al
mov ecx, dword [ebp + 0xc]
shr ecx, 0x18
mov byte [ebp - 0x13], cl
mov edx, dword [ebp + 0xc]
shr edx, 0x10
mov byte [ebp - 0x12], dl
mov eax, dword [ebp + 0xc]
shr eax, 8
mov byte [ebp - 0x11], al
mov ecx, dword [ebp + 0xc]
and ecx, 0xff
mov byte [ebp - 0x10], cl
mov edx, dword [ebp - 0x28]
shr edx, 8
mov byte [ebp - 0xe], dl
mov eax, dword [ebp - 0x28]
and eax, 0xff
mov byte [ebp - 0xd], al
mov byte [ebp - 0x1e], 0
mov byte [ebp - 0x1d], 5
push 0
lea ecx, [ebp - 4]
push ecx
push 0x1f
lea edx, [ebp - 0x24]
push edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x4fb0]
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x3c], eax
cmp dword [ebp - 0x3c], 0
jne 0x4cfd5d
xor eax, eax
jmp 0x4cff20
push 0
lea edx, [ebp - 4]
push edx
mov eax, dword [ebp + 0x14]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x4fb0]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x3c], eax
cmp dword [ebp - 0x3c], 0
jne 0x4cfd8b
xor eax, eax
jmp 0x4cff20
push 0
lea ecx, [ebp - 4]
push ecx
push 0xd
lea edx, [ebp - 0x38]
push edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x4fac]
push ecx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov dword [ebp - 0x3c], eax
cmp dword [ebp - 0x3c], 0
jne 0x4cfdb7
xor eax, eax
jmp 0x4cff20
mov edx, dword [ebp - 0x2c]
and edx, 0xff
test edx, edx
je 0x4cfdcb
xor eax, eax
jmp 0x4cff20
mov eax, 1
jmp 0x4cff20
push 0x50
push 0
lea eax, [ebp - 0x8c]
push eax
call fcn.0054bf90
add esp, 0xc
mov word [ebp - 0x8c], 0x2c
mov byte [ebp - 0x89], 0
mov byte [ebp - 0x88], 1
mov cl, byte [ebp + 0x1c]
mov byte [ebp - 0x87], cl
mov byte [ebp - 0x86], 0x10
mov byte [ebp - 0x85], 0
mov byte [ebp - 0x84], 0
mov edx, dword [ebp + 0x14]
mov dword [ebp - 0x80], edx
mov dword [ebp - 0x7c], 0x12c
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x78], eax
mov dword [ebp - 0x74], 0x30
mov cl, byte [ebp + 0x18]
mov byte [ebp - 0x70], cl
mov edx, dword [ebp + 0xc]
shr edx, 0x10
and edx, 0xffff
shr edx, 8
mov byte [ebp - 0x6e], dl
mov eax, dword [ebp + 0xc]
shr eax, 0x10
and eax, 0xffff
and eax, 0xff
mov byte [ebp - 0x6d], al
mov ecx, dword [ebp + 0xc]
and ecx, 0xffff
and ecx, 0xffff
shr ecx, 8
mov byte [ebp - 0x6c], cl
mov edx, dword [ebp + 0xc]
and edx, 0xffff
and edx, 0xffff
and edx, 0xff
mov byte [ebp - 0x6b], dl
mov eax, dword [ebp + 0x14]
shr eax, 9
shr eax, 8
mov byte [ebp - 0x69], al
mov ecx, dword [ebp + 0x14]
shr ecx, 9
and ecx, 0xff
mov byte [ebp - 0x68], cl
mov dword [ebp - 0x94], 0x50
mov dword [ebp - 0x90], 0
mov edx, dword [ebp + 8]
cmp dword [edx + 0x4fbc], 0xffffffff
je 0x4cff1a
push 0
lea eax, [ebp - 0x90]
push eax
mov ecx, dword [ebp - 0x94]
push ecx
lea edx, [ebp - 0x8c]
push edx
mov eax, dword [ebp - 0x94]
push eax
lea ecx, [ebp - 0x8c]
push ecx
push 0x4d014
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x4fbc]
push eax
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
mov dword [ebp - 0x98], eax
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x4fbc]
push edx
call dword [sym.imp.KERNEL32.dll_FlushFileBuffers]
mov eax, dword [ebp - 0x98]
mov esp, ebp
pop ebp
ret