Function at 0x412040
Capabilities:
Copy file
Delete file
Get file size
Read file on windows
Write file on windows

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x4295d8
push eax
mov eax, dword [0x43ba70]
mov dword fs:[0], esp
sub esp, 0x20
push ebx
push ebp
push esi
push edi
push 0xffffffffffffffff
mov esi, ecx
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea ecx, [esp + 0x14]
push ecx
mov ecx, esi
call fcn.00412b20
mov eax, dword [eax]
push 0
push 0x80
push 3
push 0
push 7
push 0x80000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
lea ecx, [esp + 0x14]
mov ebx, eax
call sub.MFC42u.DLL_CString::CString
cmp ebx, 0xffffffff
jne 0x4120bb
mov edx, dword [0x43ba70]
push edx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x4124d9
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ecx, eax
cmp ecx, 0xffffffff
mov dword [esp + 0x14], ecx
jne 0x4120f1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ebx
mov esi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [0x43ba70]
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, esi
jmp 0x4124d9
mov eax, 0xe91ed8f5
mov dword [esp + 0x18], 0
mul ecx
mov ebp, edx
shr ebp, 0xb
lea eax, [ebp + ebp*4]
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
lea ecx, [eax + eax*8]
shl ecx, 1
sub ecx, ebp
push ecx
call sub.MFC42u.DLL_operatornew
add esp, 4
mov edi, eax
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x18]
push 0
push edx
push eax
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp eax, 1
je 0x412166
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ebx
mov esi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call sub.MFC42u.DLL_operatordelete
mov ecx, dword [0x43ba70]
add esp, 4
push ecx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, esi
jmp 0x4124d9
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
push ebp
call fcn.0041a2b0
add esp, 8
lea edx, [esp + 0x20]
mov ecx, esi
push edx
call fcn.00412b20
push str..OLD
push eax
lea eax, [esp + 0x24]
mov dword [esp + 0x40], 0
push eax
call sub.MFC42u.DLL_operator
mov ebx, dword [eax]
lea ecx, [esp + 0x10]
push ecx
mov ecx, esi
mov byte [esp + 0x3c], 1
call fcn.00412b20
mov eax, dword [eax]
push 0
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
lea ecx, [esp + 0x10]
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x1c]
mov byte [esp + 0x38], 0
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x20]
mov dword [esp + 0x38], 0xffffffff
call sub.MFC42u.DLL_CString::CString
lea edx, [esp + 0x20]
mov ecx, esi
push edx
call fcn.00412b20
mov eax, dword [eax]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea ecx, [esp + 0x20]
call sub.MFC42u.DLL_CString::CString
xor ebx, ebx
test ebp, ebp
jbe 0x412262
lea eax, [edi + 0x451]
mov dword [esp + 0x10], eax
mov ecx, dword [esp + 0x40]
mov edx, dword [esp + 0x10]
push ecx
push edx
call dword [sym.imp.MSVCRT.dll__stricmp]
add esp, 8
test eax, eax
je 0x41223c
mov ecx, dword [esp + 0x10]
inc ebx
add ecx, 0x8c9
cmp ebx, ebp
mov dword [esp + 0x10], ecx
jb 0x412210
jmp 0x412262
lea eax, [ebx + ebx*4]
mov ecx, dword [esp + 0x44]
mov edx, dword [esp + 0x48]
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
lea eax, [eax + eax*8]
shl eax, 1
sub eax, ebx
mov dword [eax + edi + 0x89d], ecx
mov dword [eax + edi + 0x8a1], edx
lea eax, [esp + 0x40]
mov ecx, esi
push eax
call fcn.00412b20
mov eax, dword [eax]
push 0
push 0x80
push 4
push 0
push 7
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
lea ecx, [esp + 0x40]
mov ebx, eax
call sub.MFC42u.DLL_CString::CString
cmp ebx, 0xffffffff
jne 0x41236e
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea ecx, [esp + 0x20]
mov ebp, eax
push ecx
mov ecx, esi
call fcn.00412b20
mov ebx, dword [eax]
lea edx, [esp + 0x44]
push edx
mov ecx, esi
mov dword [esp + 0x3c], 2
call fcn.00412b20
push str..OLD
push eax
lea eax, [esp + 0x48]
mov byte [esp + 0x40], 3
push eax
call sub.MFC42u.DLL_operator
mov eax, dword [eax]
push 0
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
lea ecx, [esp + 0x40]
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x44]
mov byte [esp + 0x38], 2
call sub.MFC42u.DLL_CString::CString
or ebx, 0xffffffff
lea ecx, [esp + 0x20]
mov dword [esp + 0x38], ebx
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x44]
push ecx
mov ecx, esi
call fcn.00412b20
push str..OLD
lea edx, [esp + 0x44]
push eax
push edx
mov dword [esp + 0x44], 4
call sub.MFC42u.DLL_operator
mov eax, dword [eax]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea ecx, [esp + 0x40]
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x44]
mov dword [esp + 0x38], ebx
call sub.MFC42u.DLL_CString::CString
push edi
call sub.MFC42u.DLL_operatordelete
mov eax, dword [0x43ba70]
add esp, 4
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, ebp
jmp 0x4124d9
push edi
push ebp
call fcn.0041a270
mov edx, dword [esp + 0x1c]
add esp, 8
lea ecx, [esp + 0x24]
mov dword [esp + 0x24], 0
push 0
push ecx
push edx
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
cmp eax, 1
je 0x412473
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ebx
mov ebp, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [esp + 0x20]
mov ecx, esi
push eax
call fcn.00412b20
mov ebx, dword [eax]
lea ecx, [esp + 0x44]
push ecx
mov ecx, esi
mov dword [esp + 0x3c], 5
call fcn.00412b20
push str..OLD
lea edx, [esp + 0x44]
push eax
push edx
mov byte [esp + 0x44], 6
call sub.MFC42u.DLL_operator
mov eax, dword [eax]
push 0
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
lea ecx, [esp + 0x40]
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x44]
mov byte [esp + 0x38], 5
call sub.MFC42u.DLL_CString::CString
or ebx, 0xffffffff
lea ecx, [esp + 0x20]
mov dword [esp + 0x38], ebx
call sub.MFC42u.DLL_CString::CString
lea eax, [esp + 0x44]
mov ecx, esi
push eax
call fcn.00412b20
push str..OLD
lea ecx, [esp + 0x44]
push eax
push ecx
mov dword [esp + 0x44], 7
call sub.MFC42u.DLL_operator
mov eax, dword [eax]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea ecx, [esp + 0x40]
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x44]
mov dword [esp + 0x38], ebx
call sub.MFC42u.DLL_CString::CString
push edi
call sub.MFC42u.DLL_operatordelete
mov edx, dword [0x43ba70]
add esp, 4
push edx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, ebp
jmp 0x4124d9
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call sub.MFC42u.DLL_operatordelete
add esp, 4
lea eax, [esp + 0x2c]
mov ecx, esi
push eax
call fcn.00412b20
push str..OLD
lea ecx, [esp + 0x2c]
push eax
push ecx
mov dword [esp + 0x44], 8
call sub.MFC42u.DLL_operator
mov eax, dword [eax]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea ecx, [esp + 0x28]
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x2c]
mov dword [esp + 0x38], 0xffffffff
call sub.MFC42u.DLL_CString::CString
mov edx, dword [0x43ba70]
push edx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
xor eax, eax
mov ecx, dword [esp + 0x30]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x2c
ret 0xc