Function at 0x50bf00
Capabilities:
Check if file exists
Get disk information
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14c
mov eax, dword [0x5ed284]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
mov edi, dword [ebp + 8]
xor esi, esi
mov dword [ebp - 0x134], 0
mov dword [ebp - 0x144], esi
test edi, edi
je 0x50c16f
cmp byte [edi], 0
je 0x50c16f
test byte [ebp + 0xc], 7
je 0x50c16f
lea eax, [ebp - 0x108]
push eax
push edi
call sym.FLAMESLauncher.exe_FOSUtilityGetFullPath
add esp, 8
cmp byte [ebp - 0x107], 0x3a
jne 0x50bf77
movzx eax, byte [ebp - 0x105]
xor ecx, ecx
cmp byte [ebp - 0x106], 0x5c
cmove eax, ecx
mov byte [ebp - 0x105], al
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
test eax, eax
je 0x50bf8d
cmp eax, 4
jne 0x50bfd6
push 0
push 0
lea eax, [ebp - 0x130]
mov dword [ebp - 0x130], esi
push eax
lea eax, [ebp - 0x148]
push eax
push 0
push 0
push 0
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationA]
test byte [ebp - 0x130], 4
jne 0x50bfd6
pop edi
mov eax, 1
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0052bfb9
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x134]
push eax
push 0
push 0
push 7
push edi
call dword [sym.imp.ADVAPI32.dll_GetFileSecurityA]
test eax, eax
jne 0x50bffd
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x50c15d
push ebx
push dword [ebp - 0x134]
mov dword [ebp - 0x138], esi
push 1
mov dword [ebp - 0x140], esi
mov dword [ebp - 0x13c], esi
mov dword [ebp - 0x148], 0x14
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_calloc]
add esp, 8
mov ebx, eax
lea eax, [ebp - 0x134]
push eax
push dword [ebp - 0x134]
push ebx
push 7
push edi
call dword [sym.imp.ADVAPI32.dll_GetFileSecurityA]
test eax, eax
je 0x50c0fe
push 2
call dword [sym.imp.ADVAPI32.dll_ImpersonateSelf]
test eax, eax
je 0x50c0fe
lea eax, [ebp - 0x130]
mov dword [ebp - 0x138], 1
push eax
push 0
push 8
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenThreadToken]
test eax, eax
je 0x50c0fe
mov eax, dword [ebp + 0xc]
and al, 1
movzx ecx, al
mov eax, dword [ebp + 0xc]
neg ecx
sbb ecx, ecx
and ecx, 0x120089
mov edx, ecx
or edx, 0x1200a0
and al, 4
lea eax, [ebp - 0x140]
push eax
lea eax, [ebp - 0x14c]
cmove edx, ecx
mov ecx, dword [ebp + 0xc]
push eax
lea eax, [ebp - 0x148]
and ecx, 2
push eax
lea eax, [ebp - 0x12c]
mov dword [ebp + 0xc], ecx
push eax
lea eax, [ebp - 0x118]
push eax
mov eax, edx
or eax, 0x120116
test ecx, ecx
cmove eax, edx
push eax
push dword [ebp - 0x130]
push ebx
call dword [sym.imp.ADVAPI32.dll_AccessCheck]
mov dword [ebp - 0x13c], eax
xor eax, eax
cmp dword [ebp + 0xc], eax
setne al
mov dword [ebp - 0x144], eax
test ebx, ebx
je 0x50c10c
push ebx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov eax, dword [ebp - 0x130]
pop ebx
test eax, eax
je 0x50c11e
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x138], esi
je 0x50c12c
call dword [sym.imp.ADVAPI32.dll_RevertToSelf]
cmp dword [ebp - 0x13c], esi
je 0x50c142
cmp dword [ebp - 0x140], esi
mov eax, 1
cmovne esi, eax
cmp dword [ebp - 0x144], 0
je 0x50c15d
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x50c15b
test al, 1
je 0x50c15d
xor esi, esi
pop edi
mov eax, esi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0052bfb9
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
xor ecx, ebp
pop esi
call fcn.0052bfb9
mov esp, ebp
pop ebp
ret