Function at 0x100172c0
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Get file attributes
Set file attributes

Disassembly:
sub esp, 0x258
mov eax, dword [0x10023050]
xor eax, esp
mov dword [esp + 0x254], eax
push ebx
push ebp
mov ebp, dword [esp + 0x264]
push esi
push edi
push 0x103
lea eax, [esp + 0x15d]
push 0
push eax
mov byte [esp + 0x164], 0
call sub.MSVCR90.dll_memset
add esp, 0xc
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
test al, 0x10
jne 0x10017327
push 0x80
push ebp
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push ebp
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
neg eax
sbb eax, eax
neg eax
jmp 0x10017522
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
push ebp
call edi
test eax, eax
je 0x10017346
push ebp
call edi
cmp eax, 0xff
jbe 0x1001734d
push 0x6f
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x10017522
push 0x103
lea ecx, [esp + 0x15c]
push ebp
push ecx
call dword [sym.imp.MSVCR90.dll_strncpy]
add esp, 0xc
lea edx, [esp + 0x158]
push 0x5c
push edx
call dword [sym.imp.MSVCR90.dll_strrchr]
mov esi, eax
add esp, 8
lea eax, [esp + 0x158]
push eax
call edi
lea ecx, [esp + eax + 0x158]
cmp esi, ecx
je 0x100173a8
lea edi, [esp + 0x158]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x10017396
mov dx, word [0x1001caf0]
mov word [edi], dx
lea edi, [esp + 0x158]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x100173b0
mov eax, dword [0x1001f3f8]
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x15c]
push edx
mov dword [edi], eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov edi, eax
mov dword [esp + 0x10], edi
cmp edi, 0xffffffff
je 0x10017346
mov ebx, dword [esp + 0x274]
jmp 0x100173f0
push 0x103
lea eax, [esp + 0x15c]
push ebp
push eax
call dword [sym.imp.MSVCR90.dll_strncpy]
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenA]
add esp, 0xc
lea ecx, [esp + 0x44]
push ecx
call esi
lea edx, [esp + 0x158]
push edx
mov dword [esp + 0x18], eax
call esi
mov ecx, dword [esp + 0x14]
add ecx, eax
cmp ecx, 0x103
ja 0x1001747d
lea edi, [esp + 0x158]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x10017438
mov ax, word [0x1001caf0]
mov word [edi], ax
lea eax, [esp + 0x44]
mov edx, eax
nop
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x10017450
lea edi, [esp + 0x158]
sub eax, edx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x10017461
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [esp + 0x10]
test byte [esp + 0x18], 0x10
je 0x100174b2
cmp byte [esp + 0x44], 0x2e
je 0x100174d7
mov eax, dword [esp + 0x270]
test eax, eax
je 0x100174d7
push ebx
push eax
lea ecx, [esp + 0x160]
push ecx
call fcn.100172c0
add esp, 0xc
test eax, eax
je 0x10017346
jmp 0x100174d7
push 0x80
lea edx, [esp + 0x15c]
push edx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
test ebx, ebx
jne 0x100174d7
lea eax, [esp + 0x158]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea ecx, [esp + 0x18]
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x100173f0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push edi
cmp eax, 0x12
je 0x10017501
call dword [sym.imp.KERNEL32.dll_FindClose]
xor eax, eax
jmp 0x10017522
call dword [sym.imp.KERNEL32.dll_FindClose]
test eax, eax
je 0x10017346
push 0x80
push ebp
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push ebp
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
mov ecx, dword [esp + 0x264]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.100192c6
add esp, 0x258
ret