Function at 0x40be20
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x41d771
mov eax, dword fs:[0]
push eax
sub esp, 0x35c
mov eax, dword [0x42f040]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
cmp dword [esi + 0x14], 0xf
mov eax, esi
jbe 0x40be5a
mov eax, dword [esi]
lea ecx, [ebp - 0x360]
push ecx
push eax
call dword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll__stat64i32]
add esp, 8
test eax, eax
je 0x40be76
xor al, al
jmp 0x40c24e
cmp dword [esi + 0x14], 0xf
mov eax, dword [esi + 0x10]
jbe 0x40be81
mov esi, dword [esi]
push eax
mov edx, esi
lea ecx, [ebp - 0x278]
call fcn.0040da40
add esp, 4
lea edx, [ebp - 0x278]
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x330]
call fcn.0040eda0
lea eax, [ebp - 0x318]
mov byte [ebp - 4], 1
push eax
lea ecx, [ebp - 0x230]
mov ebx, 1
call fcn.00405910
mov byte [ebp - 4], 2
lea eax, [ebp - 0x230]
mov esi, dword [ebp - 0x21c]
mov edx, 0x5c
mov ecx, dword [ebp - 0x220]
cmp esi, 7
mov dword [ebp - 0x364], ecx
cmova eax, dword [ebp - 0x230]
cmp dx, word [eax + ecx*2 - 2]
je 0x40bf19
push 0x428e30
lea ecx, [ebp - 0x230]
call fcn.00405830
mov ecx, dword [ebp - 0x220]
mov esi, dword [ebp - 0x21c]
mov dword [ebp - 0x364], ecx
cmp dword [ebp - 0x2d4], 7
lea edx, [ebp - 0x2e8]
mov edi, dword [ebp - 0x2d8]
cmova edx, dword [ebp - 0x2e8]
sub esi, ecx
cmp edi, esi
ja 0x40bf77
cmp dword [ebp - 0x21c], 7
lea eax, [ecx + edi]
lea esi, [ebp - 0x230]
mov dword [ebp - 0x220], eax
cmova esi, dword [ebp - 0x230]
lea eax, [edi + edi]
push eax
push edx
lea ecx, [esi + ecx*2]
push ecx
call sub.VCRUNTIME140.dll_memmove
mov eax, dword [ebp - 0x364]
add esp, 0xc
add eax, edi
xor ecx, ecx
mov word [esi + eax*2], cx
jmp 0x40bf8b
push edi
push edx
push dword [ebp - 0x364]
lea ecx, [ebp - 0x230]
push edi
call fcn.00406070
push 0x428e34
lea ecx, [ebp - 0x230]
call fcn.00405830
cmp dword [ebp - 0x2bc], 7
lea edx, [ebp - 0x2d0]
mov ecx, dword [ebp - 0x220]
cmova edx, dword [ebp - 0x2d0]
mov eax, dword [ebp - 0x21c]
mov edi, dword [ebp - 0x2c0]
sub eax, ecx
mov dword [ebp - 0x364], ecx
cmp edi, eax
ja 0x40c00b
cmp dword [ebp - 0x21c], 7
lea eax, [ecx + edi]
lea esi, [ebp - 0x230]
mov dword [ebp - 0x220], eax
cmova esi, dword [ebp - 0x230]
lea eax, [edi + edi]
push eax
push edx
lea ecx, [esi + ecx*2]
push ecx
call sub.VCRUNTIME140.dll_memmove
mov eax, dword [ebp - 0x364]
add esp, 0xc
add eax, edi
xor ecx, ecx
mov word [esi + eax*2], cx
jmp 0x40c01f
push edi
push edx
push dword [ebp - 0x364]
lea ecx, [ebp - 0x230]
push edi
call fcn.00406070
mov esi, dword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll__wstat64i32]
xor eax, eax
lea edi, [ebp - 0x218]
push ebx
mov ecx, 0x82
inc ebx
cmp dword [ebp - 0x21c], 7
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x230]
cmova eax, dword [ebp - 0x230]
push eax
lea eax, [ebp - 0x218]
push eax
call fcn.0040c500
add esp, 0xc
lea eax, [ebp - 0x360]
push eax
lea eax, [ebp - 0x218]
push eax
call esi
add esp, 8
test eax, eax
je 0x40c025
lea eax, [ebp - 0x218]
push 0x104
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsnlen]
push eax
lea edx, [ebp - 0x218]
lea ecx, [ebp - 0x260]
call fcn.0040d960
add esp, 0xc
mov byte [ebp - 4], 3
lea edx, [ebp - 0x330]
cmp dword [ebp - 0x31c], 7
lea ecx, [ebp - 0x248]
push dword [ebp - 0x320]
cmova edx, dword [ebp - 0x330]
call fcn.0040d960
add esp, 4
lea ecx, [ebp - 0x260]
cmp dword [ebp - 0x24c], 0xf
lea eax, [ebp - 0x248]
cmova ecx, dword [ebp - 0x260]
cmp dword [ebp - 0x234], 0xf
push ecx
cmova eax, dword [ebp - 0x248]
push eax
call dword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll_rename]
mov ecx, dword [ebp - 0x234]
add esp, 8
test eax, eax
sete bl
cmp ecx, 0xf
jbe 0x40c136
mov edx, dword [ebp - 0x248]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x40c12c
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40c23c
push ecx
push edx
call fcn.0041c16d
add esp, 8
mov ecx, dword [ebp - 0x24c]
mov dword [ebp - 0x238], 0
mov dword [ebp - 0x234], 0xf
mov byte [ebp - 0x248], 0
cmp ecx, 0xf
jbe 0x40c18b
mov edx, dword [ebp - 0x260]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x40c181
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40c23c
push ecx
push edx
call fcn.0041c16d
add esp, 8
mov ecx, dword [ebp - 0x21c]
mov dword [ebp - 0x250], 0
mov dword [ebp - 0x24c], 0xf
mov byte [ebp - 0x260], 0
cmp ecx, 7
jbe 0x40c1e2
mov edx, dword [ebp - 0x230]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x40c1d8
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40c23c
push ecx
push edx
call fcn.0041c16d
add esp, 8
xor eax, eax
mov dword [ebp - 0x220], 0
lea ecx, [ebp - 0x330]
mov dword [ebp - 0x21c], 7
mov word [ebp - 0x230], ax
call fcn.0040c270
mov ecx, dword [ebp - 0x264]
cmp ecx, 7
jbe 0x40c24c
mov edx, dword [ebp - 0x278]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x40c242
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x40c242
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.0041c16d
add esp, 8
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0041bed2
mov esp, ebp
pop ebp
ret