Function at 0x50d7ec
Capabilities:
Delete file
Move file

Disassembly:
push ebp
mov ebp, esp
mov ecx, 5
push 0
push 0
dec ecx
jne 0x50d7f4
push ecx
push ebx
push esi
push edi
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x50daa4
push dword fs:[eax]
mov dword fs:[eax], esp
xor edx, edx
push ebp
push 0x50da40
push dword fs:[edx]
mov dword fs:[edx], esp
mov eax, dword [ebp - 4]
mov dword [eax + 0x68], 0
mov dword [eax + 0x6c], 0
mov eax, dword [ebp - 4]
add eax, 0x4c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x48]
call fcn.0040695c
xor ecx, ecx
mov dl, 1
mov eax, dword [0x5003ec]
call fcn.004d5de0
mov ebx, eax
mov eax, dword [ebp - 4]
mov dword [eax + 0x5c], ebx
mov byte [ebx + 0x140], 1
mov eax, ebx
mov edx, 0x2710
call fcn.004f425c
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x5c]
mov edx, dword [ebp - 4]
mov dword [eax + 0x4c], edx
mov dword [eax + 0x48], 0x50dc84
mov edx, dword [ebp - 4]
mov dword [eax + 0x44], edx
mov dword [eax + 0x40], 0x50d780
mov edx, dword [ebp - 4]
mov dword [eax + 0x15c], edx
mov dword [eax + 0x158], 0x50d72c
lea edx, [ebp - 0x10]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x44]
call fcn.00411fdc
mov eax, dword [ebp - 0x10]
call fcn.005097d4
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x48]
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x44]
lea eax, [ebp - 0x14]
call fcn.00406e30
mov eax, dword [ebp - 0x14]
call fcn.00411ce4
test al, al
je 0x50d8fc
push 1
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x4c]
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x44]
lea eax, [ebp - 0x18]
call fcn.00406e30
mov ecx, dword [ebp - 0x18]
mov dl, 1
mov eax, dword [0x42942c]
call fcn.00434a30
mov dword [ebp - 0xc], eax
jmp 0x50d927
push 0xff00
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x4c]
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x44]
lea eax, [ebp - 0x1c]
call fcn.00406e30
mov ecx, dword [ebp - 0x1c]
mov dl, 1
mov eax, dword [0x42942c]
call fcn.00434a30
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x40]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x5c]
mov ecx, dword [ebp - 0xc]
call fcn.00500a18
cmp dword [ebp - 0xc], 0
je 0x50d949
mov eax, dword [ebp - 0xc]
call fcn.00404e28
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x4c]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x48]
call fcn.00407034
je 0x50d9d1
mov eax, dword [ebp - 4]
cmp dword [eax + 0x4c], 0
je 0x50d970
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x4c]
call fcn.00507b94
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x4c]
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x44]
lea eax, [ebp - 0x20]
call fcn.00406e30
mov eax, dword [ebp - 0x20]
call fcn.004069e8
push eax
call sub.kernel32.dll_DeleteFileW
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x4c]
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x44]
lea eax, [ebp - 0x24]
call fcn.00406e30
mov eax, dword [ebp - 0x24]
call fcn.004069e8
push eax
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x48]
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x44]
lea eax, [ebp - 0x28]
call fcn.00406e30
mov eax, dword [ebp - 0x28]
call fcn.004069e8
push eax
call sub.kernel32.dll_MoveFileW
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x4c]
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x44]
lea eax, [ebp - 0x2c]
call fcn.00406e30
mov eax, dword [ebp - 0x2c]
call fcn.00507328
mov ecx, eax
mov eax, dword [ebp - 4]
cmp dword [eax + 0x6c], 0
jne 0x50da0e
cmp dword [eax + 0x68], 0
jne 0x50da0e
mov eax, ecx
cdq
mov ebx, dword [ebp - 4]
cmp edx, dword [ebx + 0x6c]
jne 0x50da0c
cmp eax, dword [ebx + 0x68]
je 0x50da31
mov eax, dword [ebp - 4]
cmp dword [eax + 0x6c], 0
jne 0x50da1b
cmp dword [eax + 0x68], 0
je 0x50da2d
mov eax, ecx
cdq
mov ecx, dword [ebp - 4]
cmp edx, dword [ecx + 0x6c]
jne 0x50da2b
cmp eax, dword [ecx + 0x68]
je 0x50da31
xor eax, eax
jmp 0x50da33
mov al, 1
mov byte [ebp - 5], al
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x50da4a
xor edx, edx
push ebp
push 0x50da7f
push dword fs:[edx]
mov dword fs:[edx], esp
cmp dword [ebp - 0xc], 0
je 0x50da66
mov eax, dword [ebp - 0xc]
call fcn.00404e28
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x5c]
test eax, eax
je 0x50da75
call fcn.00404e28
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x50da89
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x50daab
lea eax, [ebp - 0x2c]
mov edx, 8
call fcn.00406954
ret