Function at 0x300afe5f
Capabilities:
Check if file exists
Delete file
Enumerate files on windows
Get file attributes
Read file on windows
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
push ebx
and eax, 0xff00
mov ecx, 0x4000
push esi
xor ebx, ebx
cmp eax, ecx
push edi
jg 0x300affbb
je 0x300affa2
cmp eax, 0x3000
je 0x300aff94
cmp eax, 0x3b00
je 0x300aff80
cmp eax, 0x3c00
je 0x300aff4f
cmp eax, 0x3d00
je 0x300afeee
cmp eax, 0x3e00
je 0x300afee0
cmp eax, 0x3f00
jne 0x300b00de
push ebx
lea eax, [ebp + 0x10]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0x14]
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x300b00de
mov eax, dword [ebp + 0x10]
jmp 0x300b0130
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x300b00d4
movzx eax, byte [ebp + 8]
sub eax, 0xa2
je 0x300aff09
push 3
pop ebx
sub eax, 0x1e
mov edi, 0x80000000
mov dword [ebp + 0xc], ebx
jmp 0x300aff18
xor ebx, ebx
mov edi, 0xc0000000
inc ebx
mov dword [ebp + 0xc], 3
mov eax, 0x200
call fcn.3002ea85
mov esi, esp
xor eax, eax
push eax
push esi
push 0x100
push eax
push dword [ebp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_SearchPathW]
test eax, eax
mov dword [ebp + 0x10], eax
je 0x300b00de
cmp eax, 0xff
jbe 0x300aff61
jmp 0x300b00de
mov esi, dword [ebp + 0x14]
xor ebx, ebx
mov edi, 0xc0000000
inc ebx
mov dword [ebp + 0xc], 2
xor eax, eax
push eax
push eax
push dword [ebp + 0xc]
push eax
push ebx
push edi
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
je 0x300b00de
jmp 0x300b0130
push dword [ebp + 0x14]
call fcn.300b076f
mov ebx, eax
neg ebx
sbb ebx, ebx
inc ebx
jmp 0x300b00d6
call dword [sym.imp.KERNEL32.dll_GetVersion]
movzx eax, ax
jmp 0x300b0130
push ebx
lea eax, [ebp + 0x10]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0x14]
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
jmp 0x300afed0
cmp eax, 0x4100
je 0x300b00cb
cmp eax, 0x4200
je 0x300b00ac
cmp eax, 0x4300
je 0x300b0061
cmp eax, 0x4400
je 0x300b0051
cmp eax, 0x4e00
mov edi, dword [sym.imp.KERNEL32.dll_FindClose]
mov esi, 0x301e6680
je 0x300b0001
cmp eax, 0x4f00
je 0x300b002c
jmp 0x300b00de
mov eax, dword [0x301e6630]
test eax, eax
je 0x300b000d
push eax
call edi
push esi
push dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp eax, 0xffffffff
mov dword [0x301e6630], eax
je 0x300b0058
test word [0x301e6680], 0x116
je 0x300b0051
push esi
push dword [0x301e6630]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x300b0021
push dword [0x301e6630]
call edi
and dword [0x301e6630], 0
jmp 0x300b00d6
xor eax, eax
jmp 0x300b0130
and dword [0x301e6630], 0
jmp 0x300b00de
test byte [ebp + 8], 1
je 0x300b0078
push dword [ebp + 0x10]
push dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
jmp 0x300b0130
push dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x300b00a2
test al, 1
je 0x300b008d
xor ebx, ebx
inc ebx
test al, 0x10
je 0x300b0094
or ebx, 0x10
test al, 0x20
je 0x300b009b
or ebx, 0x20
mov eax, ebx
jmp 0x300b0130
mov eax, 0x80000000
jmp 0x300b0130
mov eax, dword [ebp + 0x10]
push ebx
shl eax, 0x10
or eax, dword [ebp + 0x14]
push ebx
push eax
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
xor ebx, ebx
cmp eax, 0xffffffff
setne bl
jmp 0x300b00d6
push dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov ebx, eax
test ebx, ebx
jne 0x300b0051
call dword [sym.imp.KERNEL32.dll_GetLastError]
dec eax
dec eax
je 0x300b012b
dec eax
dec eax
je 0x300b0124
dec eax
je 0x300b011d
sub eax, 3
je 0x300b0116
sub eax, 0x18
je 0x300b010f
sub eax, 0x21
je 0x300b011d
sub eax, 0x60
je 0x300b0108
or eax, 0xffffffff
jmp 0x300b0130
mov eax, 0x80000003
jmp 0x300b0130
mov eax, 0x80000020
jmp 0x300b0130
mov eax, 0x80000008
jmp 0x300b0130
mov eax, 0x80000005
jmp 0x300b0130
mov eax, 0x80000004
jmp 0x300b0130
mov eax, 0x80000002
lea esp, [ebp - 0xc]
pop edi
pop esi
pop ebx
pop ebp
ret 0x10