Function at 0x42e120
Capabilities:
Delete directory
Delete file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x48d180
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push ebx
push esi
push edi
mov eax, dword [0x4c0074]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
call fcn.0041e1d0
mov al, byte [eax + 0x1c]
test al, al
je 0x42e21d
call fcn.0041e1d0
test byte [eax + 0x20], 4
je 0x42e21d
call fcn.0041e1d0
mov edi, eax
call fcn.00403f70
mov ecx, eax
test ecx, ecx
je 0x42e5a2
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x14], eax
mov dword [ebp - 4], 2
call fcn.00403f70
mov ecx, eax
test ecx, ecx
je 0x42e5ac
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x10], eax
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x14]
push str.DoErase_started.
call fcn.00408330
push 0
push 0x4a4fb8
lea ecx, [ebp - 0x10]
call fcn.00402280
push ecx
lea eax, [ebp - 0x14]
push eax
push ecx
lea eax, [ebp - 0x10]
mov ecx, edi
push eax
call fcn.0041e320
mov byte [ebp - 4], 2
or eax, 0xffffffff
mov edx, dword [ebp - 0x10]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x42e1fb
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
or eax, 0xffffffff
mov edx, dword [ebp - 0x14]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x42e21d
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
xor edi, edi
cmp dword [esi + 0x1c], edi
jle 0x42e3d4
mov ecx, dword [esi + 0x24]
test ecx, ecx
je 0x42e251
mov eax, dword [ecx]
mov edx, dword [eax + 0x28]
test edi, edi
js 0x42e596
cmp edi, dword [esi + 0x1c]
jge 0x42e596
mov eax, dword [esi + 0x18]
push 0
push 9
push dword [eax + edi*4]
call edx
test edi, edi
js 0x42e596
cmp edi, dword [esi + 0x1c]
jge 0x42e596
mov eax, dword [esi + 0x18]
lea ebx, [edi*4]
push dword [eax + ebx]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x42e3a6
call fcn.0041e1d0
mov al, byte [eax + 0x1c]
test al, al
je 0x42e3a6
call fcn.0041e1d0
test byte [eax + 0x20], 1
je 0x42e3a6
call fcn.0041e1d0
mov dword [ebp - 0x18], eax
call fcn.00403f70
test eax, eax
je 0x42e5a2
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [ebp - 0x10], eax
mov dword [ebp - 4], 0xc
lea ecx, [ebp - 0x10]
push 0x17
push str.Failed_to_delete_file:
call fcn.00402280
cmp edi, dword [esi + 0x1c]
jge 0x42e596
mov eax, dword [esi + 0x18]
mov edx, dword [eax + ebx]
test edx, edx
je 0x42e309
mov ecx, edx
lea ebx, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x42e2f0
sub ecx, ebx
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x10]
call fcn.00402280
push 0xc
push str._LastError:
lea ecx, [ebp - 0x10]
call fcn.00402280
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
call fcn.00403f70
test eax, eax
je 0x42e5a2
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [ebp - 0x14], eax
mov byte [ebp - 4], 0xf
lea ecx, [ebp - 0x14]
push 0
push 0x4a4fb8
call fcn.00402280
push ecx
push ebx
lea ecx, [ebp - 0x10]
call fcn.0041df70
push eax
push ecx
mov ecx, dword [ebp - 0x18]
lea eax, [ebp - 0x14]
push eax
call fcn.0041e320
mov byte [ebp - 4], 0xc
or eax, 0xffffffff
mov edx, dword [ebp - 0x14]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x42e384
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
or eax, 0xffffffff
mov edx, dword [ebp - 0x10]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x42e3a6
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [esi + 0x24]
test ecx, ecx
je 0x42e3ca
mov eax, dword [ecx]
push 1
call dword [eax + 0x18]
mov ecx, dword [esi + 0x24]
test ecx, ecx
je 0x42e3ca
mov eax, dword [ecx]
mov eax, dword [eax + 0x1c]
call eax
test al, al
jne 0x42e582
inc edi
cmp edi, dword [esi + 0x1c]
jl 0x42e228
xor edi, edi
cmp dword [esi + 0x10], edi
jle 0x42e582
nop
mov ecx, dword [esi + 0x24]
test ecx, ecx
je 0x42e409
mov eax, dword [ecx]
mov edx, dword [eax + 0x28]
test edi, edi
js 0x42e596
cmp edi, dword [esi + 0x10]
jge 0x42e596
mov eax, dword [esi + 0xc]
push 0
push 9
push dword [eax + edi*4]
call edx
test edi, edi
js 0x42e596
cmp edi, dword [esi + 0x10]
jge 0x42e596
mov eax, dword [esi + 0xc]
lea ebx, [edi*4]
push dword [eax + ebx]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
jne 0x42e558
call fcn.0041e1d0
mov al, byte [eax + 0x1c]
test al, al
je 0x42e558
call fcn.0041e1d0
test byte [eax + 0x20], 1
je 0x42e558
call fcn.0041e1d0
mov dword [ebp - 0x18], eax
call fcn.00403f70
test eax, eax
je 0x42e5a2
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [ebp - 0x10], eax
mov dword [ebp - 4], 0x16
lea ecx, [ebp - 0x10]
push str.Failed_to_delete_folder:
call fcn.00408330
cmp edi, dword [esi + 0x10]
jge 0x42e596
mov eax, dword [esi + 0xc]
mov edx, dword [eax + ebx]
test edx, edx
je 0x42e4bb
mov ecx, edx
lea ebx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x42e4a2
sub ecx, ebx
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x10]
call fcn.00402280
push 0xc
push str._LastError:
lea ecx, [ebp - 0x10]
call fcn.00402280
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
call fcn.00403f70
test eax, eax
je 0x42e5a2
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [ebp - 0x14], eax
mov byte [ebp - 4], 0x19
lea ecx, [ebp - 0x14]
push 0
push 0x4a4fb8
call fcn.00402280
push ecx
push ebx
lea ecx, [ebp - 0x10]
call fcn.0041df70
push eax
push ecx
mov ecx, dword [ebp - 0x18]
lea eax, [ebp - 0x14]
push eax
call fcn.0041e320
mov byte [ebp - 4], 0x16
or eax, 0xffffffff
mov edx, dword [ebp - 0x14]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x42e536
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
or eax, 0xffffffff
mov edx, dword [ebp - 0x10]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x42e558
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [esi + 0x24]
test ecx, ecx
je 0x42e578
mov eax, dword [ecx]
push 1
call dword [eax + 0x18]
mov ecx, dword [esi + 0x24]
test ecx, ecx
je 0x42e578
mov eax, dword [ecx]
mov eax, dword [eax + 0x1c]
call eax
test al, al
jne 0x42e582
inc edi
cmp edi, dword [esi + 0x10]
jl 0x42e3e0
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 1
push 0xc000008c
call fcn.004036b0
push 0x80004005
call fcn.004023a0
push 0x80004005
call fcn.004023a0
int3