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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x51b515
mov eax, dword fs:[0]
push eax
sub esp, 0x308
mov eax, dword [0x54735c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x314], edx
push ecx
xor edi, edi
lea ecx, [ebp - 0x58]
mov dword [ebp - 0x2fc], edi
call fcn.004031b0
lea edx, [edi + 0x20]
mov dword [ebp - 4], edi
lea ecx, [ebp - 0x58]
call fcn.0040a200
cmp dword [ebp - 0x48], edi
je 0x404eb8
cmp dword [ebp - 0x44], 8
lea eax, [ebp - 0x58]
cmovae eax, dword [ebp - 0x58]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x404eb8
push 0x53623c
lea eax, [ebp - 0x58]
push eax
lea eax, [ebp - 0xa0]
push eax
call fcn.00408050
add esp, 0xc
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x2f0]
cmp dword [ebp - 0x8c], 8
lea eax, [ebp - 0xa0]
push ecx
cmovae eax, dword [ebp - 0xa0]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebp - 0x2f8], eax
cmp eax, 0xffffffff
jne 0x4049ea
mov byte [ebp - 0x2f1], 0
jmp 0x404e59
mov esi, eax
nop dword [eax]
lea eax, [ebp - 0x2c4]
push eax
push 0x536248
call fcn.004fb47c
add esp, 8
test eax, eax
je 0x404e35
lea eax, [ebp - 0x2c4]
push eax
push 0x53624c
call fcn.004fb47c
add esp, 8
test eax, eax
je 0x404e35
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x28]
xor eax, eax
mov dword [ebp - 0x18], 0
mov word [ebp - 0x28], ax
or edi, 1
mov eax, dword [ebp - 0x48]
inc eax
mov dword [ebp - 0x14], 7
push eax
mov dword [ebp - 0x310], edi
mov dword [ebp - 0x2fc], edi
call fcn.004087a0
cmp dword [ebp - 0x44], 8
lea ecx, [ebp - 0x58]
mov edx, dword [ebp - 0x18]
cmovae ecx, dword [ebp - 0x58]
mov eax, dword [ebp - 0x14]
mov edi, dword [ebp - 0x48]
sub eax, edx
mov dword [ebp - 0x300], edx
cmp edi, eax
ja 0x404aae
cmp dword [ebp - 0x14], 8
lea eax, [edx + edi]
mov dword [ebp - 0x18], eax
lea esi, [ebp - 0x28]
cmovae esi, dword [ebp - 0x28]
lea eax, [edi + edi]
push eax
push ecx
lea eax, [esi + edx*2]
push eax
call fcn.004f4a40
mov eax, dword [ebp - 0x300]
add esp, 0xc
add eax, edi
xor ecx, ecx
mov word [esi + eax*2], cx
jmp 0x404ac6
push edi
push ecx
mov byte [ebp - 0x304], 0
lea ecx, [ebp - 0x28]
push dword [ebp - 0x304]
push edi
call fcn.00408630
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x14]
cmp ecx, edx
jae 0x404ae9
lea eax, [ecx + 1]
cmp edx, 8
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
mov dword [eax + ecx*2], 0x5c
jmp 0x404b01
push 0x5c
mov byte [ebp - 0x308], 0
push dword [ebp - 0x308]
push ecx
lea ecx, [ebp - 0x28]
call fcn.004089e0
lea ecx, [ebp - 0x2c4]
lea edx, [ecx + 2]
nop word [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x404b10
mov eax, dword [ebp - 0x14]
sub ecx, edx
mov edx, dword [ebp - 0x18]
sub eax, edx
sar ecx, 1
cmp ecx, eax
ja 0x404b5e
cmp dword [ebp - 0x14], 8
lea eax, [ecx + ecx]
push eax
lea esi, [ebp - 0x28]
cmovae esi, dword [ebp - 0x28]
lea eax, [ebp - 0x2c4]
push eax
lea edi, [edx + ecx]
mov dword [ebp - 0x18], edi
lea eax, [esi + edx*2]
push eax
call fcn.004f4a40
add esp, 0xc
xor eax, eax
mov word [esi + edi*2], ax
lea eax, [ebp - 0x28]
jmp 0x404b7c
push ecx
lea eax, [ebp - 0x2c4]
mov byte [ebp - 0x30c], 0
push eax
push dword [ebp - 0x30c]
push ecx
lea ecx, [ebp - 0x28]
call fcn.00408630
mov edi, dword [ebp - 0x310]
xor ecx, ecx
mov dword [ebp - 0x30], 0
or edi, 2
mov dword [ebp - 0x2c], 0
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0x40], xmm0
movq xmm0, qword [eax + 0x10]
movq qword [ebp - 0x30], xmm0
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 7
mov word [eax], cx
and edi, 0xfffffffe
mov byte [ebp - 4], 4
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x404bf8
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x404bee
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x404f16
push edx
push ecx
call fcn.004f2ead
add esp, 8
xor eax, eax
mov dword [ebp - 0x18], 0
cmp dword [ebp - 0x2c], 8
mov word [ebp - 0x28], ax
lea eax, [ebp - 0x40]
cmovae eax, dword [ebp - 0x40]
push eax
mov dword [ebp - 0x14], 7
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
test al, 1
je 0x404c38
and eax, 0xfffffffe
lea ecx, [ebp - 0x40]
cmp dword [ebp - 0x2c], 8
push eax
cmovae ecx, dword [ebp - 0x40]
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test byte [ebp - 0x2f0], 0x10
mov dword [ebp - 0x60], 0
mov dword [ebp - 0x5c], 7
je 0x404d6d
xor eax, eax
lea ecx, [ebp - 0x70]
push eax
push 0x536234
mov word [ebp - 0x70], ax
call fcn.00403ab0
mov byte [ebp - 4], 5
lea edx, [ebp - 0x40]
cmp dword [ebp - 0x2c], 8
mov dword [ebp - 0x78], 0
cmovae edx, dword [ebp - 0x40]
xor eax, eax
mov ecx, edx
mov dword [ebp - 0x74], 7
mov word [ebp - 0x88], ax
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x404c92
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x88]
call fcn.00403ab0
lea edx, [ebp - 0x70]
mov byte [ebp - 4], 6
lea ecx, [ebp - 0x88]
call fcn.00404920
mov byte [ebp - 4], 5
mov edx, dword [ebp - 0x74]
cmp edx, 8
jb 0x404d01
mov ecx, dword [ebp - 0x88]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x404cf7
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x404f16
push edx
push ecx
call fcn.004f2ead
add esp, 8
xor eax, eax
mov byte [ebp - 4], 4
mov edx, dword [ebp - 0x5c]
mov dword [ebp - 0x78], 0
mov dword [ebp - 0x74], 7
mov word [ebp - 0x88], ax
cmp edx, 8
jb 0x404d56
mov ecx, dword [ebp - 0x70]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x404d4c
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x404f16
push edx
push ecx
call fcn.004f2ead
add esp, 8
cmp dword [ebp - 0x2c], 8
lea eax, [ebp - 0x40]
cmovae eax, dword [ebp - 0x40]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
jmp 0x404df1
cmp dword [ebp - 0x2c], 8
lea edx, [ebp - 0x40]
cmovae edx, dword [ebp - 0x40]
xor eax, eax
mov ecx, edx
mov word [ebp - 0x70], ax
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x404d83
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x70]
call fcn.00403ab0
push dword [ebp - 0x314]
mov dl, 1
mov byte [ebp - 4], 7
lea ecx, [ebp - 0x70]
call fcn.00404f30
mov byte [ebp - 4], 4
add esp, 4
mov edx, dword [ebp - 0x5c]
cmp edx, 8
jb 0x404df1
mov ecx, dword [ebp - 0x70]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x404de7
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x404f16
push edx
push ecx
call fcn.004f2ead
add esp, 8
mov byte [ebp - 4], 1
mov edx, dword [ebp - 0x2c]
cmp edx, 8
jb 0x404e2f
mov ecx, dword [ebp - 0x40]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x404e25
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x404f16
push edx
push ecx
call fcn.004f2ead
add esp, 8
mov esi, dword [ebp - 0x2f8]
lea eax, [ebp - 0x2f0]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x4049f0
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov byte [ebp - 0x2f1], 1
mov edx, dword [ebp - 0x8c]
cmp edx, 8
jb 0x404e99
mov ecx, dword [ebp - 0xa0]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x404e8f
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x404f16
push edx
push ecx
call fcn.004f2ead
add esp, 8
xor eax, eax
mov dword [ebp - 0x90], 0
mov dword [ebp - 0x8c], 7
mov word [ebp - 0xa0], ax
jmp 0x404ebf
mov byte [ebp - 0x2f1], 0
mov edx, dword [ebp - 0x44]
cmp edx, 8
jb 0x404ef5
mov ecx, dword [ebp - 0x58]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x404eeb
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x404f1b
push edx
push ecx
call fcn.004f2ead
add esp, 8
mov al, byte [ebp - 0x2f1]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004f313b
mov esp, ebp
pop ebp
ret
call fcn.004f855c
call fcn.004f855c
int3