Function at 0x1016970
Capabilities:
Check if file exists
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Get file attributes

Disassembly:
push 0x268
mov eax, 0x1039d35
call fcn.01037352
mov edi, dword [ebp + 8]
lea ecx, [ebp - 0x274]
mov dword [ebp - 0x264], edi
call fcn.01014810
and dword [ebp - 4], 0
test edi, edi
jne 0x10169dd
mov eax, dword [section..data]
cmp eax, section..data
je 0x10169bf
test byte [eax + 0x1c], 1
je 0x10169bf
push 0x1003758
push 0x2c
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.010078b5
mov esi, 0x80070057
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x274]
call fcn.01014822
mov eax, esi
call fcn.010373e4
ret 8
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x1016a1f
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0100968c
mov esi, eax
mov eax, dword [section..data]
cmp eax, section..data
je 0x10169c4
test byte [eax + 0x1c], 1
je 0x10169c4
push esi
push edi
push 0x1003758
push 0x2d
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01018c98
jmp 0x10169c4
test al, 0x10
jne 0x1016a47
mov ecx, 0x80070057
mov esi, ecx
mov eax, dword [section..data]
cmp eax, section..data
je 0x10169c4
test byte [eax + 0x1c], 1
je 0x10169c4
push ecx
push edi
push 0x1003758
push 0x2e
jmp 0x1016a12
test eax, 0x400
je 0x1016a85
mov esi, 0x80070057
mov eax, dword [section..data]
cmp eax, section..data
je 0x10169c4
test byte [eax + 0x1c], 1
je 0x10169c4
push edi
push 0x1003758
push 0x2f
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01008bcd
jmp 0x10169c4
cmp dword [ebp + 0xc], 0
mov edi, 0x1003758
mov ebx, section..data
je 0x1016ac9
push dword [ebp - 0x264]
call fcn.0101648c
test eax, eax
jge 0x1016ac9
mov ecx, dword [section..data]
cmp ecx, ebx
je 0x1016ac9
test byte [ecx + 0x1c], 2
je 0x1016ac9
push eax
push dword [ebp - 0x264]
push edi
push 0x30
push dword [ecx + 0x14]
push dword [ecx + 0x10]
call fcn.01018c98
push dword [ebp - 0x264]
lea eax, [ebp - 0x274]
push 0x1003788
push eax
call fcn.010157db
add esp, 0xc
test eax, eax
jge 0x1016b14
mov ecx, 0x80070057
mov esi, ecx
mov eax, dword [section..data]
cmp eax, ebx
je 0x10169c4
test byte [eax + 0x1c], 1
je 0x10169c4
push ecx
push dword [ebp - 0x264]
push edi
push 0x31
jmp 0x1016a12
lea eax, [ebp - 0x260]
push eax
lea ecx, [ebp - 0x274]
call fcn.01015d45
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebp - 0x268], eax
cmp eax, 0xffffffff
jne 0x1016b77
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0100968c
mov esi, eax
mov eax, dword [section..data]
cmp eax, ebx
je 0x10169c4
test byte [eax + 0x1c], 1
je 0x10169c4
push esi
lea ecx, [ebp - 0x274]
call fcn.01015d45
push eax
mov eax, dword [section..data]
push edi
push 0x32
jmp 0x1016a12
mov ecx, 0x1003784
lea eax, [ebp - 0x234]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x1016ba8
test dx, dx
je 0x1016ba4
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x1016ba8
add eax, 4
add ecx, 4
test dx, dx
jne 0x1016b82
xor eax, eax
jmp 0x1016bad
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x1016ce6
mov ecx, 0x100377c
lea eax, [ebp - 0x234]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x1016be6
test dx, dx
je 0x1016be2
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x1016be6
add eax, 4
add ecx, 4
test dx, dx
jne 0x1016bc0
xor eax, eax
jmp 0x1016beb
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x1016ce6
lea eax, [ebp - 0x234]
push eax
push dword [ebp - 0x264]
lea eax, [ebp - 0x274]
push 0x1003198
push eax
call fcn.010157db
mov esi, eax
add esp, 0x10
test esi, esi
jl 0x1016d5c
test byte [ebp - 0x260], 0x10
je 0x1016c81
push dword [ebp + 0xc]
lea ecx, [ebp - 0x274]
call fcn.01015d45
push eax
call fcn.01016970
mov esi, eax
test esi, esi
jge 0x1016ce6
mov eax, dword [section..data]
cmp eax, ebx
je 0x1016dbd
test byte [eax + 0x1c], 1
je 0x1016dbd
push esi
lea ecx, [ebp - 0x274]
call fcn.01015d45
push eax
push edi
push 0x34
mov eax, dword [section..data]
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01018c98
jmp 0x1016dbd
cmp dword [ebp + 0xc], 0
je 0x1016ccc
lea ecx, [ebp - 0x274]
call fcn.01015d45
push eax
call fcn.0101648c
test eax, eax
jge 0x1016ccc
mov ecx, dword [section..data]
cmp ecx, ebx
je 0x1016ccc
test byte [ecx + 0x1c], 2
je 0x1016ccc
push eax
lea ecx, [ebp - 0x274]
call fcn.01015d45
push eax
mov eax, dword [section..data]
push edi
push 0x35
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01018c98
lea ecx, [ebp - 0x274]
call fcn.01015d45
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x1016d89
lea eax, [ebp - 0x260]
push eax
push dword [ebp - 0x268]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x1016b77
push dword [ebp - 0x268]
call dword [sym.imp.KERNEL32.dll_FindClose]
push dword [ebp - 0x264]
or dword [ebp - 0x268], 0xffffffff
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
jne 0x1016dbb
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0100968c
mov esi, eax
mov eax, dword [section..data]
cmp eax, ebx
je 0x10169c4
test byte [eax + 0x1c], 1
je 0x10169c4
push esi
push dword [ebp - 0x264]
push edi
push 0x37
jmp 0x1016a12
mov eax, dword [section..data]
cmp eax, ebx
je 0x1016dbd
test byte [eax + 0x1c], 1
je 0x1016dbd
push esi
lea ecx, [ebp - 0x234]
push ecx
push dword [ebp - 0x264]
push edi
push 0x33
push dword [eax + 0x14]
push dword [eax + 0x10]
call fcn.01010617
jmp 0x1016dbd
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0100968c
mov esi, eax
mov eax, dword [section..data]
cmp eax, ebx
je 0x1016dbd
test byte [eax + 0x1c], 1
je 0x1016dbd
push esi
lea ecx, [ebp - 0x274]
call fcn.01015d45
push eax
push edi
push 0x36
jmp 0x1016c6c
xor esi, esi
cmp dword [ebp - 0x268], 0xffffffff
je 0x10169c4
push dword [ebp - 0x268]
call dword [sym.imp.KERNEL32.dll_FindClose]
jmp 0x10169c4