Function at 0x522988
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
mov ecx, 0x1a
push 0
push 0
dec ecx
jne 0x522990
push ecx
push ebx
xor eax, eax
push ebp
push 0x5230c1
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
mov eax, dword [eax + 0x2f4]
call fcn.00477cb4
test eax, eax
je 0x523079
xor eax, eax
push ebp
push 0x523072
push dword fs:[eax]
mov dword fs:[eax], esp
xor eax, eax
mov dword [ebp - 0x18], eax
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
mov eax, dword [eax + 0x2f4]
mov eax, dword [eax + 0x22c]
call fcn.004745d4
dec eax
test eax, eax
jl 0x522af3
inc eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 4], 0
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
mov eax, dword [eax + 0x2f4]
mov eax, dword [eax + 0x22c]
mov edx, dword [ebp - 4]
call fcn.00474604
mov dword [ebp - 0x14], eax
lea ecx, [ebp - 0xc]
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 8]
mov edx, 3
mov ebx, dword [eax]
call dword [ebx + 0xc]
cmp dword [ebp - 0xc], 0
je 0x522ae7
mov eax, dword [ebp - 0xc]
mov edx, 0x5230d8
call fcn.00404b68
je 0x522ae7
lea edx, [ebp - 0x28]
mov eax, dword [ebp - 0xc]
call fcn.0040d4c8
mov edx, dword [ebp - 0x28]
lea eax, [ebp - 0xc]
call fcn.00404804
mov eax, dword [ebp - 0xc]
call fcn.00520c3c
mov eax, dword [ebp - 0xc]
call fcn.00485768
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 1
jne 0x522ae7
lea eax, [ebp - 0x2c]
mov ecx, 0x5230e4
mov edx, dword [ebp - 0xc]
call fcn.00404a70
mov eax, dword [ebp - 0x2c]
call fcn.00409318
test al, al
je 0x522ae7
lea eax, [ebp - 0x30]
mov ecx, 0x5230e4
mov edx, dword [ebp - 0xc]
call fcn.00404a70
mov edx, dword [ebp - 0x30]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov ecx, dword [eax]
call dword [ecx + 0x68]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [eax]
call dword [edx + 0x14]
test eax, eax
jle 0x522ae7
cmp dword [ebp - 0x18], 0
jne 0x522ad1
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x18], eax
jmp 0x522ae7
mov ecx, 0x523118
mov dl, 1
mov eax, dword [0x407f94]
call fcn.0040c960
call fcn.00404148
inc dword [ebp - 4]
dec dword [ebp - 0x20]
jne 0x5229fe
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
mov eax, dword [eax + 0x2f4]
call fcn.00477cb4
cmp eax, dword [ebp - 0x18]
je 0x523064
cmp dword [ebp - 0x18], 0
je 0x522d73
lea ecx, [ebp - 0x34]
mov eax, dword [ebp - 0x18]
mov eax, dword [eax + 8]
mov edx, 3
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 0x34]
lea edx, [ebp - 0xc]
call fcn.0040d4c8
mov eax, dword [ebp + 8]
push eax
lea eax, [ebp - 0x38]
push eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x40], eax
mov byte [ebp - 0x3c], 0xb
lea edx, [ebp - 0x40]
xor ecx, ecx
mov eax, 0x523138
call fcn.00409fcc
mov eax, dword [ebp - 0x38]
mov edx, 0x52315c
call fcn.005226b0
pop ecx
lea eax, [ebp - 0x44]
mov ecx, 0x5230e4
mov edx, dword [ebp - 0xc]
call fcn.00404a70
mov edx, dword [ebp - 0x44]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov ecx, dword [eax]
call dword [ecx + 0x68]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [eax]
call dword [edx + 0x14]
dec eax
test eax, eax
jl 0x522d53
inc eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 4], 0
lea edx, [ebp - 0x4c]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
mov eax, dword [eax + 0x318]
call fcn.0040d4c8
push dword [ebp - 0x4c]
push dword [ebp - 0xc]
lea ecx, [ebp - 0x50]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
push dword [ebp - 0x50]
lea eax, [ebp - 0x48]
mov edx, 3
call fcn.00404ae4
mov eax, dword [ebp - 0x48]
lea edx, [ebp - 0x1c]
call fcn.004096d4
cmp dword [ebp - 0x1c], 0
je 0x522bf5
mov eax, dword [ebp - 0x1c]
call fcn.0040934c
lea ecx, [ebp - 0x54]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 0x54]
call fcn.00409318
test al, al
je 0x522d47
lea ecx, [ebp - 0x5c]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov ecx, dword [ebp - 0x5c]
lea eax, [ebp - 0x58]
mov edx, dword [ebp - 0xc]
call fcn.00404a70
mov eax, dword [ebp - 0x58]
call fcn.00404c1c
push eax
lea ecx, [ebp - 0x60]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 0x60]
call fcn.00404c1c
push eax
call sub.kernel32.dll_MoveFileA
test eax, eax
jne 0x522d47
mov eax, dword [ebp - 4]
dec eax
test eax, eax
jl 0x522cc7
inc eax
mov dword [ebp - 0x24], eax
mov dword [ebp - 8], 0
lea ecx, [ebp - 0x64]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 8]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 0x64]
call fcn.00404c1c
push eax
lea ecx, [ebp - 0x6c]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 8]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov ecx, dword [ebp - 0x6c]
lea eax, [ebp - 0x68]
mov edx, dword [ebp - 0xc]
call fcn.00404a70
mov eax, dword [ebp - 0x68]
call fcn.00404c1c
push eax
call sub.kernel32.dll_MoveFileA
inc dword [ebp - 8]
dec dword [ebp - 0x24]
jne 0x522c78
lea eax, [ebp - 0x70]
push eax
lea ecx, [ebp - 0x84]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 0x84]
mov dword [ebp - 0x80], eax
mov byte [ebp - 0x7c], 0xb
lea ecx, [ebp - 0x8c]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov ecx, dword [ebp - 0x8c]
lea eax, [ebp - 0x88]
mov edx, dword [ebp - 0xc]
call fcn.00404a70
mov eax, dword [ebp - 0x88]
mov dword [ebp - 0x78], eax
mov byte [ebp - 0x74], 0xb
lea edx, [ebp - 0x80]
mov ecx, 1
mov eax, 0x52316c
call fcn.00409fcc
mov ecx, dword [ebp - 0x70]
mov dl, 1
mov eax, dword [0x407f94]
call fcn.0040c960
call fcn.00404148
inc dword [ebp - 4]
dec dword [ebp - 0x20]
jne 0x522ba1
lea eax, [ebp - 0x90]
mov ecx, 0x5230e4
mov edx, dword [ebp - 0xc]
call fcn.00404a70
mov eax, dword [ebp - 0x90]
mov dl, 1
call fcn.00485234
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
mov eax, dword [eax + 0x2f4]
call fcn.00477cb4
mov eax, dword [eax + 8]
lea ecx, [ebp - 0xc]
mov edx, 3
mov ebx, dword [eax]
call dword [ebx + 0xc]
cmp dword [ebp - 0xc], 0
je 0x523064
mov eax, dword [ebp - 0xc]
mov edx, 0x5230d8
call fcn.00404b68
je 0x523064
lea edx, [ebp - 0x94]
mov eax, dword [ebp - 0xc]
call fcn.0040d4c8
mov edx, dword [ebp - 0x94]
lea eax, [ebp - 0xc]
call fcn.00404804
mov eax, dword [ebp + 8]
push eax
lea eax, [ebp - 0x98]
push eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x40], eax
mov byte [ebp - 0x3c], 0xb
lea edx, [ebp - 0x40]
xor ecx, ecx
mov eax, 0x523198
call fcn.00409fcc
mov eax, dword [ebp - 0x98]
mov edx, 0x52315c
call fcn.005226b0
pop ecx
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [eax]
call dword [edx + 0x44]
mov eax, dword [ebp + 8]
push eax
xor edx, edx
mov eax, dword [ebp - 0xc]
call fcn.0052273c
pop ecx
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [eax]
call dword [edx + 0x14]
dec eax
test eax, eax
jl 0x523040
inc eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 4], 0
lea edx, [ebp - 0x9c]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 4]
mov eax, dword [eax + 0x318]
call fcn.0040d4c8
lea eax, [ebp - 0x9c]
push eax
lea ecx, [ebp - 0xa0]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov edx, dword [ebp - 0xa0]
pop eax
call fcn.00404a2c
mov eax, dword [ebp - 0x9c]
lea edx, [ebp - 0x1c]
call fcn.004096d4
cmp dword [ebp - 0x1c], 0
je 0x522e95
mov eax, dword [ebp - 0x1c]
call fcn.0040934c
lea ecx, [ebp - 0xa4]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 0xa4]
call fcn.00409318
test al, al
je 0x522ed9
lea ecx, [ebp - 0xa8]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 0xa8]
mov dl, 1
call fcn.00485234
lea ecx, [ebp - 0xac]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 0xac]
call fcn.00404c1c
push eax
lea ecx, [ebp - 0xb4]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov ecx, dword [ebp - 0xb4]
lea eax, [ebp - 0xb0]
mov edx, dword [ebp - 0xc]
call fcn.00404a70
mov eax, dword [ebp - 0xb0]
call fcn.00404c1c
push eax
call sub.kernel32.dll_MoveFileA
test eax, eax
jne 0x523034
mov eax, dword [ebp - 4]
dec eax
test eax, eax
jl 0x522fae
inc eax
mov dword [ebp - 0x24], eax
mov dword [ebp - 8], 0
lea ecx, [ebp - 0xbc]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 8]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov ecx, dword [ebp - 0xbc]
lea eax, [ebp - 0xb8]
mov edx, dword [ebp - 0xc]
call fcn.00404a70
mov eax, dword [ebp - 0xb8]
call fcn.00404c1c
push eax
lea ecx, [ebp - 0xc0]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 8]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 0xc0]
call fcn.00404c1c
push eax
call sub.kernel32.dll_MoveFileA
inc dword [ebp - 8]
dec dword [ebp - 0x24]
jne 0x522f4d
lea eax, [ebp - 0xc4]
push eax
lea ecx, [ebp - 0xcc]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov ecx, dword [ebp - 0xcc]
lea eax, [ebp - 0xc8]
mov edx, dword [ebp - 0xc]
call fcn.00404a70
mov eax, dword [ebp - 0xc8]
mov dword [ebp - 0x80], eax
mov byte [ebp - 0x7c], 0xb
lea ecx, [ebp - 0xd0]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov edx, dword [ebp - 4]
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 0xd0]
mov dword [ebp - 0x78], eax
mov byte [ebp - 0x74], 0xb
lea edx, [ebp - 0x80]
mov ecx, 1
mov eax, 0x5231c4
call fcn.00409fcc
mov ecx, dword [ebp - 0xc4]
mov dl, 1
mov eax, dword [0x407f94]
call fcn.0040c960
call fcn.00404148
inc dword [ebp - 4]
dec dword [ebp - 0x20]
jne 0x522e3b
lea eax, [ebp - 0xd4]
mov ecx, 0x5230e4
mov edx, dword [ebp - 0xc]
call fcn.00404a70
mov edx, dword [ebp - 0xd4]
mov eax, dword [ebp + 8]
mov eax, dword [eax - 8]
mov ecx, dword [eax]
call dword [ecx + 0x74]
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x523079
ret
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x5230c8
lea eax, [ebp - 0xd4]
mov edx, 0x15
call fcn.00404790
lea eax, [ebp - 0x70]
mov edx, 0xc
call fcn.00404790
lea eax, [ebp - 0x38]
mov edx, 5
call fcn.00404790
lea eax, [ebp - 0x1c]
call fcn.0040476c
lea eax, [ebp - 0xc]
call fcn.0040476c
ret