Function at 0x510840
Capabilities:
Delete file
Move file

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffb8
push ebx
push esi
push edi
xor edx, edx
mov dword [ebp - 0x48], edx
mov dword [ebp - 0x44], edx
mov dword [ebp - 0x40], edx
mov dword [ebp - 0x38], edx
mov dword [ebp - 0x3c], edx
mov dword [ebp - 0xc], edx
mov ebx, eax
xor eax, eax
push ebp
push 0x510b59
push dword fs:[eax]
mov dword fs:[eax], esp
mov ecx, dword [0x581040]
mov ecx, dword [ecx]
mov dl, 1
mov eax, dword [0x4cec60]
call fcn.004860e4
mov edx, dword [0x580cb4]
mov dword [edx], eax
mov eax, dword [0x580cb4]
mov eax, dword [eax]
mov eax, dword [eax + 0x2fc]
mov edx, 0x510b70
call fcn.0046cef4
mov eax, dword [0x580cb4]
mov eax, dword [eax]
mov edx, dword [eax]
call dword [edx + 0x88]
mov eax, dword [0x580cb4]
mov eax, dword [eax]
call fcn.0048a43c
mov eax, dword [ebx + 0x390]
mov eax, dword [eax + 0x22c]
call fcn.004512c4
mov eax, dword [ebx + 0x358]
mov eax, dword [eax + 0x22c]
call fcn.004511d0
dec eax
test eax, eax
jl 0x510b22
inc eax
mov dword [ebp - 0x14], eax
mov dword [ebp - 4], 0
mov eax, dword [0x5809f4]
cmp byte [eax], 5
je 0x510b22
mov eax, dword [ebx + 0x358]
mov eax, dword [eax + 0x22c]
mov edx, dword [ebp - 4]
call fcn.00451200
call fcn.00450b5c
test al, al
je 0x510b16
mov eax, dword [ebx + 0x358]
mov eax, dword [eax + 0x22c]
mov edx, dword [ebp - 4]
call fcn.00451200
mov eax, dword [eax + 8]
lea ecx, [ebp - 0xc]
mov edx, 2
mov esi, dword [eax]
call dword [esi + 0xc]
mov eax, dword [ebx + 0x3e8]
mov edi, dword [eax + 8]
dec edi
test edi, edi
jl 0x510b16
inc edi
mov dword [ebp - 8], 0
mov eax, dword [0x5809f4]
cmp byte [eax], 5
je 0x510b16
mov edx, dword [ebp - 8]
mov eax, dword [ebx + 0x3e8]
call fcn.0041ad3c
mov esi, eax
lea edx, [ebp - 0x3c]
mov eax, dword [esi + 4]
call fcn.00409bcc
mov eax, dword [ebp - 0x3c]
lea edx, [ebp - 0x38]
call fcn.00408e80
mov edx, dword [ebp - 0x38]
mov eax, dword [ebp - 0xc]
call fcn.00404e2c
jne 0x510b0c
mov eax, dword [ebx + 0x390]
mov eax, dword [eax + 0x22c]
call fcn.00451168
mov dword [ebp - 0x10], eax
mov edx, dword [esi + 4]
mov eax, dword [ebp - 0x10]
call fcn.00450c08
mov eax, dword [ebx + 0x378]
mov edx, dword [eax]
call dword [edx + 0xc8]
test al, al
je 0x510a0a
mov eax, dword [esi + 4]
call fcn.00409adc
test al, al
je 0x5109f5
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 8]
mov edx, 0x510ba4
mov ecx, dword [eax]
call dword [ecx + 0x38]
jmp 0x510b0c
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 8]
mov edx, 0x510bbc
mov ecx, dword [eax]
call dword [ecx + 0x38]
jmp 0x510b0c
mov eax, dword [ebx + 0x37c]
mov edx, dword [eax]
call dword [edx + 0xc8]
test al, al
je 0x510a85
xor eax, eax
mov dword [ebp - 0x32], eax
mov dword [ebp - 0x2e], 3
lea eax, [ebp - 0x40]
mov ecx, 0x510bd4
mov edx, dword [esi + 4]
call fcn.00404d2c
mov eax, dword [ebp - 0x40]
call fcn.00404ee0
mov dword [ebp - 0x2a], eax
xor eax, eax
mov dword [ebp - 0x26], eax
mov word [ebp - 0x22], 0x450
lea eax, [ebp - 0x32]
push eax
call sub.shell32.dll_SHFileOperationA
test eax, eax
jne 0x510a70
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 8]
mov edx, 0x510ba4
mov ecx, dword [eax]
call dword [ecx + 0x38]
jmp 0x510b0c
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 8]
mov edx, 0x510bbc
mov ecx, dword [eax]
call dword [ecx + 0x38]
jmp 0x510b0c
mov eax, dword [ebx + 0x380]
mov edx, dword [eax]
call dword [edx + 0xc8]
test al, al
je 0x510b0c
xor eax, eax
mov dword [ebp - 0x32], eax
mov dword [ebp - 0x2e], 1
lea eax, [ebp - 0x44]
mov ecx, 0x510bd4
mov edx, dword [esi + 4]
call fcn.00404d2c
mov eax, dword [ebp - 0x44]
call fcn.00404ee0
mov dword [ebp - 0x2a], eax
lea edx, [ebp - 0x48]
mov eax, dword [ebx + 0x384]
call fcn.0046cec4
mov eax, dword [ebp - 0x48]
call fcn.00404ee0
mov dword [ebp - 0x26], eax
mov word [ebp - 0x22], 0x450
lea eax, [ebp - 0x32]
push eax
call sub.shell32.dll_SHFileOperationA
test eax, eax
jne 0x510afc
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 8]
mov edx, 0x510be0
mov ecx, dword [eax]
call dword [ecx + 0x38]
jmp 0x510b0c
mov eax, dword [ebp - 0x10]
mov eax, dword [eax + 8]
mov edx, 0x510bf4
mov ecx, dword [eax]
call dword [ecx + 0x38]
inc dword [ebp - 8]
dec edi
jne 0x51095e
inc dword [ebp - 4]
dec dword [ebp - 0x14]
jne 0x5108f1
mov eax, dword [0x580cb4]
mov eax, dword [eax]
call fcn.00403bec
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x510b60
lea eax, [ebp - 0x48]
call fcn.00404a20
lea eax, [ebp - 0x44]
mov edx, 4
call fcn.00404a44
lea eax, [ebp - 0xc]
call fcn.00404a20
ret