Function at 0x40cbb0
Capabilities:
Move file
Resolve function by parsing pe exports
Set file attributes
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x45331b
mov eax, dword fs:[0]
push eax
sub esp, 0x17c
mov eax, dword [0x468400]
xor eax, esp
mov dword [esp + 0x178], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x468400]
xor eax, esp
push eax
lea eax, [esp + 0x190]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x1a0]
mov eax, dword [esp + 0x1a4]
mov edi, ecx
mov ebx, 0x10
mov dword [esp + 0x30], ebp
mov dword [esp + 0x24], eax
mov dword [esp + 0x34], edi
lea esi, [edi + 4]
cmp dword [edi + 0x18], ebx
jb 0x40cc18
mov eax, dword [esi]
jmp 0x40cc1a
mov eax, esi
push eax
push 0x45bb60
mov eax, ebp
call fcn.0040c7c0
add esp, 8
lea ecx, [esp + 0x164]
push ecx
call fcn.00406120
mov dword [esp + 0x198], 0
cmp dword [edi + 0x18], ebx
jb 0x40cc4b
mov eax, dword [esi]
jmp 0x40cc4d
mov eax, esi
lea ebx, [esp + 0x164]
call fcn.00406350
test al, al
jne 0x40cc98
cmp dword [edi + 0x18], 0x10
jb 0x40cc67
mov eax, dword [esi]
jmp 0x40cc69
mov eax, esi
push eax
push 0x45bb90
mov eax, ebp
call fcn.0040c7c0
add esp, 8
lea edx, [esp + 0x164]
push edx
mov dword [esp + 0x19c], 0xffffffff
call fcn.00406200
xor al, al
jmp 0x40d833
cmp dword [ebp + 0x1a4], 0
je 0x40ccd0
mov eax, dword [ebp + 0x1a0]
mov ecx, dword [eax + 4]
lea esi, [ebp + 0x188]
push ecx
mov ecx, esi
call fcn.0040e6e0
mov eax, dword [esi + 0x18]
mov dword [eax + 4], eax
mov eax, dword [esi + 0x18]
mov dword [esi + 0x1c], 0
mov dword [eax], eax
mov esi, dword [esi + 0x18]
mov dword [esi + 8], esi
mov eax, dword [esp + 0x180]
mov ecx, dword [eax + 0x28]
sub ecx, dword [eax + 0x24]
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
mov esi, 1
add eax, edx
cmp eax, esi
jbe 0x40cd64
mov ebx, dword [esp + 0x30]
add ebx, 0x188
push str.fileID
push esi
lea ecx, [esp + 0x16c]
push ecx
call fcn.004065b0
cmp byte [eax], 0
je 0x40cd24
push eax
call fcn.00437aa5
add esp, 4
jmp 0x40cd26
xor eax, eax
lea edx, [esp + 0x28]
mov dword [esp + 0x28], eax
push edx
lea eax, [esp + 0x11c]
push eax
mov byte [esp + 0x34], 1
call fcn.0040ddd0
mov eax, dword [esp + 0x180]
mov ecx, dword [eax + 0x28]
sub ecx, dword [eax + 0x24]
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov ecx, edx
shr ecx, 0x1f
inc esi
add ecx, edx
cmp esi, ecx
jb 0x40cd01
mov edx, dword [esp + 0x24]
mov ebp, dword [esp + 0x30]
push edx
lea esi, [ebp + 0x168]
push ebp
call fcn.0040ca60
test al, al
jne 0x40cd9c
lea eax, [esp + 0x164]
push eax
mov dword [esp + 0x19c], 0xffffffff
call fcn.00406200
xor al, al
jmp 0x40d833
push 0x45bba8
mov eax, ebp
call fcn.0040c7c0
mov eax, dword [esi + 0x18]
mov eax, dword [eax]
mov edi, dword [esi]
mov ebx, eax
add esp, 4
mov byte [esp + 0x1b], 0
mov dword [esp + 0x1c], edi
mov dword [esp + 0x20], ebx
mov esi, dword [ebp + 0x180]
mov eax, dword [ebp + 0x168]
test edi, edi
je 0x40cdd5
cmp edi, eax
je 0x40cdda
call fcn.00436e91
cmp ebx, esi
je 0x40d00b
test edi, edi
jne 0x40cfcf
call fcn.00436e91
xor eax, eax
cmp ebx, dword [eax + 0x18]
jne 0x40cdfb
call fcn.00436e91
mov eax, dword [esp + 0x20]
add eax, 0xc
push eax
lea ecx, [esp + 0x128]
lea edi, [ebp + 0x148]
push ecx
mov dword [esp + 0x2c], eax
call fcn.0040dd40
mov ebx, dword [eax]
mov ebp, dword [eax + 4]
mov esi, dword [edi + 0x18]
mov edi, dword [edi]
mov dword [esp + 0x2c], ebp
test ebx, ebx
je 0x40ce30
cmp ebx, edi
je 0x40ce35
call fcn.00436e91
cmp ebp, esi
je 0x40cfb5
mov eax, dword [esp + 0x1c]
test eax, eax
jne 0x40cfd6
call fcn.00436e91
xor eax, eax
mov edx, dword [esp + 0x20]
cmp edx, dword [eax + 0x18]
jne 0x40ce5e
call fcn.00436e91
mov eax, dword [esp + 0x24]
mov ebp, dword [esp + 0x30]
push eax
lea ecx, [esp + 0x11c]
add ebp, 0x188
push ecx
mov edi, ebp
call fcn.0040df20
mov ecx, dword [eax]
mov esi, dword [eax + 4]
mov edi, dword [ebp + 0x18]
mov eax, dword [ebp]
test ecx, ecx
je 0x40ce8f
cmp ecx, eax
je 0x40ce94
call fcn.00436e91
cmp esi, edi
je 0x40cfb5
mov eax, dword [esp + 0x1c]
test eax, eax
jne 0x40cfdd
call fcn.00436e91
xor eax, eax
mov edx, dword [esp + 0x20]
cmp edx, dword [eax + 0x18]
jne 0x40cebd
call fcn.00436e91
mov eax, dword [esp + 0x20]
mov ecx, dword [eax + 0x18]
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x54], ecx
test eax, eax
jne 0x40cfe4
call fcn.00436e91
xor eax, eax
mov edx, dword [esp + 0x20]
cmp edx, dword [eax + 0x18]
jne 0x40cee9
call fcn.00436e91
mov eax, dword [esp + 0x1c]
test eax, eax
jne 0x40cfeb
call fcn.00436e91
xor eax, eax
mov ecx, dword [esp + 0x20]
cmp ecx, dword [eax + 0x18]
jne 0x40cf0a
call fcn.00436e91
mov edx, dword [esp + 0x24]
mov esi, dword [edx + 8]
mov eax, dword [esp + 0x20]
add esi, dword [eax + 0x1c]
test ebx, ebx
jne 0x40cff2
call fcn.00436e91
xor eax, eax
mov ecx, dword [esp + 0x2c]
cmp ecx, dword [eax + 0x18]
jne 0x40cf35
call fcn.00436e91
mov edx, dword [esp + 0x2c]
mov edi, dword [edx + 0x18]
test ebx, ebx
jne 0x40cff9
call fcn.00436e91
xor eax, eax
mov ecx, dword [esp + 0x2c]
cmp ecx, dword [eax + 0x18]
jne 0x40cf59
call fcn.00436e91
test ebx, ebx
jne 0x40d000
call fcn.00436e91
mov edx, dword [esp + 0x2c]
cmp edx, dword [ebx + 0x18]
jne 0x40cf74
call fcn.00436e91
cmp dword [esp + 0x54], edi
jne 0x40cf88
mov eax, dword [esp + 0x2c]
mov ecx, dword [eax + 0x14]
add ecx, dword [eax + 0x1c]
cmp esi, ecx
jbe 0x40cfb5
mov eax, dword [esp + 0x1c]
mov byte [esp + 0x1b], 1
test eax, eax
jne 0x40d007
call fcn.00436e91
xor eax, eax
mov edx, dword [esp + 0x20]
cmp edx, dword [eax + 0x18]
jne 0x40cfaa
call fcn.00436e91
mov eax, dword [esp + 0x24]
mov esi, ebp
call fcn.0040dec0
lea esi, [esp + 0x1c]
call fcn.00410bb0
mov ebx, dword [esp + 0x20]
mov edi, dword [esp + 0x1c]
mov ebp, dword [esp + 0x30]
jmp 0x40cdc1
mov eax, dword [edi]
jmp 0x40cdf1
mov eax, dword [eax]
jmp 0x40ce50
mov eax, dword [eax]
jmp 0x40ceaf
mov eax, dword [eax]
jmp 0x40cedb
mov eax, dword [eax]
jmp 0x40cefc
mov eax, dword [ebx]
jmp 0x40cf27
mov eax, dword [ebx]
jmp 0x40cf4b
mov ebx, dword [ebx]
jmp 0x40cf66
mov eax, dword [eax]
jmp 0x40cf9c
cmp byte [esp + 0x1b], 1
mov eax, ebp
jne 0x40d80c
push 0x45bbcc
call fcn.0040c7c0
mov eax, dword [esp + 0x38]
add esp, 4
push eax
mov edi, str..tmp
lea esi, [esp + 0x130]
call fcn.00408580
add esp, 4
mov byte [esp + 0x198], 1
mov eax, dword [esp + 0x130]
mov ebx, 0x10
cmp dword [esp + 0x144], ebx
jae 0x40d062
lea eax, [esp + 0x130]
push 0x45b92c
push eax
call fcn.00436b9c
mov edi, eax
xor esi, esi
add esp, 8
mov dword [esp + 0x24], edi
cmp edi, esi
je 0x40d796
push 7
push str.fileID_n
lea ecx, [esp + 0x150]
mov dword [esp + 0x168], 0xf
mov dword [esp + 0x164], esi
mov byte [esp + 0x154], 0
call fcn.00404b10
mov byte [esp + 0x198], 2
mov esi, dword [esp + 0x15c]
mov eax, dword [esp + 0x14c]
cmp dword [esp + 0x160], ebx
jae 0x40d0d3
lea eax, [esp + 0x14c]
push edi
push esi
push 1
push eax
call fcn.004387c6
add esp, 0x10
cmp eax, esi
je 0x40d192
mov ecx, dword [esp + 0x130]
cmp dword [esp + 0x144], ebx
jae 0x40d0ff
lea ecx, [esp + 0x130]
push esi
push eax
push ecx
push 0x45bc04
mov eax, ebp
call fcn.0040c7c0
push edi
call fcn.004375bd
mov ecx, dword [ebp + 8]
mov edx, dword [ebp + 4]
add esp, 0x14
xor edi, edi
push edi
push 0x69
push ecx
push edx
call dword [sym.imp.USER32.dll_PostMessageA]
cmp dword [esp + 0x160], ebx
jb 0x40d143
mov eax, dword [esp + 0x14c]
push eax
call fcn.00419a12
add esp, 4
mov esi, 0xf
mov dword [esp + 0x160], esi
mov dword [esp + 0x15c], edi
mov byte [esp + 0x14c], 0
cmp dword [esp + 0x144], ebx
jb 0x40d177
mov ecx, dword [esp + 0x130]
push ecx
call fcn.00419a12
add esp, 4
mov dword [esp + 0x144], esi
mov dword [esp + 0x140], edi
mov byte [esp + 0x130], 0
jmp 0x40cc79
mov eax, dword [ebp + 0x1a0]
mov eax, dword [eax]
mov esi, dword [ebp + 0x188]
mov edi, eax
mov dword [esp + 0x28], esi
mov dword [esp + 0x2c], edi
lea ebx, [ebx]
mov ebx, dword [ebp + 0x1a0]
mov eax, dword [ebp + 0x188]
test esi, esi
je 0x40d1c4
cmp esi, eax
je 0x40d1c9
call fcn.00436e91
cmp edi, ebx
je 0x40d5f3
lea eax, [esp + 0x74]
push eax
call fcn.00403b90
mov byte [esp + 0x198], 3
test esi, esi
jne 0x40d2b4
call fcn.00436e91
cmp edi, dword [esi + 0x18]
jne 0x40d1fa
call fcn.00436e91
mov ecx, dword [edi + 0xc]
push ecx
lea edx, [esp + 0x80]
push edx
call fcn.0040d890
mov esi, eax
push 0xa
mov ecx, esi
call fcn.0040da10
mov eax, dword [esi]
mov ecx, dword [eax + 4]
lea eax, [ecx + esi]
xor edi, edi
test byte [eax + 8], 6
jne 0x40d23c
mov eax, dword [eax + 0x28]
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0x30]
call eax
cmp eax, 0xffffffff
jne 0x40d23c
mov edi, 4
mov ecx, dword [esi]
mov ecx, dword [ecx + 4]
add ecx, esi
test edi, edi
je 0x40d25d
mov eax, dword [ecx + 8]
or eax, edi
cmp dword [ecx + 0x28], 0
jne 0x40d255
or eax, 4
push 0
push eax
call fcn.004019a0
lea ecx, [esp + 0x38]
lea eax, [esp + 0x74]
call fcn.00403cc0
mov edi, dword [eax + 0x14]
mov esi, 0x10
cmp dword [esp + 0x50], esi
jb 0x40d285
mov edx, dword [esp + 0x3c]
push edx
call fcn.00419a12
add esp, 4
lea ecx, [esp + 0xfc]
lea eax, [esp + 0x74]
mov dword [esp + 0x50], 0xf
mov dword [esp + 0x4c], 0
mov byte [esp + 0x3c], 0
call fcn.00403cc0
cmp dword [eax + 0x18], esi
jb 0x40d2bb
mov eax, dword [eax + 4]
jmp 0x40d2be
mov esi, dword [esi]
jmp 0x40d1f0
add eax, 4
mov ebx, dword [esp + 0x24]
push ebx
push edi
push 1
push eax
call fcn.004387c6
add esp, 0x10
cmp dword [esp + 0x114], 0x10
mov esi, eax
jb 0x40d2eb
mov eax, dword [esp + 0x100]
push eax
call fcn.00419a12
add esp, 4
mov dword [esp + 0x114], 0xf
mov dword [esp + 0x110], 0
mov byte [esp + 0x100], 0
cmp esi, edi
jne 0x40d44d
push 0
push 0x45aaeb
lea ecx, [esp + 0x60]
mov dword [esp + 0x78], 0xf
mov dword [esp + 0x74], 0
mov byte [esp + 0x64], 0
call fcn.00404b10
mov byte [esp + 0x198], 5
test byte [esp + 0xc0], 1
je 0x40d35a
mov ecx, dword [esp + 0x90]
mov eax, dword [ecx]
push eax
call fcn.00419a12
add esp, 4
mov edx, dword [esp + 0x90]
mov dword [edx], 0
mov eax, dword [esp + 0xa0]
mov dword [eax], 0
mov ecx, dword [esp + 0xb0]
mov dword [ecx], 0
mov edx, dword [esp + 0x94]
mov dword [edx], 0
mov eax, dword [esp + 0xa4]
mov dword [eax], 0
mov ecx, dword [esp + 0xb4]
mov dword [ecx], 0
and dword [esp + 0xc0], 0xfffffffe
cmp dword [esp + 0x70], 0x10
mov eax, dword [esp + 0x5c]
jae 0x40d3bf
lea eax, [esp + 0x5c]
mov ebx, dword [esp + 0x6c]
mov dword [esp + 0xbc], 0
test ebx, ebx
je 0x40d3df
push eax
lea esi, [esp + 0x84]
call fcn.00404e70
cmp dword [esp + 0x70], 0x10
jb 0x40d3f3
mov edx, dword [esp + 0x5c]
push edx
call fcn.00419a12
add esp, 4
lea ecx, [esp + 0xc8]
mov dword [esp + 0x70], 0xf
mov dword [esp + 0x6c], 0
mov byte [esp + 0x5c], 0
mov byte [esp + 0x198], 2
call fcn.00403c30
lea eax, [esp + 0xc8]
push eax
mov dword [esp + 0xcc], vtable.std::ios_base.0
call fcn.0044ffc6
add esp, 4
lea esi, [esp + 0x28]
call fcn.00410ca0
mov edi, dword [esp + 0x2c]
mov esi, dword [esp + 0x28]
jmp 0x40d1b0
push edi
push esi
push 0x45bc3c
mov eax, ebp
call fcn.0040c7c0
add esp, 0xc
push ebx
call fcn.004375bd
add esp, 4
push 0
push 0x45aaeb
lea ecx, [esp + 0x40]
mov dword [esp + 0x58], 0xf
mov dword [esp + 0x54], 0
mov byte [esp + 0x44], 0
call fcn.00404b10
mov byte [esp + 0x198], 4
test byte [esp + 0xc0], 1
je 0x40d4b0
mov ecx, dword [esp + 0x90]
mov eax, dword [ecx]
push eax
call fcn.00419a12
add esp, 4
mov edx, dword [esp + 0x90]
mov dword [edx], 0
mov eax, dword [esp + 0xa0]
mov dword [eax], 0
mov ecx, dword [esp + 0xb0]
mov dword [ecx], 0
mov edx, dword [esp + 0x94]
mov dword [edx], 0
mov eax, dword [esp + 0xa4]
mov dword [eax], 0
mov ecx, dword [esp + 0xb4]
mov dword [ecx], 0
and dword [esp + 0xc0], 0xfffffffe
cmp dword [esp + 0x50], 0x10
mov eax, dword [esp + 0x3c]
jae 0x40d515
lea eax, [esp + 0x3c]
mov ebx, dword [esp + 0x4c]
xor edi, edi
mov dword [esp + 0xbc], edi
cmp ebx, edi
je 0x40d533
push eax
lea esi, [esp + 0x84]
call fcn.00404e70
mov esi, 0x10
cmp dword [esp + 0x50], esi
jb 0x40d54b
mov edx, dword [esp + 0x3c]
push edx
call fcn.00419a12
add esp, 4
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 4]
push edi
push 0x69
push eax
push ecx
call dword [sym.imp.USER32.dll_PostMessageA]
lea ecx, [esp + 0xc8]
mov byte [esp + 0x198], 2
call fcn.00403c30
lea edx, [esp + 0xc8]
push edx
mov dword [esp + 0xcc], vtable.std::ios_base.0
call fcn.0044ffc6
add esp, 4
cmp dword [esp + 0x160], esi
jb 0x40d5a4
mov eax, dword [esp + 0x14c]
push eax
call fcn.00419a12
add esp, 4
mov ebx, 0xf
mov dword [esp + 0x160], ebx
mov dword [esp + 0x15c], edi
mov byte [esp + 0x14c], 0
cmp dword [esp + 0x144], esi
jb 0x40d5d8
mov ecx, dword [esp + 0x130]
push ecx
call fcn.00419a12
add esp, 4
mov dword [esp + 0x144], ebx
mov dword [esp + 0x140], edi
mov byte [esp + 0x130], 0
jmp 0x40cc79
mov eax, dword [esp + 0x24]
push eax
call fcn.004375bd
add esp, 4
push 0x45bc74
mov eax, ebp
call fcn.0040c7c0
mov edi, dword [esp + 0x38]
mov ebx, 0x10
add esp, 4
lea esi, [edi + 4]
cmp dword [edi + 0x18], ebx
jb 0x40d624
mov eax, dword [esi]
jmp 0x40d626
mov eax, esi
push 0x80
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
cmp dword [edi + 0x18], ebx
jb 0x40d63b
mov eax, dword [esi]
jmp 0x40d63d
mov eax, esi
mov ecx, dword [esp + 0x130]
cmp dword [esp + 0x144], ebx
jae 0x40d654
lea ecx, [esp + 0x130]
push 1
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
test eax, eax
jne 0x40d71d
cmp dword [edi + 0x18], ebx
jb 0x40d66f
mov eax, dword [esi]
jmp 0x40d671
mov eax, esi
mov ecx, dword [esp + 0x130]
cmp dword [esp + 0x144], ebx
jae 0x40d688
lea ecx, [esp + 0x130]
push eax
push ecx
push 0x45bc98
mov eax, ebp
call fcn.0040c7c0
add esp, 0xc
cmp dword [esp + 0x160], ebx
jb 0x40d6b2
mov ecx, dword [esp + 0x14c]
push ecx
call fcn.00419a12
add esp, 4
xor esi, esi
mov edi, 0xf
mov dword [esp + 0x160], edi
mov dword [esp + 0x15c], esi
mov byte [esp + 0x14c], 0
cmp dword [esp + 0x144], ebx
jb 0x40d6e8
mov edx, dword [esp + 0x130]
push edx
call fcn.00419a12
add esp, 4
lea eax, [esp + 0x164]
push eax
mov dword [esp + 0x148], edi
mov dword [esp + 0x144], esi
mov byte [esp + 0x134], 0
mov dword [esp + 0x19c], 0xffffffff
call fcn.00406200
xor al, al
jmp 0x40d833
cmp dword [esp + 0x160], ebx
jb 0x40d736
mov ecx, dword [esp + 0x14c]
push ecx
call fcn.00419a12
add esp, 4
mov edi, 0xf
xor esi, esi
push 0x45bce0
mov eax, ebp
mov dword [esp + 0x164], edi
mov dword [esp + 0x160], esi
mov byte [esp + 0x150], 0
call fcn.0040c7c0
add esp, 4
cmp dword [esp + 0x144], ebx
jb 0x40d77b
mov edx, dword [esp + 0x130]
push edx
call fcn.00419a12
add esp, 4
mov dword [esp + 0x144], edi
mov dword [esp + 0x140], esi
mov byte [esp + 0x130], 0
jmp 0x40d819
mov eax, dword [esp + 0x130]
cmp dword [esp + 0x144], ebx
jae 0x40d7ad
lea eax, [esp + 0x130]
push eax
push 0x45bcc0
mov eax, ebp
call fcn.0040c7c0
add esp, 8
cmp dword [esp + 0x144], ebx
jb 0x40d7d6
mov eax, dword [esp + 0x130]
push eax
call fcn.00419a12
add esp, 4
lea ecx, [esp + 0x164]
push ecx
mov dword [esp + 0x148], 0xf
mov dword [esp + 0x144], esi
mov byte [esp + 0x134], 0
mov dword [esp + 0x19c], 0xffffffff
call fcn.00406200
xor al, al
jmp 0x40d833
push 0x45bd08
call fcn.0040c7c0
add esp, 4
lea edx, [esp + 0x164]
push edx
mov dword [esp + 0x19c], 0xffffffff
call fcn.00406200
mov al, 1
mov ecx, dword [esp + 0x190]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x178]
xor ecx, esp
call fcn.00436724
add esp, 0x188
ret 8